Skip to main content

HTTP API reference

Use the HTTP API when integrating EnvLoop into a service that cannot use the Python SDK. For an interactive terminal, the CLI handles authentication, output and resource commands for you.

All business jobs use /v1/job: submit with type=agent|sandbox|train|inference (default agent), and list training with ?type=train. Details and results identify job_id, with training fields under training; stop with POST /v1/job/{job_id}/stop. Retired jobs/train/sessions APIs are removed; upgrade the platform and clients together. Native protocol create_session/session_id stays inside its protocol adapter.

Addresses and authentication​

PurposeAddressAuthentication
Website and product informationhttps://envloop.aiPublic pages
Browser Consolehttps://console.envloop.aiBrowser sign-in
CLI, SDK and resource APIhttps://api.envloop.aiBearer API key
OpenAI-compatible inferencehttps://api.envloop.ai/v1/job/YOUR_JOB_ID/InferenceAuthorized project key and a ready endpoint
Compatible training SDK protocolhttps://api.envloop.ai/v1/job/tinkerProject key through TINKER_CREDENTIAL_CMD

Create a project key in the Console as described in Authentication. Set ENVLOOP_API_KEY through your shell's secret input or your service's secret manager. Never put a key into a page URL or frontend bundle.

curl --fail-with-body --silent --show-error \
https://api.envloop.ai/v1/me \
-H "Authorization: Bearer $ENVLOOP_API_KEY"

A successful response establishes who the key represents and its permitted scope. A browser session and an API key are distinct credentials. An endpoint existing in this reference does not mean every key may call it: user-only account actions require the signed-in Console, and project operations also check resource ownership and capabilities.

Workspace and project context​

The SDK sends X-Workspace-ID and X-Project-ID when configured. You can use the same headers in an HTTP integration:

curl --fail-with-body --silent --show-error \
'https://api.envloop.ai/v1/job?limit=10' \
-H "Authorization: Bearer $ENVLOOP_API_KEY" \
-H "X-Workspace-ID: $ENVLOOP_WORKSPACE_ID" \
-H "X-Project-ID: $ENVLOOP_PROJECT_ID"

Use the actual IDs from your selected context, not display names. Headers select context; they do not grant access outside the key's scope. Avoid accidentally reusing another project's environment variables. If context is omitted, use the resolved context returned by the platform rather than assuming which project was selected.

Resource map​

The following paths are relative to the resource API origin. Braced identifiers are placeholders; URL-encode ordinary ID parameters. Dataset and Profile logical names instead require unpadded base64url of their UTF-8 bytes. A name such as team/data cannot be inserted directly or merely percent-encoded; prefer SDK helpers for these names. For request bodies and validated examples, follow the linked guide or the matching SDK method. Do not guess fields from the Console's display text.

ResourceMain pathsUser workflow
Identity and current context/v1/me; browser-only context via /v1/session-contextConnect and verify identity
Jobs/v1/job, /v1/job/{job_id}, /v1/job/{job_id}/resultSubmit, inspect and stop work
Job evaluation snapshot/v1/job/{job_id}/leaderboardCompare aggregate results
Trials/v1/trials, /v1/trials/{trial_id}, /detail, /logs, /result under a TrialInspect one attempt
Trial artifacts/v1/trials/{trial_id}/artifacts, artifact content and download routesRead output files
Datasets/v1/datasets, /v1/datasets/{encoded_name}/versions, version task listsSelect a dataset revision
Profiles/v1/profiles, profile detail, versions and default selectionReuse execution parameters
Checkpoints/v1/job/checkpoints, /v1/job/checkpoints/{checkpoint_id}, …/ttl, …/visibility, /v1/job/checkpoints/copy, /v1/job/checkpoints/usage, download routesSave, inspect and recover
Serving profiles/v1/serving/profilesChoose a supported serving profile
Adapters/v1/adapters, /v1/adapters/{adapter_id}Register trained weights
Endpoints/v1/endpoints, /v1/endpoints/{endpoint_id}, endpoint events and actionsDeploy, pause and resume inference
Cleanup operations/v1/projects/{project_id}/cleanup-operations, /v1/projects/{project_id}/operations/{operation_id}, operation retryTrack asynchronous cleanup
Temporary resource scopes/v1/projects/{project_id}/temporary-resource-scopes, scope detail and retain routesKeep selected training outputs
Billing/v1/billing/account, /ledger, /prices, /usage; workspace-scoped billing routesInterpret usage and charges
Workspaces and projects/v1/workspaces, workspace project lists and project detailChoose and manage context
Membership and invitationsWorkspace members/invitations; project members/member-candidates routesManage permitted access
Project credentialsProject /api-keys and /service-accounts routesManage keys and machine identities
Project limitsProject /limits routeUnderstand resource limits

