- Invoice
- Payment instruments
- Transactions
Pay an invoice
POST
https://api-sandbox.synswi.com/v1/invoices/pay
Request
Body Params application/json
invoiceId
string
required
paymentInstrumentId
string
required
method
enum<string>
required
Allowed values:
cardach
Example
{
"paymentInstrumentId": "payment-instrument-75359708-3227-4466-8809-146f60bbbf60",
"invoiceId": "invoice-67c28842-39e1-48a0-97d9-ccafa20914bd",
"method": "card"
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api-sandbox.synswi.com/v1/invoices/pay' \
--header 'Content-Type: application/json' \
--data-raw '{
"paymentInstrumentId": "payment-instrument-75359708-3227-4466-8809-146f60bbbf60",
"invoiceId": "invoice-67c28842-39e1-48a0-97d9-ccafa20914bd",
"method": "card"
}'
Responses
🟢200Success
application/json
Body
object {0}
Example
{}