Skip to content
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
namespace Soniox
{
/// <summary>
/// Example: {"api_key":"temp:WYJ67RBEFUWQXXPKYPD2UGXKWB","expires_at":"2025-02-22T22:47:37.150Z"}
/// Example: {"api_key":"snx_temp_AcsDGHvigal7tHRzzzqJI7EdJ5CFwk9C0PtXN_s_cUKJ.Oo1TyosFa7b3rgAcXA2bayqBFO7667gXROEu0mH0U4vgvlNzCqVGgTzitabbXlK7FKH-sSy0F1NKI1OOJzQaAw.YPj4oA","expires_at":"2025-02-22T22:47:37.150Z"}
/// </summary>
public sealed partial class CreateTemporaryApiKeyResponse
{
Expand Down
2 changes: 1 addition & 1 deletion src/libs/Soniox/Generated/autosdk.generated-examples.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"Slug": "create-temporary-api-key",
"Description": "Creates a short-lived API key for specific temporary use cases. The key will automatically expire after the specified duration.\n\nUse \u0060single_use\u0060 and \u0060max_session_duration_seconds\u0060 to limit how the key can be used by a client. See the [Temporary API keys guide](https://soniox.com/docs/guides/temporary-api-keys) for details.",
"Language": "csharp",
"Code": "using var client = new SonioxClient(apiKey);\n\nvar request = global::System.Text.Json.JsonSerializer.Deserialize\u003Cglobal::Soniox.CreateTemporaryApiKeyPayload\u003E(\n @\u0022{\n \u0022\u0022client_reference_id\u0022\u0022: \u0022\u0022reference_id\u0022\u0022,\n \u0022\u0022expires_in_seconds\u0022\u0022: 1800,\n \u0022\u0022max_session_duration_seconds\u0022\u0022: 120,\n \u0022\u0022single_use\u0022\u0022: true,\n \u0022\u0022usage_type\u0022\u0022: \u0022\u0022transcribe_websocket\u0022\u0022\n}\u0022)!;\n\nvar response = await client.Auth.CreateTemporaryApiKeyAsync(\n request: request\n);\n\n// Example response:\n// {\n// \u0022api_key\u0022: \u0022temp:WYJ67RBEFUWQXXPKYPD2UGXKWB\u0022,\n// \u0022expires_at\u0022: \u00222025-02-22T22:47:37.150Z\u0022\n// }",
"Code": "using var client = new SonioxClient(apiKey);\n\nvar request = global::System.Text.Json.JsonSerializer.Deserialize\u003Cglobal::Soniox.CreateTemporaryApiKeyPayload\u003E(\n @\u0022{\n \u0022\u0022client_reference_id\u0022\u0022: \u0022\u0022reference_id\u0022\u0022,\n \u0022\u0022expires_in_seconds\u0022\u0022: 1800,\n \u0022\u0022max_session_duration_seconds\u0022\u0022: 120,\n \u0022\u0022single_use\u0022\u0022: true,\n \u0022\u0022usage_type\u0022\u0022: \u0022\u0022transcribe_websocket\u0022\u0022\n}\u0022)!;\n\nvar response = await client.Auth.CreateTemporaryApiKeyAsync(\n request: request\n);\n\n// Example response:\n// {\n// \u0022api_key\u0022: \u0022snx_temp_AcsDGHvigal7tHRzzzqJI7EdJ5CFwk9C0PtXN_s_cUKJ.Oo1TyosFa7b3rgAcXA2bayqBFO7667gXROEu0mH0U4vgvlNzCqVGgTzitabbXlK7FKH-sSy0F1NKI1OOJzQaAw.YPj4oA\u0022,\n// \u0022expires_at\u0022: \u00222025-02-22T22:47:37.150Z\u0022\n// }",
"Format": "sdk",
"OperationId": "create_temporary_api_key",
"Setup": "This example assumes \u0060using Soniox;\u0060 is in scope and \u0060apiKey\u0060 contains the required credential."
Expand Down
4 changes: 2 additions & 2 deletions src/libs/Soniox/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1724,7 +1724,7 @@ paths:
schema:
$ref: '#/components/schemas/CreateTemporaryApiKeyResponse'
example:
api_key: temp:WYJ67RBEFUWQXXPKYPD2UGXKWB
api_key: snx_temp_AcsDGHvigal7tHRzzzqJI7EdJ5CFwk9C0PtXN_s_cUKJ.Oo1TyosFa7b3rgAcXA2bayqBFO7667gXROEu0mH0U4vgvlNzCqVGgTzitabbXlK7FKH-sSy0F1NKI1OOJzQaAw.YPj4oA
expires_at: '2025-02-22T22:47:37.150Z'
'400':
description: |
Expand Down Expand Up @@ -4306,7 +4306,7 @@ components:
type: object
CreateTemporaryApiKeyResponse:
example:
api_key: temp:WYJ67RBEFUWQXXPKYPD2UGXKWB
api_key: snx_temp_AcsDGHvigal7tHRzzzqJI7EdJ5CFwk9C0PtXN_s_cUKJ.Oo1TyosFa7b3rgAcXA2bayqBFO7667gXROEu0mH0U4vgvlNzCqVGgTzitabbXlK7FKH-sSy0F1NKI1OOJzQaAw.YPj4oA
expires_at: '2025-02-22T22:47:37.150Z'
properties:
api_key:
Expand Down