Training uses managed Jobs: discover recipes with client.training_jobs.models() and submit with client.training_jobs.submit(request). Public interactive training is removed; see migration.

Managed discovery: GET /v1/job/training-models returns configured project-scoped recipes, frozen revisions, modalities, features/limits (labels, parent checkpoint, hyperparameter ranges, loss mask, sequence length) and the request schema. A type=train Job returns the labels, effective hyperparameters and parent_checkpoint it was admitted with, and its checkpoint.path once it succeeds; see Qwen3.8-27B options. readiness=configured does not guarantee admission or GPU capacity. Removed interactive routes return 410 INTERACTIVE_TRAINING_REMOVED; Job/checkpoint/history and normal inference retain their permissions.

Read a result without creating new work​

curl --fail-with-body --silent --show-error \
"https://api.envloop.ai/v1/job/$JOB_ID/result" \
-H "Authorization: Bearer $ENVLOOP_API_KEY" \
-H "X-Workspace-ID: $ENVLOOP_WORKSPACE_ID" \
-H "X-Project-ID: $ENVLOOP_PROJECT_ID"

Record the original resource ID immediately after submission. Poll that resource with a bounded interval and deadline. A successful submission is acceptance of work; it does not establish that execution, scoring, checkpoint upload or deployment has finished. Interpret each resource's state using its guide.

For a new Job, use the supported request_id through the SDK or submission contract to recover from an uncertain network response. Reuse it only for the same intended request; a changed experiment needs a new ID. Read before retrying a write. Do not repeatedly create endpoints or training jobs while waiting for readiness.

Pagination and downloads​

List endpoints may return a continuation cursor. Preserve the original filters and pass the returned cursor to the next request; stop when the response has no continuation. A single page is not the full collection. Field names and limits are resource-specific; use the matching CLI help or SDK method rather than assuming every list has the same envelope.

For downloads, use the supported SDK/CLI helpers where possible. Signed download links expire and contain their own authorization. If your integration follows a storage redirect, do not forward the platform Bearer key or context headers to the storage host. Validate the expected file size/hash when provided, and refresh the download request if its link expires.

Handle errors​

ResponseCheck firstNext action
400 / 422Request fields, identifier format, supported optionsFix the request; repeated identical retries will not help
401Missing, expired or revoked key; wrong API originVerify the key with /v1/me and update the saved configuration
403Key capability, project role or a user-only operationUse an appropriately authorized account; context headers cannot elevate permissions
404Resource ID, project context, deletion or resource visibilityConfirm the resource in the same project before creating a replacement
409Concurrent change, state conflict or operation preconditionsRefresh the resource and apply the change to its current state
429Rate limit and any retry guidanceBack off within a bounded deadline
5xx / timeoutTransient service failure or work still in progressRead the existing resource before retrying a write; keep the request/resource ID

When requesting support, include UTC time, method/path, HTTP status, returned error code, and relevant resource/request IDs. Remove Authorization headers, signed URLs and private task contents. See Troubleshooting.

Next steps​

CLI reference · Python SDK reference · Inference endpoints · Client configuration