Skip to main content
Order

Object schema for Klar API.

Frank Birzle avatar
Written by Frank Birzle
Updated over 6 months ago

id

Type: string

Description: The (technical) unique identifier of the order. If you're re-using the same id when submitting an order, the old version gets overwritten.

Example Value(s): '12345678' or 'ABC-12345678-XYZ'

createdAt

Type: number

Description: Unix timestamp in seconds of the time when the order was placed.

Example Value(s): 1678376546

updatedAt

Type: number

Description: Unix timestamp in seconds of the time when the order last updated in your system.

Example Value(s): 1678376546

processedAt

Type: number

Description: Unix timestamp in seconds of the time when the order was fullfilled.

Example Value(s): 1678376546

closedAt

Type: number

Description: Unix timestamp in seconds of the time when the order was closed.

Example Value(s): 1678376546

cancelledAt

Type: number

Description: Unix timestamp in seconds of the time when the order was cancelled.

Example Value(s): 1678376546

currencyCodeIso3Letter

Type: string

Description: 3-letter ISO 4217 alpha-3 standard currency code the order was processed.

Example Value(s): 'EUR' or 'GBP'

financialStatus

Type: string

Description: The status of the order in regards to the financial processing. You can use your internal statuses which can be mapped to Klar's standard statuses in the app, e.g. if instead of 'pending' the status is called 'open' in your system you can map 'open' to 'pending', making sure that the order statuses are matching.

Example Value(s): 'pending' or 'partially_paid' or 'paid'

shipmentStatus

Type: string

Description: The status of the order in regard to shipping. You can use your internal statuses which can be mapped to Klar's standard statuses in the app, e.g. if instead of 'pending' the status is called 'open' in your system you can map 'open' to 'pending', making sure that the order statuses are matching.

Example Value(s): 'shipped' or 'pending'

paymentGatewayName

Type: string

Description: The payment gateway that was used to process the payment.

Example Value(s): 'paypal' or 'stripe'

paymentMethodName

Type: string

Description: The payment method that was used to process the payment.

Example Value(s): 'credit_card' or 'invoice'

orderName

Type: string

Description: A customer friendly name of the order, usually included in a transactional email order a order status page.

Example Value(s): 'Order #12312341234' or 'Awesome Food - Order #1342'

orderNumber

Type: string

Description: The order number used in your shop system to identify the order.

Example Value(s): '12312345213412' or 'O-4234234-A'

tags

Type: [string]

Description: An array of tags for the order

Example Value(s): ['subscription', 'first_order'] or ['giveaway']

lineItems

Type: [LineItem]

Description: The products that were part of that order as an array of objects of the type LineItem.

Example Value(s): see LineItem

refundedLineItems

Type: [RefundedLineItems]

Description: The products that were refunded in that order of type refundedLineItem. Empty array [] in no items have been refunded.

Example Value(s): see RefundedLineItem

shipping

Type: Shipping

Description: The shipping info for that order of type Shipping

Example Value(s): see Shipping

transactionCosts

Type: number

Description: The payment and transaction costs for the order.

Example Value(s): 1.10 or 2

customer

Type: Customer

Description: The customer info for that order of type Customer

Example Value(s): see Customer

optionalIdentifiers

Type: OptionalIdentifiers

Description: An object of type OptionalIdentifiers that contain info like utmParameters, subscription info, orders source and others.

Example Value(s): see OptionalIdentifiers

Did this answer your question?