For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dashboard
User GuideDeveloper GuidesAPI Reference
User GuideDeveloper GuidesAPI Reference
    • Overview
  • Runtype API
      • GETList available models
      • GETGet grouped models
      • GETList search-capable models
      • GETList configured search providers
      • GETList model configurations
      • POSTCreate model configuration
      • PUTUpdate model configuration
      • DELDelete model configuration
      • PATCHEnable or disable model configuration
      • PATCHSet default model configuration
      • GETGet model configuration usage
      • GETList distinct models in use
Dashboard
LogoLogo
Runtype APIModel Configs

Create model configuration

POST
/v1/model-configs
POST
/v1/model-configs
$curl -X POST https://api.runtype.com/v1/model-configs \
> -H "Authorization: Bearer <token>" \
> -H "Content-Type: application/json" \
> -d '{
> "provider": "openai",
> "modelId": "gpt-4"
>}'
1{
2 "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
3 "userId": "user_987654321",
4 "organizationId": "org_123456789",
5 "provider": "openai",
6 "modelId": "gpt-4",
7 "providerKeyId": "key_abcdef123456",
8 "isEnabled": true,
9 "isDefault": false,
10 "settings": {},
11 "createdAt": "2024-06-01T12:00:00Z",
12 "updatedAt": "2024-06-01T12:00:00Z",
13 "displayName": "OpenAI GPT-4 Model Config",
14 "creator": "user_987654321",
15 "creatorDisplayName": "Jane Doe",
16 "costPer1kTokens": 0.03,
17 "inputCostPer1kTokens": 0.015,
18 "outputCostPer1kTokens": 0.015,
19 "supportsCustomKey": true,
20 "keyStatus": "platform",
21 "maxOutputTokens": 4096,
22 "supportsStreaming": true,
23 "supportedResponseFormats": [
24 "text",
25 "json"
26 ],
27 "supportsSearch": false,
28 "reasoningCapability": {
29 "supported": true,
30 "provider": "openai",
31 "supportsReasoningSummary": true,
32 "googleThinkingMode": "budget"
33 },
34 "configScope": "user"
35}
Create a new model configuration for the authenticated user.
Was this page helpful?
Previous

Update model configuration

Next
Built with

Authentication

AuthorizationBearer
API key or Clerk session token

Request

This endpoint expects an object.
providerenumRequired
modelIdstringRequired>=1 character
providerKeyIdstringOptional
settingsobjectOptionalDefaults to {}

Response

Created model configuration
idstring
userIdstring
organizationIdstring or null
providerstring
modelIdstring
providerKeyIdstring or null
isEnabledboolean
isDefaultboolean
settingsmap from strings to any
createdAtstring
updatedAtstring
displayNamestring
creatorstring
creatorDisplayNamestring or null
costPer1kTokensdouble
inputCostPer1kTokensdouble
outputCostPer1kTokensdouble
supportsCustomKeyboolean
keyStatusenum
Allowed values:
maxOutputTokensdouble
supportsStreamingboolean
supportedResponseFormatslist of strings
supportsSearchboolean
reasoningCapabilityobject
configScopestring

Errors

400
Bad Request Error
401
Unauthorized Error
402
Payment Required Error
403
Forbidden Error
500
Internal Server Error