Skip to main content
POST
/
orders
/
{orderId}
/
actions
/
update-payment-status
Update order payment status by order ID
curl --request POST \
  --url https://api.fabric.inc/v3/orders/{orderId}/actions/update-payment-status \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'x-fabric-channel-id: <x-fabric-channel-id>' \
  --header 'x-fabric-tenant-id: <x-fabric-tenant-id>' \
  --data '
{
  "balances": {
    "authorized": 123.2,
    "capturable": 12.2,
    "captured": 13.2,
    "refundable": 23.22,
    "refunded": 3.2
  },
  "connectorInfo": {
    "connectorName": "checkout",
    "eventId": "abc12345",
    "paymentMethodType": "Visa"
  },
  "paymentIdentifier": "12321343223",
  "status": "Authorized"
}
'
{}

Authorizations

Authorization
string
header
required

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

Headers

x-fabric-tenant-id
string
required

A header used by fabric to identify the tenant making the request. You must include tenant id in the authentication header for an API request to access any of fabric’s endpoints. You can retrieve the tenant id , which is also called account id, from Copilot. This header is required.

x-fabric-channel-id
string
required

x-fabric-channel-id identifies the sales channel where the API request is being made; primarily for multichannel use cases. The channel ids are 12 corresponding to US and 13 corresponding to Canada. The default channel id is 12. This field is required.

x-fabric-request-id
string

Unique request ID

Path Parameters

orderId
string
required

24-character system-generated ID. It is returned in the response of Create Order - POST /orders endpoint.

Body

application/json

Update payment status model

paymentIdentifier
string
required

Payment identifier

Example:

"12321343223"

balances
object

Order update payment status request balances model

connectorInfo
object

Order update payment status request connector info model

status
string

Payment status such as Authorized, Captured, etc.

Example:

"Authorized"

Response

OK

An object containing order details.

channelId
string
required

Sales channel ID

Example:

"12"

items
object[]
required

Item details

Required array length: 1 - 2147483647 elements
orderNumber
string
required

Merchant-defined order identifier. If omitted, this is generated by fabric's sequence generator using Configuration service

Example:

"309019176"

shipInfo
object[]
required
Required array length: 1 - 2147483647 elements
statusCode
string
required

Status code. There are no pre-defined values; possible values are - ORDER_ALLOCATED ("Order Allocated"), ORDER_SHIPPED ("Order Shipped"), ORDER_PARTIALLY_SHIPPED ("Order Partially Shipped"), ORDER_PICKED_UP ("Order Picked Up"), ORDER_PARTIALLY_PICKED_UP ("Order Partially Picked Up"), ORDER_DELIVERED ("Order Delivered"), ORDER_PARTIALLY_DELIVERED ("Order Partially Delivered"), ORDER_RETURNED ("Order Returned"), etc.

Example:

"ORDER_CREATED"

version
integer
required

Current version of order document. Indicates the number of times the order is updated by any operation.

Example:

2

adjustmentTotal
number

The total amount of price adjustments for all items of the order.

Example:

123.45

adjustmentTotalInCurrencies
object[]
adjustments
object[]

Price adjustments refer to changes or modifications made to the listed price of a product. A Customer Sales Representative (CSR) makes the price adjustments to provide discounts, promotional offers, or coupons that the shopper used.

allocatedAt
string<date-time>

System-generated order allocation time (UTC) once the order is allocated using Allocation service

Example:

"2022-05-12T09:30:31.198Z"

appeasementTotal
number

Final appeasement amount

Example:

12.34

appeasementTotalInCurrencies
object[]
appeasements
object[]
attributes
object

Merchant-defined custom attributes. This is a placeholder for additional info (in key-value pairs).

Example:
{
"fraudCheckStatus": "UPDATED",
"loyaltyStatus": "N"
}
auditLogs
object[]
cancelTotal
number

Amount to be returned after order cancellation, calculated as cancelledQuantity / orderedQuantity * itemTotal

Example:

12.34

cancelTotalInCurrencies
object[]
cancellations
object[]
cancelledAt
string<date-time>

System-generated order cancellation time in UTC. This is returned in the response of Cancel order by ID - POST /orders/{orderId}/actions/cancel or Cancel order by order number - POST /orders/order-number/{orderNumber}/actions/cancel once the order is successfully cancelled.

Example:

"2022-05-12T09:30:31.198Z"

cartId
string

