배송 설정

shippingsettings 리소스를 사용하면 멀티 클라이언트 계정 (MCA) 및 이와 연결된 모든 하위 계정의 배송 설정을 검색하고 업데이트할 수 있습니다.

MCA는 일반적으로 여러 판매자의 온라인 스토어 및 API 서비스를 관리하는 통합업체, 애그리게이터, 채널 파트너가 사용합니다. 별도의 웹사이트에서 판매하는 여러 온라인 상점 또는 브랜드가 있는 판매자도 단일 MCA에 하위 계정을 선택할 수 있습니다.

일부 제품의 예상 배송 시간은 Google에서 자동으로 업데이트할 수 있습니다. 자세한 내용은 자동 개선 사용 설정을 참고하세요.

shippingsettings.list

MCA 계정을 처리하는 경우 shippingsettings.list 호출은 특정 계정 또는 모든 하위 계정의 모든 배송 리소스 정보를 반환합니다.

shippingsettings.list 메서드의 URL 예시:

GET https://shoppingcontent.googleapis.com/content/v2.1/merchantId/shippingsettings

다음은 MCA 계정의 하위 계정 11112222에 대한 배송 설정을 보여주는 샘플 JSON 응답입니다.

{
 "kind": "content#shippingsettingsListResponse",
 "resources": [
  {
   "accountId": "1111",
   "services": [
    {
     "name": "Standard Shipping",
     "active": true,
     "deliveryCountry": "US",
     "currency": "USD",
     "deliveryTime": {
      "minHandlingTimeInDays": 0,
      "maxHandlingTimeInDays": 1,
      "transitTimeTable": {
       "postalCodeGroupNames": [
        "Region1",
        "Region2",
        "all other locations"
       ],
       "transitTimeLabels": [
        "all other labels"
       ],
       "rows": [
        {
         "values": [
          {
           "minTransitTimeInDays": 1,
           "maxTransitTimeInDays": 2
          }
         ]
        },
        {
         "values": [
          {
           "minTransitTimeInDays": 2,
           "maxTransitTimeInDays": 3
          }
         ]
        },
        {
         "values": [
          {
           "minTransitTimeInDays": 3,
           "maxTransitTimeInDays": 5
          }
         ]
        }
       ]
      }
     },
     "rateGroups": [
      {
       "singleValue": {
        "flatRate": {
         "value": "0",
         "currency": "USD"
        }
       },
       "name": "Standard Shipping"
      }
     ],
     "eligibility": "All scenarios"
    },
    {
     "name": "Expedited",
     "active": true,
     "deliveryCountry": "US",
     "currency": "USD",
     "deliveryTime": {
      "minTransitTimeInDays": 2,
      "maxTransitTimeInDays": 2,
      "minHandlingTimeInDays": 0,
      "maxHandlingTimeInDays": 1
     },
     "rateGroups": [
      {
       "singleValue": {
        "flatRate": {
         "value": "9.99",
         "currency": "USD"
        }
       },
       "name": "Expedited"
      }
     ],
     "eligibility": "All scenarios"
    }
   ],
   "postalCodeGroups": [
    {
     "name": "Region1",
     "country": "US",
     "postalCodeRanges": [
      {
       "postalCodeRangeBegin": "94035",
       "postalCodeRangeEnd": "94070"
      }
     ]
    },
    {
     "name": "Region2",
     "country": "US",
     "postalCodeRanges": [
      {
       "postalCodeRangeBegin": "94071",
       "postalCodeRangeEnd": "94082"
      }
     ]
    }
   ]
  },
  {
   "accountId": "2222",
   "services": [
    {
     "name": "FedEx",
     "active": true,
     "deliveryCountry": "US",
     "currency": "USD",
     "deliveryTime": {
      "minTransitTimeInDays": 4,
      "maxTransitTimeInDays": 6,
      "minHandlingTimeInDays": 0,
      "maxHandlingTimeInDays": 0
     },
     "rateGroups": [
      {
       "singleValue": {
        "flatRate": {
         "value": "5.99",
         "currency": "USD"
        }
       },
       "name": "All products"
      }
     ],
     "eligibility": "All scenarios except Shopping Actions"
    },
    {
     "name": "GSA Shipping - Free Ship Over $49.99",
     "active": true,
     "deliveryCountry": "US",
     "currency": "USD",
     "deliveryTime": {
      "minTransitTimeInDays": 3,
      "maxTransitTimeInDays": 7,
      "minHandlingTimeInDays": 1,
      "maxHandlingTimeInDays": 2
     },
     "rateGroups": [
      {
       "mainTable": {
        "rowHeaders": {
         "prices": [
          {
           "value": "49.99",
           "currency": "USD"
          },
          {
           "value": "infinity",
           "currency": "USD"
          }
         ]
        },
        "rows": [
         {
          "cells": [
           {
            "flatRate": {
             "value": "6.99",
             "currency": "USD"
            }
           }
          ]
         },
         {
          "cells": [
           {
            "flatRate": {
             "value": "0",
             "currency": "USD"
            }
           }
          ]
         }
        ]
       },
       "name": "Free Ship Over $49.99"
      }
     ],
     "eligibility": "Shopping Actions"
    }
   ]
  }
 ]
}

