MCPcopy Index your code
hub / github.com/codeaashu/claude-code / checkOpus1mAccess

Function checkOpus1mAccess

src/utils/model/check1mAccess.ts:46–58  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

44
45// @[MODEL LAUNCH]: Add check if the new model supports 1M context
46export function checkOpus1mAccess(): boolean {
47 if (is1mContextDisabled()) {
48 return false
49 }
50
51 if (isClaudeAISubscriber()) {
52 // Subscribers have access if extra usage is enabled for their account
53 return isExtraUsageEnabled()
54 }
55
56 // Non-subscribers (API/PAYG) have access
57 return true
58}
59
60export function checkSonnet1mAccess(): boolean {
61 if (is1mContextDisabled()) {

Callers 3

getAvailableUpgradeFunction · 0.85
getModelOptionsBaseFunction · 0.85
isOpus1mUnavailableFunction · 0.85

Calls 3

is1mContextDisabledFunction · 0.85
isExtraUsageEnabledFunction · 0.85
isClaudeAISubscriberFunction · 0.50

Tested by

no test coverage detected