Events

Query event stream

Retrieves a stream of events for the specified cryptocurrency.

get/v1/cryptos/{cryptoCode}/events

Path parameters

cryptoCodestring required

The cryptocurrency code to track (e.g., 'BTC' for Bitcoin, 'LTC' for Litecoin).

Query parameters

lastEventIdinteger

Will query all events which happened after this event ID; the first event has ID 1 (default: 0).

longPollingboolean

If no events have been received since lastEventId, the call will block (default: false).

limitinteger

Limit the maximum number of events to return (default: null).

Response

Event stream retrieved successfully.

eventIdinteger

Unique identifier of the event. (Sequential)

type'newblock' | 'newtransaction'

Type of the event (e.g., 'newblock', 'newtransaction').

Example response

[
  {
    "data": {
      "height": 104,
      "hash": "1f31c605c0a5d54b65fa39dc8cb4db025be63c66280279ade9338571a9e63d35",
      "previousBlockHash": "7639350b31f3ce07ff976ebae772fef1602b30a10ccb8ca69047fe0fe8b9083c",
      "cryptoCode": "BTC",
      "confirmations": 1
    }
  }
]

Changes

Changed in 8 of the 40 revisions of this API.24818

    • added the optional property items/data/oneOf[NewTransactionEvent]/transactionData/metadata/chunk to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/inputs/items/keyIndex to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/outputs/items/keyIndex to the response with the 200 status

      response-optional-property-added

  • 8f8eb2939c5c51See the full diff
    • removed the optional property items/data/oneOf[NewTransactionEvent]/transactionData/balanceChange from the response with the 200 status

      response-optional-property-removed

    • removed the optional property items/data/oneOf[NewTransactionEvent]/transactionData/inputs from the response with the 200 status

      response-optional-property-removed

    • removed the optional property items/data/oneOf[NewTransactionEvent]/transactionData/outputs from the response with the 200 status

      response-optional-property-removed

    • removed the optional property items/data/oneOf[NewTransactionEvent]/transactionData/replaceable from the response with the 200 status

      response-optional-property-removed

    • removed the optional property items/data/oneOf[NewTransactionEvent]/transactionData/replacing from the response with the 200 status

      response-optional-property-removed

    • added the optional property items/data/oneOf[NewTransactionEvent]/transactionData/metadata to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/inputs/items/feature to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/outputs/items/feature to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/transactionData/inputs/items/feature to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/transactionData/outputs/items/feature to the response with the 200 status

      response-optional-property-added

  • 272dc200f071215See the full diff
    • added the new path request parameter cryptoCode

      new-request-path-parameter

    • the response property items/data became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewBlockEvent]/confirmations became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewBlockEvent]/cryptoCode became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewBlockEvent]/hash became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewBlockEvent]/height became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewBlockEvent]/previousBlockHash became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/cryptoCode became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/derivationStrategy became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/outputs became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/trackedSource became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/confirmations became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/inputs became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/inputs/items/index became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/inputs/items/inputIndex became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/inputs/items/transactionId became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/outputs became optional for the status 200

      response-property-became-optional

    • the response property items/data/oneOf[NewTransactionEvent]/transactionData/transactionId became optional for the status 200

      response-property-became-optional

    • the response property items/eventId became optional for the status 200

      response-property-became-optional

    • the response property items/type became optional for the status 200

      response-property-became-optional

    • api operation id EventStream was added

      api-operation-id-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/inputs to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/outputs/items/address to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/transactionData/inputs/items/keyPath to the response with the 200 status

      response-optional-property-added

    • added the optional property items/data/oneOf[NewTransactionEvent]/transactionData/outputs/items/address to the response with the 200 status

      response-optional-property-added

  • 6bfc5768516c234See the full diff
    • added NewBlockEvent NewTransactionEvent to the items/data response property oneOf list for the response status 200

      response-property-one-of-added

    • the items/data response's property type/format changed from object/ to / for status 200

      response-property-type-changed

    • deleted the path request parameter cryptoCode

      request-parameter-removed

    • added the new newblock enum value to the items/type response property for the response status 200

      response-property-enum-value-added

    • added the new newtransaction enum value to the items/type response property for the response status 200

      response-property-enum-value-added

    • added the non-success response with the status 400

      response-non-success-status-added

    • the response property items/data became required for the status 200

      response-property-became-required

    • the response property items/eventId became required for the status 200

      response-property-became-required

    • the response property items/type became required for the status 200

      response-property-became-required

    • endpoint added

      endpoint-added

    • api path removed without deprecation

      api-path-removed-without-deprecation

    This revision also has 14 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog