Manual Payments

Out of the box we are able to support an unlimited amount of payment gateways using the Manual Payments API.

The manual gateway currently supports the authorize and capture methods only.

Authorize payment

POST https://api.moltin.com/v2/orders/:orderId/payments

Path Parameters

NameTypeDescription

orderId

string

The UUID of the order you want to authorize payment for

Headers

NameTypeDescription

Authorization

string

The Bearer token to grant access to the API

Request Body

NameTypeDescription

method

string

The payment method, in this example it is authorize

gateway

string

This will always be manual for the manual payment gateway

{
    "data": {
        "id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
        "type": "transaction",
        "reference": "manual",
        "gateway": "manual",
        "amount": 100,
        "currency": "USD",
        "transaction-type": "authorize",
        "status": "complete",
        "relationships": {
            "order": {
                "data": {
                    "type": "order",
                    "id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                }
            }
        },
        "meta": {
            "display_price": {
                "amount": 100,
                "currency": "USD",
                "formatted": "$100.00"
            },
            "created_at": "2019-01-31T17:20:39.378Z"
        }
    }
}
curl -X POST https://api.moltin.com/v2/orders/:orderId/payments \
     -H "Authorization: Bearer XXXX" \
     -H "Content-Type: application/json" \
     -d $'{
       "data": {
         "gateway": "manual",
         "method": "authorize",
       }
     }'

Capture transaction

POST https://api.moltin.com/v2/orders/:orderId/transactions/:transactionId/capture

Path Parameters

NameTypeDescription

transactionId

string

The UUID of the previously authorized transaction

orderId

string

The UUID of the order you want to capture for

Headers

NameTypeDescription

Authorization

string

The Bearer token to grant access to the API

Request Body

NameTypeDescription

method

string

The payment method, in this example it is capture

gateway

string

This will always be manual for the manual payment gateway

{
    "data": {
        "id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
        "type": "transaction",
        "reference": "manual",
        "gateway": "manual",
        "amount": 100,
        "currency": "USD",
        "transaction-type": "capture",
        "status": "complete",
        "relationships": {
            "order": {
                "data": {
                    "type": "order",
                    "id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
                }
            }
        },
        "meta": {
            "display_price": {
                "amount": 100,
                "currency": "USD",
                "formatted": "$100.00"
            },
            "created_at": "2019-01-31T17:20:39.378Z"
        }
    }
}

The capture method requires client_credentials authentication.

curl -X POST https://api.moltin.com/v2/orders/:orderId/transactions/transactionId/capture \
     -H "Authorization: Bearer XXXX" \
     -H "Content-Type: application/json" \
     -d $'{
       "data": {
         "gateway": "manual",
         "method": "capture"
       }
     }'

Last updated