Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5012,31 +5012,31 @@ paths:
- in: query
name: ai_service
required: false
description: Filter models by the AI service (e.g., 'openai', 'anthropic').
description: Filter models by AI service (e.g., 'openai', 'anthropic').
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor consistency: this description uses single quotes around example values ('openai', 'anthropic'), but most other parameter descriptions in this spec either omit quotes or use backticks for inline code (e.g., "AI provider organization (e.g., openai, anthropic)" at openapi.yaml:33920). Consider aligning the formatting to match the rest of the document.

Copilot uses AI. Check for mistakes.
schema:
type: string
- in: query
name: provider
required: false
description: Filter models by the provider.
description: Filter models by virtual key slug (the provider segment in model id `@provider/model`).
schema:
type: string
- in: query
name: limit
required: false
description: The maximum number of models to return.
description: Maximum number of models to return per page.
schema:
type: integer
- in: query
name: offset
required: false
description: The number of models to skip before starting to collect the result set.
description: Number of models to skip before collecting the result set.
schema:
type: integer
- in: query
name: sort
required: false
description: The field to sort the results by.
description: The field to sort the results by (`provider` sorts by virtual key slug).
schema:
type: string
enum: [name, provider, ai_service]
Expand Down Expand Up @@ -5071,13 +5071,13 @@ paths:
label: Default
source: |
# Example of sending a query parameter in the URL
curl 'https://api.portkey.ai/v1/models?provider=openai' \
curl 'https://api.portkey.ai/v1/models?ai_service=openai' \
-H "x-portkey-api-key: $PORTKEY_API_KEY"
- lang: curl
label: Self-Hosted
source: |
# Example of sending a query parameter in the URL
curl 'https://YOUR_SELF_HOSTED_URL/models?provider=openai' \
curl 'https://YOUR_SELF_HOSTED_URL/models?ai_service=openai' \
-H "x-portkey-api-key: $PORTKEY_API_KEY"
Comment on lines 5077 to 5081
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The self-hosted samples use a different placeholder (YOUR_SELF_HOSTED_URL) than the rest of the spec and the declared DataPlaneServers (SELF_HOSTED_GATEWAY_URL). Consider switching these self-hosted examples to SELF_HOSTED_GATEWAY_URL for consistency (this placeholder also appears in the adjacent Python/JS self-hosted samples at openapi.yaml:5103 and :5135).

Copilot uses AI. Check for mistakes.
- lang: python
label: Default
Expand All @@ -5090,7 +5090,7 @@ paths:

# Example of sending query parameters via extra_query
models = client.models.list(
extra_query={"provider": "openai"}
extra_query={"ai_service": "openai"}
)
print(models)
- lang: python
Expand All @@ -5105,7 +5105,7 @@ paths:

# Example of sending query parameters via extra_query
models = client.models.list(
extra_query={"provider": "openai"}
extra_query={"ai_service": "openai"}
)
print(models)
- lang: javascript
Expand All @@ -5120,7 +5120,7 @@ paths:
async function main() {
// Example of sending query parameters in the list method
const list = await client.models.list({
provider: "openai"
ai_service: "openai"
});
console.log(list);
}
Expand All @@ -5138,7 +5138,7 @@ paths:
async function main() {
// Example of sending query parameters in the list method
const list = await client.models.list({
provider: "openai"
ai_service: "openai"
});
console.log(list);
}
Expand Down
Loading