DocumentationTypesInterfaces

Order

amerta


amerta / payload-types / Order

Interface: Order

Defined in: payload-types.ts:2415

This interface was referenced by Config's JSON-Schema via the definition "orders".

Properties

address

address: { address: string; apartment: string; building?: string | null; city: string; country: string | Country; countryName?: string | null; firstName: string; floor?: string | null; isDefaultBilling?: boolean | null; isDefaultShipping?: boolean | null; lastName: string; lat?: number | null; lng?: number | null; phone?: number | null; phoneCountryCode?: string | null; postalCode?: string | null; state?: string | null; street: string; title?: string | null; type?: "0" | "1" | "2" | null; }

Defined in: payload-types.ts:2499

address

address: string

apartment

apartment: string

building?

optional building: string | null

city

city: string

country

country: string | Country

countryName?

optional countryName: string | null

firstName

firstName: string

floor?

optional floor: string | null

isDefaultBilling?

optional isDefaultBilling: boolean | null

isDefaultShipping?

optional isDefaultShipping: boolean | null

lastName

lastName: string

lat?

optional lat: number | null

lng?

optional lng: number | null

phone?

optional phone: number | null

phoneCountryCode?

optional phoneCountryCode: string | null

Country code (e.g., +1)

postalCode?

optional postalCode: string | null

state?

optional state: string | null

street

street: string

title?

optional title: string | null

type?

optional type: "0" | "1" | "2" | null


billingAddress

billingAddress: { address: string; apartment: string; building?: string | null; city: string; country: string | Country; countryName?: string | null; firstName: string; floor?: string | null; isDefaultBilling?: boolean | null; isDefaultShipping?: boolean | null; lastName: string; lat?: number | null; lng?: number | null; phone?: number | null; phoneCountryCode?: string | null; postalCode?: string | null; state?: string | null; street: string; title?: string | null; type?: "0" | "1" | "2" | null; }

Defined in: payload-types.ts:2524

address

address: string

apartment

apartment: string

building?

optional building: string | null

city

city: string

country

country: string | Country

countryName?

optional countryName: string | null

firstName

firstName: string

floor?

optional floor: string | null

isDefaultBilling?

optional isDefaultBilling: boolean | null

isDefaultShipping?

optional isDefaultShipping: boolean | null

lastName

lastName: string

lat?

optional lat: number | null

lng?

optional lng: number | null

phone?

optional phone: number | null

phoneCountryCode?

optional phoneCountryCode: string | null

Country code (e.g., +1)

postalCode?

optional postalCode: string | null

state?

optional state: string | null

street

street: string

title?

optional title: string | null

type?

optional type: "0" | "1" | "2" | null


couponCode?

optional couponCode: string | null

Defined in: payload-types.ts:2441

Coupon code used for discount


createdAt

createdAt: string

Defined in: payload-types.ts:2550


customerCurrency

customerCurrency: string | Currency

Defined in: payload-types.ts:2461

Currency shown to user (e.g. USD)


customerTotal

customerTotal: number

Defined in: payload-types.ts:2457

Amount shown to user (e.g. 100.00)


discountTotal?

optional discountTotal: number | null

Defined in: payload-types.ts:2437

Discount amount applied to this order


exchangeRate

exchangeRate: number

Defined in: payload-types.ts:2465

Exchange rate from sales channel currency to customer currency at the time of order


id

id: string

Defined in: payload-types.ts:2416


isFreeShipping?

optional isFreeShipping: boolean | null

Defined in: payload-types.ts:2445

Whether free shipping was applied to this order


items?

optional items: { id?: string | null; image?: string | ProductMedia | null; metaData?: string | number | boolean | unknown[] | {[k: string]: unknown; } | null; price: number; product: string | Product; productName?: string | null; productSKU?: string | null; quantity?: number | null; variant?: string | null; variantText?: string | null; }[] | null

Defined in: payload-types.ts:2471


orderCounter?

optional orderCounter: number | null

Defined in: payload-types.ts:2421


orderedBy

orderedBy: string | Customer

Defined in: payload-types.ts:2422


orderId?

optional orderId: string | null

Defined in: payload-types.ts:2420

Automatically generated order ID


orderNote?

optional orderNote: string | null

Defined in: payload-types.ts:2428

Customer's notes or special instructions for this order


paidAt?

optional paidAt: string | null

Defined in: payload-types.ts:2470


paymentMethod

paymentMethod: string | PaymentMethod

Defined in: payload-types.ts:2467


paymentMethodName?

optional paymentMethodName: string | null

Defined in: payload-types.ts:2469


salesChannel

salesChannel: string | SalesChannel

Defined in: payload-types.ts:2423


shippingMethod

shippingMethod: string | Shipping

Defined in: payload-types.ts:2466


shippingMethodName?

optional shippingMethodName: string | null

Defined in: payload-types.ts:2468


shippingTotal

shippingTotal: number

Defined in: payload-types.ts:2433


status?

optional status: "pending" | "refunded" | "processing" | "shipped" | "completed" | "cancelled" | "on-hold" | null

Defined in: payload-types.ts:2424


subtotal

subtotal: number

Defined in: payload-types.ts:2432

Automatically calculated from items


tax

tax: number

Defined in: payload-types.ts:2453

Taxes applied to this order


total

total: number

Defined in: payload-types.ts:2449

Automatically calculated: subtotal - discount + shipping


updatedAt

updatedAt: string

Defined in: payload-types.ts:2549