GET/return_policy/get_by_policy_name
This method retrieves the details of a specific return policy. Supply both the policy name
and its associated marketplace_id
in the request query parameters.
Marketplaces and locales
Get the correct policy for a marketplace that supports multiple locales using the Content-Language
request header. For example, get a policy for the French locale of the Canadian marketplace by specifying fr-CA
for the Content-Language
header. Likewise, target the Dutch locale of the Belgium marketplace by setting Content-Language: nl-BE
. For details on header values, see HTTP request headers.
Input
Resource URI
This method is supported in Sandbox environment. To access the endpoint, just replace the api.ebay.com
root URI with api.sandbox.ebay.com
URI parameters
Parameter | Type | Description |
---|---|---|
marketplace_id | MarketplaceIdEnum | This query parameter specifies the ID of the eBay marketplace of the policy you want to retrieve. Occurrence: Required |
name | string | This query parameter specifies the seller-defined name of the return policy you want to retrieve. This value can be retrieved for a return policy by using the getReturnPolicies method. Occurrence: Required |
HTTP request headers
All requests made to eBay REST operations require you to provide the Authorization
HTTP header for authentication authorization.
All other standard RESTful request headers are optional. For more information on standard RESTful request headers, see the HTTP request headers- opens rest request components page table.
OAuth scope
This request requires an access token created with the authorization code grant flow, using one or more scopes from the following list (please check your Application Keys page for a list of OAuth scopes available to your application):
https://api.ebay.com/oauth/api_scope/sell.account
https://api.ebay.com/oauth/api_scope/sell.account.readonly
See OAuth access tokens for more information.
Request payload
This call has no payload.
Request fields
This call has no field definitions.
Output
HTTP response headers
This call has no response headers.
Response payload
Response fields
Output container/field | Type | Description |
---|---|---|
categoryTypes | array of CategoryType | This container indicates which category group that the return policy applies to. Occurrence: Always |
categoryTypes.default | boolean | Note: This field has been deprecated and is no longer used. Occurrence: Conditional |
categoryTypes.name | CategoryTypeEnum | The category type to which the policy applies (motor vehicles or non-motor vehicles). Occurrence: Always |
description | string | A seller-defined description of the return business policy. This description is only for the seller's use, and is not exposed on any eBay pages. Occurrence: Conditional |
extendedHolidayReturnsOffered | boolean | Important! This field is deprecated, since eBay no longer supports extended holiday returns. Any value supplied in this field is neither read nor returned. Occurrence: Conditional |
internationalOverride | InternationalReturnOverrideType | This container shows the seller's international return policy settings. This container is only returned if the seller has set a separate international return policy for the business policies. International return policies are optional, even if the seller ships to international locations. If a separate international return policy is not set, all of the domestic return policy settings also apply to international orders. Occurrence: Conditional |
internationalOverride.returnMethod | ReturnMethodEnum | This field sets/indicates if the seller offers replacement items to the buyer in the case of an international return. The buyer must be willing to accept a replacement item; otherwise, the seller will need to issue a refund for a return. Occurrence: Conditional |
internationalOverride.returnPeriod | TimeDuration | This container indicates the number of calendar days that the buyer has to return an item. The return period begins when the item is marked "delivered" at the buyer's specified ship-to location. Occurrence: Conditional |
internationalOverride.returnPeriod.unit | TimeDurationUnitEnum | These enum values represent the time measurement unit, such as Occurrence: Conditional |
internationalOverride.returnPeriod.value | integer | An integer that represents an amount of time, as measured by the time-measurement unit specified in the unit field. Occurrence: Conditional |
internationalOverride.returnsAccepted | boolean | If set to Occurrence: Conditional |
internationalOverride.returnShippingCostPayer | ReturnShippingCostPayerEnum | This field indicates who is responsible for paying for the shipping charges for returned items. The field can be set to either Occurrence: Conditional |
marketplaceId | MarketplaceIdEnum | The ID of the eBay marketplace to which this return business policy applies. Occurrence: Always |
name | string | A seller-defined name for this payment business policy. Names must be unique for policies assigned to the same marketplace. Occurrence: Always |
refundMethod | RefundMethodEnum | If a seller indicates that they will accept buyer returns, this value will be set to Occurrence: Always |
restockingFeePercentage | string | Important! This field is deprecated, since eBay no longer allows sellers to charge a restocking fee for buyer remorse returns. If this field is included, it is ignored and it is no longer returned. Occurrence: Conditional |
returnInstructions | string | This text-based field provides more details on seller-specified return instructions. This field is only returned if set for the return business policy. Important! This field is no longer supported on many eBay marketplaces. To see if a marketplace and eBay category does support this field, call getReturnPolicies method of the Metadata API. Then you will look for the policyDescriptionEnabled field with a value of Max length: 5000 (8000 for DE) Occurrence: Conditional |
returnMethod | ReturnMethodEnum | This field is only returned if the seller is willing to offer a replacement item as an alternative to 'Money Back'. Occurrence: Conditional |
returnPeriod | TimeDuration | This container indicates the number of calendar days that the buyer has to return an item. The return period begins when the item is marked "delivered" at the buyer's specified ship-to location. Occurrence: Always |
returnPeriod.unit | TimeDurationUnitEnum | These enum values represent the time measurement unit, such as Occurrence: Conditional |
returnPeriod.value | integer | An integer that represents an amount of time, as measured by the time-measurement unit specified in the unit field. Occurrence: Conditional |
returnPolicyId | string | A unique eBay-assigned ID for a return business policy. This ID is generated when the policy is created. Occurrence: Always |
returnsAccepted | boolean | If this field is returned as Occurrence: Always |
returnShippingCostPayer | ReturnShippingCostPayerEnum | This field indicates who is responsible for paying for the shipping charges for returned items. The field can be set to either Occurrence: Always |
HTTP status codes
This call can return one of the following HTTP status codes. For an overview of the status codes, see HTTP status codes in Using eBay RESTful APIs.
Status | Meaning |
---|---|
200 | Success |
400 | Bad Request |
500 | Internal Server Error |
Error codes
For more on errors, plus the codes of other common errors, see Handling errors.
Code | Domain | Category | Meaning |
---|---|---|---|
20401 | API_ACCOUNT | REQUEST | Missing field {fieldName}. {additionalInfo} |
20403 | API_ACCOUNT | REQUEST | Invalid {fieldName}. {additionalInfo} |
20404 | API_ACCOUNT | REQUEST | {fieldName} not found. |
20500 | API_ACCOUNT | APPLICATION | System error. |
20501 | API_ACCOUNT | APPLICATION | Service unavailable. Please try again in next 24 hours. |
Warnings
This call has no warnings.
Samples
New to making API calls? Please see Making a Call.
Note: Identifiers, such as order IDs or user IDs, and personal data in these samples might be anonymized or may no longer be active on eBay. If necessary, substitute current, relevant eBay data in your requests.
Sample 1: Get Return Policy by Name
This call retrieves the return policy that matches the name you specify in the request.
Input
This call uses two query parameters to identify the policy you want to retrieve. Specify the name of the policy you want to retrieve using the name query parameter and supply the marketplace for the policy using the marketplace_id parameter. This call does not use a request body.
GEThttps://api.sandbox.ebay.com/sell/account/v1/return_policy/get_by_policy_name?name=m********e& marketplace_id=EBAY_US
Output
A successful call returns an HTTP status code of 200 OK and a response body containing the specified return policy.