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

# Create Customer Subscription

> Create a customer subscription for a customer.



## OpenAPI

````yaml https://cdn.ecrypt.dev/swagger/gateway-swagger-v25.json post /v1/customers/{Customer}/subscriptions
openapi: 3.0.4
info:
  title: Ecrypt.Gateway.Api
  description: Ecrypt API
  contact:
    name: Ecrypt
    url: https://www.ecrypt.com/
    email: Engineering@Ecrypt.com
  version: 1.0.0.0
servers: []
security: []
paths:
  /v1/customers/{Customer}/subscriptions:
    post:
      tags:
        - Customers Subscription
      summary: Create Customer Subscription
      description: Create a customer subscription for a customer.
      parameters:
        - name: Customer
          in: path
          description: "`Customer` is the Ecrypt customer identifier.\r\n\r\nExample: 00000000-0000-0000-0000-000000000000"
          required: true
          schema:
            maxLength: 64
            minLength: 8
            pattern: ^[0-9A-Za-z-]*$
            type: string
            default: 00000000-0000-0000-0000-000000000000
          example: 00000000-0000-0000-0000-000000000000
      requestBody:
        description: ''
        content:
          application/json:
            schema:
              $ref: >-
                #/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateRequest
          text/json:
            schema:
              $ref: >-
                #/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateRequest
          application/*+json:
            schema:
              $ref: >-
                #/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateRequest
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateResponse
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Ecrypt.Gateway.Api.Core.Model.BadRequest'
        '404':
          description: Not Found
        '429':
          description: Too Many Requests
components:
  schemas:
    Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateRequest:
      required:
        - payment
      type: object
      properties:
        id:
          type: string
          nullable: true
          readOnly: true
        subscription_id:
          type: string
          nullable: true
        start:
          type: string
          format: date-time
          nullable: true
        skip_first_payment:
          type: boolean
        payment:
          $ref: '#/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.Payment'
      additionalProperties: false
    Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateResponse:
      required:
        - requestId
      type: object
      properties:
        customer_subscription:
          $ref: >-
            #/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.CustomerSubscriptionCreateRequest
        request_id:
          maxLength: 100
          minLength: 1
          type: string
          default: '000000000000000000000'
        errors:
          type: array
          items:
            $ref: >-
              #/components/schemas/Ecrypt.Gateway.Api.Core.Model.ResponseBaseError
          nullable: true
      additionalProperties: false
    Ecrypt.Gateway.Api.Core.Model.BadRequest:
      required:
        - requestId
      type: object
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Ecrypt.Gateway.Api.Core.Model.BadRequestError'
          nullable: true
        request_id:
          maxLength: 100
          minLength: 1
          type: string
          default: '000000000000000000000'
      additionalProperties: false
    Ecrypt.Gateway.Api.Core.Model.Customers.Payment:
      required:
        - stored
      type: object
      properties:
        stored:
          $ref: '#/components/schemas/Ecrypt.Gateway.Api.Core.Model.Customers.Stored'
      additionalProperties: false
    Ecrypt.Gateway.Api.Core.Model.ResponseBaseError:
      type: object
      properties:
        type:
          type: string
          nullable: true
        message:
          nullable: true
      additionalProperties: false
    Ecrypt.Gateway.Api.Core.Model.BadRequestError:
      type: object
      properties:
        type:
          type: string
          nullable: true
        message:
          nullable: true
      additionalProperties: false
    Ecrypt.Gateway.Api.Core.Model.Customers.Stored:
      required:
        - wallet
      type: object
      properties:
        wallet:
          minLength: 1
          type: string
        initiated_by:
          type: string
          nullable: true
      additionalProperties: false

````