Nexus/API Reference/Setups

Tag one of your bot's trades with one of its setups

PUThttps://app.skylit.ai/api/nexus/v1/trades/{id}/playbook

A bot trade takes a setup of your bot's account only (400 wrong_account for one of your own). checks replaces the trade's answers: send every rule you answered; a rule you leave out is unknown, never "not followed". Tagging again with another setup clears the old setup's answers.

curl -s -X PUT "https://app.skylit.ai/api/nexus/v1/trades/$TRADE_ID/playbook" \
  -H "Authorization: Bearer $SKYLIT_API_KEY" -H "Content-Type: application/json" \
  -d '{"playbookId":"'$SETUP_ID'","checks":[{"ruleId":"'$RULE_ID'","followed":true}]}'

Authorization

Authorization: Bearer <your API key>

Required. A missing header returns 401; an invalid, revoked or expired key returns 403.

Path parameters

  • idstringuuidrequired

    The trade id (tradeId on GET /v1/trades). Options and stock trades; a futures position is 404 trade_not_found.

Request body

  • playbookIdstringuuidrequired
  • checksobject[]
    • ruleIdstringuuidrequired
    • followedbooleanrequired

Responses

  • 200

    The tag as saved: {"tag": {...}}.

  • 400

    wrong_account (a setup of your own on a bot trade), or bad_request (no playbookId, an archived setup, a rule answered twice).

  • 403

    main_account_web_only: your own account's setups and tags are changed only on skylit.ai, signed in as yourself.

  • 404

    trade_not_found, playbook_not_found or rule_not_found (a rule that is not on that setup).

Last updated

Was this page helpful?