shippingsettings.get

shippingsettings.get 호출을 통해 MCA 계정은 단일 하위 계정의 배송 설정 정보를 가져오거나 독립형 계정이 자체 계정 상태 정보를 가져올 수 있습니다.

다음 호출을 사용하여 배송 설정 정보를 가져옵니다. 여기서 merchantId는 MCA 계정 번호, accountId는 하위 계정입니다. 판매자 센터 계정이 멀티 클라이언트 계정이 아닌 경우에도 shippingsettings.get에서 배송 설정 정보를 반환할 수 있습니다. 이 경우 merchantIdaccountId 매개변수에 동일한 판매자 센터 계정 번호를 사용하세요.

GET https://shoppingcontent.googleapis.com/content/v2.1/merchantId/shippingsettings/accountId

다음은 list 호출에 사용되는 MCA 계정에서 구성된 StandardExpedited 배송 서비스가 있는 하위 계정에 대한 샘플 JSON 응답입니다.

{
 "accountId": "1111",
 "services": [
  {
   "name": "Standard Shipping",
   "active": true,
   "deliveryCountry": "US",
   "currency": "USD",
   "deliveryTime": {
    "minHandlingTimeInDays": 0,
    "maxHandlingTimeInDays": 1,
    "transitTimeTable": {
     "postalCodeGroupNames": [
      "Region1",
      "Region2",
      "all other locations"
     ],
     "transitTimeLabels": [
      "all other labels"
     ],
     "rows": [
      {
       "values": [
        {
         "minTransitTimeInDays": 1,
         "maxTransitTimeInDays": 2
        }
       ]
      },
      {
       "values": [
        {
         "minTransitTimeInDays": 2,
         "maxTransitTimeInDays": 3
        }
       ]
      },
      {
       "values": [
        {
         "minTransitTimeInDays": 3,
         "maxTransitTimeInDays": 5
        }
       ]
      }
     ]
    }
   },
   "rateGroups": [
    {
     "singleValue": {
      "flatRate": {
       "value": "0",
       "currency": "USD"
      }
     },
     "name": "Standard Shipping"
    }
   ],
   "eligibility": "All scenarios"
  },
  {
   "name": "Expedited",
   "active": true,
   "deliveryCountry": "US",
   "currency": "USD",
   "deliveryTime": {
    "minTransitTimeInDays": 2,
    "maxTransitTimeInDays": 2,
    "minHandlingTimeInDays": 0,
    "maxHandlingTimeInDays": 1
   },
   "rateGroups": [
    {
     "singleValue": {
      "flatRate": {
       "value": "9.99",
       "currency": "USD"
      }
     },
     "name": "Expedited"
    }
   ],
   "eligibility": "All scenarios"
  }
 ],
 "postalCodeGroups": [
  {
   "name": "Region1",
   "country": "US",
   "postalCodeRanges": [
    {
     "postalCodeRangeBegin": "94035",
     "postalCodeRangeEnd": "94070"
    }
   ]
  },
  {
   "name": "Region2",
   "country": "US",
   "postalCodeRanges": [
    {
     "postalCodeRangeBegin": "94071",
     "postalCodeRangeEnd": "94082"
    }
   ]
  }
 ]
}

shippingsettings.update

