DOCS

建立已計入成本 - GraphQL

建立已計入成本

了解如何從運輸評級建立已計入成本。

GraphQL

在需要使用 Zonos 計算運輸評級,但透過其他方式計算稅款以支持您業務的情況下,您可以使用 createLandedCost 變異。此變異可讓您建立訂單建立所需的已計入成本,而無需 Zonos 計算關稅、稅款和費用。

API 範例 

使用 landedCostCreate 時,您需要傳遞 currencyCodeendUse。您還需要傳遞從原始運輸評級工作流程取得的 rootIdshipmentRatingId。您可以選擇性地提供關稅、費用和稅款清單。提供這些詳細資訊時,您需要傳遞用於確定 amount 欄位中使用的值的 amountformula

1mutation CreateLandedCost($input: LandedCostCreateInput!) {
2 landedCostCreate(input: $input) {
3 id
4 landedCostGuaranteeCode
5 taxes {
6 amount
7 formula
8 item {
9 id
10 sku
11 amount
12 }
13 }
14 amountSubtotals {
15 items
16 taxes
17 shipping
18 }
19 shipmentRating {
20 shipmentRatingCartons {
21 carton {
22 items {
23 item {
24 sku
25 amount
26 id
27 }
28 }
29 }
30 }
31 }
32 }
33}
GraphQL API ReferenceTypes, inputs, and operations used in this guide
預約演示

這個頁面有幫助嗎?


在此頁面: