Skip to main content
POST
/
v1
/
customers
/
{Customer}
/
subscriptions
Create Customer Subscription
curl --request POST \
  --url https://api.ecrypt.com/v1/customers/{Customer}/subscriptions \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "payment": {
    "stored": {
      "wallet": "<string>",
      "initiatedBy": "<string>"
    }
  },
  "subscriptionId": "<string>",
  "start": "2023-11-07T05:31:56Z",
  "skipFirstPayment": true
}
'
{
  "requestId": "000000000000000000000",
  "customerSubscription": {
    "payment": {
      "stored": {
        "wallet": "<string>",
        "initiatedBy": "<string>"
      }
    },
    "id": "<string>",
    "subscriptionId": "<string>",
    "start": "2023-11-07T05:31:56Z",
    "skipFirstPayment": true
  },
  "errors": [
    {
      "type": "<string>",
      "message": "<unknown>"
    }
  ]
}

Authorizations

x-api-key
string
header
required

Authorization by x-api-key inside request's header

Path Parameters

Customer
string
default:00000000-0000-0000-0000-000000000000
required

Customer is the Ecrypt customer identifier.

Example: 00000000-0000-0000-0000-000000000000

Required string length: 8 - 64
Pattern: ^[0-9A-Za-z-]*$

Body

payment
object
required
subscriptionId
string
start
string<date-time> | null
skipFirstPayment
boolean

Response

object | null

OK

requestId
string
default:000000000000000000000
required
Required string length: 1 - 100
customerSubscription
object
errors
(object | null)[] | null