# Get subscriptions

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /v2/placement-tests/subscriptions:
    get:
      summary: Get subscriptions
      deprecated: false
      description: >-
        Retrieve all placement test subscriptions for the authenticated user.
        Returns both active and cancelled subscriptions, including Monthly
        recurring subscriptions and LTD (Lifetime Deal) plans.
      tags:
        - placement test
      parameters:
        - name: x-auth-zapmail
          in: header
          description: ''
          required: true
          example: ''
          schema:
            type: string
        - name: x-workspace-key
          in: header
          description: ''
          required: false
          example: ''
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                  message:
                    type: string
                  data:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        subscriptionId:
                          type: string
                        planType:
                          type: string
                        billingCycle:
                          type: string
                        lookupKey:
                          type: string
                        status:
                          type: string
                        monthlyCredits:
                          type: integer
                        usedCredits:
                          type: integer
                        availableCredits:
                          type: integer
                        periodStart:
                          type: string
                        periodEnd:
                          type: string
                        price:
                          type: integer
                        currency:
                          type: string
                        createdAt:
                          type: string
                        cancelledByUser:
                          type: boolean
                      required:
                        - id
                        - subscriptionId
                        - planType
                        - billingCycle
                        - lookupKey
                        - status
                        - monthlyCredits
                        - usedCredits
                        - availableCredits
                        - periodStart
                        - periodEnd
                        - price
                        - currency
                        - createdAt
                        - cancelledByUser
                      x-apidog-orders:
                        - id
                        - subscriptionId
                        - planType
                        - billingCycle
                        - lookupKey
                        - status
                        - monthlyCredits
                        - usedCredits
                        - availableCredits
                        - periodStart
                        - periodEnd
                        - price
                        - currency
                        - createdAt
                        - cancelledByUser
                required:
                  - status
                  - message
                  - data
                x-apidog-orders:
                  - status
                  - message
                  - data
              example:
                status: 200
                message: Placement test subscriptions retrieved successfully
                data:
                  - id: sub_abc123
                    subscriptionId: sub_1AbcDefGhiJklMnop
                    planType: STARTER
                    billingCycle: LTD
                    lookupKey: placement_test_starter_ltd
                    status: ACTIVE
                    monthlyCredits: 30
                    usedCredits: 12
                    availableCredits: 18
                    periodStart: '2024-01-15T00:00:00.000Z'
                    periodEnd: '2025-01-15T00:00:00.000Z'
                    price: 99
                    currency: USD
                    createdAt: '2024-01-15T10:30:00.000Z'
                    cancelledByUser: false
                  - id: sub_def456
                    subscriptionId: sub_2GhiJklMnoPqrStu
                    planType: GROWTH
                    billingCycle: MONTHLY
                    lookupKey: placement_test_growth_monthly
                    status: ACTIVE
                    monthlyCredits: 200
                    usedCredits: 85
                    availableCredits: 115
                    periodStart: '2024-12-01T00:00:00.000Z'
                    periodEnd: '2025-01-01T00:00:00.000Z'
                    price: 49
                    currency: USD
                    createdAt: '2024-11-15T14:20:00.000Z'
                    cancelledByUser: false
          headers: {}
          x-apidog-name: Success
        '401':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                  message:
                    type: string
                  errorId:
                    type: string
                required:
                  - status
                  - message
                  - errorId
                x-apidog-orders:
                  - status
                  - message
                  - errorId
              example:
                status: 401
                message: API key is required
                errorId: uuid-v4-error-id
          headers: {}
          x-apidog-name: Unauthorized
        '500':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                  message:
                    type: string
                  errorId:
                    type: string
                required:
                  - status
                  - message
                  - errorId
                x-apidog-orders:
                  - status
                  - message
                  - errorId
              example:
                status: 500
                message: Internal server error
                errorId: uuid-v4-error-id
          headers: {}
          x-apidog-name: Internal Server Error
      security: []
      x-apidog-folder: placement test
      x-apidog-status: released
      x-run-in-apidog: https://app.apidog.com/web/project/797058/apis/api-25778521-run
components:
  schemas: {}
  securitySchemes: {}
servers:
  - url: https://api.zapmail.ai/api
    description: Prod Env
security: []

```
