Created
December 21, 2022 09:53
-
-
Save oops-wrong/fdf84c50f076d93c9b3f4ea85cfae4ba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { CheckoutEmailAddress } from './checkout'; | |
import { Price } from './price'; | |
import { Merchandise } from './product'; | |
// Explanations https://shopify.dev/api/storefront/2022-04/objects/Order | |
export interface Order { | |
canceledAt?: string; | |
cancelReason?: string; | |
currencyCode: string; | |
currentSubtotalPrice: string; | |
currentSubtotalPriceOrigin: Price; | |
currentTotalDuties?: string; | |
currentTotalDutiesOrigin?: Price; | |
currentTotalPrice: string; | |
currentTotalPriceOrigin: Price; | |
currentTotalTax: string; | |
currentTotalTaxOrigin: Price; | |
customerUrl: string; | |
email: string; | |
financialStatus: string; | |
id: string; | |
lineItems: OrderLineItem[]; | |
orderNumber: number; | |
originalTotalDuties?: string; | |
originalTotalDutiesOrigin?: Price; | |
originalTotalPrice: string; | |
originalTotalPriceOrigin: Price; | |
phone?: string; | |
processedAt: string; | |
shippingAddress: CheckoutEmailAddress; | |
shippingDiscountAllocations: { | |
allocatedAmount: string; | |
allocatedAmountOrigin: Price; | |
}[]; | |
statusUrl: string; | |
subtotalPrice: string; | |
subtotalPriceOrigin: Price; | |
totalPrice: string; | |
totalPriceOrigin: Price; | |
totalRefunded: string; | |
totalRefundedOrigin: Price; | |
totalShippingPrice: string; | |
totalShippingPriceOrigin: Price; | |
totalTax: string; | |
totalTaxOrigin: Price; | |
} | |
export interface OrderLineItem { | |
currentQuantity: number; | |
discountAllocations: { | |
allocatedAmount: string; | |
allocatedAmountOrigin: Price; | |
}[]; | |
discountedTotalPrice: string; | |
discountedTotalPriceOrigin: Price; | |
originalTotalPrice: string; | |
originalTotalPriceOrigin: Price; | |
quantity: number; | |
title: string; | |
variant: Merchandise; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment