{
  "status": "200",
  "example": "{\n    \"id\": \"9741164c-06a1-4dd7-a649-72cca8f9603a\",\n    \"business_recurring_plans_id\": \"973ee344-6737-4897-9929-edbc9d7bf433\",\n    \"customer_name\": \"Paul\",\n    \"customer_email\": \"paul@hitpayapp.com\",\n    \"name\": \"Spotify Premium\",\n    \"description\": \"Spotify Monthly Subscription\",\n    \"reference\": \"cust_id_123\",\n    \"cycle\": \"monthly\",\n    \"cycle_repeat\": null,\n    \"cycle_frequency\": null,\n    \"currency\": \"sgd\",\n    \"amount\": 9.90,\n    \"times_to_be_charged\": 3,\n    \"times_charged\": 0,\n    \"status\": \"scheduled\",\n    \"send_email\": false,\n    \"save_card\": 0,\n    \"redirect_url\": \"https://github.com/\",\n    \"payment_methods\": [\n        \"giro\",\n        \"card\"\n    ],\n    \"created_at\": \"2022-09-13T16:33:47\",\n    \"updated_at\": \"2022-09-13T16:33:47\",\n    \"expires_at\": \"2022-11-11T23:59:59\",\n    \"url\": \"https://securecheckout.sandbox.hit-pay.com/9673bdea-058c-44b5-a957-845a7c487bc2/recurring-plan/9741164c-06a1-4dd7-a649-72cca8f9603a\",\n    \"webhook\": \"https://webhoo.site/test\"\n}"
}

Authorizations

X-BUSINESS-API-KEYheaderrequired
string
X-Requested-With
Default: "XMLHttpRequest"
string

Body

amount
string

It's is required when save card = true and plan_id = null. This is an optional value. By default, the amount from the subscription plan will be used. You can use this parameter for discounts for specific customers.

customer_email
string

Customer email. It's required field

customer_name
string

It's optional field. Customer name

cycle
string

It's is required when plan_id = null. By default, the cycle from the subscription plan will be used.

name
string

It's is required when save card = true or plan_id = null. By default, the name from the subscription plan will be used.

payment_methods
object
plan_id
string

Subscription plan id created from Create a Subscription Plan API. If you would like to create a subscription without a plan, plan_id should be null

redirect_url
string

URL where hitpay redirects the user after the users enters the card details and the subscription is active. Query arguments reference (subscription id) and status are sent along

reference
string
save_card
string

Only set the value “true” if you wish to save the card and charge the customer later on. More details in “Save Card” section

send_email
string

Hitpay to send email receipts to the customer. Default value is false

start_date
string

Billing start date (YYYY-MM-DD) in SGT

times_to_be_charged
integer

It's optional field. if you wish to save the card.

webhook
string

Optional URL value to which hitpay will send a POST request when there is a new charge or if there is an error charging the card

Response

amount
Default: "0"
number
business_recurring_plans_id
string
created_at
string
currency
string
customer_email
string
customer_name
string
cycle
string
cycle_frequency
cycle_repeat
description
string
expires_at
string
id
string
name
string
payment_methods
string[]
redirect_url
string
reference
string
save_card
Default: "0"
integer
send_email
Default: true
boolean
status
string
times_charged
Default: "0"
integer
times_to_be_charged
Default: "0"
integer
updated_at
string
url
string
webhook
string