1. Billing
  • Jokoor API Documentation
  • Getting started
    • Authentication
    • Pagination
    • Quick Start
    • Error Handling
    • Response Format
  • Payments
    • Payment Links
    • Checkouts
    • Payment Status
  • SMS
    • SMS Templates
    • Resending SMS Messages
    • Message Segments
    • SMS Contact Groups
    • SMS Contacts
    • SMS Campaigns
    • Sending SMS Messages
  • Billing
    • Invoices
    • Invoice Payments (Offline/Manual Recording)
    • Receipts
    • Subscriptions
  • Resources
    • Donations
    • Customers
    • Products
    • Transactions
    • Refunds
  • Payouts
    • Payout Requests
    • Bank Accounts
    • Recipient Payouts
    • Payout Recipients
    • Payout Reversals
    • Payout Balance
    • Bulk Payout Operations
    • Payout Deposits
  • Webhooks
    • Webhook Events
    • Webhook Endpoints
  • APIs
    • Health
      • Health check
    • SMS
      • Send SMS message
      • List SMS messages
      • Get SMS message details
      • Send a draft SMS message
      • Resend failed SMS
      • Batch resend failed messages
    • SMS Templates
      • Create SMS template
      • List SMS templates
      • Get SMS template
      • Update SMS template
      • Delete SMS template
    • SMS Contacts
      • Create contact
      • List contacts
      • Get contact
      • Update contact
      • Delete contact
    • SMS Contact Groups
      • Create contact group
      • List contact groups
      • Get contact group
      • Update contact group
      • Delete contact group
      • Add contacts to group
      • Remove contacts from group
    • SMS Campaigns
      • Create SMS campaign
      • List SMS campaigns
      • Get SMS campaign
      • Update SMS campaign
      • Delete SMS campaign
      • Send SMS campaign
      • Send draft SMS campaign
      • Send campaign asynchronously
      • Get campaign messages
      • Get campaign statistics
      • Resend failed campaign messages
    • SMS Analytics
      • Get segment analytics
      • Preview message segments
    • Checkouts
      • Create checkout session
      • Get checkout session
      • Cancel checkout
    • Payment Links
      • Create payment link
      • List payment links
      • Get payment link
      • Update payment link
      • Delete payment link
    • Invoices
      • Create invoice
      • List invoices
      • Get invoice
      • Update invoice
      • Cancel invoice
      • Finalize draft invoice
      • Send invoice via email
      • Download invoice PDF
      • Record invoice payment
      • List invoice payments
      • Get invoice receipts
    • Receipts
      • List receipts
      • Get receipt by ID
      • Get receipt by number
      • Download receipt PDF
    • Transactions
      • List transactions
      • Get transaction
    • Refunds
      • Refund transaction
      • List refunds
      • Get refund
    • Customers
      • Create or retrieve customer
      • List customers
      • Get customer
      • Update customer
      • Delete customer
    • Products
      • Create product
      • List products
      • Get product
      • Update product
      • Delete product
    • Donations
      • Create donation campaign
      • List donation campaigns
      • Get donation campaign
      • Update donation campaign
      • Delete donation campaign
    • Subscriptions
      • Create subscription
      • List subscriptions
      • Get subscription
      • Update subscription
      • Cancel subscription
      • List subscription invoices
      • Trigger subscription processing
    • Payouts
      • Get payout balance
      • List bank accounts
      • Create payout request
      • List payout requests
      • Get payout request
      • Cancel payout request
      • List deposit transactions
      • Get deposit transaction
    • Payout Recipients
      • Create payout recipient
      • List payout recipients
      • Get payout recipient
      • Update payout recipient
      • Delete payout recipient
      • Send payout to recipient
      • List recipient payouts
      • Get recipient payout
      • Reverse or cancel recipient payout
      • Send bulk payouts to recipients
      • Get bulk payout batch status
      • Upload CSV for bulk payouts
      • Process uploaded CSV bulk payouts
      • Send bulk payouts by recipient type
    • Webhooks
      • Create webhook endpoint
      • List webhook endpoints
      • Get webhook endpoint
      • Update webhook endpoint
      • Delete webhook endpoint
      • Test webhook endpoint
    • Webhook Events
      • List webhook events
      • Get webhook event
      • Retry webhook event
  • Schemas
    • Schemas
    • ErrorResponse
    • HealthResponse
    • SendSMSRequest
    • SMSMessageResponse
    • SMSMessageListResponse
    • BatchResendResponse
    • SMSDashboardResponse
    • SMSPlansListResponse
    • CreateSMSTemplateRequest
    • UpdateSMSTemplateRequest
    • SMSTemplateResponse
    • SMSTemplateListResponse
    • CreateSMSContactRequest
    • UpdateSMSContactRequest
    • SMSContactResponse
    • SMSContactListResponse
    • CreateSMSContactGroupRequest
    • UpdateSMSContactGroupRequest
    • SMSContactGroupResponse
    • SMSContactGroupListResponse
    • CreateSenderIDRequest
    • UpdateSenderIDRequest
    • SenderIDResponse
    • SenderIDListResponse
    • CreateSMSCampaignRequest
    • UpdateSMSCampaignRequest
    • SMSCampaignResponse
    • SMSCampaignListResponse
    • CreateCheckoutRequest
    • CheckoutResponse
    • InitializePaymentRequest
    • InitializePaymentResponse
    • PaymentStatusResponse
    • PaymentSessionResponse
    • CreatePaymentLinkRequest
    • UpdatePaymentLinkRequest
    • PaymentLinkResponse
    • PaymentLinkListResponse
    • CreateInvoiceRequest
    • UpdateInvoiceRequest
    • RecordInvoicePaymentRequest
    • InvoiceResponse
    • InvoiceListResponse
    • InvoicePaymentListResponse
    • InvoiceReceiptInfo
    • Receipt
    • ListReceiptsResponse
    • CreateSubscriptionRequest
    • SubscriptionResponse
    • SubscriptionListResponse
    • UpdateSubscriptionRequest
    • TransactionResponse
    • TransactionListResponse
    • RefundResponse
    • RefundListResponse
    • CreateCustomerRequest
    • UpdateCustomerRequest
    • CustomerResponse
    • CustomerListResponse
    • CreateProductRequest
    • UpdateProductRequest
    • ProductResponse
    • ProductListResponse
    • CreateDonationCampaignRequest
    • UpdateDonationCampaignRequest
    • DonationCampaignResponse
    • DonationCampaignListResponse
    • PayoutBalanceResponse
    • CreateBankAccountRequest
    • BankAccountResponse
    • CreatePayoutRequest
    • PayoutRequestResponse
    • PayoutRequestListResponse
    • CreatePayoutRecipientRequest
    • UpdatePayoutRecipientRequest
    • PayoutRecipientResponse
    • PayoutRecipientListResponse
    • SendRecipientPayoutRequest
    • RecipientPayoutResponse
    • RecipientPayoutListResponse
    • CreateWebhookEndpointRequest
    • DepositTransactionResponse
    • UpdateWebhookEndpointRequest
    • DepositTransactionListResponse
    • WebhookEndpointResponse
    • BulkRecipientPayoutRequest
    • WebhookEndpointListResponse
    • ProcessCSVPayoutRequest
    • WebhookEventResponse
    • BulkPayoutByTypeRequest
    • WebhookEventListResponse
    • BulkPayoutBatchResponse
    • CSVUploadResponse
  1. Billing

