hail.sodocs
PUT
/providers/{layer}

Path Parameters

layer*Layer

Header Parameters

authorization?string|null

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Body of PUT /providers/{layer} — save and activate one provider.

A partial write. Fields you omit keep the value already saved for this (layer, provider) pair: omit api_key to edit params without resending the key, send only the params keys you want to change, and omit fallback_enabled to leave the flag as it is. The merged result is what gets validated against the layer's schema (422 on a mismatch), so a partial write can never leave an invalid config behind.

Rows are keyed by (organization, layer, provider), so writing a different provider for the same layer starts from scratch rather than inheriting the previous provider's params. On a brand-new row fallback_enabled defaults to false.

Keys are write-only: no response ever echoes one back.

Response Body

application/json

application/json

curl -X PUT "https://example.com/providers/string" \  -H "Content-Type: application/json" \  -d '{    "provider": "string"  }'
{  "layer": "llm",  "provider": "string",  "key_last4": "string",  "key_set_at": "string",  "params": {},  "fallback_enabled": true,  "is_active": true}