نقل إدارة سياسة الإرجاع على الإنترنت
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
تم تغيير المورد OnlineReturnPolicy
في Content API والحقول المرتبطة به، بما في ذلك ReturnPolicyPolicy
وReturnPolicySeasonalOverride
.
المورد المكافئ returnpolicy
في Merchant API ضمن Content API هو accounts.onlineReturnPolicies
.
يوضّح هذا الجدول التغييرات التي تطرأ على OnlineReturnPolicy
.
Content API |
Merchant API |
"country": string
|
"countries": [ string ]
|
"policy": {
object (ReturnPolicyPolicy)
}
|
"policy": {
object (Policy)
}
|
"seasonalOverrides": [
{
object (ReturnPolicySeasonalOverride)
}
]
|
"seasonalOverrides": [
{
object (SeasonalOverride)
}
],
|
nonFreeReturnReasons": [ string ]
|
ستتم إزالة هذا الحقل.
|
kind
|
ستتم إزالة هذا الحقل.
|
"returnShippingFee": {
object (Price)
}
|
"returnShippingFee": {
object (ReturnShippingFee)
}
|
بالإضافة إلى ذلك، يتضمّن Merchant API عددًا من الحقول الجديدة.
حقل Merchant API |
الوصف |
"restockingFee": {
object (RestockingFee)
},
|
اختيارية: رسوم إعادة التخزين التي تنطبق على جميع فئات أسباب الإرجاع
سيتم التعامل مع هذا الحقل على أنّه رسوم إعادة تخزين مجانية إذا لم يتم ضبط القيمة.
|
"returnMethods": [
enum (ReturnMethod)
]
|
اختيارية: تمثّل هذه السمة طرق الإرجاع التي يمكن للعملاء من خلالها إرجاع سلعة. يجب أن تكون هذه القيمة غير فارغة ما لم يكن نوع سياسة الإرجاع noReturns.
|
"itemConditions": [ enum (ItemCondition) ],
|
اختيارية: يجب ألا تكون حالات السلع المقبولة للإرجاع فارغة إلا إذا كان نوع سياسة الإرجاع هو noReturns.
|
"returnShippingFee": {
object (ReturnShippingFee)
}
|
اختيارية: تمثّل هذه السمة رسوم شحن السلع المرجَعة. يجب ضبط هذا الحقل فقط عندما يحتاج العميل إلى تنزيل وطباعة ملصق الإرجاع.
|
"returnPolicyUri": string
|
مطلوب. تمثّل هذه السمة معرّف الموارد المنتظم (URI) لسياسة الإرجاع. تستخدم Google هذا الرقم للتحقّق من صحة السياسة.
يجب أن يكون عنوان URL صالحًا.
|
"acceptDefectiveOnly": boolean
|
مطلوب. تحدّد هذه السمة أنّ التاجر يقبل إرجاع المنتجات التي تتضمّن عيوبًا فقط.
|
"processRefundDays": integer
|
اختيارية: تحدّد هذه السمة عدد الأيام التي يستغرقها التجّار لمعالجة عمليات ردّ الأموال.
|
"acceptExchange": boolean
|
اختيارية: تحدّد هذه السمة ما إذا كان التاجر يسمح للعملاء باستبدال المنتجات.
|
"returnLabelSource": enum (ReturnLabelSource)
|
تحدّد هذه السمة مصدر ملصق الإرجاع. تكون هذه السمة مطلوبة عندما تكون قيمة سمة "طريقة الإرجاع" هي BY_MAIL.
|
ReturnPolicyPolicy
تصبح Content API ReturnPolicyPolicy
Policy
في Merchant API. في ما يلي
كيفية تغيير الحقول.
Content API |
Merchant API |
"type": string,
|
"type": enum (Type)
تشمل القيم المحتملة
NUMBER_OF_DAYS_AFTER_DELIVERY, NO_RETURNS or LIFETIME_RETURNS.
|
"numberOfDays": string
|
"days": string
|
"lastReturnDate": string
|
يمكنك استخدام days كبديل. يمثّل هذا السمة عدد الأيام التي يمكن فيها إرجاع السلع بعد تسليمها، ويُعرّف اليوم الواحد على أنّه 24 ساعة بعد الطابع الزمني للتسليم. مطلوب لعمليات إرجاع NUMBER_OF_DAYS_AFTER_DELIVERY .
|
ReturnPolicySeasonalOverride
يصبح Content API ReturnPolicySeasonalOverride
هو SeasonalOverride
في Merchant API. بالإضافة إلى التغييرات في الحقول، الحقل الإضافي
return_window
هو اتحاد يمكن أن يكون إما returnDays
أو returnUntilDate
:
"returnDays": integer,
"returnUntilDate": {
object (Date)
وتحمل المعاني التالية:
-
returnDays
: تمثّل هذه السمة عدد الأيام التي يمكن خلالها إرجاع المنتج (بدءًا من تاريخ التسليم).
-
returnUntilDate
: تاريخ انتهاء ثابت يجب إرجاع المنتج قبله.
في ما يلي التغييرات التي طرأت على الحقول.
Content API |
Merchant API |
"name": string
|
"label": string
|
"startDate": string
|
"startDate": {
object (Date)
}
|
"endDate": string
|
"endDate": {
object (Date)
}
|
"policy": {
object (ReturnPolicyPolicy)
}
|
يمكنك استخدام policy كبديل.
|
تعريفات الكائنات الأخرى
للاطّلاع على تعريفات عناصر Merchant API الجديدة
RestockingFee
ReturnMethod
ItemCondition
ReturnShippingFee
Type
ReturnLabelSource
راجِع
accounts.onlineReturnPolicies
.
الطُرق
باستخدام Merchant API، هناك بعض التغييرات أيضًا مقارنةً بطُرق Content API.
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2025-08-08 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-08-08 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Migrate online return policy management\n\nThe Content API resource `OnlineReturnPolicy` and associated fields including\n`ReturnPolicyPolicy` and `ReturnPolicySeasonalOverride` have changed.\n\nThe Merchant API equivalent of the\n[`returnpolicy`](/shopping-content/reference/rest/v2.1/returnpolicy) resource in\nContent API is\n[`accounts.onlineReturnPolicies`](/merchant/api/reference/rest/accounts_v1/accounts.onlineReturnPolicies).\n\nThis table explains what changes in `OnlineReturnPolicy`.\n\n| Content API | Merchant API |\n|------------------------------------------------------------------------|-------------------------------------------------------------|\n| ` \"country\": string ` | ` \"countries\": [ string ] ` |\n| ` \"policy\": { object (ReturnPolicyPolicy) } ` | ` \"policy\": { object (Policy) } ` |\n| ` \"seasonalOverrides\": [ { object (ReturnPolicySeasonalOverride) } ] ` | ` \"seasonalOverrides\": [ { object (SeasonalOverride) } ], ` |\n| ` nonFreeReturnReasons\": [ string ] ` | This field goes away.` ` |\n| `kind ` | This field goes away.` ` |\n| ` \"returnShippingFee\": { object (Price) } ` | ` \"returnShippingFee\": { object (ReturnShippingFee) } ` |\n\nIn addition, a number of fields are new with Merchant API.\n\n| Merchant API field | Description |\n|---------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` \"restockingFee\": { object (RestockingFee) }, ` | Optional. The restocking fee that applies to all return reason categories. This would be treated as a free restocking fee if the value is not set. ` ` |\n| ` \"returnMethods\": [ enum (ReturnMethod) ] ` | Optional. The return methods of how customers can return an item. This value is required to not be empty unless the type of return policy is noReturns. ` ` |\n| ` \"itemConditions\": [ enum (ItemCondition) ], ` | Optional. The item conditions accepted for returns must not be empty unless the type of return policy is `noReturns.` |\n| ` \"returnShippingFee\": { object (ReturnShippingFee) } ` | Optional. The return shipping fee. Should be set only when customer need to download and print the return label. ` ` |\n| ` \"returnPolicyUri\": string ` | Required. The return policy URI. Google uses this to validate the policy. It must be a valid URL. ` ` |\n| ` \"acceptDefectiveOnly\": boolean ` | Required. Specifies that a merchant accepts only defective products for returns. ` ` |\n| ` \"processRefundDays\": integer ` | Optional. Specifies the number of days it takes for merchants to process refunds. ` ` |\n| ` \"acceptExchange\": boolean ` | Optional. Specifies whether the merchant allows customers to exchange products. |\n| ` \"returnLabelSource\": enum (ReturnLabelSource) ` | Specifies the return label source. Required when return method is BY_MAIL. ` ` |\n\nReturnPolicyPolicy\n------------------\n\nThe Content API `ReturnPolicyPolicy` becomes `Policy` in Merchant API. Here's\nhow the fields have changed.\n\n| Content API | Merchant API |\n|------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` \"type\": string, ` | ` \"type\": enum (Type) ` Possible values include ` NUMBER_OF_DAYS_AFTER_DELIVERY, NO_RETURNS or LIFETIME_RETURNS. ` |\n| ` \"numberOfDays\": string ` | ` \"days\": string ` |\n| ` \"lastReturnDate\": string ` | Use `days` instead. It represents the number of days items can be returned after delivery, where one day is defined as 24 hours after the delivery timestamp. Required for `NUMBER_OF_DAYS_AFTER_DELIVERY` returns. |\n\nReturnPolicySeasonalOverride\n----------------------------\n\nThe Content API `ReturnPolicySeasonalOverride` becomes `SeasonalOverride` in\nMerchant API. In addition to the changes in fields, the additional field\n`return_window` is a union that can be either `returnDays` or `returnUntilDate`: \n\n \"returnDays\": integer,\n \"returnUntilDate\": {\n object (Date)\n\nThey have the following meanings:\n\n- `returnDays`: Number of days (from the delivery date) that the product can still be returned.\n- `returnUntilDate`: Fixed end date until which the product can be returned.\n\nHere's how the fields have changed.\n\n| Content API | Merchant API |\n|-----------------------------------------------|------------------------------------|\n| ` \"name\": string ` | ` \"label\": string ` |\n| ` \"startDate\": string ` | ` \"startDate\": { object (Date) } ` |\n| ` \"endDate\": string ` | ` \"endDate\": { object (Date) } ` |\n| ` \"policy\": { object (ReturnPolicyPolicy) } ` | Use `policy` instead. |\n\nDefinitions of other objects\n----------------------------\n\nFor definitions of the new Merchant API objects\n\n- `RestockingFee`\n- `ReturnMethod`\n- `ItemCondition`\n- `ReturnShippingFee`\n- `Type`\n- `ReturnLabelSource`\n\nsee\n[`accounts.onlineReturnPolicies`](/merchant/api/reference/rest/accounts_v1/accounts.onlineReturnPolicies).\n\nMethods\n-------\n\nWith Merchant API, there are some changes from the Content API methods as well.\n\n| Content API | Merchant API |\n|-----------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` customBatch ` | With Mechant API, there is a different approach. See [Refactor code for concurrent requests.](/merchant/api/guides/compatibility/refactor-concurrent-requests) |\n| ` delete ` | ` delete ` |\n| ` get ` | ` get ` |\n| ` insert ` | `create` |\n| ` list ` | ` list ` |"]]