> ## Documentation Index
> Fetch the complete documentation index at: https://docs.coinstack.net/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> The CoinStack API base URL is https://coinstack.net/api/v1. Authenticate with an API key sent as 'Authorization: Bearer sk_...' from a server, never from a browser. Every response is a JSON object with 'success' and 'response'. Amounts are strings; token amounts on quotes and payments are in the token's smallest unit. Fulfil an order when its checkout status is 'completed', not when the customer returns to success_url. Verify the CoinStack-Signature header on every webhook using the raw request body. The OpenAPI file is at https://docs.coinstack.net/openapi.json.

# List events

> Returns your events, newest first, each with the record of its deliveries to your webhooks.

Requires an API key with write access.



## OpenAPI

````yaml /openapi.json get /events
openapi: 3.1.0
info:
  title: CoinStack API
  version: 1.0.0
  description: >-
    Create checkouts, read payments and manage webhooks. Authenticate with an
    API key sent as a Bearer token. Every response is a JSON object with
    `success` and `response`.
servers:
  - url: https://coinstack.net/api/v1
security:
  - bearerAuth: []
tags:
  - name: Checkouts
    description: Requests for one payment.
  - name: Quotes
    description: >-
      Deposit addresses and amounts for showing payment details in your own
      interface.
  - name: Payments
    description: Transfers customers have sent.
  - name: Tokens
    description: The tokens and networks customers can pay with.
  - name: Webhooks
    description: URLs that receive events.
  - name: Events
    description: Changes to checkouts and payments, and their deliveries.
  - name: Webhook events
    description: Requests CoinStack sends to your webhooks.
paths:
  /events:
    get:
      tags:
        - Events
      summary: List events
      description: >-
        Returns your events, newest first, each with the record of its
        deliveries to your webhooks.


        Requires an API key with write access.
      operationId: listEvents
      parameters:
        - name: limit
          in: query
          description: >-
            How many results to return, from 1 to 100. Values above 100 are
            treated as 100.
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 100
        - name: cursor
          in: query
          description: >-
            The `cursor` value from the previous page. Leave it out for the
            first page.
          schema:
            type: string
      responses:
        '200':
          description: Successful response.
          content:
            application/json:
              schema:
                type: object
                required:
                  - success
                  - response
                properties:
                  success:
                    type: boolean
                    description: Always `true` for a successful request.
                  response:
                    type: object
                    required:
                      - events
                      - cursor
                    properties:
                      events:
                        type: array
                        items:
                          type: object
                          required:
                            - event
                            - deliveries
                          properties:
                            event:
                              $ref: '#/components/schemas/Event'
                            deliveries:
                              type: array
                              items:
                                $ref: '#/components/schemas/Delivery'
                              description: >-
                                One entry for each time the event was queued for
                                a webhook. Empty if no webhook was subscribed.
                      cursor:
                        type:
                          - string
                          - 'null'
                        description: >-
                          Pass this as `cursor` to get the next page. `null`
                          when there are no more results.
              example:
                success: true
                response:
                  events:
                    - event:
                        event_id: e41b7c92-3a5d-4f8e-b1c6-9d2a7f4e0b85
                        kind: checkout.completed
                        data:
                          checkout:
                            checkout_id: 8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
                            quote_id: >-
                              0x5c1d9a7e3b6f48021e9d7c4a5b3f6e8d1a2c4b6e8f0a1c3e5d7f9b2a4c6e8d0f
                            email: customer@example.com
                            reference: order-1042
                            description: 'Order #1042'
                            success_url: https://example.com/orders/1042/thanks
                            cancel_url: https://example.com/cart
                            currency: USD
                            status: completed
                            amount: '25.00000000'
                            value: '25.00000000'
                            received: '24.77643200'
                            fee: '0.20000000'
                            underpaid: false
                            overpaid: false
                            late: false
                            metadata:
                              order_id: '1042'
                            created_at: '2026-12-02T16:20:11.482913Z'
                            updated_at: '2026-12-02T16:24:37.905218Z'
                            expires_at: '2026-12-03T16:20:11.482501Z'
                            completed_at: '2026-12-02T16:24:37.905218Z'
                            url: >-
                              https://coinstack.net/checkout/8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
                        created_at: '2026-12-02T16:24:37.905218Z'
                      deliveries:
                        - webhook_id: c2a9f1d4-7b3e-4c6a-9d2f-5e8b1a4c7d30
                          event_id: e41b7c92-3a5d-4f8e-b1c6-9d2a7f4e0b85
                          delivery_id: 4127
                          code: 200
                          attempts: 1
                          delivered: true
                          created_at: '2026-12-02T16:24:37.905218Z'
                          updated_at: '2026-12-02T16:24:38.214077Z'
                          next_at: null
                          delivered_at: '2026-12-02T16:24:38.214077Z'
                  cursor: null
        '400':
          description: A query parameter is not valid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                invalid_limit:
                  summary: Invalid limit
                  value:
                    success: false
                    response: Invalid limit
                invalid_cursor:
                  summary: Invalid cursor
                  value:
                    success: false
                    response: Invalid cursor
        '401':
          description: The API key is missing, wrong or deleted.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                invalid_authentication:
                  summary: Invalid authentication
                  value:
                    success: false
                    response: Invalid authentication
        '403':
          description: >-
            The API key is read only. This endpoint needs a key with write
            access.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                invalid_permissions:
                  summary: Invalid permissions
                  value:
                    success: false
                    response: Invalid permissions
