eBay .NET API, Adding Listings, Unexpected number of Return Polices Have Been Created.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2023 01:19 AM
I am using .Net SDK for eBay, I am creating products and assigning return policy as per code before.
private static ReturnPolicyType GetReturnPolicyForAU()
{
ReturnPolicyType policy =
new ReturnPolicyType
{
Refund = "MoneyBack",
ReturnsWithinOption = "Days_30",
ReturnsAcceptedOption = "ReturnsAccepted",
ShippingCostPaidByOption = "Buyer"
};
return policy;
}
and I use it this way
item.Location = product.Location;
item.PostalCode = product.PostCode;
item.DispatchTimeMax = 5;
item.ShippingDetails = defaultItem.ShippingDetails;
item.ReturnPolicy = GetReturnPolicyForAU();
but in my business policies, It has created many polices,
https://github.com/CMS365-PTY-LTD/EbaySharp
eBay .NET API, Adding Listings, Unexpected number of Return Polices Have Been Created.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2023 01:43 AM
Business policies are newer than the older ReturnPolicy field.
And when a listing is created in some way that doesn't specify one of the existing policies by a given name or ID, one instead gets generated.
To use them in the Trading API (when predefined) you use Item.SellerProfiles followed by .(SellerPaymentProfile/SellerShippingProfile/SellerReturnProfile) and then either Name or ID of the policy (yes, policy/profile wording is a bit mixed) (ID takes precedence when both are present)
template:
<SellerProfiles> SellerProfilesType
<SellerPaymentProfile> SellerPaymentProfileType
<PaymentProfileID> long </PaymentProfileID>
<PaymentProfileName> string </PaymentProfileName>
</SellerPaymentProfile>
<SellerReturnProfile> SellerReturnProfileType
<ReturnProfileID> long </ReturnProfileID>
<ReturnProfileName> string </ReturnProfileName>
</SellerReturnProfile>
<SellerShippingProfile> SellerShippingProfileType
<ShippingProfileID> long </ShippingProfileID>
<ShippingProfileName> string </ShippingProfileName>
</SellerShippingProfile>
</SellerProfiles>
To manage / create them using API instead of the website, you have to use the REST Sell API Account v1. (Payment/Fulfillment/Return)
https://developer.ebay.com/api-docs/sell/account/static/overview.html
