curl --request POST \
--url https://sbx.api.easybilling.cloud/billing/api/contract-actions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"accountNumber": "ACC-0000000001",
"actions": [
{
"type": "create-contract-with-plan",
"createContractWithPlan": [
{
"planId": "16ad814a-dd1b-41c8-9b4b-4e8551170fee",
"effectiveDate": "2026-02-01",
"expirationDate": "2027-02-01",
"currency": [
"USD"
]
}
],
"immediatelyPay": true,
"paymentInfo": {
"paymentGatewayType": "stripe-connect",
"paymentSuccessUrl": "https://sbx.app.easybilling.cloud/customer/info?type=paymentSuccess",
"paymentCancelUrl": "https://sbx.app.easybilling.cloud/customer/info?type=paymentFailed"
}
}
]
}
'{
"contractActionNumber": "CA-0000000176",
"contractInfo": {
"accountNumber": "A000-525",
"contractNumber": "CT-0000000085",
"effectiveDate": "2025-07-01",
"expirationDate": "2026-07-01",
"status": "active",
"contractSegments": [
{
"accountNumber": "A000-525",
"contractNumber": "CT-0000000085",
"previousContractSegmentId": null,
"effectiveDate": "2025-07-01",
"expirationDate": "2026-07-01",
"currency": [
"CNY"
],
"planId": "16ad814a-dd1b-41c8-9b4b-4e8551170fee",
"billingCycleDay": 1,
"billingCycleType": "monthly",
"status": "active",
"id": "979b1d96-1d82-4270-9d95-9db7c77fc237",
"createdAt": "2025-07-13T03:41:23.723864Z",
"updatedAt": "2025-07-13T03:41:23.723868Z",
"createdBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542",
"updatedBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542"
}
],
"id": "06380c37-9fbe-439f-bb38-926745116471",
"createdAt": "2025-07-13T03:41:23.726906Z",
"updatedAt": "2025-07-13T03:41:23.726910Z",
"createdBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542",
"updatedBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542"
},
"paymentResults": [
{
"documentId": "b3b2a701-c51e-45a9-9bdc-89d6786cf0eb",
"legalDocumentType": "invoice",
"paymentGatewayType": "stripe-connect",
"sessionId": "b3b2a701xxxx45a99bdc89d6786cxxxx",
"sessionUrl": "https://checkout.stripe.com/c/pay/cs_test_sampleDataReplaceABCDEFGhijklmnopQRSTUVWXYZ1234567890abcdefghijklm#fidnandhSAMPLEWIDTHxKEEPlengthPATTERNreplaceALLcharactersWITHrandomLETTERSnumbersANDsymbolsFORtestingOnlyNOTvalidStripeKEYpurposeKEEPunderscoresANDpercentsANDhashfragmentsLENGTHexactMATCHoriginalURLbutMEANINGlessCONTENT"
}
]
}contract action
Create Contract Action
POST
/
api
/
contract-actions
curl --request POST \
--url https://sbx.api.easybilling.cloud/billing/api/contract-actions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"accountNumber": "ACC-0000000001",
"actions": [
{
"type": "create-contract-with-plan",
"createContractWithPlan": [
{
"planId": "16ad814a-dd1b-41c8-9b4b-4e8551170fee",
"effectiveDate": "2026-02-01",
"expirationDate": "2027-02-01",
"currency": [
"USD"
]
}
],
"immediatelyPay": true,
"paymentInfo": {
"paymentGatewayType": "stripe-connect",
"paymentSuccessUrl": "https://sbx.app.easybilling.cloud/customer/info?type=paymentSuccess",
"paymentCancelUrl": "https://sbx.app.easybilling.cloud/customer/info?type=paymentFailed"
}
}
]
}
'{
"contractActionNumber": "CA-0000000176",
"contractInfo": {
"accountNumber": "A000-525",
"contractNumber": "CT-0000000085",
"effectiveDate": "2025-07-01",
"expirationDate": "2026-07-01",
"status": "active",
"contractSegments": [
{
"accountNumber": "A000-525",
"contractNumber": "CT-0000000085",
"previousContractSegmentId": null,
"effectiveDate": "2025-07-01",
"expirationDate": "2026-07-01",
"currency": [
"CNY"
],
"planId": "16ad814a-dd1b-41c8-9b4b-4e8551170fee",
"billingCycleDay": 1,
"billingCycleType": "monthly",
"status": "active",
"id": "979b1d96-1d82-4270-9d95-9db7c77fc237",
"createdAt": "2025-07-13T03:41:23.723864Z",
"updatedAt": "2025-07-13T03:41:23.723868Z",
"createdBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542",
"updatedBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542"
}
],
"id": "06380c37-9fbe-439f-bb38-926745116471",
"createdAt": "2025-07-13T03:41:23.726906Z",
"updatedAt": "2025-07-13T03:41:23.726910Z",
"createdBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542",
"updatedBy": "d3e40eb2-c5d4-4141-b9d2-c8ebdad3c542"
},
"paymentResults": [
{
"documentId": "b3b2a701-c51e-45a9-9bdc-89d6786cf0eb",
"legalDocumentType": "invoice",
"paymentGatewayType": "stripe-connect",
"sessionId": "b3b2a701xxxx45a99bdc89d6786cxxxx",
"sessionUrl": "https://checkout.stripe.com/c/pay/cs_test_sampleDataReplaceABCDEFGhijklmnopQRSTUVWXYZ1234567890abcdefghijklm#fidnandhSAMPLEWIDTHxKEEPlengthPATTERNreplaceALLcharactersWITHrandomLETTERSnumbersANDsymbolsFORtestingOnlyNOTvalidStripeKEYpurposeKEEPunderscoresANDpercentsANDhashfragmentsLENGTHexactMATCHoriginalURLbutMEANINGlessCONTENT"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Body
application/json
Response
200 - application/json
Show child attributes
Show child attributes
Available options:
active, expired, canceled ⌘I
