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

# List credit grants

> List all credit grants for this account



## OpenAPI

````yaml billing.latest.product.live GET /credits
openapi: 3.0.0
info:
  title: Billing
  description: Manage Billing
  version: '0.1'
servers:
  - url: https://dev.seqhq.io/api
    description: DEV
  - url: https://sandbox.sequencehq.com/api
    description: SANDBOX
  - url: https://eu.sequencehq.com/api
    description: PRODUCTION
security: []
tags: []
paths:
  /credits:
    servers: []
    parameters: []
    get:
      tags:
        - Credits
      summary: List credit grants
      description: List all credit grants for this account
      operationId: getCredits
      parameters:
        - name: Authorization
          in: header
          description: >-
            Your [API credentials](/reference/authentication). Eg. `Basic
            {credentials}`.
          required: true
          schema:
            type: string
        - name: limit
          in: query
          description: >-
            Maximum number of objects to return per-page. Must be between 1 and
            100 (inclusive).
          required: false
          schema:
            type: integer
        - name: after
          in: query
          description: >-
            Pagination offset. To page through items, omit this parameter to
            retrieve the first page, and then successively use the value you get
            from `pagination.after` or `pagination.before` to retrieve each
            page.
          required: false
          schema:
            type: string
        - name: before
          in: query
          description: >-
            Pagination offset. To page through items, omit this parameter to
            retrieve the first page, and then successively use the value you get
            from `pagination.next` or `pagination.previous` to retrieve each
            page.
          required: false
          schema:
            type: string
        - name: Sequence-Version
          in: header
          description: Use this header to select an API version
          required: false
          schema:
            type: string
            enum:
              - '2024-07-30'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListCreditGrantEndpointResponseModel'
                example:
                  items:
                    - id: 746fc7f2-8098-4fe7-953c-7d51c580a126
                      sequenceAccountId: dce9ae85-d8d0-42b4-bcad-f221a64363c6
                      customerId: 61b083e0-1faa-47ca-9aeb-6205da8f6c47
                      name: On-boarding Credits
                      creditUnitType: CURRENCY
                      currency: GBP
                      metricId: f092246c-6b90-4106-bcca-304ccf06bf45
                      amount: 10
                      costOfCredit: 10
                      taxRateId: 179d1ab3-cc96-48e2-9310-067b0b42d47c
                      effectiveDate: '2023-01-01'
                      expiryDate: '2023-01-31'
                      createdAt: '2022-10-07T14:12:08.826121Z'
                      creditNoteId: 73086198-8752-4ec9-a99b-16209a32dc6c
                      integrationIds:
                        - service: Xero
                          id: 74ed2615-4730-49ab-9445-74f31723a206
                          isPending: false
                  pagination:
                    after: MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3
                    before: MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz
                    totalResultSize: 10
              examples:
                ListCreditGrantEndpointResponseModel:
                  summary: ''
                  value:
                    items:
                      - id: 746fc7f2-8098-4fe7-953c-7d51c580a126
                        sequenceAccountId: dce9ae85-d8d0-42b4-bcad-f221a64363c6
                        customerId: 61b083e0-1faa-47ca-9aeb-6205da8f6c47
                        name: On-boarding Credits
                        creditUnitType: CURRENCY
                        currency: GBP
                        metricId: f092246c-6b90-4106-bcca-304ccf06bf45
                        amount: 10
                        costOfCredit: 10
                        taxRateId: 179d1ab3-cc96-48e2-9310-067b0b42d47c
                        effectiveDate: '2023-01-01'
                        expiryDate: '2023-01-31'
                        createdAt: '2022-10-07T14:12:08.826121Z'
                        creditNoteId: 73086198-8752-4ec9-a99b-16209a32dc6c
                        integrationIds:
                          - service: Xero
                            id: 74ed2615-4730-49ab-9445-74f31723a206
                            isPending: false
                    pagination:
                      after: MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3
                      before: MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz
                      totalResultSize: 10
        '400':
          description: Bad Request
          content: {}
        '401':
          description: Unauthorized
          content: {}
        '500':
          description: Internal Server Error
          content: {}
components:
  schemas:
    ListCreditGrantEndpointResponseModel:
      required:
        - items
        - pagination
      type: object
      example:
        items:
          - id: 746fc7f2-8098-4fe7-953c-7d51c580a126
            sequenceAccountId: dce9ae85-d8d0-42b4-bcad-f221a64363c6
            customerId: 61b083e0-1faa-47ca-9aeb-6205da8f6c47
            name: On-boarding Credits
            creditUnitType: CURRENCY
            currency: GBP
            metricId: f092246c-6b90-4106-bcca-304ccf06bf45
            amount: 10
            costOfCredit: 10
            taxRateId: 179d1ab3-cc96-48e2-9310-067b0b42d47c
            effectiveDate: '2023-01-01'
            expiryDate: '2023-01-31'
            createdAt: '2022-10-07T14:12:08.826121Z'
            creditNoteId: 73086198-8752-4ec9-a99b-16209a32dc6c
            integrationIds:
              - service: Xero
                id: 74ed2615-4730-49ab-9445-74f31723a206
                isPending: false
        pagination:
          after: MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3
          before: MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz
          totalResultSize: 10
      properties:
        items:
          type: array
          description: Credit grants
          example:
            - id: 746fc7f2-8098-4fe7-953c-7d51c580a126
              sequenceAccountId: dce9ae85-d8d0-42b4-bcad-f221a64363c6
              customerId: 61b083e0-1faa-47ca-9aeb-6205da8f6c47
              name: On-boarding Credits
              creditUnitType: CURRENCY
              currency: GBP
              metricId: f092246c-6b90-4106-bcca-304ccf06bf45
              amount: 10
              costOfCredit: 10
              taxRateId: 179d1ab3-cc96-48e2-9310-067b0b42d47c
              effectiveDate: '2023-01-01'
              expiryDate: '2023-01-31'
              createdAt: '2022-10-07T14:12:08.826121Z'
              creditNoteId: 73086198-8752-4ec9-a99b-16209a32dc6c
              integrationIds:
                - service: Xero
                  id: 74ed2615-4730-49ab-9445-74f31723a206
                  isPending: false
          items:
            $ref: '#/components/schemas/CreditGrant'
        pagination:
          $ref: '#/components/schemas/PaginationMeta'
    CreditGrant:
      required:
        - costOfCredit
        - createdAt
        - currency
        - currentBalance
        - customerId
        - id
        - name
        - originalAmount
        - sequenceAccountId
        - type
      type: object
      example:
        id: 5a0faea3-7ad5-4a83-a420-09bb6576f7e6
        sequenceAccountId: a507e782-d26b-4d34-92b9-aacd1667e1f0
        customerId: eabb3196-9c73-4c0d-b508-d3c4fc7b2cbb
        type: CASH
        currency: GBP
        metricId: b84f5290-fe95-4c6f-bedc-477700125265
        name: GBP
        originalAmount: '10'
        currentBalance: '1'
        expiryDate: '2024-01-02'
        costOfCredit: '10'
        taxRateId: b3c37ea3-96bb-44fb-baed-01eb38d3328e
        effectiveDate: '2024-01-01'
        createdAt: '2024-01-01T12:00:00Z'
      properties:
        id:
          type: string
          description: Credit Grant ID
          example: 5a0faea3-7ad5-4a83-a420-09bb6576f7e6
        sequenceAccountId:
          type: string
          description: Sequence account ID
          example: a507e782-d26b-4d34-92b9-aacd1667e1f0
        customerId:
          type: string
          description: Customer ID
          example: eabb3196-9c73-4c0d-b508-d3c4fc7b2cbb
        type:
          $ref: '#/components/schemas/CreditType'
          description: Type of the Credit - will either be CASH or USAGE
        currency:
          $ref: '#/components/schemas/Currency'
          description: Currency
        metricId:
          type: string
          description: Usage metric ID (if type is USAGE)
          example: b84f5290-fe95-4c6f-bedc-477700125265
        name:
          type: string
          description: >-
            Name of the Credit - will either be the currency or name of the
            metric
          example: GBP
        originalAmount:
          type: string
          description: Amount of credits originally granted
          example: '10'
        currentBalance:
          type: string
          description: Amount remaining of Credits Granted
          example: '1'
        expiryDate:
          type: string
          description: Last Day Credit Grant can be consumed
          format: date
          example: '2024-01-02'
        costOfCredit:
          type: string
          description: Cost of credit grant
          example: '10'
        taxRateId:
          type: string
          description: Tax Rate ID for Credit Purchase
          example: b3c37ea3-96bb-44fb-baed-01eb38d3328e
        effectiveDate:
          type: string
          description: First Day Credit Grant can be consumed
          format: date
          example: '2024-01-01'
        createdAt:
          type: string
          description: The created at
          example: '2024-01-01T12:00:00Z'
    PaginationMeta:
      type: object
      description: Results pagination
      example:
        after: MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3
        before: MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz
        totalResultSize: 10
      properties:
        after:
          type: string
          description: Cursor for the page after this (if it exists)
          example: MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3
        before:
          type: string
          description: Cursor for the page before this (if it exists)
          example: MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz
        totalResultSize:
          type: integer
          description: Total number of entries across all pages
          format: int64
          example: 10
    CreditType:
      type: string
      example: CASH
      enum:
        - CASH
        - USAGE
    Currency:
      type: string
      example: GBP
      enum:
        - AED
        - ARS
        - AUD
        - BRL
        - BGN
        - CAD
        - CHF
        - CLP
        - CNY
        - COP
        - CZK
        - DKK
        - EGP
        - EUR
        - GBP
        - HKD
        - ILS
        - INR
        - ISK
        - JPY
        - KRW
        - MXN
        - NOK
        - NZD
        - PLN
        - SAR
        - SEK
        - SGD
        - THB
        - USD
        - UYU
        - ZAR

````