> ## 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.2024-07-30.product.live GET /credits
openapi: 3.0.0
info:
  title: Billing
  description: Manage Billing
  version: 0.0.1
servers:
  - url: https://dev.seqhq.io
    description: E2E
  - url: https://dev.seqhq.io
    description: DEV
  - url: https://sandbox.sequencehq.com
    description: SANDBOX
  - url: https://eu.sequencehq.com
    description: PRODUCTION
security: []
tags:
  - name: Prices
  - name: Discounts
  - name: Credits
  - name: Billing Schedules
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/ListCreditGrantsResponse'
                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:
                ListCreditGrantsResponse:
                  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:
    ListCreditGrantsResponse:
      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/CreditGrant2'
        pagination:
          $ref: '#/components/schemas/PaginationMeta'
    CreditGrant2:
      required:
        - amount
        - costOfCredit
        - createdAt
        - creditUnitType
        - currency
        - customerId
        - id
        - integrationIds
        - name
        - sequenceAccountId
      type: object
      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
      properties:
        id:
          type: string
          description: Credit Grant ID
          example: 746fc7f2-8098-4fe7-953c-7d51c580a126
        sequenceAccountId:
          type: string
          description: Sequence Account ID
          example: dce9ae85-d8d0-42b4-bcad-f221a64363c6
        customerId:
          type: string
          description: The ID of the Customer Credit is granted to
          example: 61b083e0-1faa-47ca-9aeb-6205da8f6c47
        name:
          type: string
          description: Name of the Credit Grant
          example: On-boarding Credits
        creditUnitType:
          $ref: '#/components/schemas/CreditUnitType'
          description: Type of the Unit of Credit
        currency:
          $ref: '#/components/schemas/Currency'
          description: Currency of Cash Credit (if CreditUnitType is CURRENCY)
        metricId:
          type: string
          description: Metric ID (if CreditUnitType is METRIC)
          example: f092246c-6b90-4106-bcca-304ccf06bf45
        amount:
          type: number
          description: Amount of Units Granted
          example: 10
        costOfCredit:
          type: number
          description: Cost of Credit Grant, to be Invoiced to the Customer
          example: 10
        taxRateId:
          type: string
          description: Tax Rate ID for Credit Purchase
          example: 179d1ab3-cc96-48e2-9310-067b0b42d47c
        effectiveDate:
          type: string
          description: First Day Credit Grant can be consumed
          example: '2023-01-01'
        expiryDate:
          type: string
          description: Last Day Credit Grant can be consumed
          example: '2023-01-31'
        createdAt:
          type: string
          description: The created at
          example: '2022-10-07T14:12:08.826121Z'
        creditNoteId:
          type: string
          description: ID of the credit note that created this grant (if applicable)
          example: 73086198-8752-4ec9-a99b-16209a32dc6c
        integrationIds:
          type: array
          description: IDs in external integrations
          example:
            - service: Xero
              id: 74ed2615-4730-49ab-9445-74f31723a206
              isPending: false
          items:
            $ref: '#/components/schemas/IntegrationId'
    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
    CreditUnitType:
      type: string
      example: CURRENCY
      enum:
        - CURRENCY
        - METRIC
    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
    IntegrationId:
      required:
        - id
        - isPending
        - service
      type: object
      example:
        service: Xero
        id: '123'
        isPending: false
      properties:
        service:
          $ref: '#/components/schemas/IntegrationService'
        id:
          type: string
          example: '123'
        isPending:
          type: boolean
          example: false
    IntegrationService:
      type: string
      example: Xero
      enum:
        - Amazon_Redshift
        - GoCardless
        - Google_BigQuery
        - Google_Sheets
        - HubSpot
        - NetSuite
        - QuickBooks_Online
        - Salesforce
        - Slack
        - Snowflake
        - Stripe
        - Xero
        - Avalara
        - Anrok
        - Attio
        - Numeral
        - Rillet
        - Sphere

````