Skip to main content
POST
/
v1
/
payments
/
attempt
Attempt payment for an invoice
curl --request POST \
  --url https://api.metronome.com/v1/payments/attempt \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "customer_id": "13117714-3f05-48e5-a6e9-a66093f13b4d",
  "invoice_id": "6162d87b-e5db-4a33-b7f2-76ce6ead4e85"
}'
{
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "invoice_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "contract_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "payment_gateway": {
      "type": "stripe",
      "stripe": {
        "payment_intent_id": "<string>",
        "error": {
          "type": "<string>",
          "code": "<string>",
          "decline_code": "<string>"
        }
      }
    },
    "fiat_credit_type": {
      "name": "<string>",
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
    },
    "amount": 123,
    "amount_paid": 123,
    "status": "pending",
    "error_message": "<string>",
    "updated_at": "2022-02-01T00:00:00Z",
    "created_at": "2022-02-01T00:00:00Z"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
customer_id
string<uuid>
required
invoice_id
string<uuid>
required

Response

Success

data
object
required
I