Unique cart identifier, either from fabric Cart service or an external Cart service. It is used for linking an order to a specific cart. If available, it is also used for inventory reservation from cart workflow.

Example:

"b03b72dc-78d8-4ea4-90fc-2fe6a1fe6569"

createdAt
string<date-time>

Order creation time (UTC)

Example:

"2022-05-12T09:30:31.198Z"

currencies
object

The supported currency groups you defined.

currency
string

Three-letter currency code as defined by ISO-4217

Example:

"USD"

customer
object

Invoice customer

discounts
object[]
employeeId
string

Employee (ID or name) who initiated the request

Example:

"43278"

erroredFields
object[]
feeTotal
number

Recalculated total fee, calculated as orderedQuantity* itemFeeTotal

Example:

12.34

feeTotalInCurrencies
object[]
fees
object[]
invoiceTotal
number

Total payment captured by fabric Invoice service. If merchant is using third-party service, then this amount will be null. For partial payment scenarios, this value will be different from orderTotal.

Example:

12.34

invoiceTotalInCurrencies
object[]
notes
object[]
orderDiscount
number

Recalculated order discount

Example:

1.23

orderDiscountInCurrencies
object[]
orderId
string

24-character system-generated order ID

Example:

"5349b4ddd2781d08c09890f4"

orderExternalId
string

A merchant-defined external order identifier.
This field is optional and can be used to reference the order in external systems such as an ERP, OMS, or CRM.

Example:

"191763090_O1231"

orderReleasedAt
string<date-time>

Order released time (UTC). When an order is placed, its status is On Hold by default and the duration of hold may vary from merchant to merchant (~1 min). After the hold period, the order is released from hold.

Example:

"2022-05-12T09:30:31.198Z"

orderSubtotal
number

Recalculated orderSubtotal - summationOfAll(itemSubTotal)

Example:

123.45

orderSubtotalInCurrencies
object[]
orderTotal
number

Total amount to be charged for the order = orderSubTotal - orderDiscountTotal + orderFeeTotal + orderTaxTotal

Example:

146.9

orderTotalInCurrencies
object[]
orderedAt
string<date-time>

Merchant-defined order creation time in UTC. It is mandatory in the request body of Create Order endpoint - POST /orders.

Example:

"2022-05-12T09:30:31.198Z"

originalAdjustmentTotal
number

Original adjustment total

Example:

123.45

originalAdjustmentTotalInCurrencies
object[]
originalDiscount
number

System-generated total discount, auto-filled by Orders service when the order is placed. This is saved for reference in case the value changes later.

Example:

1.45

originalDiscountInCurrencies
object[]
originalFeeTotal
number

System-generated total fees, auto-filled by Orders service when the order is placed.

Example:

12.34

originalFeeTotalInCurrencies
object[]
originalOrderTotal
number

System-generated order total, auto-filled by Orders service when the order is placed. This is saved for reference in case the orderTotal changes later.

Example:

146.9

originalOrderTotalInCurrencies
object[]
originalSubtotal
number

System-generated order subtotal, auto-filled by Orders service when the order is placed. This is saved for reference in case the value changes later.

Example:

113.45

originalSubtotalInCurrencies
object[]
originalTaxTotal
number

System-generated total tax, auto-filled by Orders service when the order is placed.

Example:

12.34

originalTaxTotalInCurrencies
object[]
payments
object[]
retail
object

Optionally used as reference, for orders created from Point-of-Sale systems

returnTotal
number

Return total of order, for return scenarios, calculated as summationOfAll(itemReturnTotal)

Example:

12.34

returnTotalInCurrencies
object[]
returns
object[]
statusDescription
string

Human-readable brief description based on statusCode

Example:

"Order Created"

subtype
enum<string>

Order subtype, for further classification

Available options:
IOS,
ANDROID,
INTERNATIONAL
Example:

"INTERNATIONAL"

taxTotal
number

Recalculated total tax on order summationOfAll(itemTaxTotal)+summationOf(tax[].value)

Example:

12.34

taxTotalInCurrencies
object[]
type
enum<string>

Order type is critical for the order life cycle as it indicates the workflow. For example, storefront orders have a different workflow than call center orders. fabric Orders service offers standard configurations for storefront, call center, point of sale, iOS, Android, and international.

Available options:
WEB,
CSC,
MOBILE_APP,
POS
Example:

"WEB"

updatedAt
string<date-time>

Time of last update to order (UTC)

Example:

"2022-05-12T09:30:31.198Z"