Skip to content
Open
Show file tree
Hide file tree
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
26 changes: 18 additions & 8 deletions .speakeasy/gen.lock
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
lockVersion: 2.0.0
id: cfd52247-6a25-4c6d-bbce-fe6fce0cd69d
management:
docChecksum: 4cc4a9d9115d0eca9a5eb4786505579d
docChecksum: df8176ff428f8885f4b799a5b5492507
docVersion: 1.0.0
speakeasyVersion: 1.658.2
generationVersion: 2.755.9
releaseVersion: 0.0.19
configChecksum: 834d5c1cea368e35ab6535ffb2bf9e7a
speakeasyVersion: 1.660.0
generationVersion: 2.760.2
releaseVersion: 0.1.0
configChecksum: 31c563db2b5251b8ce4f3716a3e31e7d
repoURL: https://github.com/OpenRouterTeam/python-sdk.git
installationURL: https://github.com/OpenRouterTeam/python-sdk.git
published: true
Expand All @@ -15,7 +15,7 @@ features:
acceptHeaders: 3.0.0
additionalDependencies: 1.0.0
constsAndDefaults: 1.0.5
core: 5.23.9
core: 5.23.10
defaultEnabledRetries: 0.2.0
deprecations: 3.0.2
devContainers: 3.0.0
Expand All @@ -27,6 +27,7 @@ features:
globalSecurityCallbacks: 1.0.0
globalSecurityFlattening: 1.0.0
globalServerURLs: 3.2.0
globals: 3.0.0
groups: 3.0.1
methodArguments: 1.0.2
methodSecurity: 3.0.1
Expand Down Expand Up @@ -67,12 +68,14 @@ generatedFiles:
- docs/components/chatmessagecontentitemaudio.md
- docs/components/chatmessagecontentitemaudioformat.md
- docs/components/chatmessagecontentitemaudioinputaudio.md
- docs/components/chatmessagecontentitemfile.md
- docs/components/chatmessagecontentitemimage.md
- docs/components/chatmessagecontentitemimagedetail.md
- docs/components/chatmessagecontentitemtext.md
- docs/components/chatmessagecontentitemvideo.md
- docs/components/chatmessagecontentitemvideoinputvideo.md
- docs/components/chatmessagecontentitemvideovideourl.md
- docs/components/chatmessagecontentitemvideovideourlvideourl.md
- docs/components/chatmessagetokenlogprob.md
- docs/components/chatmessagetokenlogprobs.md
- docs/components/chatmessagetoolcall.md
Expand Down Expand Up @@ -110,6 +113,7 @@ generatedFiles:
- docs/components/effort.md
- docs/components/endpointstatus.md
- docs/components/engine.md
- docs/components/file.md
- docs/components/filecitation.md
- docs/components/filecitationtype.md
- docs/components/filepath.md
Expand Down Expand Up @@ -416,8 +420,7 @@ generatedFiles:
- docs/components/usermessage.md
- docs/components/usermessagecontent.md
- docs/components/variables.md
- docs/components/videourl1.md
- docs/components/videourl2.md
- docs/components/videourl.md
- docs/components/websearchpreviewtooluserlocation.md
- docs/components/websearchpreviewtooluserlocationtype.md
- docs/components/websearchstatus.md
Expand All @@ -436,6 +439,7 @@ generatedFiles:
- docs/errors/toomanyrequestsresponseerror.md
- docs/errors/unauthorizedresponseerror.md
- docs/errors/unprocessableentityresponseerror.md
- docs/models/internal/globals.md
- docs/models/utils/retryconfig.md
- docs/operations/apitype.md
- docs/operations/calldata.md
Expand Down Expand Up @@ -554,6 +558,7 @@ generatedFiles:
- src/openrouter/components/chatgenerationtokenusage.py
- src/openrouter/components/chatmessagecontentitem.py
- src/openrouter/components/chatmessagecontentitemaudio.py
- src/openrouter/components/chatmessagecontentitemfile.py
- src/openrouter/components/chatmessagecontentitemimage.py
- src/openrouter/components/chatmessagecontentitemtext.py
- src/openrouter/components/chatmessagecontentitemvideo.py
Expand Down Expand Up @@ -684,6 +689,7 @@ generatedFiles:
- src/openrouter/components/unprocessableentityresponseerrordata.py
- src/openrouter/components/urlcitation.py
- src/openrouter/components/usermessage.py
- src/openrouter/components/videourl.py
- src/openrouter/components/websearchpreviewtooluserlocation.py
- src/openrouter/components/websearchstatus.py
- src/openrouter/credits.py
Expand Down Expand Up @@ -711,6 +717,9 @@ generatedFiles:
- src/openrouter/errors/unprocessableentityresponse_error.py
- src/openrouter/generations.py
- src/openrouter/httpclient.py
- src/openrouter/models/__init__.py
- src/openrouter/models/internal/__init__.py
- src/openrouter/models/internal/globals.py
- src/openrouter/models_.py
- src/openrouter/oauth.py
- src/openrouter/operations/__init__.py
Expand Down Expand Up @@ -1104,3 +1113,4 @@ examples:
"500":
application/json: {"error": {"code": "<value>", "message": "<value>"}}
examplesVersion: 1.0.2
releaseNotes: "## Python SDK Changes Detected:\n* `open_router.chat.send()`: \n * `request.messages.[].[user_message].content.[array].[].[video_url]` **Added**\n * `response.choices.[].message.content.[array].[].[video_url]` **Added**\n"
2 changes: 1 addition & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ generation:
generateNewTests: true
skipResponseBodyAssertions: false
python:
version: 0.0.19
version: 0.1.0
additionalDependencies:
dev: {}
main: {}
Expand Down
44 changes: 37 additions & 7 deletions .speakeasy/out.openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4669,12 +4669,7 @@ components:
type: string
const: input_video
video_url:
type: object
properties:
url:
type: string
required:
- url
$ref: '#/components/schemas/VideoURL'
required:
- type
- video_url
Expand All @@ -4694,12 +4689,40 @@ components:
- type
- video_url
type: object
VideoURL:
type: object
properties:
url:
type: string
required:
- url
ChatMessageContentItemFile:
type: object
properties:
type:
type: string
const: file
file:
type: object
properties:
file_data:
type: string
file_id:
type: string
filename:
type: string
required:
- file_data
required:
- type
- file
ChatMessageContentItem:
oneOf:
- $ref: '#/components/schemas/ChatMessageContentItemText'
- $ref: '#/components/schemas/ChatMessageContentItemImage'
- $ref: '#/components/schemas/ChatMessageContentItemAudio'
- $ref: '#/components/schemas/ChatMessageContentItemVideo'
- $ref: '#/components/schemas/ChatMessageContentItemFile'
type: object
discriminator:
propertyName: type
Expand All @@ -4709,6 +4732,7 @@ components:
input_audio: '#/components/schemas/ChatMessageContentItemAudio'
input_video: '#/components/schemas/ChatMessageContentItemVideo'
video_url: '#/components/schemas/ChatMessageContentItemVideo'
file: '#/components/schemas/ChatMessageContentItemFile'
ChatMessageToolCall:
type: object
properties:
Expand Down Expand Up @@ -5626,7 +5650,7 @@ components:
- model
- choices
additionalProperties: false
parameters: {}
parameters: {AppIdentifier: {name: HTTP-Referer, in: header, schema: {type: string}, description: "The app identifier should be your app's URL and is used as the primary identifier for rankings.\nThis is used to track API usage per application.\n"}, AppDisplayName: {name: X-Title, in: header, schema: {type: string}, description: "The app display name allows you to customize how your app appears in OpenRouter's dashboard.\n"}}
securitySchemes:
apiKey:
type: http
Expand Down Expand Up @@ -8385,3 +8409,9 @@ x-retry-strategy:
initialDelay: 500
maxDelay: 60000
maxAttempts: 3
x-speakeasy-globals:
parameters:
- $ref: "#/components/parameters/AppIdentifier"
- $ref: "#/components/parameters/AppDisplayName"
- $ref: "#/components/parameters/AppIdentifier"
- $ref: "#/components/parameters/AppDisplayName"
11 changes: 6 additions & 5 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
speakeasyVersion: 1.658.2
speakeasyVersion: 1.660.0
sources:
-OAS:
sourceNamespace: open-router-chat-completions-api
sourceRevisionDigest: sha256:fc0c90dc8ebb69ef4a571e4e63dcd7f8f33c3254c17ad2583b628fbbf3d1ac05
sourceBlobDigest: sha256:635d63fd18db468c1dcc23700382af788de76594ba3b8292fae9b14c0e5c22c4
sourceRevisionDigest: sha256:01256c8494de6bfc13c36d82ae316a6a13d402194f844618bcd4d59e34f325f3
sourceBlobDigest: sha256:4c80e48fd5e1cd030e68d664eb93984b4d5946867252ff1755a2bd2a05eccd4e
tags:
- latest
- speakeasy-sdk-regen-1763684529
targets:
open-router:
source: -OAS
sourceNamespace: open-router-chat-completions-api
sourceRevisionDigest: sha256:fc0c90dc8ebb69ef4a571e4e63dcd7f8f33c3254c17ad2583b628fbbf3d1ac05
sourceBlobDigest: sha256:635d63fd18db468c1dcc23700382af788de76594ba3b8292fae9b14c0e5c22c4
sourceRevisionDigest: sha256:01256c8494de6bfc13c36d82ae316a6a13d402194f844618bcd4d59e34f325f3
sourceBlobDigest: sha256:4c80e48fd5e1cd030e68d664eb93984b4d5946867252ff1755a2bd2a05eccd4e
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
Expand Down
12 changes: 11 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,14 @@ Based on:
### Generated
- [python v0.0.16] .
### Releases
- [PyPI v0.0.16] https://pypi.org/project/openrouter/0.0.16 - .
- [PyPI v0.0.16] https://pypi.org/project/openrouter/0.0.16 - .