Subscriptions

Manage recurring payment subscriptions that automatically generate invoices.

Create Subscription#

Create a new subscription with automatic invoice generation.
Endpoint: POST /v1/pay/subscriptions
Authentication: Required
Request Body:
FieldTypeRequiredDescription
customer_idstringNo*ID of existing customer
customer_emailstringNo*Customer email (required if customer_id not provided)
customer_namestringNo*Customer name (required if customer_id not provided)
customer_phonestringNoCustomer phone number
customer_addressstringNoCustomer address
currencystringYesCurrency code (default: "GMD")
tax_ratenumberNoTax rate as percentage (0-100, default: 0)
intervalstringYesBilling interval (day, week, month, year)
interval_countintegerYesNumber of intervals between billings
day_of_monthintegerNo**Day of month for monthly billing (1-28, required for monthly interval)
day_of_weekintegerNo**Day of week for weekly billing (0=Sunday, 6=Saturday, required for weekly interval)
start_datestringYesSubscription start date (YYYY-MM-DD)
end_datestringNoOptional end date to limit subscription duration (YYYY-MM-DD)
itemsarrayYesSubscription items (minimum 1)
notesstringNoAdditional notes
metadataobjectNoCustom metadata
*Either customer_id or customer_email+customer_name required
**Required based on interval type
Subscription Statuses:
active - Subscription is active, invoices will be generated
paused - Temporarily stopped, no invoices generated
cancelled - Permanently cancelled
completed - Subscription reached its end date
TIP
Billing Intervals:
Daily: interval: "day", interval_count: 1 for daily billing
Weekly: interval: "week", day_of_week: 1 (Monday) for weekly billing
Monthly: interval: "month", day_of_month: 15 for billing on the 15th each month
Yearly: interval: "year", interval_count: 1 for annual billing
Example:
HTTP
TypeScript
Python
Success Response (201):
{
  "data": {
    "id": "sub_abc123",
    "organization_id": "org_xyz789",
    "customer_id": "cus_def456",
    "customer_email": "customer@example.com",
    "customer_name": "John Doe",
    "amount": "1000.00",
    "currency": "GMD",
    "tax_rate": 15,
    "interval": "month",
    "interval_count": 1,
    "day_of_month": 1,
    "start_date": "2024-12-01T00:00:00Z",
    "end_date": null,
    "next_invoice_date": "2024-12-01T00:00:00Z",
    "last_invoice_date": null,
    "status": "active",
    "invoice_count": 0,
    "mode": "test",
    "version": 1,
    "items": [
      {
        "description": "Monthly subscription",
        "quantity": 1,
        "unit_price": "1000.00",
        "total": "1000.00"
      }
    ],
    "notes": null,
    "metadata": {},
    "created_at": "2024-01-15T10:30:00Z",
    "updated_at": "2024-01-15T10:30:00Z"
  }
}

