Skip to main content
POST
/
billing
/
payment
/
move-to-location
Move Payment To Location
curl --request POST \
  --url https://api.decodahealth.com/billing/payment/move-to-location \
  --header 'API-KEY: <api-key>' \
  --header 'Content-Type: application/json' \
  --header 'TENANT: <tenant>' \
  --data '
{
  "paymentId": "<string>",
  "newLocationId": "<string>"
}
'
{
  "id": "<string>",
  "amount": 123,
  "status": "CANCELED",
  "paymentMedium": "<string>",
  "createdDate": "2023-11-07T05:31:56Z",
  "feeToPatient": 123,
  "patientId": "<string>",
  "payinId": "<string>",
  "currency": "USD",
  "payinConfigId": "<string>",
  "paymentMethodId": "<string>",
  "stripePaymentIntentId": "<string>",
  "failedReason": "<string>",
  "updatedDate": "2023-11-07T05:31:56Z",
  "fee": 0
}

Headers

TENANT
string
required

The tenant you are making this request on behalf of

API-KEY
string
required

Your api key

Body

application/json

Request to move a payment from one location to another.

paymentId
string
required

The ID of the payment to move.

newLocationId
string
required

The ID of the location to move the payment to.

Response

Successful Response

id
string
required

The unique identifier for the payment.

amount
integer
required

The total amount of the payment.

status
enum<string>
required

The current status of the payment.

Available options:
CANCELED,
CREATED,
FAILED,
IN_REVIEW,
PRESENTING,
PROCESSING,
SUCCEEDED
paymentMedium
string
required

The name of the payment medium.

createdDate
string<date-time>
required

The date and time the payment was created.

feeToPatient
integer
required

The fee charged to the patient for the transaction.

patientId
string | null

The ID of the patient associated with the payment.

payinId
string | null

The ID of the payin associated with the payment.

currency
string
default:USD

The currency in which the payment was made.

payinConfigId
string | null

The configuration ID for the payin.

paymentMethodId
string | null

The ID of the payment method used.

stripePaymentIntentId
string | null

Stripe's payment intent ID if used.

failedReason
string | null

Reason for payment failure if applicable.

updatedDate
string<date-time> | null

The date and time the payment was last updated.

fee
integer
default:0

The fee charged by the payment processor.