Skip to main content
Call a known Endpoint from your backend through the HTTP API. No Agent is required.

Call an Endpoint

Example: take an Instagram username from your app and retrieve its latest public posts.
1

Connect your backend

Base URL: https://api.glasser.ai
Header: Authorization: Bearer <your Key>
Your product’s account: use your Workspace’s Key.
Your user’s account: select that user’s Key for each request.
Store Keys on your backend. Check the connection with a free GET /v1/balance request.
2

Inspect the Endpoint once during setup

Send JSON to POST /v1/endpoints/inspect:
Get: input schema and current Price. This Endpoint requires username, an array containing one username. Inspection is free.
3

Call it from your product

Send JSON to POST /v1/runs. Use the same Authorization header, Content-Type: application/json, and a unique Idempotency-Key header for this intended execution.
Replace mkbhd with your user’s input.Get: a Run with id, status, and charge_usd. When ready, output contains up to 10 public posts with captions, like counts, and comment counts.For QUEUED or RUNNING, read that Run until it reaches a terminal state. Runs use the connected Workspace’s balance.
  • Set endpoint_version from Inspect, or omit it to use the default version. A version does not lock the Price; new Runs use the Price at admission.
  • Retry the same request with the same Idempotency-Key and input. Keep reading an unfinished Run instead of creating another one.
  • Check both status and provider_response.http_status before using output. A COMPLETED Run can still contain a Provider error.
  • Keep the Run ID and charge_usd with your product’s request record. A failed Run can still have a charge under the Endpoint’s Price.
  • Keep each user’s Key separate. Select it from their authenticated connection, not from the request’s input fields.

Browse Provider APIs

Choose an Endpoint in Data Sources, then Inspect it for its schema. You can reuse it without searching before every Run. To list Providers and Endpoints in code, use GET /public/catalog. No Key is required, and the request is free:
  • providers: Provider names, descriptions, and Endpoint counts.
  • entries: Endpoint identifiers, descriptions, categories, and display prices. Match provider to find a Provider’s Endpoints.
  • One response: the full public list, with no pagination.
The response is cached and does not apply your Key’s Policy. Use Inspect with your Key for the selected Endpoint’s input schema and current Price before running it.

Optional: Solutions

The GTM Solution offers six fixed capabilities through HTTP. Glasser handles Endpoint selection, input mapping, and fallback for supported failures. Each Capability has its own API under /v1/solutions/gtm/. Use the same Key and an Idempotency-Key header; the response is a Run. See Solutions overview for an example and the Provider selection rules.