shippingsettings.update 호출을 통해 MCA 계정은 단일 하위 계정 또는 독립형 계정의 배송 설정 정보를 업데이트할 수 있습니다.

PUT https://shoppingcontent.googleapis.com/content/v2.1/merchantId/shippingsettings/accountId

다음은 MCA 상품 ID 10 내에 계정 ID가 2222인 하위 계정의 배송 서비스 GSA Shipping - Free Ship Over $49.99에 대해 maxTransitTimeInDays7로 업데이트하는 샘플 JSON 요청 본문입니다.

{
...
    "services": [
      {
        "name": "FedEx",
        "active": true,
        "deliveryCountry": "US",
        "currency": "USD",
        "deliveryTime": {
          "minTransitTimeInDays": 4,
          "maxTransitTimeInDays": 6,
          "minHandlingTimeInDays": 0,
          "maxHandlingTimeInDays": 0
        },
        "rateGroups": [
          {
            "singleValue": {
              "flatRate": {
                "value": "5.99",
                "currency": "USD"
              }
            },
            "name": "All products"
          }
        ],
        "eligibility": "All scenarios except Shopping Actions"
      },
      {
        "name": "GSA Shipping - Free Ship Over $49.99",
        "active": true,
        "deliveryCountry": "US",
        "currency": "USD",
        "deliveryTime": {
          "minTransitTimeInDays": 3,
          "maxTransitTimeInDays": 7,
          "minHandlingTimeInDays": 1,
          "maxHandlingTimeInDays": 2
        },
        "rateGroups": [
          {
            "mainTable": {
              "rowHeaders": {
                "prices": [
                  {
                    "value": "49.99",
                    "currency": "USD"
                  },
                  {
                    "value": "infinity",
                    "currency": "USD"
                  }
                ]
              },
              "rows": [
                {
                  "cells": [
                    {
                      "flatRate": {
                        "value": "6.99",
                        "currency": "USD"
                      }
                    }
                  ]
                },
                {
                  "cells": [
                    {
                      "flatRate": {
                        "value": "0",
                        "currency": "USD"
                      }
                    }
                  ]
                }
              ]
            },
            "name": "Free Ship Over $49.99"
          }
        ],
        "eligibility": "Shopping Actions"
      }
    ]
  }
}

다음은 샘플 JSON 응답 본문입니다.

{
 "accountId": "2222",
 "services": [
  {
   "name": "FedEx",
   "active": true,
   "deliveryCountry": "US",
   "currency": "USD",
   "deliveryTime": {
    "minTransitTimeInDays": 4,
    "maxTransitTimeInDays": 6,
    "minHandlingTimeInDays": 0,
    "maxHandlingTimeInDays": 0
   },
   "rateGroups": [
    {
     "singleValue": {
      "flatRate": {
       "value": "5.99",
       "currency": "USD"
      }
     },
     "name": "All products"
    }
   ],
   "eligibility": "All scenarios except Shopping Actions"
  },
  {
   "name": "GSA Shipping - Free Ship Over $49.99",
   "active": true,
   "deliveryCountry": "US",
   "currency": "USD",
   "deliveryTime": {
    "minTransitTimeInDays": 3,
    "maxTransitTimeInDays": 7,
    "minHandlingTimeInDays": 1,
    "maxHandlingTimeInDays": 2
   },
   "rateGroups": [
    {
     "mainTable": {
      "rowHeaders": {
       "prices": [
        {
         "value": "49.99",
         "currency": "USD"
        },
        {
         "value": "infinity",
         "currency": "USD"
        }
       ]
      },
      "rows": [
       {
        "cells": [
         {
          "flatRate": {
           "value": "6.99",
           "currency": "USD"
          }
         }
        ]
       },
       {
        "cells": [
         {
          "flatRate": {
           "value": "0",
           "currency": "USD"
          }
         }
        ]
       }
      ]
     },
     "name": "Free Ship Over $49.99"
    }
   ],
   "eligibility": "Shopping Actions"
  }
 ]
}

shippingsettings.custombatch

shippingsettings.custombatch 호출은 멀티 클라이언트 계정의 여러 하위 계정에 대한 배송 설정 정보를 검색하거나 업데이트합니다.

JSON 요청에는 MCA 계정 번호의 merchantId, 하위 계정의 accountId, 고유 batchId, 배송 설정을 가져오기 위한 get로 설정된 method, 배송 설정을 수정하기 위한 update가 포함됩니다.

