Call the API
Each command under praxis api maps to one platform operation. This page shows how to find it, how parameters travel, how lists page, and which credential each environment uses.
Find the command
The command words come from the operation’s domain, resource, and method. List a domain first:
praxis api model --helpThe output lists command groups such as list, get, chat, and embedding; the actual --help output is authoritative. Then read one command’s full options:
praxis api model list --helpThe first line is the usage, followed by the SDK method, the HTTP method and path, and every option with its type. Required options are marked (required).
Pass parameters
Option names come from the operation’s parameters. Array parameters can be repeated:
praxis api model list --limit 3Send a request body with --data, in one of three forms:
--data '{"key":"value"}': inline JSON.--data @body.json: JSON read from a file.--data -: JSON read from standard input.
praxis api sandbox create --data '{"template_id":"<template_id>"}'Operations that change state (delete, overwrite) ask once before running. In a script or an agent, add --yes to confirm, or --no-input to fail instead of waiting.
Page through lists
Three global options page a list operation:
--limit <n>: how many rows this page returns.--cursor <token>: continue from the position the previous page ended at.--all: read every page before printing. An operation without paging fails instead.
Without --cursor you start at the first page. --all and --limit cannot be used together.
Environment and credentials
The default environment is production. Switch with PRAXIS_ENV, for example PRAXIS_ENV=develop; when it is unset you are on production:
praxis whoamiCredentials are kept per environment, so one environment’s key never replaces another’s login:
| Environment | Variable | Notes |
|---|---|---|
| production (default) | PRAXIS_API_KEY | A production key |
| Other environments | PRAXIS_API_KEY with the environment suffix, such as PRAXIS_API_KEY_DEVELOP | A key for that environment |
Within one environment the order is: PRAXIS_API_TOKEN (your own API Token, or a token the platform issues to a machine), then the API key, then a browser login. Several agents on one machine each set their own PRAXIS_API_TOKEN and act as themselves. With a token the organization comes from the token, and --org cannot override it.
Raw requests
When you are not sure how the command is spelled, send the request directly:
praxis api GET '/model/v1/models?limit=3'The method and path go to the operation as written; authentication, environment, and --debug work the same as for generated commands. GET and HEAD cannot take --data: put query parameters in the path, and keep --data for methods with a body (such as POST).
Verify
--debug prints the request’s method, URL, and headers (never the body or query values), which is the fastest way to confirm that a command hit the operation you meant. A successful run exits 0; see Exit codes and errors for failures.