Get a payment
GET
/api/v1/payments/{id}
const url = 'https://digize.com/api/v1/payments/example';const options = {method: 'GET', headers: {'x-api-key': '<x-api-key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://digize.com/api/v1/payments/example \ --header 'x-api-key: <x-api-key>'One payment with its card, fee and refunds so far.
Needs the crm:read permission.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string
Responses
Section titled “Responses”Done
Media typeapplication/json
object
id
required
string
stripeId
required
The Stripe PaymentIntent, or a subscription charge’s Stripe invoice.
string
source
required
string
description
required
string
contact
required
object
id
required
The contact’s id.
string
name
required
string
email
required
string
amount
required
In the workspace currency’s minor unit: 2000 is $20.00.
integer
refunded
required
In the workspace currency’s minor unit: 2000 is $20.00.
integer
fee
required
Stripe’s fee, once Stripe reported it.
number | null
method
required
status
required
string
failure
required
string | null
createdAt
required
string format: date-time
orderId
required
A store order’s payment: refund it with commerce.orders.refund.
string | null
Example
{ "source": "order", "method": { "wallet": "apple_pay" }, "status": "succeeded"}What was sent isn’t valid (invalid).
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
object
key
additional properties
any
Example
{ "error": { "code": "invalid" }}No key, or one that’s unknown, off or expired.
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
object
key
additional properties
any
Example
{ "error": { "code": "invalid" }}The key doesn’t have the permission this needs.
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
object
key
additional properties
any
Example
{ "error": { "code": "invalid" }}Nothing has that id (not_found).
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
object
key
additional properties
any
Example
{ "error": { "code": "invalid" }}Over the rate limit; see retry-after.
Media typeapplication/json
object
error
required
object
code
required
string
message
required
string
details
object
key
additional properties
any
Example
{ "error": { "code": "invalid" }}