Example Usage
import { UpdateObservabilityDestinationRequest } from "@openrouter/sdk/models";
let value: UpdateObservabilityDestinationRequest = {};
Fields
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
apiKeyHashes | string[] | ➖ | Optional allowlist of OpenRouter API key hashes. null clears the filter (all keys). Omitting leaves the current value. Must contain at least one hash if provided. Every hash must belong to an API key in the destination’s workspace; any other hash returns 400. A hash the destination already lists is kept even if that key has since moved to another workspace, so an already-listed hash can always be written back. | null |
broadcastGenerationCost | boolean | ➖ | Whether to include cost and billing generation metadata. | false |
broadcastGenerationCostAllocation | boolean | ➖ | Beta. When true, include openrouter_cost_allocation: per-token-kind usage and cost, sent only when they reconcile with the billed cost. | false |
broadcastGenerationIdentity | boolean | ➖ | Whether to include identity generation metadata. | false |
broadcastGenerationRequestContext | boolean | ➖ | Whether to include request-context generation metadata. | false |
config | Record<string, any> | ➖ | Provider-specific configuration fields to update. Masked values are ignored; unset fields keep their current value. | { “baseUrl”: “https://us.cloud.langfuse.com”, “publicKey”: “pk-l…EfGh”, “secretKey”: “sk-l…AbCd” } |
enabled | boolean | ➖ | Whether the destination is enabled. | true |
filterRules | models.ObservabilityFilterRulesConfigNullable | ➖ | N/A | null |
name | string | ➖ | Human-readable name for the destination. | Production Langfuse |
privacyMode | boolean | ➖ | When true, request/response bodies are not forwarded — only metadata. | false |
regions | models.ObservabilityDataRegionInput[] | ➖ | Data regions this destination applies to. eu is accepted as an alias for europe and normalizes to europe. Omitting this field keeps the current value; it cannot be cleared. | [ “global” ] |
samplingRate | number | ➖ | Sampling rate between 0.0001 and 1 (1 = 100%). | 1 |