Skip to main content

Execute via API

The public run endpoint is:
Every run must include a model, an input object, and optional operation parameters. Developer integrations authenticate with X-API-Key. Do not pass API keys in Authorization: Bearer; bearer tokens are for signed-in product sessions.

curl

Python

JavaScript

Validation checklist

  • model is a published model slug or identifier.
  • mode exists on the model contract.
  • input matches the model input schema.
  • params is an object, even when empty.
  • scope is present for vector-enabled modes.
  • index and search use the same scope when they should read/write the same vector dataset.

Index and search a vector model

File inputs must be uploaded before execution. Start the upload:
Upload the file bytes to the returned upload_url, then complete the upload:
Use the returned media_ref to index into a vector namespace:
Search the same indexed data by using the same scope:
Indexed data appears in Knowledge Bases as model, collection, and scope.