POST https://shoppingcontent.googleapis.com/content/v2.1/shippingsettings/batch

다음 샘플 JSON 요청 본문은 두 부분으로 구성됩니다.

  1. 계정 ID 1111의 배송 설정을 가져오는 데 사용되는 batchId=1입니다.
  2. batchId=2: 배송 서비스 GSA Shipping - Free Ship Over $49.99maxTransitTimeInDays8로 업데이트하는 데 사용됩니다. 이 설정은 shippingsettings.update의 이전 응답 본문 예시에 표시된 계정 ID 22227에서 변경되었습니다.
{
  "entries": [
    {
      "accountId": 1111,
      "merchantId": 10,
      "method": "get",
      "batchId": 1
    },
    {
      "accountId": 2222,
      "merchantId": 10,
      "method": "update",
      "batchId": 2,
      "shippingSettings": {
        "services": [
          {
            "name": "FedEx",
            "active": true,
            "deliveryCountry": "US",
            "currency": "USD",
            "deliveryTime": {
              "minTransitTimeInDays": 4,
              "maxTransitTimeInDays": 5,
              "minHandlingTimeInDays": 0,
              "maxHandlingTimeInDays": 0
            },
            "rateGroups": [
              {
                "singleValue": {
                  "flatRate": {
                    "value": "5.99",
                    "currency": "USD"
                  }
                },
                "name": "All products"
              }
            ],
            "eligibility": "All scenarios except Shopping Actions"
          },
          {
            "name": "GSA Shipping - Free Ship Over $49.99",
            "active": true,
            "deliveryCountry": "US",
            "currency": "USD",
            "deliveryTime": {
              "minTransitTimeInDays": 3,
              "maxTransitTimeInDays": 8,
              "minHandlingTimeInDays": 1,
              "maxHandlingTimeInDays": 2
            },
            "rateGroups": [
              {
                "mainTable": {
                  "rowHeaders": {
                    "prices": [
                      {
                        "value": "49.99",
                        "currency": "USD"
                      },
                      {
                        "value": "infinity",
                        "currency": "USD"
                      }
                    ]
                  },
                  "rows": [
                    {
                      "cells": [
                        {
                          "flatRate": {
                            "value": "6.99",
                            "currency": "USD"
                          }
                        }
                      ]
                    },
                    {
                      "cells": [
                        {
                          "flatRate": {
                            "value": "0",
                            "currency": "USD"
                          }
                        }
                      ]
                    }
                  ]
                },
                "name": "Free Ship Over $49.99"
              }
            ],
            "eligibility": "Shopping Actions"
          }
        ]
      }
    }
  ]
}

다음은 샘플 JSON 응답 본문입니다.

