Schedule
The Schedule Payment API sets up recurring or future-dated payments.
Endpoint
/v1/External/SchedulePayment
Http Request Method
POST
Request Header
See authorization.
Request Body
note
* Indicates required field.
* Required when using a credit card.
* Indicates suggested field.
* Required when using ACH.
Name | Type | Description | Child Attributes | |
---|---|---|---|---|
orgGUID * | string | Identifier for the organization receiving the funds. | ||
scheduleDetails | object | Details of the payment schedule. | ||
donor | object | Information about the donor. Learn more about matching to an existing donor or creating a new donor record. | ||
campaign | object | Campaign details. Learn more about matching to an existing campaign or creating a new record. | ||
reason | object | Provide when the donation should be applied to one reason. Learn more about matching to an existing reason record or creating one. | ||
amount | double | Total sum to be paid in the schedule, including initial payment. | ||
card * | object | Credit card information; for a credit card payment. | ||
paymentMethodId | string | Method of payment, format as follows:
OJC
Credit_Card
Matbia
Pledger
Donors_Fund
ACH | ||
note | string | Additional note for the payment. | ||
paymentDate | string | Date and time of the payment in UTC format. | ||
uniqueTransactionId * | string | Unique identifier for the transaction in GUID format. | ||
currency * | string | Currency of the transaction, the following currencies are supported:
USD
ILS
EUR
CAD
GBP | ⚠️ Your account needs to be set up to accept the necessary currencies. | |
reasons | array of objects | Provide this field when there are multiple reasons the payment should be applied to. | ⓘ The system will create a pledge for each reason and apply the payment accordingly | |
bankAccount * | object | Bank account information; for an ACH payment. |
Response
Name | Type | Description | Child Attributes | |
---|---|---|---|---|
scheduleNum | int | Identifier for the payment schedule. | ||
scheduleTotal | int | Total amount charged for the schedule. | ||
receiptNum | string | Receipt number associated with the payment. | ||
amount | int | Amount of the payment. | ||
accountId | int | Account ID of the donor associated with the payment. | ||
currency | string | Currency code used for the payment. | ||
paymentStatus | string | Status of the payment:
Success
Failed | ||
responseTitle | string | Status | ||
error | object | Details of any error that occurred. |
Example:
cURL:
curl --location 'https://sandbox-api.donary.com/v1/External/SchedulePayment' \
--header 'APIKey: YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{"amount":1,"bankAccount":{"accountNum":null,"accountType":null,"checkType":null,"nameOnAccount":null,"routingNum":null},"campaign":{"campaignName":"BaisMedresh","campaignNum":1001},"card":{"ccNum":"4242424242424242","cvv":"666","expiry":"12/28"},"currency":"USD","donor":{"accountNum":"DNR1015","firstName":"Moshe","lastName":"Green","phoneNumber":"2162544878"},"note":"TestSchedule","orgGUID":"115e9d3d-baf2-4089-b896-9b2621ffcf1b","paymentDate":"2024-12-15","paymentMethodId":"Credit_Card","reason":null,"reasons":[{"reasonAmount":1,"reasonName":"KerenHabinyan","reasonNum":55555},{"reasonAmount":9,"reasonName":"Mamudes","reasonNum":1001}],"scheduleDetails":{"amountPerPayment":1,"firstPaymentAmount":1,"frequencyID":"Daily","startDate":"2024-12-15","totalPaymentsCount":10},"uniqueTransactionId":"5f10f1a9-4d5f-ef48-03b4-e44428e1e60e892"}'
Payload:
{
"amount": 1,
"bankAccount": {
"accountNum": null,
"accountType": null,
"checkType": null,
"nameOnAccount": null,
"routingNum": null
},
"campaign": {
"campaignName": "BaisMedresh",
"campaignNum": 1001
},
"card": {
"ccNum": "4242424242424242",
"cvv": "666",
"expiry": "12/28"
},
"currency": "USD",
"donor": {
"accountNum": "DNR1015",
"firstName": "Moshe",
"lastName": "Green",
"phoneNumber": "2162544878"
},
"note": "TestSchedule",
"orgGUID": "115e9d3d-baf2-4089-b896-9b2621ffcf1b",
"paymentDate": "2024-12-15",
"paymentMethodId": "Credit_Card",
"reason": null,
"reasons": [
{
"reasonAmount": 1,
"reasonName": "KerenHabinyan",
"reasonNum": 55555
},
{
"reasonAmount": 9,
"reasonName": "Mamudes",
"reasonNum": 1001
}
],
"scheduleDetails": {
"amountPerPayment": 1,
"firstPaymentAmount": 1,
"frequencyID": "Daily",
"startDate": "2024-12-15",
"totalPaymentsCount": 10
},
"uniqueTransactionId": "5f10f1a9-4d5f-ef48-03b4-e44428e1e60e892"
}
Response:
{
"scheduleNum": null,
"scheduleTotal": null,
"receiptNum": "1288-1",
"amount": 10.0000,
"accountNum": "DNR1015",
"currency": "USD",
"paymentStatus": "Success",
"responseTitle": "Success !!",
"error": {
"errorCode": null,
"message": null
}
}