deepseek· Public API
Complete conditional rule · expand for every branch and condition
All prices, conditions and source evidence
deepseek-v4-pro
api.aisecur1ty.top · Public API declaration
Plan / group: declared-group:deepseek · deepseek
Within observation window · not a live quote
Observed as of: · Original cache limit: · Effective limit (exclusive):
Public declaration; cash qualification is not evaluated. Upstream identity, purchase eligibility and service quality are unverified.
Original pricing unit: See individual units in the complete rule · STRUCTURED_DECLARED_PRICING_RULE
Complete pricing rule; no single minimum represents this declaration. · STRUCTURED_RULE
- Input
- Not provided / unresolved
- Output
- Not provided / unresolved
- Per request
- Not provided / unresolved
- Cache read
- Not provided / unresolved
- Cache write
- Not provided / unresolved
Complete pricing rule · all branches, units and conditions
{
"branches": [
{
"components": [
{
"coefficient": "27",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "OUTPUT_BASE",
"usageVariable": "c"
},
{
"coefficient": "0.3",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "CACHE_READ",
"usageVariable": "cr"
},
{
"coefficient": "9",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "INPUT_BASE",
"usageVariable": "p"
}
],
"pathConditions": [
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"matches": true
}
],
"perRequestPrice": null,
"tierName": "peak",
"unit": "DECLARED_USD_PER_MILLION_TOKENS"
},
{
"components": [
{
"coefficient": "27",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "OUTPUT_BASE",
"usageVariable": "c"
},
{
"coefficient": "0.3",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "CACHE_READ",
"usageVariable": "cr"
},
{
"coefficient": "9",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "INPUT_BASE",
"usageVariable": "p"
}
],
"pathConditions": [
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"matches": false
},
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "14"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "18"
},
"type": "binary"
},
"type": "binary"
},
"matches": true
}
],
"perRequestPrice": null,
"tierName": "peak",
"unit": "DECLARED_USD_PER_MILLION_TOKENS"
},
{
"components": [
{
"coefficient": "13.5",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "OUTPUT_BASE",
"usageVariable": "c"
},
{
"coefficient": "0.15",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "CACHE_READ",
"usageVariable": "cr"
},
{
"coefficient": "4.5",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "INPUT_BASE",
"usageVariable": "p"
}
],
"pathConditions": [
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"matches": false
},
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "14"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "18"
},
"type": "binary"
},
"type": "binary"
},
"matches": false
}
],
"perRequestPrice": null,
"tierName": "offpeak",
"unit": "DECLARED_USD_PER_MILLION_TOKENS"
}
],
"cashQualification": "NOT_EVALUATED",
"cashQualified": false,
"conditionAST": {
"condition": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"type": "conditional",
"whenFalse": {
"condition": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "14"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "18"
},
"type": "binary"
},
"type": "binary"
},
"type": "conditional",
"whenFalse": {
"arguments": [
{
"type": "string",
"value": "offpeak"
},
{
"left": {
"left": {
"left": {
"name": "p",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "4.5"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "c",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "13.5"
},
"type": "binary"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "cr",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "0.15"
},
"type": "binary"
},
"type": "binary"
}
],
"function": "tier",
"type": "call"
},
"whenTrue": {
"arguments": [
{
"type": "string",
"value": "peak"
},
{
"left": {
"left": {
"left": {
"name": "p",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "c",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "27"
},
"type": "binary"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "cr",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "0.3"
},
"type": "binary"
},
"type": "binary"
}
],
"function": "tier",
"type": "call"
}
},
"whenTrue": {
"arguments": [
{
"type": "string",
"value": "peak"
},
{
"left": {
"left": {
"left": {
"name": "p",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "c",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "27"
},
"type": "binary"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "cr",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "0.3"
},
"type": "binary"
},
"type": "binary"
}
],
"function": "tier",
"type": "call"
}
},
"dependencies": {
"requestContext": [
{
"argument": "Asia/Shanghai",
"function": "hour"
},
{
"argument": "Asia/Shanghai",
"function": "weekday"
}
],
"taskUsageSchema": null,
"usageVariables": [
"c",
"cr",
"p"
]
},
"evidenceRefs": [
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/expr.md",
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/settle.go",
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/run.go",
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/fixed.go"
],
"expressionVersion": "v1",
"groupRatio": "0.3",
"groupRatioApplied": false,
"humanExtractionReview": "NOT_PERFORMED",
"kind": "CONDITIONAL_EXPRESSION",
"limitations": [
"DECLARED_USD_COEFFICIENTS_NOT_RECHARGE_CASH_PROOF",
"PROVIDER_DEPLOYMENT_SEMANTICS_UNVERIFIED",
"TOKEN_USAGE_NORMALIZATION_REQUIRES_UPSTREAM_USAGE_SHAPE",
"GROUP_RATIO_NOT_APPLIED",
"TOOL_SURCHARGES_AND_EXTERNAL_REQUEST_MULTIPLIERS_NOT_ESTABLISHED",
"OTHER_PRICING_FIELDS_REQUIRE_SEPARATE_REVIEW",
"CONDITIONS_RETAINED_NOT_EVALUATED_WITH_REQUEST_OR_PROVIDER_CLOCK"
],
"normalization": {
"contextLength": "len is full input context, before subclass exclusion",
"inputBase": "p excludes separately referenced input subclasses; omitted subclasses follow its base rate",
"outputBase": "c excludes separately referenced output subclasses; omitted subclasses follow its base rate",
"profile": "NEW_API_BILLINGEXPR_V1",
"referencedVariablesAreExpressionWide": true,
"upstreamUsageConvention": "Normalization depends on OpenAI or Claude usage shape; img_cr requires valid modality details"
},
"parserVersion": "grandet.new-api-expression-projection/1.1.0",
"ruleContentSha256": "b5dc4b213e9d3a23abed7583dc2a4f3fa4ab7d9acc2f0c326d08d1f1826463c8",
"schema": "grandet.public-pricing-rule/v1",
"sourceExpressionSha256": "c1126c15134d4aaace71c600fdeb26343637d5b6b1704c4d4a68269fffbea267",
"status": "SUPPORTED_PUBLIC_DECLARATION",
"units": [
"DECLARED_USD_PER_MILLION_TOKENS"
]
}Complete declared conditions
{
"balanceExpiry": {
"status": "UNKNOWN"
},
"bonusWallet": {
"status": "UNKNOWN"
},
"declaredEndpointTypes": [
"openai"
],
"declaredGroupDescription": "",
"declaredGroupRatio": "0.3",
"eligibility": {
"declaredGroup": "deepseek",
"status": "UNKNOWN"
},
"membership": {
"status": "UNKNOWN"
},
"minimumTopup": {
"status": "UNKNOWN"
},
"mixedWallet": {
"status": "UNKNOWN"
},
"nightDiscount": {
"status": "UNKNOWN"
},
"rateWindows": {
"status": "UNKNOWN"
},
"requiredFees": {
"status": "UNKNOWN"
},
"sharedAllowance": {
"status": "UNKNOWN"
},
"sourceEffectiveAt": {
"status": "UNKNOWN"
},
"tieredRates": {
"status": "UNKNOWN"
},
"topupBonus": {
"status": "UNKNOWN"
}
}Bound source freshness context
{
"cacheFreshUntil": "2026-10-10T23:40:45.228000Z",
"firstObservedAt": "2026-10-03T23:40:46.518Z",
"maximumQuoteAgeDays": 7,
"observedAt": "2026-10-03T23:40:46.518Z",
"snapshotId": "146decb8870b3d23dc4fbe1d17ab25a450ee6860635733b32307f7db4233f4b0",
"sourceId": "api.aisecur1ty.top",
"transactionId": "528aa99674d221cb6cc4797f0dd95e1bac301f77717297facd7f8f5dde99ae55"
}Complete public declaration and source identity
{
"accountEligibility": "UNVERIFIED",
"analysisDoesNotRenewObservation": true,
"attemptId": "ee243d630a1a2e544de781997e792d9d7a1bd77816685a2595b9c2fff9077f99",
"cacheReadPrice": null,
"cacheWritePrice": null,
"captureParserVersion": "grandet.new-api-public-pricing/1.4.0",
"cashQualification": "NOT_EVALUATED",
"cashQualified": false,
"classification": "STRUCTURED_PRICING_RULE",
"conditions": {
"balanceExpiry": {
"status": "UNKNOWN"
},
"bonusWallet": {
"status": "UNKNOWN"
},
"declaredEndpointTypes": [
"openai"
],
"declaredGroupDescription": "",
"declaredGroupRatio": "0.3",
"eligibility": {
"declaredGroup": "deepseek",
"status": "UNKNOWN"
},
"membership": {
"status": "UNKNOWN"
},
"minimumTopup": {
"status": "UNKNOWN"
},
"mixedWallet": {
"status": "UNKNOWN"
},
"nightDiscount": {
"status": "UNKNOWN"
},
"rateWindows": {
"status": "UNKNOWN"
},
"requiredFees": {
"status": "UNKNOWN"
},
"sharedAllowance": {
"status": "UNKNOWN"
},
"sourceEffectiveAt": {
"status": "UNKNOWN"
},
"tieredRates": {
"status": "UNKNOWN"
},
"topupBonus": {
"status": "UNKNOWN"
}
},
"declaredGroup": "deepseek",
"formulaAssurance": "DECLARED_BILLING_EXPRESSION_IMPLEMENTATION_UNVERIFIED",
"formulaProjectionBlockers": [],
"freshUntil": "2026-10-10T23:40:45.228000Z",
"humanExtractionReview": "NOT_PERFORMED",
"inputPrice": null,
"modelName": "deepseek-v4-pro",
"multimodalPricing": null,
"observedAt": "2026-10-03T23:40:46.518Z",
"outputPrice": null,
"parseRevisionId": "a8306679a3bd79b44e886e6b33a85d51320755f79a79f8d9ff35e3dde9f6a98c",
"parsedPricingDeclarations": null,
"parserFamily": "NEW_API_PUBLIC_PRICING",
"parserVersion": "grandet.new-api-public-pricing/1.5.1",
"partialPriceComponents": null,
"perRequestPrice": null,
"planId": "declared-group:deepseek",
"pricePairSourceRowId": "172d36bc2b754e4d1ee38dafaaaca0c97ecc80043082be1841619423aa6f92f8",
"pricingAdapterEvidence": [
{
"kind": "PUBLIC_PRIMARY_VENDOR_SCHEMA",
"url": "https://raw.githubusercontent.com/QuantumNous/new-api/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/model/pricing.go"
},
{
"kind": "PUBLIC_PRIMARY_USABLE_GROUP_FILTER",
"url": "https://raw.githubusercontent.com/QuantumNous/new-api/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/controller/pricing.go"
}
],
"pricingResolution": "STRUCTURED_RULE",
"pricingRule": {
"branches": [
{
"components": [
{
"coefficient": "27",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "OUTPUT_BASE",
"usageVariable": "c"
},
{
"coefficient": "0.3",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "CACHE_READ",
"usageVariable": "cr"
},
{
"coefficient": "9",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "INPUT_BASE",
"usageVariable": "p"
}
],
"pathConditions": [
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"matches": true
}
],
"perRequestPrice": null,
"tierName": "peak",
"unit": "DECLARED_USD_PER_MILLION_TOKENS"
},
{
"components": [
{
"coefficient": "27",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "OUTPUT_BASE",
"usageVariable": "c"
},
{
"coefficient": "0.3",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "CACHE_READ",
"usageVariable": "cr"
},
{
"coefficient": "9",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "INPUT_BASE",
"usageVariable": "p"
}
],
"pathConditions": [
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"matches": false
},
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "14"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "18"
},
"type": "binary"
},
"type": "binary"
},
"matches": true
}
],
"perRequestPrice": null,
"tierName": "peak",
"unit": "DECLARED_USD_PER_MILLION_TOKENS"
},
{
"components": [
{
"coefficient": "13.5",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "OUTPUT_BASE",
"usageVariable": "c"
},
{
"coefficient": "0.15",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "CACHE_READ",
"usageVariable": "cr"
},
{
"coefficient": "4.5",
"unit": "DECLARED_USD_PER_MILLION_TOKENS",
"usageKind": "INPUT_BASE",
"usageVariable": "p"
}
],
"pathConditions": [
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"matches": false
},
{
"conditionAST": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "14"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "18"
},
"type": "binary"
},
"type": "binary"
},
"matches": false
}
],
"perRequestPrice": null,
"tierName": "offpeak",
"unit": "DECLARED_USD_PER_MILLION_TOKENS"
}
],
"cashQualification": "NOT_EVALUATED",
"cashQualified": false,
"conditionAST": {
"condition": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "12"
},
"type": "binary"
},
"type": "binary"
},
"type": "conditional",
"whenFalse": {
"condition": {
"left": {
"left": {
"left": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "1"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "weekday",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "6"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": ">=",
"right": {
"type": "number",
"value": "14"
},
"type": "binary"
},
"type": "binary"
},
"operator": "&&",
"right": {
"left": {
"arguments": [
{
"type": "string",
"value": "Asia/Shanghai"
}
],
"function": "hour",
"type": "call"
},
"operator": "<",
"right": {
"type": "number",
"value": "18"
},
"type": "binary"
},
"type": "binary"
},
"type": "conditional",
"whenFalse": {
"arguments": [
{
"type": "string",
"value": "offpeak"
},
{
"left": {
"left": {
"left": {
"name": "p",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "4.5"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "c",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "13.5"
},
"type": "binary"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "cr",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "0.15"
},
"type": "binary"
},
"type": "binary"
}
],
"function": "tier",
"type": "call"
},
"whenTrue": {
"arguments": [
{
"type": "string",
"value": "peak"
},
{
"left": {
"left": {
"left": {
"name": "p",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "c",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "27"
},
"type": "binary"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "cr",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "0.3"
},
"type": "binary"
},
"type": "binary"
}
],
"function": "tier",
"type": "call"
}
},
"whenTrue": {
"arguments": [
{
"type": "string",
"value": "peak"
},
{
"left": {
"left": {
"left": {
"name": "p",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "9"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "c",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "27"
},
"type": "binary"
},
"type": "binary"
},
"operator": "+",
"right": {
"left": {
"name": "cr",
"type": "variable"
},
"operator": "*",
"right": {
"type": "number",
"value": "0.3"
},
"type": "binary"
},
"type": "binary"
}
],
"function": "tier",
"type": "call"
}
},
"dependencies": {
"requestContext": [
{
"argument": "Asia/Shanghai",
"function": "hour"
},
{
"argument": "Asia/Shanghai",
"function": "weekday"
}
],
"taskUsageSchema": null,
"usageVariables": [
"c",
"cr",
"p"
]
},
"evidenceRefs": [
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/expr.md",
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/settle.go",
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/run.go",
"https://github.com/QuantumNous/new-api/blob/1a4166d8e8ba9802d2ca56fe8ecf0ed5404e80d5/pkg/billingexpr/fixed.go"
],
"expressionVersion": "v1",
"groupRatio": "0.3",
"groupRatioApplied": false,
"humanExtractionReview": "NOT_PERFORMED",
"kind": "CONDITIONAL_EXPRESSION",
"limitations": [
"DECLARED_USD_COEFFICIENTS_NOT_RECHARGE_CASH_PROOF",
"PROVIDER_DEPLOYMENT_SEMANTICS_UNVERIFIED",
"TOKEN_USAGE_NORMALIZATION_REQUIRES_UPSTREAM_USAGE_SHAPE",
"GROUP_RATIO_NOT_APPLIED",
"TOOL_SURCHARGES_AND_EXTERNAL_REQUEST_MULTIPLIERS_NOT_ESTABLISHED",
"OTHER_PRICING_FIELDS_REQUIRE_SEPARATE_REVIEW",
"CONDITIONS_RETAINED_NOT_EVALUATED_WITH_REQUEST_OR_PROVIDER_CLOCK"
],
"normalization": {
"contextLength": "len is full input context, before subclass exclusion",
"inputBase": "p excludes separately referenced input subclasses; omitted subclasses follow its base rate",
"outputBase": "c excludes separately referenced output subclasses; omitted subclasses follow its base rate",
"profile": "NEW_API_BILLINGEXPR_V1",
"referencedVariablesAreExpressionWide": true,
"upstreamUsageConvention": "Normalization depends on OpenAI or Claude usage shape; img_cr requires valid modality details"
},
"parserVersion": "grandet.new-api-expression-projection/1.1.0",
"ruleContentSha256": "b5dc4b213e9d3a23abed7583dc2a4f3fa4ab7d9acc2f0c326d08d1f1826463c8",
"schema": "grandet.public-pricing-rule/v1",
"sourceExpressionSha256": "c1126c15134d4aaace71c600fdeb26343637d5b6b1704c4d4a68269fffbea267",
"status": "SUPPORTED_PUBLIC_DECLARATION",
"units": [
"DECLARED_USD_PER_MILLION_TOKENS"
]
},
"publicOfferingStatus": "DECLARED_IN_PUBLIC_GROUP",
"quoteId": "9581efd30185298bd7958478f15f13b2b8d451794500584062eeda93407d415c",
"quoteOrdinal": 77,
"snapshotId": "146decb8870b3d23dc4fbe1d17ab25a450ee6860635733b32307f7db4233f4b0",
"sourceDomain": "api.aisecur1ty.top",
"sourceId": "api.aisecur1ty.top",
"sourceRowId": "172d36bc2b754e4d1ee38dafaaaca0c97ecc80043082be1841619423aa6f92f8",
"transactionId": "528aa99674d221cb6cc4797f0dd95e1bac301f77717297facd7f8f5dde99ae55",
"unit": "STRUCTURED_DECLARED_PRICING_RULE"
}