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

# List of Subscriptions



## OpenAPI

````yaml get /v1/subscriptions/list
openapi: 3.0.1
info:
  title: SwipeAPI
  description: Partner API
  version: '2.0'
servers:
  - url: https://app.getswipe.in/api/partner
security:
  - bearerAuth: []
tags:
  - name: Document
    description: Document related operations
  - name: Customer
    description: Customer related operations
  - name: Payment
    description: Payment related operations
  - name: Product
    description: Product related operations
  - name: Utility
    description: Generic operations
  - name: Subscriptions
    description: Subscriptions related operations
  - name: Document V2
    description: Document related operations
  - name: Customer V2
    description: Customer related operations
  - name: Payment V2
    description: Payment related operations
  - name: Product V2
    description: Product related operations
  - name: Subscriptions V2
    description: Subscriptions related operations
  - name: Utility V2
    description: Generic operations
  - name: Vendor V2
    description: Vendor related operations
  - name: EwayBill
    description: EwayBill related operations
  - name: Inventory V2
    description: Inventory related operations
paths:
  /v1/subscriptions/list:
    get:
      tags:
        - Subscriptions
      summary: List of Subscriptions
      operationId: get_transactions
      parameters:
        - name: start_date
          in: query
          description: Start date for the list, [DD-MM-YYY]
          required: true
          schema:
            type: string
            default: 01-01-2024
        - name: end_date
          in: query
          description: End date for the list, [DD-MM-YYY]
          required: true
          schema:
            type: string
            default: 31-12-2024
        - name: status
          in: query
          description: Filter list based on status of the document
          schema:
            type: string
            default: all
            enum:
              - all
              - active
              - expired
              - error
              - cancelled
        - name: num_records
          in: query
          description: Number of records to fetch
          schema:
            type: string
            default: '10'
        - name: page
          in: query
          description: Page number
          schema:
            type: integer
            default: 1
        - name: customer_id
          in: query
          description: Customer ID
          schema:
            type: string
      responses:
        '200':
          description: Subscription List fetched successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ListSubscriptions'
        '400':
          description: Error in fetching subscription list
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubscriptionErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubscriptionErrorResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SubscriptionErrorResponse'
components:
  schemas:
    ListSubscriptions:
      type: object
      properties:
        success:
          type: boolean
          description: Success flag
          example: true
        message:
          type: string
          description: Message
          example: Details Fetched
        error_code:
          type: string
          description: Error code
          example: ''
        errors:
          type: object
          properties: {}
          description: Error details
        data:
          $ref: '#/components/schemas/ListSubscriptionData'
    SubscriptionErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          example: true
          default: true
        message:
          type: string
          description: Success Message
          example: Message
        error_code:
          type: string
          description: Error Code
          example: ''
        errors:
          type: object
          properties: {}
          description: Error details
        data:
          type: object
          properties: {}
          description: Data
    ListSubscriptionData:
      type: object
      properties:
        transactions:
          type: array
          description: List of subscriptions
          items:
            $ref: '#/components/schemas/SubscriptionDetails'
        total_records:
          type: integer
          description: Total number of records
          example: 10
    SubscriptionDetails:
      type: object
      properties:
        customer_id:
          type: string
          description: Customer ID
          example: Cust123
        customer_name:
          type: string
          description: Customer Name
          example: CUST123
        subscription_date:
          type: string
          description: Subscription Date
          example: 10 June 2024
        subscription_start_time:
          type: string
          description: Subscription Start Time
          example: 10 June 2024
        subscription_end_time:
          type: string
          description: Subscription End Time
          example: 10 Aug 2024
        sub_serial_number:
          type: string
          description: Subscription Serial Number
          example: SUB-123
        repeat_every:
          type: integer
          description: Repeat Every
          example: 1
        repeat_unit:
          type: string
          description: Repeat Unit
          example: months
          enum:
            - days
            - weeks
            - months
            - years
        status:
          type: string
          description: Subscription Status
          example: active
          enum:
            - active
            - expired
            - cancelled
        invoice_count:
          type: integer
          description: Invoices Count
          example: 1
        invoices:
          type: array
          description: List of invoices under this subscription
          items:
            $ref: '#/components/schemas/Invoice'
        last_created_invoice:
          type: string
          description: Last Created Invoice Date
          example: 10 June 2024
        upcoming_date:
          type: string
          description: Upcoming Date
          example: 10 June 2024
        hash_id:
          type: string
          description: Hash ID
          example: SUB123
        total_amount:
          type: number
          description: Total Amount
          example: 1000
    Invoice:
      type: object
      properties:
        name:
          type: string
          description: Customer Name
          example: CUST123
        id:
          type: string
          description: Customer ID
          example: Cust123
        serial_number:
          type: string
          description: Serial Number
          example: INV-123
        status:
          type: string
          description: Status
          example: active
          enum:
            - paid
            - pending
            - cancelled
        hash_id:
          type: string
          description: Hash ID
          example: SUB123
        record_time:
          type: string
          description: Record Time
          example: 10 June 2024
        total_amount:
          type: number
          description: Total Amount
          example: 1000
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Bearer authentication header of the form Bearer <token>, where <token>
        is your auth token.

````