Skip to main content

Perdura documentation / Guide 07

API behavior and security

Understand the client boundary, failures, storage and supported service paths.

The API paths this client uses

The API origin is provided by your operator. This documentation does not announce a public unauthenticated market-data API. Signals marks and contributed records are not exported by this client.

CommandService path
login / logoutPOST / DELETE /api/v1/session
whoamiGET /api/v1/session/current
requirements list / getGET /api/v1/requisitions and /api/v1/requisitions/{id}
requirements createPOST /api/v1/requisitions
requirements submit / publishPOST /api/v1/requisitions/{id}/submit or /publish
orders list / getGET /api/v1/orders and /api/v1/orders/{id}

Credentials never travel to another origin

The client requires HTTPS outside loopback, rejects embedded URL credentials and refuses redirects. Saved tokens are bound to the exact API origin. It never accepts a password or token as a command argument and does not read a token from an environment variable.

The API remains responsible for tenant authorization and current account grants. The private token file is not an additional server-side permission scope.

A separate public evidence endpoint

The website exposes GET /api/public/evidence?format=json for approved source evidence. Its state may be pending when no approved publication is available. Ready responses contain permitted source metadata and supported presentation rows, not private trading data or reference marks.

GET /api/public/evidence?format=csv offers approved tabular evidence only. It returns HTTP 409 when no approved table is available. These website endpoints are separate from the authenticated trading API and are not CLI market-data commands.

Read failures without exposing credentials

Error output includes bounded status/code/request information, not raw response HTML, request bodies, passwords or session headers. Keep the request id when asking for help. A 403 does not justify changing roles or weakening a check.

ExitMeaning
0The command completed.
1The API refused the request; inspect HTTP status, field names and request id.
2Command usage, unsafe configuration or credential storage problem.
3Sign-in required or the session is no longer accepted.
4Network or unreadable response; a write may already have committed.

Handle procurement files deliberately

JSON preview and draft upload may include private delivery and procurement details. Review the destination origin and file before a real create. Do not place personal identity documents or credentials in a requirement file.

The CLI stores one session file outside Git. On sign-out it clears that file even when remote revocation cannot be confirmed, and reports the uncertainty.