Reference
//
Create subscription
Creates a new subscription with specified configuration
Security
oauth2ClientCredentials(Required scopes: subscriptions:write)
- Mock serverhttps://developer.boyahq.com/_mock/v2/openapi/subscriptions/create
- Productionhttps://api.boyahq.com/v2/subscriptions/create
- Sandboxhttps://sandbox.api.boyahq.com/v2/subscriptions/create
curl -i -X POST \
https://developer.boyahq.com/_mock/v2/openapi/subscriptions/create \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-H 'business_id: string' \
-H 'org_wallet_ref: string' \
-d '{
"name": "DIGITALOCEAN.COM",
"limit": "10",
"cards": [
"683ee0b950009c749ba23312"
],
"assignee": "67befe9f17f57a814696e291",
"status": "DRAFT",
"frequency_period_unit": "MONTH",
"wallet_name": "xyz - MAIN",
"wallet_currency": "KES",
"wallet_id": "1271",
"web_url": "https://www.digitalocean.com",
"create_new_merchant": false,
"team": {
"_id": "688877881b49af84b1aa11d9",
"code": "74CAAEEA",
"name": "AAR Bamburi"
},
"subcategory": {
"_id": "64f04ea40aac0abfb44b3bb7",
"code": "P003",
"name": "General Materials"
},
"is_request": false,
"org_wallet_ref": 1,
"business_id": "E74490ACDCAF716DC722",
"notes": "Brian Ryb is requesting creation of a DIGITALOCEAN.COM subscription"
}'Subscription created successfully
Subscription status
Enum:"DRAFT""ACTIVE""PAUSED""REJECTED""DELETED""PENDING"
Example:"ACTIVE"
Response
{ "_id": "string", "business": { "_id": "string", "name": "string", "email": "string", "phone": "string", "country": "string" }, "name": "string", "limit": 0, "cards": [ { … } ], "assignee": { "_id": "string", "name": "string", "employee_id": "string", "team_code": "string" }, "status": "ACTIVE", "wallet_id": "string", "wallet_currency": "string", "frequency_period_unit": "string", "frequency": 0, "icon": "string", "merchant_category_code": "string", "merchant_receiver_name": "string", "amount_spent": 0, "last_transacted_amount": 0, "score": 0, "next_invoice_date": "string", "createdAt": "string", "updatedAt": "string", "subcategory": { "_id": "string", "code": "string", "name": "string" }, "team": { "code": "string", "name": "string" } }