Create Subscription
Create a new subscription with items, coupons, and payment methods.
Important: For most use cases, use the Checkout/Payment Link API (/v2/payment_links) instead. It generates a payment link that you can embed in your own web page or redirect to.
Use Cases:
- Create a subscription and manually marking it as paid for reference
- Automated subscription creation
Request body
Whether to send a notification to the consumer about the subscription's first invoice
Subscription description or notes
List of coupon UUIDs to apply for discounts on subscription invoices
UUID of the consumer who will subscribe
UUID of the beneficiaries to the consumer who will subscribe
Start date of the first billing cycle. For trial subscriptions, this must be a future date — the trial runs from now until this date.
Number of billing cycles before the subscription automatically cancels. If not specified, the subscription continues indefinitely until manually canceled.
If enabled, all coupons (subscription-level and item-level) will be excluded when the payer chooses installments. The payer will need to pay the full amount without discounts when paying by installments.
ISO 4217 currency codes supported by Moyasar.
Includes all currencies supported by Moyasar payment gateway.
Whether this is a free trial subscription. If true, the trial starts now and billing begins at period_start.
Response
Successful Response
Creation timestamp of the object.
Last modification timestamp of the object.
Unique identifier (UUID) of the subscription
Description of the subscription
Total subscription amount after discounts
Original subscription amount before discounts
Total amount discounted at the item level
Number of days remaining in the current billing period
ISO 4217 currency codes supported by Moyasar.
Includes all currencies supported by Moyasar payment gateway.
Amount in home currency (SAR) at creation
Exchange rate used at subscription creation
Number of intervals per billing cycle (e.g., 2 for bi-monthly)
Start date and time of the current billing period
End date and time of the current billing period
Current cycle number of the subscription
Whether the subscription will be canceled at the end of the current period
Cycle number at which the subscription will be automatically canceled
Date and time when the subscription started
Date and time when the subscription ended
Unique identifier (UUID) of the user who created the subscription
Unique identifier (UUID) of the organization consumer
Unique identifier (UUID) of the most recent invoice for this subscription
Number of days for the free trial period
Date and time when the trial period ends
Subscription amount in smallest currency unit (e.g. halala for SAR).
Original subscription amount (before discounts) in smallest currency unit.
Changes
No recorded changes to this endpoint across all 1 revision of this API.