mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-07-29 11:23:49 +08:00
4.3 KiB
4.3 KiB
Parameters
(parameters)
Overview
Parameters endpoints
Available Operations
- get_parameters - Get a model's supported parameters and data about which are most popular
get_parameters
Get a model's supported parameters and data about which are most popular
Example Usage
from openrouter import OpenRouter, operations
import os
with OpenRouter() as open_router:
res = open_router.parameters.get_parameters(security=operations.GetParametersSecurity(
bearer=os.getenv("OPENROUTER_BEARER", ""),
), author="<value>", slug="<value>")
# Handle response
print(res)
Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
security |
operations.GetParametersSecurity | ✔️ | N/A | |
author |
str | ✔️ | N/A | |
slug |
str | ✔️ | N/A | |
provider |
Optional[components.ProviderName] | ➖ | N/A | OpenAI |
retries |
Optional[utils.RetryConfig] | ➖ | Configuration to override the default retry behavior of the client. |
Response
operations.GetParametersResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.UnauthorizedResponseError | 401 | application/json |
| errors.NotFoundResponseError | 404 | application/json |
| errors.InternalServerResponseError | 500 | application/json |
| errors.OpenRouterDefaultError | 4XX, 5XX | */* |