Skip to navigation

Evaluate state with TypeSafe Jev

Evaluate a state against named questions and return TypeSafe’s answers keyed by question name. Respan removes the typesafe/ model prefix and respan_params before forwarding the request, then returns the TypeSafe JSON response unchanged.

Authenticate with your Respan key and supply a TypeSafe key through respan_params.credential_override or Respan Settings > Providers. Use the model name without typesafe/ as the override key: jev-1.13.0 for typesafe/jev-1.13.0. To use a saved key, select Use saved TypeSafe key and omit credential_override. TypeSafe does not use Respan gateway credits.

The refund example uses noul, a probability from 0 to 1. See the TypeSafe API reference for question types. Streaming is unsupported: stream: true returns HTTP 400. Retry HTTP 429 (rate limit) and 529 (overloaded) with exponential backoff.

Authentication

AuthorizationBearer

Use your Respan API key for Respan API authentication. Enter only the Respan API key value; clients send Authorization: Bearer <RESPAN_API_KEY>. For /api/responses, provider credentials such as Perplexity, OpenAI, or Azure OpenAI go in Settings -> Providers or respan_params.credential_override in the request body, not in this authentication field.

Request

This endpoint expects an object.
Enter TypeSafe API keyobjectRequired
Supply a TypeSafe API key with this request. Authenticate with your Respan key in Authorization.
OR
Use saved TypeSafe keyobjectRequired

Use a TypeSafe key saved in Respan Settings > Providers.

Response

TypeSafe evaluation result. The example is from the refund request; probabilities and token counts can vary.

modelstring
Model identifier returned by TypeSafe.
answersmap from strings to objects
Results keyed by the names supplied in questions.
usageobject

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
422
Unprocessable Entity Error
429
Too Many Requests Error