components:
  schemas:
    Event:
      type: object
      description: >-
        A change to a checkout or payment. This is also the body of every
        webhook request.
      required:
        - event_id
        - kind
        - data
        - created_at
      properties:
        event_id:
          type: string
          format: uuid
          description: The event ID. It stays the same across retries and resends.
        kind:
          $ref: '#/components/schemas/EventKind'
        data:
          type: object
          description: >-
            Holds `checkout` for `checkout.*` events and `payment` for
            `payment.*` events, as it was when the event happened.
          properties:
            checkout:
              $ref: '#/components/schemas/Checkout'
            payment:
              $ref: '#/components/schemas/Payment'
        created_at:
          type: string
          format: date-time
          description: When the event happened. Time in RFC 3339 format, in UTC.
      example:
        event_id: e41b7c92-3a5d-4f8e-b1c6-9d2a7f4e0b85
        kind: checkout.completed
        data:
          checkout:
            checkout_id: 8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
            quote_id: '0x5c1d9a7e3b6f48021e9d7c4a5b3f6e8d1a2c4b6e8f0a1c3e5d7f9b2a4c6e8d0f'
            email: customer@example.com
            reference: order-1042
            description: 'Order #1042'
            success_url: https://example.com/orders/1042/thanks
            cancel_url: https://example.com/cart
            currency: USD
            status: completed
            amount: '25.00000000'
            value: '25.00000000'
            received: '24.77643200'
            fee: '0.20000000'
            underpaid: false
            overpaid: false
            late: false
            metadata:
              order_id: '1042'
            created_at: '2026-12-02T16:20:11.482913Z'
            updated_at: '2026-12-02T16:24:37.905218Z'
            expires_at: '2026-12-03T16:20:11.482501Z'
            completed_at: '2026-12-02T16:24:37.905218Z'
            url: >-
              https://coinstack.net/checkout/8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
        created_at: '2026-12-02T16:24:37.905218Z'
    Delivery:
      type: object
      description: The record of sending one event to one webhook.
      required:
        - webhook_id
        - event_id
        - delivery_id
        - code
        - attempts
        - delivered
        - created_at
        - updated_at
        - next_at
        - delivered_at
      properties:
        webhook_id:
          type: string
          format: uuid
          description: The webhook the event was sent to.
        event_id:
          type: string
          format: uuid
          description: The event that was sent.
        delivery_id:
          type: integer
          description: The delivery ID.
        code:
          type: integer
          description: >-
            The HTTP status your server returned on the latest attempt. `0` if
            there was no response or no attempt yet.
        attempts:
          type: integer
          description: How many times CoinStack has tried to deliver the event.
        delivered:
          type: boolean
          description: '`true` once your server answered with a 2xx status.'
        created_at:
          type: string
          format: date-time
          description: When the delivery was created. Time in RFC 3339 format, in UTC.
        updated_at:
          type: string
          format: date-time
          description: When the delivery last changed. Time in RFC 3339 format, in UTC.
        next_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            When the next attempt is due. `null` once the event is delivered or
            CoinStack has stopped trying. Time in RFC 3339 format, in UTC.
        delivered_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            When the event was delivered. `null` until then. Time in RFC 3339
            format, in UTC.
      example:
        webhook_id: c2a9f1d4-7b3e-4c6a-9d2f-5e8b1a4c7d30
        event_id: e41b7c92-3a5d-4f8e-b1c6-9d2a7f4e0b85
        delivery_id: 4127
        code: 200
        attempts: 1
        delivered: true
        created_at: '2026-12-02T16:24:37.905218Z'
        updated_at: '2026-12-02T16:24:38.214077Z'
        next_at: null
        delivered_at: '2026-12-02T16:24:38.214077Z'
    Error:
      type: object
      required:
        - success
        - response
      properties:
        success:
          type: boolean
          description: Always `false` for an error.
        response:
          type: string
          description: What went wrong, for example `Invalid amount`.
      example:
        success: false
        response: Invalid amount
    EventKind:
      type: string
      enum:
        - checkout.confirming
        - checkout.partial
        - checkout.completed
        - checkout.expired
        - checkout.resolved
        - payment.pending
        - payment.completed
        - payment.refunded
    Checkout:
      type: object
      description: A request for one payment.
      required:
        - checkout_id
        - quote_id
        - email
        - reference
        - description
        - success_url
        - cancel_url
        - currency
        - status
        - amount
        - value
        - received
        - fee
        - underpaid
        - overpaid
        - late
        - metadata
        - created_at
        - updated_at
        - expires_at
        - completed_at
        - url
      properties:
        checkout_id:
          type: string
          format: uuid
          description: The checkout ID.
        quote_id:
          type: string
          description: >-
            The quote the customer selected most recently. Empty until a payment
            method is chosen.
        email:
          type: string
          description: The customer's email address. Empty if none was given.
        reference:
          type: string
          description: >-
            Your own identifier for this checkout, such as an order number.
            Empty if none was given.
        description:
          type: string
          description: >-
            The description shown to the customer on the checkout page. Empty if
            none was given.
        success_url:
          type: string
          description: >-
            The link behind the Return to merchant button that the checkout page
            shows once the checkout is completed. Empty if none was given.
        cancel_url:
          type: string
          description: >-
            The link the checkout page offers for leaving without paying, and
            for returning to you if the checkout expires. Empty if none was
            given.
        currency:
          type: string
          description: The three-letter currency code the checkout was priced in.
          example: USD
        status:
          type: string
          enum:
            - pending
            - confirming
            - partial
            - completed
            - expired
            - resolved
          description: >-
            `pending`: nothing has been paid yet. `confirming`: a payment was
            detected and is being processed. `partial`: less than the full
            amount has been paid and the checkout is still open. `completed`:
            paid in full. `expired`: the checkout closed before it was paid in
            full. `resolved`: you marked an underpaid checkout as settled.
        amount:
          type: string
          description: The amount in `currency`. A decimal number sent as a string.
        value:
          type: string
          description: >-
            The amount in US dollars, converted when the checkout was created. A
            decimal number sent as a string.
        received:
          type: string
          description: >-
            The USDC that has reached your wallet from completed payments on
            this checkout. A decimal number sent as a string.
        fee:
          type: string
          description: >-
            The CoinStack fee for the full amount, in US dollars. A decimal
            number sent as a string.
        underpaid:
          type: boolean
          description: >-
            `true` if payments have arrived but add up to less than the full
            amount.
        overpaid:
          type: boolean
          description: '`true` if the customer paid more than 2% over the full amount.'
        late:
          type: boolean
          description: >-
            `true` if the payment that completed the checkout arrived after
            `expires_at`.
        metadata:
          type: object
          additionalProperties:
            type: string
          description: The key-value pairs you attached when creating the checkout.
        created_at:
          type: string
          format: date-time
          description: When the checkout was created. Time in RFC 3339 format, in UTC.
        updated_at:
          type: string
          format: date-time
          description: When the checkout last changed. Time in RFC 3339 format, in UTC.
        expires_at:
          type: string
          format: date-time
          description: >-
            When the checkout closes if it has not been paid. Time in RFC 3339
            format, in UTC.
        completed_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            When the checkout was completed. `null` until then. Time in RFC 3339
            format, in UTC.
        url:
          type: string
          format: uri
          description: The checkout page. Send your customer here to pay.
      example:
        checkout_id: 8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
        quote_id: ''
        email: customer@example.com
        reference: order-1042
        description: 'Order #1042'
        success_url: https://example.com/orders/1042/thanks
        cancel_url: https://example.com/cart
        currency: USD
        status: pending
        amount: '25.00000000'
        value: '25.00000000'
        received: '0'
        fee: '0.20000000'
        underpaid: false
        overpaid: false
        late: false
        metadata:
          order_id: '1042'
        created_at: '2026-12-02T16:20:11.482913Z'
        updated_at: '2026-12-02T16:20:11.482913Z'
        expires_at: '2026-12-03T16:20:11.482501Z'
        completed_at: null
        url: https://coinstack.net/checkout/8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
    Payment:
      type: object
      description: One transfer a customer sent to a deposit address.
      required:
        - checkout_id
        - quote_id
        - payment_id
        - network
        - token
        - address
        - sender
        - settlement
        - recipient
        - status
        - amount
        - value
        - settled
        - fee
        - cost
        - share
        - deposit_tx_hash
        - fill_tx_hash
        - fail_reason
        - created_at
        - updated_at
        - settled_at
      properties:
        checkout_id:
          type: string
          format: uuid
          description: The checkout this payment belongs to.
        quote_id:
          type: string
          description: The quote whose deposit address received the payment.
        payment_id:
          type: string
          description: The payment ID.
        network:
          type: string
          description: The network the customer paid on.
          example: base
        token:
          type: string
          description: The token the customer paid with.
          example: USDC
        address:
          type: string
          description: The deposit address the payment was sent to.
        sender:
          type: string
          description: The address the payment came from. Empty if not known.
        settlement:
          type: string
          description: The network your USDC was settled on.
          example: base
        recipient:
          type: string
          description: The address that received your USDC.
        status:
          type: string
          enum:
            - pending
            - completed
            - refunded
            - failed
          description: >-
            `pending`: the payment was detected and is being processed.
            `completed`: the USDC reached your wallet. `refunded`: the payment
            could not be processed and was returned to the sender. `failed`: the
            payment could not be processed.
        amount:
          type: string
          description: What the customer sent, in the token's smallest unit.
          example: '25000000'
        value:
          type: string
          description: >-
            What the customer sent, in US dollars. A decimal number sent as a
            string.
        settled:
          type: string
          description: >-
            The USDC that reached your wallet. `0` until the payment is
            completed. A decimal number sent as a string.
        fee:
          type: string
          description: >-
            The CoinStack fee taken from this payment, in US dollars. A decimal
            number sent as a string.
        cost:
          type: string
          description: >-
            The network cost of this payment, in US dollars. A decimal number
            sent as a string.
        share:
          type: string
          description: >-
            How much of the checkout this payment covered. `1` is the full
            amount and `0.5` is half. A decimal number sent as a string.
        deposit_tx_hash:
          type: string
          description: The transaction the customer sent. Empty if not known yet.
        fill_tx_hash:
          type: string
          description: >-
            The transaction that delivered the USDC to your wallet. Empty until
            the payment is completed.
        fail_reason:
          type: string
          description: >-
            Why a `failed` or `refunded` payment did not go through. Empty
            otherwise.
        created_at:
          type: string
          format: date-time
          description: >-
            When the payment was first detected. Time in RFC 3339 format, in
            UTC.
        updated_at:
          type: string
          format: date-time
          description: When the payment last changed. Time in RFC 3339 format, in UTC.
        settled_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            When the USDC reached your wallet. `null` until then. Time in RFC
            3339 format, in UTC.
      example:
        checkout_id: 8f3b2c1e-5d47-4a9b-b6e0-2c7f1a9d4e53
        quote_id: '0x5c1d9a7e3b6f48021e9d7c4a5b3f6e8d1a2c4b6e8f0a1c3e5d7f9b2a4c6e8d0f'
        payment_id: '0x5c1d9a7e3b6f48021e9d7c4a5b3f6e8d1a2c4b6e8f0a1c3e5d7f9b2a4c6e8d0f'
        network: base
        token: USDC
        address: '0x7a3e9c5d1b4f8026e9a1c3d5b7f9e2a4c6d8b0f1'
        sender: '0x2b9d4f6a8c1e3057b9d2f4a6c8e0b1d3f5a7c9e2'
        settlement: base
        recipient: '0x91C4e7B2a6D83f05E2b7A9c4D6f8E1a3B5c7D9F0'
        status: completed
        amount: '25000000'
        value: '24.99375000'
        settled: '24.77643200'
        fee: '0.19995000'
        cost: '0.01736800'
        share: '1.000000000000000000'
        deposit_tx_hash: '0x3e7a1c9d5b2f4e6a8c0d1b3f5a7e9c2d4b6f8a0c1e3d5b7f9a2c4e6d8b0f1a3c'
        fill_tx_hash: '0x9b2d4f6a8c0e1b3d5f7a9c2e4b6d8f0a1c3e5b7d9f2a4c6e8b0d1f3a5c7e9b2d'
        fail_reason: ''
        created_at: '2026-12-02T16:23:58.774310Z'
        updated_at: '2026-12-02T16:24:37.889456Z'
        settled_at: '2026-12-02T16:24:37.889456Z'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Your API key, which starts with `sk_`. Create one in the dashboard under
        Developers.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.