Param name | Description |
---|---|
idempotency_key
optional |
A unique key to ensure that the payment is not processed more than once. If not provided, one will be generated for you. Validations:
|
payments
required |
Validations:
|
payments[ledger_id]
required |
Validations:
|
payments[amount]
optional |
Validations:
|
payments[kind]
required |
Validations:
|
payments[months]
optional |
Number of prepay months, used with Validations:
|
payment_method
required |
Can accept a paymentmethodid, or fields for CC or ACH payments Validations:
|
payment_method[payment_method_id]
optional |
If you want to use an existing payment method, pass in the id Validations:
|
payment_method[first_name]
optional |
Required if not using an existing payment method Validations:
|
payment_method[last_name]
optional |
Required if not using an existing payment method Validations:
|
payment_method[kind]
optional |
Required if not using an existing payment method Validations:
|
payment_method[reuseable]
optional |
Validations:
|
payment_method[magnetic_track]
optional |
Required if using a card swipe Validations:
|
payment_method[card_number]
optional |
Required if using a credit card Validations:
|
payment_method[card_type]
optional |
Required if using a credit card Validations:
|
payment_method[security_code]
optional |
Required if using a credit card Validations:
|
payment_method[expiration_date]
optional |
Required if using a credit card. Format: MM/YY Validations:
|
payment_method[account_number]
optional |
Required if using ACH Validations:
|
payment_method[account_number_confirmation]
optional |
Required if using ACH Validations:
|
payment_method[account_type]
optional |
Required if using ACH Validations:
|
payment_method[bank_name]
optional |
Required if using ACH Validations:
|
payment_method[routing_number]
optional |
Required if using ACH Validations:
|
payment_method[billing_address_attributes]
optional |
Required if not using an existing payment method Validations:
|
payment_method[billing_address_attributes][company]
optional |
Validations:
|
payment_method[billing_address_attributes][address1]
optional |
Validations:
|
payment_method[billing_address_attributes][address2]
optional |
Validations:
|
payment_method[billing_address_attributes][city]
optional |
Validations:
|
payment_method[billing_address_attributes][postal]
optional |
Validations:
|
payment_method[billing_address_attributes][state]
optional |
Validations:
|
payment_method[check_number]
optional |
Required if using Check Validations:
|
payment_method[name_on_check]
optional |
Required if using Check Validations:
|
payment_method[check_amount]
optional |
Required if using Check Validations:
|
payment_method[reference_number]
optional |
Required if using Money Order Validations:
|
payment_method[money_order_amount]
optional |
Required if using Money Order Validations:
|
payment_method[amount_tendered]
optional |
Required if using Cash Validations:
|
POST /v1/d9c08c72-13c1-4cb5-88ab-3f04056ce71a/ledgers/pay_multiple_ledgers { "payments": [ { "ledger_id": "ceca2c52-5bfd-4839-b5e1-48d488c2e22c", "amount": 5.0, "kind": "custom" }, { "ledger_id": "392ec7ce-4de0-4fab-8a07-e2dcdad4dfa2", "months": 2, "kind": "prepay" } ], "payment_method": { "kind": "credit_card", "first_name": "John", "last_name": "Doe", "reuseable": true, "card_type": "visa", "card_number": "00000000", "security_code": "123", "expiration_date": "10/24", "billing_address_attributes": { "address1": "123 Main", "city": "Somecity", "state": "AL", "postal": "12345", "country": "US" } }, "ledger": {} } 200 { "successful_payment_event": { "id": "2ff5bd5f-5a4a-4dde-b93a-dc713df08364", "amount": 263.78, "success": true, "date": "2023-09-15T04:38:35.755-10:00", "payment_method": { "id": "8b242565-7ff3-49cc-8f41-0a194ee7732e", "kind": "credit_card", "first_name": "John", "last_name": "Doe", "reuseable": true, "card_number": "****0000", "card_type": "visa", "expiration_date": "10/24", "billing_address": { "id": "4231a6aa-b1be-410a-8168-b0e1d87119ed", "address1": "123 Main", "address2": null, "city": "Somecity", "state": "AL", "postal": "12345", "country": "US", "full_address": "123 Main, Somecity, AL 12345", "latitude": null, "longitude": null, "time_zone_id": "America/Chicago", "time_zone_offset": "-05:00", "invalid_data": false, "label": "Home" } } }, "meta": { "status_code": 200, "status_message": "OK", "status_cat": "https://http.cat/200", "request_method": "POST", "request_id": null, "parameters": { "payments": [ { "ledger_id": "ceca2c52-5bfd-4839-b5e1-48d488c2e22c", "amount": 5.0, "kind": "custom" }, { "ledger_id": "392ec7ce-4de0-4fab-8a07-e2dcdad4dfa2", "months": 2, "kind": "prepay" } ], "payment_method": { "kind": "credit_card", "first_name": "John", "last_name": "Doe", "reuseable": true, "card_type": "visa", "card_number": "[FILTERED]", "security_code": "[FILTERED]", "expiration_date": "10/24", "billing_address_attributes": { "address1": "123 Main", "city": "Somecity", "state": "AL", "postal": "12345", "country": "US" } }, "facility_id": "d9c08c72-13c1-4cb5-88ab-3f04056ce71a", "ledger": {} } } }