GetScripts¶
Info
GET https://{some_domain}/scripts
Returns scripts available to the current session.
USER:scope=mereturns own scriptsscope=publicreturns public scriptsscope=allreturns own scripts plus public scriptsMANAGER,ADMIN,DEALER:- may use
scope=allto read all scripts - may pass
logintogether withscope=meto read one account's scripts
Authorization¶
All requests must include a JWT token in Authorization.
Allowed roles: USER, MANAGER, ADMIN, DEALER.
Query Parameters¶
| Field | Type | Required | Description |
|---|---|---|---|
scope |
string | No | me, public, or all |
login |
int | No | Target login for staff sessions |
kind |
string | No | indicator, robot, strategy, widget |
language |
string | No | stscript, javascript |
visibility |
string | No | private, public |
enabled |
int | No | 0 or 1 |
Response¶
Success 200¶
{
"rows": [
{
"id": 42,
"login": 1001,
"name": "MorningScalper",
"script": "print('hi')",
"description": "simple moving average",
"kind": "indicator",
"language": "stscript",
"visibility": "private",
"autostart": 1,
"enabled": 1,
"created_time": 1777196331,
"updated_time": 1777196331
}
],
"count": 1
}
Error Responses¶
| Code | Error | Description |
|---|---|---|
| 400 | INVALID_DATA |
Invalid query params |
| 401 | PERMISSION_DENIED |
Missing or invalid access context |