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

# Get credit note list

> List credit notes given a `next` or `previous` cursor and a limit. If cursor is not provided you will get the beginning of the search set



## OpenAPI

````yaml /openAPI/openapi-20240301.json get /credit_notes
openapi: 3.1.0
info:
  title: zenskar
  version: 2.0.0
servers:
  - url: https://api.zenskar.com
security:
  - ApiTokenAuth: []
    OrganisationAuth: []
paths:
  /credit_notes:
    get:
      tags:
        - Credit Notes
      summary: Get credit note list
      description: >-
        List credit notes given a `next` or `previous` cursor and a limit. If
        cursor is not provided you will get the beginning of the search set
      operationId: Get-credit-note-list
      parameters:
        - name: cursor
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              The cursor indicating a unique set of results - this should be
              auto generated and you get it from the `next` and `previous`
              fields of the response
            examples:
              - V2VsbCBhcmV1IGN1cmlvdxM=
            title: Cursor
          description: >-
            The cursor indicating a unique set of results - this should be auto
            generated and you get it from the `next` and `previous` fields of
            the response
        - name: limit
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            description: The number of results to return - defaults to 10
            examples:
              - 10
            title: Limit
          description: The number of results to return - defaults to 10
        - name: order
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            examples:
              - '-created_at'
            title: Order
        - name: search
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            examples:
              - currency=inr,status=issued
            title: Search
        - name: sort_key
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            examples:
              - sort_key=id
            title: Sort Key
        - name: sort_type
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            examples:
              - sort_key=asc
            title: Sort Type
        - name: id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Id
        - name: id__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Id  In
        - name: id__not_in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Id  Not In
        - name: customer_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Customer Id
        - name: customer_id__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Customer Id  In
        - name: customer_id__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Customer Id  Isnull
        - name: invoice_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            title: Invoice Id
        - name: invoice_id__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Invoice Id  In
        - name: invoice_id__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Invoice Id  Isnull
        - name: status
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Status
        - name: status__ilike
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Status  Ilike
        - name: status__like
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Status  Like
        - name: status__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Status  In
        - name: status__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Status  Isnull
        - name: amount
          in: query
          required: false
          schema:
            anyOf:
              - type: number
              - type: 'null'
            title: Amount
        - name: amount__neq
          in: query
          required: false
          schema:
            anyOf:
              - type: number
              - type: 'null'
            title: Amount  Neq
        - name: amount__gt
          in: query
          required: false
          schema:
            anyOf:
              - type: number
              - type: 'null'
            title: Amount  Gt
        - name: amount__gte
          in: query
          required: false
          schema:
            anyOf:
              - type: number
              - type: 'null'
            title: Amount  Gte
        - name: amount__lt
          in: query
          required: false
          schema:
            anyOf:
              - type: number
              - type: 'null'
            title: Amount  Lt
        - name: amount__lte
          in: query
          required: false
          schema:
            anyOf:
              - type: number
              - type: 'null'
            title: Amount  Lte
        - name: amount__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Amount  Isnull
        - name: amount__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Amount  In
        - name: created_at
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At
        - name: created_at__neq
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Neq
        - name: created_at__gt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Gt
        - name: created_at__gte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Gte
        - name: created_at__lt
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Lt
        - name: created_at__lte
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Created At  Lte
        - name: created_at__isnull
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            title: Created At  Isnull
        - name: created_at__in
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Created At  In
        - name: credit_note_number__ilike
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Credit Note Number  Ilike
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/PaginatedResults_CreditNoteResponseSchema_
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    PaginatedResults_CreditNoteResponseSchema_:
      properties:
        next:
          anyOf:
            - type: string
            - type: 'null'
          title: Next
          description: The cursor for the next page of results
          examples:
            - V2VsbCBhcmV1IGN1cmlvdxM=
        previous:
          anyOf:
            - type: string
            - type: 'null'
          title: Previous
          description: The cursor for the previous page of results
          examples:
            - GmBsbCBhcmV1IGN1cmlvdxM=
        total_count:
          anyOf:
            - type: integer
            - type: 'null'
          title: Total Count
          description: The total count of rows
        results:
          items:
            $ref: '#/components/schemas/CreditNoteResponseSchema'
          type: array
          title: Results
          description: The results for the current page
      type: object
      required:
        - results
      title: PaginatedResults[CreditNoteResponseSchema]
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    CreditNoteResponseSchema:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: ID
        amount:
          type: integer
          title: Amount
          description: Amount in lowest denomination of the currency
        credits_returned:
          anyOf:
            - type: integer
            - type: 'null'
          title: Credits Returned
          description: Credits amount in lowest denomination of the currency
        currency:
          type: string
          title: Currency
          description: Currency
        customer_id:
          type: string
          format: uuid
          title: Customer Id
          description: Customer ID
        customer:
          anyOf:
            - $ref: '#/components/schemas/app__invoice__schema__DetailsObject'
            - type: 'null'
          description: Customer Object
        invoice:
          anyOf:
            - $ref: '#/components/schemas/app__invoice__schema__DetailsObject'
            - type: 'null'
          description: Invoice Object
        invoice_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Invoice Id
          description: Invoice ID
        status:
          $ref: '#/components/schemas/CreditNoteStatuses'
          description: Status
        repayment_method:
          $ref: '#/components/schemas/CreditNoteRepaymentMethods'
          description: Repayment Method
        line_items_url:
          type: string
          title: Line Items Url
          description: Line Items URL
        custom_data:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Custom Data
          description: Custom Data Dictionary
        created_at:
          type: string
          format: date-time
          title: Created At
          description: Created At
        credit_note_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Credit Note Number
          description: Credit Note Number
      type: object
      required:
        - id
        - amount
        - currency
        - customer_id
        - status
        - repayment_method
        - line_items_url
        - created_at
      title: CreditNoteResponseSchema
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    app__invoice__schema__DetailsObject:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
        external_id:
          anyOf:
            - type: string
            - type: 'null'
          title: External Id
      type: object
      required:
        - id
      title: DetailsObject
    CreditNoteStatuses:
      type: string
      enum:
        - in_progress
        - issued
        - void
        - paid
      title: CreditNoteStatuses
    CreditNoteRepaymentMethods:
      type: string
      enum:
        - credits
        - invoice_adjusted
        - external_payment
        - credits_against_payment
        - original_payment_method
      title: CreditNoteRepaymentMethods
  securitySchemes:
    ApiTokenAuth:
      type: apiKey
      in: header
      name: x-api-key
      x-default: <your-api-key>
    OrganisationAuth:
      type: apiKey
      in: header
      name: organisation
      x-default: <your-organisation-id>

````