{
 "kind": "content#shippingsettingsCustomBatchResponse",
 "entries": [
  {
   "kind": "content#shippingsettingsCustomBatchResponseEntry",
   "batchId": 1,
   "shippingSettings": {
    "accountId": "1111",
    "services": [
     {
      "name": "Standard Shipping",
      "active": true,
      "deliveryCountry": "US",
      "currency": "USD",
      "deliveryTime": {
       "minHandlingTimeInDays": 0,
       "maxHandlingTimeInDays": 1,
       "transitTimeTable": {
        "postalCodeGroupNames": [
         "Region1",
         "Region2",
         "all other locations"
        ],
        "transitTimeLabels": [
         "all other labels"
        ],
        "rows": [
         {
          "values": [
           {
            "minTransitTimeInDays": 1,
            "maxTransitTimeInDays": 2
           }
          ]
         },
         {
          "values": [
           {
            "minTransitTimeInDays": 2,
            "maxTransitTimeInDays": 3
           }
          ]
         },
         {
          "values": [
           {
            "minTransitTimeInDays": 3,
            "maxTransitTimeInDays": 5
           }
          ]
         }
        ]
       }
      },
      "rateGroups": [
       {
        "singleValue": {
         "flatRate": {
          "value": "0",
          "currency": "USD"
         }
        },
        "name": "Standard Shipping"
       }
      ],
      "eligibility": "All scenarios"
     },
     {
      "name": "Expedited",
      "active": true,
      "deliveryCountry": "US",
      "currency": "USD",
      "deliveryTime": {
       "minTransitTimeInDays": 2,
       "maxTransitTimeInDays": 2,
       "minHandlingTimeInDays": 0,
       "maxHandlingTimeInDays": 1
      },
      "rateGroups": [
       {
        "singleValue": {
         "flatRate": {
          "value": "9.99",
          "currency": "USD"
         }
        },
        "name": "Expedited"
       }
      ],
      "eligibility": "All scenarios"
     }
    ],
    "postalCodeGroups": [
     {
      "name": "Region1",
      "country": "US",
      "postalCodeRanges": [
       {
        "postalCodeRangeBegin": "94035",
        "postalCodeRangeEnd": "94070"
       }
      ]
     },
     {
      "name": "Region2",
      "country": "US",
      "postalCodeRanges": [
       {
        "postalCodeRangeBegin": "94071",
        "postalCodeRangeEnd": "94082"
       }
      ]
     }
    ]
   }
  },
  {
   "kind": "content#shippingsettingsCustomBatchResponseEntry",
   "batchId": 2,
   "shippingSettings": {
    "accountId": "2222",
    "services": [
     {
      "name": "FedEx",
      "active": true,
      "deliveryCountry": "US",
      "currency": "USD",
      "deliveryTime": {
       "minTransitTimeInDays": 4,
       "maxTransitTimeInDays": 5,
       "minHandlingTimeInDays": 0,
       "maxHandlingTimeInDays": 0
      },
      "rateGroups": [
       {
        "singleValue": {
         "flatRate": {
          "value": "5.99",
          "currency": "USD"
         }
        },
        "name": "All products"
       }
      ],
      "eligibility": "All scenarios except Shopping Actions"
     },
     {
      "name": "GSA Shipping - Free Ship Over $49.99",
      "active": true,
      "deliveryCountry": "US",
      "currency": "USD",
      "deliveryTime": {
       "minTransitTimeInDays": 3,
       "maxTransitTimeInDays": 8,
       "minHandlingTimeInDays": 1,
       "maxHandlingTimeInDays": 2
      },
      "rateGroups": [
       {
        "mainTable": {
         "rowHeaders": {
          "prices": [
           {
            "value": "49.99",
            "currency": "USD"
           },
           {
            "value": "infinity",
            "currency": "USD"
           }
          ]
         },
         "rows": [
          {
           "cells": [
            {
             "flatRate": {
              "value": "6.99",
              "currency": "USD"
             }
            }
           ]
          },
          {
           "cells": [
            {
             "flatRate": {
              "value": "0",
              "currency": "USD"
             }
            }
           ]
          }
         ]
        },
        "name": "Free Ship Over $49.99"
       }
      ],
      "eligibility": "Shopping Actions"
     }
    ]
   }
  }
 ]
}

shippingsettings.getsupportedcarriers

shippingsettings.getsupportedcarriers 호출을 통해 MCA 계정 또는 독립형 계정이 지원되는 이동통신사를 가져올 수 있습니다.

GET https://shoppingcontent.googleapis.com/content/v2.1/merchantId/supportedCarriers

다음은 샘플 JSON 응답 본문입니다.

{
 "kind": "content#shippingsettingsGetSupportedCarriersResponse",
 "carriers": [
  {
   "name": "FedEx",
   "country": "US",
   "services": [
    "Ground",
    "Home Delivery",
    "Express Saver",
    "First Overnight",
    "Priority Overnight",
    "Standard Overnight",
    "2Day"
   ]
  },
  {
   "name": "UPS",
   "country": "US",
   "services": [
    "2nd Day Air",
    "2nd Day Air AM",
    "3 Day Select",
    "Ground",
    "Next Day Air",
    "Next Day Air Early AM",
    "Next Day Air Saver"
   ]
  },
  {
   "name": "USPS",
   "country": "US",
   "services": [
    "Priority Mail Express",
    "Media Mail",
    "Retail Ground",
    "Priority Mail",
    "First Class Package Service Retail",
    "First Class Package Service Commercial Base"
   ]
  },
  {
   "name": "Australia Post",
   "country": "AU",
   "services": [
    "Regular Parcel",
    "Express Post"
   ]
  },
  {
   "name": "TNT",
   "country": "AU",
   "services": [
    "Road Express",
    "Overnight Express"
   ]
  },
  {
   "name": "TOLL",
   "country": "AU",
   "services": [
    "Road Delivery",
    "Overnight Priority"
   ]
  },
  {
   "name": "DHL",
   "country": "DE",
   "services": [
    "Paket",
    "Päckchen"
   ]
  },
  {
   "name": "DPD",
   "country": "DE",
   "services": [
    "Express 12",
    "Express",
    "Classic Parcel"
   ]
  },
  {
   "name": "Hermes",
   "country": "DE",
   "services": [
    "Päckchen",
    "Paketklasse S",
    "Paketklasse M",
    "Paketklasse L"
   ]
  },
  {
   "name": "UPS",
   "country": "DE",
   "services": [
    "Express",
    "Express Saver",
    "Standard"
   ]
  },
  {
   "name": "DHL UK",
   "country": "GB",
   "services": [
    "Express",
    "Express 12"
   ]
  },
  {
   "name": "DPD UK",
   "country": "GB",
   "services": [
    "Express 12",
    "Express Next Day",
    "Standard Parcel 12",
    "Standard Parcel Next Day",
    "Standard Parcel Two Day"
   ]
  },
  {
   "name": "RMG",
   "country": "GB",
   "services": [
    "1st Class Small Parcel",
    "1st Class Medium Parcel",
    "2nd Class Small Parcel",
    "2nd Class Medium Parcel"
   ]
  },
  {
   "name": "TNT UK",
   "country": "GB",
   "services": [
    "Express",
    "Express 10",
    "Express 12"
   ]
  },
  {
   "name": "UPS UK",
   "country": "GB",
   "services": [
    "Express",
    "Express Saver",
    "Standard"
   ]
  },
  {
   "name": "Yodel",
   "country": "GB",
   "services": [
    "B2C 48HR",
    "B2C 72HR",
    "B2C Packet"
   ]
  }
 ]
}

shippingsettings.getsupportedholidays

shippingsettings.getsupportedholidays 호출을 통해 MCA 계정 또는 독립형 계정에서 지원되는 휴일을 가져올 수 있습니다.

GET https://shoppingcontent.googleapis.com/content/v2.1/merchantId/supportedHolidays

다음은 샘플 JSON 응답입니다.

{
 "kind": "content#shippingsettingsGetSupportedHolidaysResponse",
 "holidays": [
  {
   "id": "FR_Christmas_2019-12-25",
   "countryCode": "FR",
   "type": "Christmas",
   "date": "2019-12-25",
   "deliveryGuaranteeDate": "2019-12-24",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Easter_2019-04-21",
   "countryCode": "US",
   "type": "Easter",
   "date": "2019-04-21",
   "deliveryGuaranteeDate": "2019-04-20",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Mother's Day_2019-05-12",
   "countryCode": "US",
   "type": "Mother's Day",
   "date": "2019-05-12",
   "deliveryGuaranteeDate": "2019-05-11",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Father's Day_2019-06-16",
   "countryCode": "US",
   "type": "Father's Day",
   "date": "2019-06-16",
   "deliveryGuaranteeDate": "2019-06-15",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Independence Day (USA)_2019-07-04",
   "countryCode": "US",
   "type": "Independence Day (USA)",
   "date": "2019-07-04",
   "deliveryGuaranteeDate": "2019-07-03",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Halloween_2019-10-31",
   "countryCode": "US",
   "type": "Halloween",
   "date": "2019-10-31",
   "deliveryGuaranteeDate": "2019-10-30",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Thanksgiving_2019-11-28",
   "countryCode": "US",
   "type": "Thanksgiving",
   "date": "2019-11-28",
   "deliveryGuaranteeDate": "2019-11-27",
   "deliveryGuaranteeHour": "18"
  },
  {
   "id": "US_Christmas_2019-12-25",
   "countryCode": "US",
   "type": "Christmas",
   "date": "2019-12-25",
   "deliveryGuaranteeDate": "2019-12-24",
   "deliveryGuaranteeHour": "18"
  }
 ]
}

우편번호 그룹 설정

판매자 센터에서 리전을 구축하는 것이 편리하지만 Content API를 사용하여 자주 변경되는 여러 리전의 계정을 유지할 수 있습니다.

배송 설정 서비스를 사용하면 배송 설정 및 지역을 설정, 가져오기, 업데이트할 수 있습니다. API에서는 리전을 postalCodeGroups라고 합니다.

"postalCodeGroups": [
  {
    "name": "string,
    "country": string,
    "postalCodeRanges": [
      {
        "postalCodeRangeBegin": string,
        "postalCodeRangeEnd": string
      }
    ]
  }
]

UI에서와 같이 postalCodeGroups는 우편번호, 우편번호 범위, 우편번호 접두어 또는 접두사 범위로 구성된 간단한 목록입니다.

지역은 배송 설정과 함께 검색 및 설정되므로 기존 배송 설정 리소스를 통해 postalCodeGroups를 채우면 배송 서비스가 삭제됩니다.

API를 통해 지역을 설정하는 올바른 방법은 다음과 같습니다.

  1. get를 호출하여 모든 배송 서비스 및 postalCodeGroups(지역)를 가져옵니다.
  2. 배송 서비스를 get 호출에서 update 호출로 복사합니다.
  3. 배송 서비스에서 운송 시간 라벨을 사용하지 않는 경우 요청 본문에서 다음 항목을 삭제합니다.

    "transitTimeLabels": [
        "all other labels"
    ],
    
  4. update 호출을 위해 postalCodeGroups 섹션에 리전을 채웁니다.

  5. 배송 서비스와 postalCodeGroups 섹션이 모두 채워진 상태로 update를 호출합니다.

다음은 위에서 사용한 첫 번째 get 예시의 update 호출 요청 본문 샘플로, 리전 1의 postalCodeGroups94035에서 94036로 업데이트되었습니다.

{
  "services": [
    {
      "name": "Standard Shipping",
      "active": true,
      "deliveryCountry": "US",
      "currency": "USD",
      "deliveryTime": {
        "minHandlingTimeInDays": 0,
        "maxHandlingTimeInDays": 1,
        "transitTimeTable": {
          "postalCodeGroupNames": [
            "Region1",
            "Region2",
            "all other locations"
          ],
          "rows": [
            {
              "values": [
                {
                  "minTransitTimeInDays": 1,
                  "maxTransitTimeInDays": 2
                }
              ]
            },
            {
              "values": [
                {
                  "minTransitTimeInDays": 2,
                  "maxTransitTimeInDays": 3
                }
              ]
            },
            {
              "values": [
                {
                  "minTransitTimeInDays": 3,
                  "maxTransitTimeInDays": 5
                }
              ]
            }
          ]
        }
      },
      "rateGroups": [
        {
          "singleValue": {
            "flatRate": {
              "value": "0",
              "currency": "USD"
            }
          },
          "name": "Standard Shipping"
        }
      ],
      "eligibility": "All scenarios"
    },
    {
      "name": "Expedited",
      "active": true,
      "deliveryCountry": "US",
      "currency": "USD",
      "deliveryTime": {
        "minTransitTimeInDays": 2,
        "maxTransitTimeInDays": 2,
        "minHandlingTimeInDays": 0,
        "maxHandlingTimeInDays": 1
      },
      "rateGroups": [
        {
          "singleValue": {
            "flatRate": {
              "value": "9.99",
              "currency": "USD"
            }
          },
          "name": "Expedited"
        }
      ],
      "eligibility": "All scenarios"
    }
  ],
  "postalCodeGroups": [
    {
      "name": "Region1",
      "country": "US",
      "postalCodeRanges": [
        {
          "postalCodeRangeBegin": "94036",
          "postalCodeRangeEnd": "94070"
        }
      ]
    },
    {
      "name": "Region2",
      "country": "US",
      "postalCodeRanges": [
        {
          "postalCodeRangeBegin": "94071",
          "postalCodeRangeEnd": "94082"
        }
      ]
    }
  ]
}

다음은 샘플 JSON 응답입니다.

{
 "accountId": "1111",
 "services": [
  {
   "name": "Standard Shipping",
   "active": true,
   "deliveryCountry": "US",
   "currency": "USD",
   "deliveryTime": {
    "minHandlingTimeInDays": 0,
    "maxHandlingTimeInDays": 1,
    "transitTimeTable": {
     "postalCodeGroupNames": [
      "Region1",
      "Region2",
      "all other locations"
     ],
     "rows": [
      {
       "values": [
        {
         "minTransitTimeInDays": 1,
         "maxTransitTimeInDays": 2
        }
       ]
      },
      {
       "values": [
        {
         "minTransitTimeInDays": 2,
         "maxTransitTimeInDays": 3
        }
       ]
      },
      {
       "values": [
        {
         "minTransitTimeInDays": 3,
         "maxTransitTimeInDays": 5
        }
       ]
      }
     ]
    }
   },
   "rateGroups": [
    {
     "singleValue": {
      "flatRate": {
       "value": "0",
       "currency": "USD"
      }
     },
     "name": "Standard Shipping"
    }
   ],
   "eligibility": "All scenarios"
  },
  {
   "name": "Expedited",
   "active": true,
   "deliveryCountry": "US",
   "currency": "USD",
   "deliveryTime": {
    "minTransitTimeInDays": 2,
    "maxTransitTimeInDays": 2,
    "minHandlingTimeInDays": 0,
    "maxHandlingTimeInDays": 1
   },
   "rateGroups": [
    {
     "singleValue": {
      "flatRate": {
       "value": "9.99",
       "currency": "USD"
      }
     },
     "name": "Expedited"
    }
   ],
   "eligibility": "All scenarios"
  }
 ],
 "postalCodeGroups": [
  {
   "name": "Region1",
   "country": "US",
   "postalCodeRanges": [
    {
     "postalCodeRangeBegin": "94036",
     "postalCodeRangeEnd": "94070"
    }
   ]
  },
  {
   "name": "Region2",
   "country": "US",
   "postalCodeRanges": [
    {
     "postalCodeRangeBegin": "94071",
     "postalCodeRangeEnd": "94082"
    }
   ]
  }
 ]
}

수령/화물 취급소 사용

집으로 배달 주문과의 차이점, 처리해야 하는 수령 관련 정보 등 수령/화물 취급소 주문에 대한 자세한 내용은 수령/수령 지점 가이드를 참고하세요.

당일 배송

오프라인 판매점 인벤토리가 있는 경우 Content API for Shopping을 사용하여 당일 배송 서비스를 구성할 수 있습니다.

당일 배송 서비스의 경우 shipmentTypelocal_delivery이(가) 적용됩니다. 현재 local_delivery의 모든 배송 서비스는 당일 배송으로 간주됩니다. 지역 배송의 deliveryTime 정보는 변경할 수 없습니다.

shippingsettings.update를 사용하여 오프라인 판매점 인벤토리 제품에 당일 배송을 설정하세요.

다음은 계정의 모든 매장에 당일 배송 서비스를 추가하는 요청 본문의 예입니다.

구현에서 사용하기 전에 다음 샘플의 모든 값을 업데이트하세요.

{
   "accountId":"accountId",
   "services":[
      {
         "name": "Local Delivery",
         "active":true,
         "shipmentType":"local_delivery",
         "deliveryCountry":"US",
         "currency":"USD",
         "rateGroups":[
            {
               "singleValue":{
                  "flatRate":{
                     "value":"0",
                     "currency":"USD"
                  }
               }
            }
         ],
         "eligibility":"All scenarios",
         "storeConfig":{
            "storeServiceType":"all stores",
            "storeCodes":[
               
            ],
            "cutoffConfig":{
               "storeCloseOffsetHours":2,
               "no_delivery_post_cutoff":true
            },
            "serviceRadius":{
               "value":4,
               "unit":"Miles"
            }
         }
      }
   ]
}

익일 배송

당일 배송 마감 시간 이후에 접수된 주문은 기본적으로 다음 날 배송으로 예약됩니다. 다음날 배송을 사용 중지하려면 no_delivery_post_cutofftrue로 설정하세요. 다음날 배송을 사용 중지하면 매일 마감 시간 전에만 배송 서비스가 표시됩니다.

shipmentType이(가) local_delivery인 경우에만 익일 배송이 가능합니다.

테스트

모든 항목이 프로덕션 단계에 있으므로, 게시 중인 항목에서 중요한 항목을 변경하지 않도록 주의해야 합니다. 특히 update() 메서드를 사용할 때는 이 메서드가 기존 값을 변경하는 유일한 방법이기 때문입니다.