SDK Reference (BETA)TypeScript SDKOperations
CreateKeysResponse - TypeScript SDK
CreateKeysResponse type definition
The TypeScript SDK and docs are currently in beta. Report issues on GitHub.
API key created successfully
Example Usage
1 import { CreateKeysResponse } from "@openrouter/sdk/models/operations"; 2 3 let value: CreateKeysResponse = { 4 data: { 5 hash: 6 "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", 7 name: "My New API Key", 8 label: "My New API Key", 9 disabled: false, 10 limit: 50, 11 limitRemaining: 50, 12 limitReset: "monthly", 13 includeByokInLimit: true, 14 usage: 0, 15 usageDaily: 0, 16 usageWeekly: 0, 17 usageMonthly: 0, 18 byokUsage: 0, 19 byokUsageDaily: 0, 20 byokUsageWeekly: 0, 21 byokUsageMonthly: 0, 22 createdAt: "2025-08-24T10:30:00Z", 23 updatedAt: null, 24 }, 25 key: 26 "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", 27 };
Fields
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
data | operations.CreateKeysData | ✔️ | The created API key information | {"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 | string | ✔️ | The actual API key string (only shown once) | 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 |