Merchant Promotions API를 사용하여 Google에서 프로모션을 만들고 관리할 수 있습니다. accounts.promotions
리소스를 사용하면 Google에서 판매하는 제품의 특별 이벤트를 선보일 수 있습니다.
자세한 내용은 판매자 프로모션 API 개요를 참고하세요.
Content API for Shopping에서 Merchant API로의 변경사항 개요
중요한 차이점은 Content API for Shopping은 첫 번째 프로모션 삽입 시 데이터 소스를 자동으로 생성하지만 Merchant API에서는 그렇지 않다는 것입니다. Merchant API를 사용하여 프로모션을 삽입하려면 먼저 프로모션 데이터 소스를 만들어야 합니다.
accounts.dataSources
리소스의 promotionDataSource
객체 필드에 관한 자세한 내용은 PromotionDataSource를 참고하세요.
요청
요청을 수행하려면 다음 URL을 사용하세요.
POST https://merchantapi.googleapis.com/promotions/v1/{ACCOUNT_NAME}/promotions
Content API for Shopping에서 이전
다음은 프로모션 관련 요청에 대한 Content API for Shopping과 Merchant Promotions API를 비교한 것입니다.
URL
Content API for Shopping:
https://shoppingcontent.googleapis.com/content/v2.1/{MERCHANT_ID}/promotions
판매자 API에서 다음과 같이 변경됩니다.
https://merchantapi.googleapis.com/promotions/v1/{parent=accounts/*}/promotions
식별자
Content API for Shopping:
{MERCHANT_ID}/promotions/{PROMOTION_ID}
판매자 API에서 다음과 같이 변경됩니다.
{NAME}
메서드
Merchant API는 프로모션에 다음 메서드를 지원합니다.
- 프로모션 삽입
- 프로모션 받기
- 프로모션 나열
다음은 쇼핑용 Content API와 Merchant API에서 사용할 수 있는 프로모션 방법을 비교한 것입니다.
기능 | Content API for Shopping | Merchant API |
---|---|---|
URL | https://shoppingcontent.googleapis.com/content/v2.1/{MERCHANT_ID}/promotions |
https://merchantapi.googleapis.com/promotions/v1/{parent=accounts/*}/promotions |
식별자 | {MERCHANT_ID}/promotions/{PROMOTION_ID} |
{NAME} |
메서드 |
|
|
필드 변경사항
표에는 Merchant Promotions API의 프로모션 변경사항이 표시되어 있습니다.
참고용 예시를 보려면 오프라인 인벤토리를 참고하세요.
Content API for Shopping | Merchant API | 설명 |
---|---|---|
(지원되지 않음) | custom_attributes |
맞춤 (사용자 제공) 속성 목록입니다. 또한 일반적인 형식으로 피드 사양의 속성을 제출하는 데 사용할 수도 있습니다. 예를 들면 다음과 같습니다. { "name": "size type", "value": "regular" } 노출되지 않는 속성을 제출하는 데 유용합니다. |
지원되지 않음 | data_source | 프로모션을 만들려면 기존 데이터 소스가 필요합니다. |
지원되지 않음 | attributes |
long_tile, promotion_effective_timeperiod 등 프로모션 관련 속성은 속성 메시지의 일부입니다. |
item_id | item_id_inclusion |
프로모션이 적용되는 상품 ID 목록이 로 이름이 변경됩니다. |
store_id | store_id_inclusion |
프로모션이 적용되는 매장 ID 목록의 이름이 변경됩니다.
|
product_type | product_type_inclusion |
프로모션이 적용되는 제품 유형 목록의 이름이 변경됩니다.
|
item_group_id | item_group_id_inclusion |
프로모션이 적용되는 상품 그룹 ID 목록의 이름이 변경됩니다. |
brand | brand_inclusion |
프로모션이 적용되는 브랜드 목록의 이름이 변경됩니다.
|
store_code | store_codes_inclusion |
프로모션이 적용되는 스토어 코드 목록의 이름이 변경됩니다.
|
price: { object (Price) } |
price: { object (Price) } |
가격의 정의가 변경되었습니다.
Content API for Shopping에서 Price
이제 가격 금액이 마이크로 단위로 기록됩니다.
amount 필드 이름이 value에서
currency 필드 이름이 |
order_limit | (지원되지 않음) | order_limit 속성은 지원되지 않습니다. |
shippingServiceNames[] | (지원되지 않음) | shippingServiceNames[]는 지원되지 않습니다. |
money_budget | (지원되지 않음) | money_budget은 지원되지 않습니다. |
promotion_destination_ids | promotion_destinations | promotionDestinationIds의 이름이 변경되었습니다. |
프로모션 상태
{ "destinationStatuses": [ { "destination": string, "status": enum (State) } ], "promotionIssue": [ { "code": string, "detail": string } ], "creationDate": string, "lastUpdateDate": string } |
프로모션 상태가 변경되었습니다.
문제에서 더 세부적인 세부정보를 확인할 수 있습니다. promotionStatus = { destinationStatuses = [ { reportingContext = Enum status = Enum }, ], itemLevelIssues = [ { code = String severity = Enum resolution = String reportingContext = Enum description = String detail = String documentation = String applicableCountries = [ String, ] } ] } |