Skip to main content
Kylon proxy calls are checked and recorded against workspace credits where applicable.

Preflight checks

Before a proxy request is sent to a provider, Kylon may check:
  • Whether the workspace has enough credits
  • Whether the request is allowed by a script-level credit policy
  • Whether the agent has access to the requested provider capability
If a credit check fails, the proxy returns 402 payment_required.

Fixed-cost endpoints

Some endpoints have fixed credit costs. Examples include:

Dynamic-cost endpoints

Some providers are accounted from returned usage:

Streaming requests

For streaming model requests, Kylon records usage after the stream completes or disconnects. If the client disconnects, the request is stopped and recorded as disconnected.

Error accounting

Failed provider requests are still recorded with status code, provider, endpoint, model when available, and a short error summary. This helps teams understand which calls are failing and why.