HTTP APIConnections
Get a connection
Build your request
Change the values and the command follows. The token is never typed here: the command reads it from the SPECTRE_LOCAL_API_TOKEN environment variable. Run it in your own terminal.
Command
curl 'http://127.0.0.1:48180/v1/connections/12' \ -H "Authorization: Bearer $SPECTRE_LOCAL_API_TOKEN"
GET
bearerToken connections:readheader
AuthorizationBearer <token>The Local API token: spt_ and 64 hex characters. Copy it from Settings App → General → Local API. It is accepted only in the Authorization header. The names listed with an operation are the scopes it requires. The token of the terminal carries all of them.
Scope: connections:read
id*integerConnection id.
Format
int64The connection.
application/json- response
id*integerFormat
int64exchange*stringThe exchange in lower case, as in an instrument address: binance.
market*stringspot, futures, …
label*stringenabled*booleanread_only*booleanA connection without credentials, created by the terminal for market data.
has_credentials*booleanproxy_bound*booleanWhether a proxy is bound to the connection.
status*curl 'http://127.0.0.1:48180/v1/connections/12' \ -H "Authorization: Bearer $SPECTRE_LOCAL_API_TOKEN"Example Response
{ "id": 12, "exchange": "binance", "market": "futures", "label": "Main", "enabled": true, "read_only": false, "has_credentials": true, "proxy_bound": false, "status": { "state": "connected", "last_event": { "code": "connected", "ts": 1730294400123 } }}