From fe6af72ec78033f458d2b8468af94bc8e9973987 Mon Sep 17 00:00:00 2001 From: yogasanas <124478414+yogasanas@users.noreply.github.com> Date: Sat, 18 Oct 2025 05:25:08 +0000 Subject: [PATCH] chore: update OpenAPI specification from openrouter-web --- .speakeasy/in.openapi.yaml | 643 ++++++++++++++++++++++++++++++++++++- 1 file changed, 633 insertions(+), 10 deletions(-) diff --git a/.speakeasy/in.openapi.yaml b/.speakeasy/in.openapi.yaml index 14f4c108..34b80486 100644 --- a/.speakeasy/in.openapi.yaml +++ b/.speakeasy/in.openapi.yaml @@ -30,6 +30,11 @@ components: - file_id - filename - index + example: + type: file_citation + file_id: file-abc123 + filename: research_paper.pdf + index: 0 URLCitationAnnotation: type: object properties: @@ -51,6 +56,12 @@ components: - start_index - title - url + example: + type: url_citation + start_index: 0 + end_index: 42 + title: OpenRouter Documentation + url: https://openrouter.ai/docs FilePathAnnotation: type: object properties: @@ -66,6 +77,10 @@ components: - type - file_id - index + example: + type: file_path + file_id: file-xyz789 + index: 0 OutputTextContent: type: object properties: @@ -85,6 +100,15 @@ components: required: - type - text + example: + type: output_text + text: The capital of France is Paris. + annotations: + - type: url_citation + start_index: 0 + end_index: 42 + title: Paris - Wikipedia + url: https://en.wikipedia.org/wiki/Paris RefusalContent: type: object properties: @@ -97,6 +121,9 @@ components: required: - type - refusal + example: + type: refusal + refusal: I'm sorry, I cannot assist with that request OutputMessage: type: object properties: @@ -133,6 +160,14 @@ components: - type - status - content + example: + id: msg-abc123 + role: assistant + type: message + status: completed + content: + - type: output_text + text: Hello! How can I help you today? ReasoningTextContent: type: object properties: @@ -145,6 +180,9 @@ components: required: - type - text + example: + type: reasoning_text + text: Let me think step by step about this problem... ReasoningSummaryText: type: object properties: @@ -157,6 +195,9 @@ components: required: - type - text + example: + type: summary_text + text: Analyzed the problem using first principles OutputItemReasoning: type: object properties: @@ -181,6 +222,12 @@ components: - type - id - summary + example: + type: reasoning + id: reasoning-abc123 + summary: + - type: summary_text + text: Analyzed the problem using first principles OutputItemFunctionCall: type: object properties: @@ -201,6 +248,12 @@ components: - name - arguments - call_id + example: + type: function_call + id: call-abc123 + name: get_weather + arguments: '{"location":"San Francisco","unit":"celsius"}' + call_id: call-abc123 WebSearchStatus: type: string enum: @@ -208,6 +261,7 @@ components: - searching - in_progress - failed + example: completed OutputItemWebSearchCall: type: object properties: @@ -223,6 +277,10 @@ components: - type - id - status + example: + type: web_search_call + id: search-abc123 + status: completed OutputItemFileSearchCall: type: object properties: @@ -243,6 +301,13 @@ components: - id - queries - status + example: + type: file_search_call + id: filesearch-abc123 + queries: + - machine learning algorithms + - neural networks + status: completed ImageGenerationStatus: type: string enum: @@ -250,6 +315,7 @@ components: - completed - generating - failed + example: completed OutputItemImageGenerationCall: type: object properties: @@ -269,33 +335,82 @@ components: - id - result - status + example: + type: image_generation_call + id: imagegen-abc123 + result: iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg== + status: completed ResponsesOutputItem: anyOf: - allOf: - $ref: '#/components/schemas/OutputMessage' - type: object properties: {} + example: + id: msg-abc123 + role: assistant + type: message + status: completed + content: + - type: output_text + text: Hello! How can I help you today? - allOf: - $ref: '#/components/schemas/OutputItemReasoning' - type: object properties: {} + example: + type: reasoning + id: reasoning-abc123 + summary: + - type: summary_text + text: Analyzed the problem using first principles - allOf: - $ref: '#/components/schemas/OutputItemFunctionCall' - type: object properties: {} + example: + type: function_call + id: call-abc123 + name: get_weather + arguments: '{"location":"San Francisco","unit":"celsius"}' + call_id: call-abc123 - allOf: - $ref: '#/components/schemas/OutputItemWebSearchCall' - type: object properties: {} + example: + type: web_search_call + id: search-abc123 + status: completed - allOf: - $ref: '#/components/schemas/OutputItemFileSearchCall' - type: object properties: {} + example: + type: file_search_call + id: filesearch-abc123 + queries: + - machine learning algorithms + - neural networks + status: completed - allOf: - $ref: '#/components/schemas/OutputItemImageGenerationCall' - type: object properties: {} + example: + type: image_generation_call + id: imagegen-abc123 + result: iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg== + status: completed description: An output item from the response + example: + id: msg-abc123 + role: assistant + type: message + status: completed + content: + - type: output_text + text: Hello! How can I help you today? ResponsesErrorField: type: object nullable: true @@ -312,6 +427,9 @@ components: - code - message description: Error information returned from the API + example: + code: rate_limit_exceeded + message: Rate limit exceeded. Please try again later. ResponsesUsage: type: object properties: @@ -362,6 +480,15 @@ components: - output_tokens_details - total_tokens description: Token usage information for the response + example: + input_tokens: 10 + output_tokens: 25 + total_tokens: 35 + input_tokens_details: + cached_tokens: 0 + output_tokens_details: + reasoning_tokens: 0 + cost: 0.0012 OpenResponsesReasoning: allOf: - $ref: '#/components/schemas/OutputItemReasoning' @@ -539,6 +666,7 @@ components: - in_progress - completed - incomplete + example: completed OpenResponsesFunctionToolCall: type: object properties: @@ -608,26 +736,62 @@ components: - $ref: '#/components/schemas/OutputMessage' - type: object properties: {} + example: + id: msg-abc123 + role: assistant + type: message + status: completed + content: + - type: output_text + text: Hello! How can I help you today? - allOf: - $ref: '#/components/schemas/OutputItemReasoning' - type: object properties: {} + example: + type: reasoning + id: reasoning-abc123 + summary: + - type: summary_text + text: Analyzed the problem using first principles - allOf: - $ref: '#/components/schemas/OutputItemFunctionCall' - type: object properties: {} + example: + type: function_call + id: call-abc123 + name: get_weather + arguments: '{"location":"San Francisco","unit":"celsius"}' + call_id: call-abc123 - allOf: - $ref: '#/components/schemas/OutputItemWebSearchCall' - type: object properties: {} + example: + type: web_search_call + id: search-abc123 + status: completed - allOf: - $ref: '#/components/schemas/OutputItemFileSearchCall' - type: object properties: {} + example: + type: file_search_call + id: filesearch-abc123 + queries: + - machine learning algorithms + - neural networks + status: completed - allOf: - $ref: '#/components/schemas/OutputItemImageGenerationCall' - type: object properties: {} + example: + type: image_generation_call + id: imagegen-abc123 + result: iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg== + status: completed description: An item in the input array for a response request example: role: user @@ -704,6 +868,7 @@ components: - medium - high description: Size of the search context for web search tools + example: medium ResponsesWebSearchUserLocation: type: object nullable: true @@ -727,6 +892,12 @@ components: required: - type description: User location information for web search + example: + type: approximate + city: San Francisco + country: USA + region: California + timezone: America/Los_Angeles OpenResponsesWebSearchPreviewTool: type: object properties: @@ -1526,11 +1697,23 @@ components: - $ref: '#/components/schemas/OutputTextContent' - type: object properties: {} + example: + type: output_text + text: The capital of France is Paris. + annotations: + - type: url_citation + start_index: 0 + end_index: 42 + title: Paris - Wikipedia + url: https://en.wikipedia.org/wiki/Paris OpenResponsesRefusalContent: allOf: - $ref: '#/components/schemas/RefusalContent' - type: object properties: {} + example: + type: refusal + refusal: I'm sorry, I cannot assist with that request OpenResponsesContentPartAddedEvent: type: object properties: @@ -2102,6 +2285,11 @@ components: - item_id - output_index - sequence_number + example: + type: response.image_generation_call.in_progress + item_id: item-abc123 + output_index: 0 + sequence_number: 1 OpenResponsesImageGenCallGenerating: type: object properties: @@ -2120,6 +2308,11 @@ components: - item_id - output_index - sequence_number + example: + type: response.image_generation_call.generating + item_id: item-abc123 + output_index: 0 + sequence_number: 2 OpenResponsesImageGenCallPartialImage: type: object properties: @@ -2144,6 +2337,13 @@ components: - sequence_number - partial_image_b64 - partial_image_index + example: + type: response.image_generation_call.partial_image + item_id: item-abc123 + output_index: 0 + sequence_number: 3 + partial_image_b64: iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJ + partial_image_index: 0 OpenResponsesImageGenCallCompleted: type: object properties: @@ -2162,6 +2362,11 @@ components: - item_id - output_index - sequence_number + example: + type: response.image_generation_call.completed + item_id: item-abc123 + output_index: 0 + sequence_number: 4 OpenResponsesStreamEvent: oneOf: - allOf: @@ -2556,19 +2761,61 @@ components: - $ref: '#/components/schemas/OpenResponsesImageGenCallInProgress' - type: object properties: {} + example: + type: response.image_generation_call.in_progress + item_id: item-abc123 + output_index: 0 + sequence_number: 1 - allOf: - $ref: '#/components/schemas/OpenResponsesImageGenCallGenerating' - type: object properties: {} + example: + type: response.image_generation_call.generating + item_id: item-abc123 + output_index: 0 + sequence_number: 2 - allOf: - $ref: '#/components/schemas/OpenResponsesImageGenCallPartialImage' - type: object properties: {} + example: + type: response.image_generation_call.partial_image + item_id: item-abc123 + output_index: 0 + sequence_number: 3 + partial_image_b64: iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJ + partial_image_index: 0 - allOf: - $ref: '#/components/schemas/OpenResponsesImageGenCallCompleted' - type: object properties: {} + example: + type: response.image_generation_call.completed + item_id: item-abc123 + output_index: 0 + sequence_number: 4 description: Union of all possible event types emitted during response streaming + example: + type: response.created + response: + id: resp-abc123 + object: response + created_at: 1704067200 + model: gpt-4 + status: in_progress + output: [] + tools: [] + tool_choice: auto + parallel_tool_calls: true + error: null + incomplete_details: null + metadata: null + instructions: null + temperature: null + top_p: null + max_output_tokens: null + sequence_number: 0 ErrorResponse: type: object properties: @@ -2664,6 +2911,14 @@ components: required: - error description: Error response + example: + error: + code: 400 + message: Invalid request parameters + metadata: + field: temperature + reason: Must be between 0 and 2 + user_id: user-abc123 OpenResponsesIncludable: type: string enum: @@ -2683,12 +2938,14 @@ components: - flex - priority - scale + example: auto OpenResponsesTruncation: type: string nullable: true enum: - auto - disabled + example: auto DataCollection: type: string nullable: true @@ -2702,6 +2959,7 @@ components: - allow: (default) allow providers which store user data non-transiently and may train on it - deny: use only providers which do not collect user data. + example: deny ProviderName: type: string enum: @@ -2790,6 +3048,7 @@ components: - xAI - Z.AI - FakeProvider + example: OpenAI Quantization: type: string enum: @@ -2802,6 +3061,7 @@ components: - bf16 - fp32 - unknown + example: fp16 ProviderSort: type: string nullable: true @@ -2812,6 +3072,7 @@ components: description: >- The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed. + example: price OpenResponsesRequest: type: object properties: @@ -3130,6 +3391,18 @@ components: - prompt_tokens - completion_tokens - reasoning_tokens + example: + date: '2025-08-24' + model: openai/gpt-4.1 + model_permaslug: openai/gpt-4.1-2025-04-14 + endpoint_id: 550e8400-e29b-41d4-a716-446655440000 + provider_name: OpenAI + usage: 0.015 + byok_usage_inference: 0.012 + requests: 5 + prompt_tokens: 50 + completion_tokens: 125 + reasoning_tokens: 25 ModelGroup: type: string enum: @@ -3153,6 +3426,7 @@ components: - RWKV - Qwen3 description: Tokenizer type used by the model + example: GPT InstructType: type: string nullable: true @@ -3180,6 +3454,7 @@ components: - qwq - qwen3 description: Instruction format type + example: chatml InputModality: type: string enum: @@ -3187,12 +3462,14 @@ components: - image - file - audio + example: text OutputModality: type: string enum: - text - image - embeddings + example: text ModelArchitecture: type: object properties: @@ -3204,7 +3481,7 @@ components: type: string nullable: true description: Primary modality of the model - example: text + example: text->text input_modalities: type: array items: @@ -3220,6 +3497,14 @@ components: - input_modalities - output_modalities description: Model architecture information + example: + tokenizer: GPT + instruct_type: chatml + modality: text->text + input_modalities: + - text + output_modalities: + - text TopProviderInfo: type: object properties: @@ -3240,6 +3525,10 @@ components: required: - is_moderated description: Information about the top provider for this model + example: + context_length: 8192 + max_completion_tokens: 4096 + is_moderated: true Parameter: type: string enum: @@ -3266,6 +3555,7 @@ components: - reasoning - web_search_options - verbosity + example: temperature DefaultParameters: type: object nullable: true @@ -3287,6 +3577,10 @@ components: maximum: 2 additionalProperties: false description: Default parameters for this model + example: + temperature: 0.7 + top_p: 0.9 + frequency_penalty: 0 Model: type: object properties: @@ -3421,6 +3715,36 @@ components: - supported_parameters - default_parameters description: Information about an AI model available on OpenRouter + example: + id: openai/gpt-4 + canonical_slug: openai/gpt-4 + name: GPT-4 + created: 1692901234 + description: GPT-4 is a large multimodal model that can solve difficult problems with greater accuracy. + pricing: + prompt: '0.00003' + completion: '0.00006' + request: '0' + image: '0' + context_length: 8192 + architecture: + tokenizer: GPT + instruct_type: chatml + modality: text->text + input_modalities: + - text + output_modalities: + - text + top_provider: + context_length: 8192 + max_completion_tokens: 4096 + is_moderated: true + per_request_limits: null + supported_parameters: + - temperature + - top_p + - max_tokens + default_parameters: null EndpointStatus: type: integer enum: @@ -3430,6 +3754,7 @@ components: - -3 - -5 - -10 + example: 0 PublicEndpoint: type: object properties: @@ -3542,6 +3867,27 @@ components: - uptime_last_30m - supports_implicit_caching description: Information about a specific model endpoint + example: + name: 'OpenAI: GPT-4' + model_name: GPT-4 + context_length: 8192 + pricing: + prompt: '0.00003' + completion: '0.00006' + request: '0' + image: '0' + provider_name: OpenAI + tag: openai + quantization: fp16 + max_completion_tokens: 4096 + max_prompt_tokens: 8192 + supported_parameters: + - temperature + - top_p + - max_tokens + status: 0 + uptime_last_30m: 99.5 + supports_implicit_caching: true ChatMessageContentItemText: type: object properties: @@ -4513,6 +4859,19 @@ paths: description: List of activity items required: - data + example: + data: + - date: '2025-08-24' + model: openai/gpt-4.1 + model_permaslug: openai/gpt-4.1-2025-04-14 + endpoint_id: 550e8400-e29b-41d4-a716-446655440000 + provider_name: OpenAI + usage: 0.015 + byok_usage_inference: 0.012 + requests: 5 + prompt_tokens: 50 + completion_tokens: 125 + reasoning_tokens: 25 default: description: Error Response content: @@ -4540,13 +4899,24 @@ paths: properties: total_credits: type: number + description: Total credits purchased + example: 100.5 total_usage: type: number + description: Total credits used + example: 25.75 required: - total_credits - total_usage + example: + total_credits: 100.5 + total_usage: 25.75 required: - data + example: + data: + total_credits: 100.5 + total_usage: 25.75 default: description: Internal server error content: @@ -4885,6 +5255,7 @@ paths: description: Generation data required: - data + description: Generation response default: description: Error content: @@ -4915,8 +5286,13 @@ paths: required: - count description: Model count data + example: + count: 150 required: - data + example: + data: + count: 150 default: description: Error Response content: @@ -5262,12 +5638,29 @@ paths: - web_search_options - verbosity description: List of parameters supported by this model + example: + - temperature + - top_p + - max_tokens required: - model - supported_parameters description: Parameter analytics data + example: + model: openai/gpt-4 + supported_parameters: + - temperature + - top_p + - max_tokens required: - data + example: + data: + model: openai/gpt-4 + supported_parameters: + - temperature + - top_p + - max_tokens default: description: Data not found content: @@ -5322,6 +5715,12 @@ paths: - name - slug - privacy_policy_url + example: + name: OpenAI + slug: openai + privacy_policy_url: https://openai.com/privacy + terms_of_service_url: https://openai.com/terms + status_page_url: https://status.openai.com required: - data '500': @@ -5346,8 +5745,15 @@ paths: - code - message description: Error details + example: + code: 400 + message: Bad Request required: - error + example: + error: + code: 400 + message: Bad Request /keys: get: operationId: list @@ -5359,12 +5765,14 @@ paths: - schema: type: string description: Whether to include disabled API keys in the response + example: 'false' required: false name: include_disabled in: query - schema: type: string description: Number of API keys to skip for pagination + example: '0' required: false name: offset in: query @@ -5384,7 +5792,7 @@ paths: hash: type: string description: Unique hash identifier for the API key - example: sk-or-v1-abc123def456 + example: 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 name: type: string description: Name of the API key @@ -5476,9 +5884,48 @@ paths: - byok_usage_monthly - created_at - updated_at + example: + hash: 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 + name: My Production Key + label: Production API Key + disabled: false + limit: 100 + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T15:45:00Z' description: List of API keys required: - data + example: + data: + - hash: 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 + name: My Production Key + label: Production API Key + disabled: false + limit: 100 + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T15:45:00Z' default: description: Error response content: @@ -5523,6 +5970,11 @@ paths: example: true required: - name + example: + name: My New API Key + limit: 50 + limit_reset: monthly + include_byok_in_limit: true required: true responses: '201': @@ -5538,7 +5990,7 @@ paths: hash: type: string description: Unique hash identifier for the API key - example: sk-or-v1-abc123def456 + example: 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 name: type: string description: Name of the API key @@ -5631,13 +6083,53 @@ paths: - created_at - updated_at description: The created API key information + example: + hash: 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 + name: My Production Key + label: Production API Key + disabled: false + limit: 100 + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T15:45:00Z' key: type: string description: The actual API key string (only shown once) - example: sk-or-v1-abc123def456ghi789jkl012 + example: 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 required: - data - key + example: + data: + hash: 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 + name: My New API Key + label: My New API Key + disabled: false + limit: 50 + limit_remaining: 50 + limit_reset: monthly + include_byok_in_limit: true + usage: 0 + usage_daily: 0 + usage_weekly: 0 + usage_monthly: 0 + byok_usage: 0 + byok_usage_daily: 0 + byok_usage_weekly: 0 + byok_usage_monthly: 0 + created_at: '2025-08-24T10:30:00Z' + updated_at: null + key: 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 default: description: Error response content: @@ -5655,7 +6147,7 @@ paths: - schema: type: string description: The hash identifier of the API key to update - example: sk-or-v1-abc123def456 + example: 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 required: true name: hash in: path @@ -5693,6 +6185,12 @@ paths: type: boolean description: Whether to include BYOK usage in the limit example: true + example: + name: Updated API Key Name + disabled: false + limit: 75 + limit_reset: daily + include_byok_in_limit: true required: true responses: '200': @@ -5708,7 +6206,7 @@ paths: hash: type: string description: Unique hash identifier for the API key - example: sk-or-v1-abc123def456 + example: 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 name: type: string description: Name of the API key @@ -5801,8 +6299,47 @@ paths: - created_at - updated_at description: The updated API key information + example: + hash: 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 + name: My Production Key + label: Production API Key + disabled: false + limit: 100 + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T15:45:00Z' required: - data + example: + data: + hash: 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 + name: Updated API Key Name + label: Updated API Key Name + disabled: false + limit: 75 + limit_remaining: 49.5 + limit_reset: daily + include_byok_in_limit: true + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T16:00:00Z' default: description: Error response content: @@ -5819,7 +6356,7 @@ paths: - schema: type: string description: The hash identifier of the API key to delete - example: sk-or-v1-abc123def456 + example: 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 required: true name: hash in: path @@ -5838,6 +6375,8 @@ paths: example: true required: - deleted + example: + deleted: true default: description: Error response content: @@ -5855,7 +6394,7 @@ paths: - schema: type: string description: The hash identifier of the API key to retrieve - example: sk-or-v1-abc123def456 + example: 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 required: true name: hash in: path @@ -5873,7 +6412,7 @@ paths: hash: type: string description: Unique hash identifier for the API key - example: sk-or-v1-abc123def456 + example: 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 name: type: string description: Name of the API key @@ -5966,8 +6505,47 @@ paths: - created_at - updated_at description: The API key information + example: + hash: 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 + name: My Production Key + label: Production API Key + disabled: false + limit: 100 + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T15:45:00Z' required: - data + example: + data: + hash: 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 + name: My Production Key + label: Production API Key + disabled: false + limit: 100 + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + created_at: '2025-08-24T10:30:00Z' + updated_at: '2025-08-24T15:45:00Z' default: description: Error response content: @@ -5996,7 +6574,7 @@ paths: label: type: string description: Human-readable label for the API key - example: sk-or-v1-au78b3456789012345678901234567890 + example: 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 limit: type: number nullable: true @@ -6077,6 +6655,10 @@ paths: - note description: Legacy rate limit information about a key. Will always return -1. deprecated: true + example: + requests: 1000 + interval: 1h + note: This field is deprecated and safe to ignore. required: - label - limit @@ -6095,8 +6677,49 @@ paths: - include_byok_in_limit - rate_limit description: Current API key information + example: + label: sk-or-v1-au78b3456789012345678901234567890 + limit: 100 + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + is_free_tier: false + is_provisioning_key: false + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + rate_limit: + requests: 1000 + interval: 1h + note: This field is deprecated and safe to ignore. required: - data + example: + data: + label: sk-or-v1-au78b3456789012345678901234567890 + limit: 100 + usage: 25.5 + usage_daily: 25.5 + usage_weekly: 25.5 + usage_monthly: 25.5 + byok_usage: 17.38 + byok_usage_daily: 17.38 + byok_usage_weekly: 17.38 + byok_usage_monthly: 17.38 + is_free_tier: false + is_provisioning_key: false + limit_remaining: 74.5 + limit_reset: monthly + include_byok_in_limit: false + rate_limit: + requests: 1000 + interval: 1h + note: This field is deprecated and safe to ignore. default: description: Error response content: