tastytradeDeveloper Docs
Legacy ↗

API Reference / Market Sessions

Get Current Futures Sessions

getMarketTimeFuturesSessionsCurrent
get/market-time/futures/sessions/current

Base URL: https://api.cert.tastyworks.com (Sandbox) · https://api.tastyworks.com (Production)

Returns the current trading session for each supported futures exchange (`CFE` and `CME`), each with its previous and next sessions. Use this to see the current session state across all futures collections in a single call.

Code samples

curl -X GET 'https://api.cert.tastyworks.com/market-time/futures/sessions/current' \
  -H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
  -H 'User-Agent: tastytrade-docs-example/1.0'

Parameters

No parameters.

Responses

200An array of current futures sessions, one per supported exchange.application/json

Example response

{
  "data": {
    "items": [
      {
        "close-at": "2024-01-15T14:30:00.000Z",
        "close-at-ext": "2024-01-15T14:30:00.000Z",
        "instrument-collection": "Equity",
        "open-at": "2024-01-15T14:30:00.000Z",
        "start-at": "2024-01-15T14:30:00.000Z",
        "next-session": {
          "close-at": "2024-01-15T14:30:00.000Z",
          "close-at-ext": "2024-01-15T14:30:00.000Z",
          "instrument-collection": "string",
          "open-at": "2024-01-15T14:30:00.000Z",
          "session-date": "2024-01-15",
          "start-at": "2024-01-15T14:30:00.000Z"
        },
        "previous-session": {
          "close-at": "2024-01-15T14:30:00.000Z",
          "close-at-ext": "2024-01-15T14:30:00.000Z",
          "instrument-collection": "string",
          "open-at": "2024-01-15T14:30:00.000Z",
          "session-date": "2024-01-15",
          "start-at": "2024-01-15T14:30:00.000Z"
        },
        "state": "string"
      }
    ]
  },
  "context": "/market-time/futures/sessions/current",
  "pagination": {
    "per-page": 0,
    "page-offset": 0,
    "item-offset": 0,
    "total-items": 0,
    "total-pages": 0,
    "current-item-count": 0
  }
}

Schema

  • datarequiredobject
    • itemsrequiredarray<object>{8 fields}
  • contextrequiredstring

    example: "/market-time/futures/sessions/current"

  • paginationobject

    Paging metadata, present on paginated list responses.

    • per-pageinteger
    • page-offsetinteger
    • item-offsetinteger
    • total-itemsinteger
    • total-pagesinteger
    • current-item-countinteger
401Missing or expired access token, or a missing/malformed `User-Agent` header.application/json

Example response

{
  "error": {
    "code": "unauthorized",
    "message": "No valid access token was provided; access tokens expire after 15 minutes."
  }
}

Schema

  • errorrequiredobject
    • coderequiredstring

      Machine-readable error code (see the Error reference).

    • messagerequiredstring

      Human-readable explanation.

    • errorsarray<object>{3 fields}

      Present for multi-error / validation failures; one entry per problem.

429Too many requests. Back off and reduce your request rate.application/json

Example response

{
  "error": {
    "code": "string",
    "message": "string",
    "errors": [
      {
        "code": "string",
        "message": "string",
        "domain": "string"
      }
    ]
  }
}

Schema

  • errorrequiredobject
    • coderequiredstring

      Machine-readable error code (see the Error reference).

    • messagerequiredstring

      Human-readable explanation.

    • errorsarray<object>{3 fields}

      Present for multi-error / validation failures; one entry per problem.

Related

Agents: this page is also Markdown (with the embedded OpenAPI definition) — append .md or send Accept: text/markdown. Index at /llms.txt.