Nexus/API Reference/Journal and Edge

Read a month of days

GEThttps://app.skylit.ai/api/nexus/v1/journal/calendar

One month, in New York time: a row for each day that closed a trade, and the month's totals.

  • A day or a month with nothing measured has realizedPnl: null, never 0. A day with 0 < measuredCount < tradeCount is a partial sum.
  • grossProfit, grossLoss, avgWin and avgLoss come from the trades, so profitFactor is the trade figure.
  • bestDay and worstDay are among measured days only, and left out when none was measured.

Authorization

Authorization: Bearer <your API key>

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

Query parameters

  • accountstring

    main (your own simulated wallet, the default) or agent (your bot's).

    mainagent
  • monthstring

    YYYY-MM. Left out, the month in progress.

Responses

  • 200

    The month.

  • 400

    Code: bad_request. account, range, by or month isn't one of the allowed values, or account=main was sent to agent/edge. The message says which.

  • 401

    No key, or a key that isn't valid. Codes: missing_api_key, invalid_api_key.

  • 403

    The key works but this can't be read. Codes: feature_disabled (you sent port: ports aren't available yet, so leave it out), account_suspended, nexus_access_denied.

  • 404

    Code: user_not_found. This Skylit account hasn't used Nexus yet, so it has no journal.

  • 429

    Over a rate limit. Wait Retry-After seconds, then retry. Codes: rate_limited, and stream_limit_reached (too many live streams open: 3 per key, 6 per account).

  • 500

    Something went wrong on our side. If you sent a clientOrderId, retry with the same one. Code: internal_error.

Response fields

  • dataobject
    • monthstring
    • timezonestring
    • realizedPnlnumber | null
    • tradeCountinteger
    • measuredCountinteger
    • winsinteger
    • lossesinteger
    • breakeveninteger
    • winRatenumber
    • greenDaysinteger
    • redDaysinteger
    • flatDaysinteger
    • unmeasuredDaysinteger
    • grossProfitnumber
    • grossLossnumber
    • profitFactornumber
    • avgWinnumber
    • avgLossnumber
    • riskRewardnumber

      Average win over average loss. 0 when nothing was lost.

    • bestDayobject

      One day in New York time. realizedPnl is over measured trades only, and null when none was measured.

    • worstDayobject

      One day in New York time. realizedPnl is over measured trades only, and null when none was measured.

    • daysobject[]
  • metaobject

    Which account was read.

    • accountstring
      mainagent
    • portstring | nulluuid

      Always null for now.

Last updated

Was this page helpful?