## 2025-11-24 00:23:44
### Changes
Based on:
- OpenAPI Doc
- Speakeasy CLI 1.660.0 (2.760.2) https://github.com/speakeasy-api/speakeasy
### Generated
- [python v0.1.0] .
### Releases
- [PyPI v0.1.0] https://pypi.org/project/openrouter/0.1.0 - .
6 changes: 6 additions & 0 deletions docs/components/chatmessagecontentitem.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,9 @@ value: components.ChatMessageContentItemVideo = /* values here */
value: components.ChatMessageContentItemVideo = /* values here */
```

### `components.ChatMessageContentItemFile`

```python
value: components.ChatMessageContentItemFile = /* values here */
```

9 changes: 9 additions & 0 deletions docs/components/chatmessagecontentitemfile.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# ChatMessageContentItemFile


## Fields

| Field | Type | Required | Description |
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
| `type` | *Literal["file"]* | :heavy_check_mark: | N/A |
| `file` | [components.File](../components/file.md) | :heavy_check_mark: | N/A |
8 changes: 4 additions & 4 deletions docs/components/chatmessagecontentitemvideoinputvideo.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

## Fields

| Field | Type | Required | Description |
| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- |
| `type` | *Literal["input_video"]* | :heavy_check_mark: | N/A |
| `video_url` | [components.VideoURL1](../components/videourl1.md) | :heavy_check_mark: | N/A |
| Field | Type | Required | Description |
| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ |
| `type` | *Literal["input_video"]* | :heavy_check_mark: | N/A |
| `video_url` | [components.VideoURL](../components/videourl.md) | :heavy_check_mark: | N/A |
8 changes: 4 additions & 4 deletions docs/components/chatmessagecontentitemvideovideourl.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

## Fields

| Field | Type | Required | Description |
| -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- | -------------------------------------------------- |
| `type` | *Literal["video_url"]* | :heavy_check_mark: | N/A |
| `video_url` | [components.VideoURL2](../components/videourl2.md) | :heavy_check_mark: | N/A |
| Field | Type | Required | Description |
| ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
| `type` | *Literal["video_url"]* | :heavy_check_mark: | N/A |
| `video_url` | [components.ChatMessageContentItemVideoVideoURLVideoURL](../components/chatmessagecontentitemvideovideourlvideourl.md) | :heavy_check_mark: | N/A |
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# VideoURL2
# ChatMessageContentItemVideoVideoURLVideoURL


## Fields
Expand Down
10 changes: 10 additions & 0 deletions docs/components/file.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# File


## Fields

| Field | Type | Required | Description |
| ------------------ | ------------------ | ------------------ | ------------------ |
| `file_data` | *str* | :heavy_check_mark: | N/A |
| `file_id` | *Optional[str]* | :heavy_minus_sign: | N/A |
| `filename` | *Optional[str]* | :heavy_minus_sign: | N/A |
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# VideoURL1
# VideoURL


## Fields
Expand Down
9 changes: 9 additions & 0 deletions docs/models/internal/globals.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Globals


## Fields

| Field | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| `http_referer` | *Optional[str]* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.<br/>This is used to track API usage per application.<br/> |
| `x_title` | *Optional[str]* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.<br/> |
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "openrouter"
version = "0.0.19"
version = "0.1.0"
description = "Official Python Client SDK for OpenRouter."
authors = [{ name = "OpenRouter" },]
readme = "README-PYPI.md"
Expand Down
6 changes: 3 additions & 3 deletions src/openrouter/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
import importlib.metadata

__title__: str = "openrouter"
__version__: str = "0.0.19"
__version__: str = "0.1.0"
__openapi_doc_version__: str = "1.0.0"
__gen_version__: str = "2.755.9"
__user_agent__: str = "speakeasy-sdk/python 0.0.19 2.755.9 1.0.0 openrouter"
__gen_version__: str = "2.760.2"
__user_agent__: str = "speakeasy-sdk/python 0.1.0 2.760.2 1.0.0 openrouter"

try:
if __package__ is not None:
Expand Down
Loading