Get Subscription#

Get details of a specific subscription.
Endpoint: GET /v1/pay/subscriptions/{id}
Authentication: Required
Example:
HTTP
TypeScript
Python

List Subscriptions#

Get a paginated list of subscriptions.
Endpoint: GET /v1/pay/subscriptions
Authentication: Required
Query Parameters:
ParameterTypeRequiredDescription
offsetintegerNoNumber of items to skip (default: 0)
limitintegerNoMaximum number of items to return (default: 20, max: 100)
statusstringNoFilter by status (active, paused, cancelled, completed)
Example:
HTTP
TypeScript
Python

Update Subscription#

Update an existing subscription.
Endpoint: PUT /v1/pay/subscriptions/{id}
Authentication: Required
Request Body:
FieldTypeRequiredDescription
statusstringNoStatus (active, paused, cancelled)
end_datestringNoEnd date (YYYY-MM-DD)
amountstringNoNew amount (affects future invoices only)
notesstringNoUpdated notes
Example:
HTTP
TypeScript
Python

Cancel Subscription#

Cancel a subscription immediately.
Endpoint: POST /v1/pay/subscriptions/{id}/cancel
Authentication: Required
Example:
HTTP
TypeScript
Python
WARNING
Permanent Action: Cancelling a subscription is permanent and cannot be undone. Existing invoices remain valid, but no new invoices will be generated.

List Subscription Invoices#

Get all invoices generated by a subscription.
Endpoint: GET /v1/pay/subscriptions/{id}/invoices
Authentication: Required
Query Parameters:
ParameterTypeRequiredDescription
offsetintegerNoNumber of items to skip (default: 0)
limitintegerNoMaximum number of items to return (default: 20, max: 100)
Example:
HTTP
TypeScript
Python

Trigger Subscription Processing#

Manually trigger invoice generation for subscriptions that are due.
Endpoint: POST /v1/pay/subscriptions/trigger-processing
Authentication: Required
Example:
HTTP
TypeScript
Python
INFO
Testing: This endpoint is useful for testing subscription billing in test mode. In production, subscriptions are automatically processed by the background worker.
Modified at 2025-11-15 15:43:35
Previous
Receipts
Next
Donations
Built with