POST
/
v1
/
payments
curl --request POST \
  --url https://api.getreditus.com/api/v1/payments \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "referral_email": "<string>",
  "referral_id": "<string>",
  "amount": 123,
  "currency": "<string>",
  "idempotency_key": "<string>",
  "subscription_id": "<string>",
  "interval": "<string>",
  "interval_count": 123
}'
{
  "data": {
    "id": "<string>",
    "type": "<string>",
    "attributes": {
      "referral_email": "<string>",
      "referral_id": "<string>",
      "amount": 123,
      "currency": "<string>",
      "idempotency_key": "<string>",
      "subscription_id": "<string>",
      "interval": "<string>",
      "interval_count": 123
    }
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
amount
integer
required

Payment amount (in cents)

currency
string
required

Payment currency - (lowercase, i.e. usd)

idempotency_key
string
required

A unique string to identify this payment. Used to prevent double payments.

referral_email
string

required if referral_id not set - Email of the referral

referral_id
string

required if referral_email not set - Reditus id of the referral

subscription_id
string

Should be the id of the subscription on your side. Used to associate subsequent payments to this subscription.

interval
string

Subscription interval ('month'/'year')

interval_count
integer

Number of intervals the payment is made (default: 1)

Response

202 - application/json
Accepted
data
object