Add Product to sales channels
PUT https://{handle}.myshopline.com/admin/openapi/v20260301/product_listings/:product_listing_id.json
handle : The store's unique identifier, which is the prefix of the store's domain name. For example, if a store's domain name is open001.myshopline.com , the store handle is open001 .Path Parameters
- product_listing_id string requiredProduct IDExample:
16057039432335097907370282
Request Headers
- Content-Type string requiredThe field must be set to the fixed value
application/json; charset=utf-8. - Authorization string requiredThe access token for the API resource. Refer to App authorization to obtain the access token, and then pass the obtained token in the Bearer format.Example:
Bearer eyJhbGciOiJIUzUxMiJ9.eyJhcHBLZXkiOiJmMjM3OWQyMTYyOGMzM2QxMWRiMWZkYjY5N2EzZjdjMjZlNGMwYTA5Iiwic2VsbGVySWQiOiIyMDAwMjM0ODgwIiwic3RvcmVJZCI6IjE2NzIzNjk3Mjk2MDYiLCJ2ZXJzaW9uIjoiVjIiLCJkb21haW4iOiJodHRwczovL3NsLW9wZW4tc2cubXlzaG9wbGluZS5jb20iLCJ0aW1lc3RhbXAiOjE2NzUzMTk0OTI0MzksImlzcyI6Inlzb3VsIiwiZXhwIjoxNzY5OTI3NDkyfQ.UwQzomM2veGCUaOZ0paUxq5dpc7DXuhHYFvsQ_uIAKduzWcb_j2E4q_36El83sp145D4cKbpcE5KCeeIz-JNQw
Request Body
product_listingobject
Product informationproduct_id stringProduct IDExample:16057039432335097907370282
Status Codes
- 200
- 401
- 429
For the complete list of codes and messages, see Http status code.
Response Headers
traceId
A globally unique identifier for the request. It is used to track the request flow throughout the system, allowing for easy location and debugging when issues arise.
Response Body
product_listingobject
Product listhandle stringGlobal unique Product handleExample:product-handleupdated_at stringProduct update timeExample:2022-12-06T15:13:50+08:00vendor stringvendorExample:Shoplineimagesobject[]
Product main image listingsrc stringImage srcExample:https://img.myshopline.com/image/official/e46e6189dd5641a3b179444cacdcdd2a.pngalt stringImage altExample:This is a image altpublished_at stringTime to post to the online storeExample:2022-12-06T15:13:50+08:00template_path stringtemplate pathExample:templates/products/detail.jsonpublished_scope stringSet the release scope, when the value is "web", it means an online storeExample:webstatus stringProduct status ; activated- on shelves , deactivated- off shelves , archived- filingExample:activesubtitle stringProduct summaryExample:This is a subtitlevariantsobject[]
Variant listoption1 stringThe variant corresponds to the value of the option1Example:Redproduct_id stringProduct IDExample:16057039432335097907370282weight stringWeightExample:0.5inventory_item_id stringInventory item IDExample:5703943240925324252option5 stringThe variant corresponds to the value of the option5imageobject
variant picturealt stringImage altExample:This is a image altsrc stringImage srcExample:https://img.myshopline.com/image/official/e46e6189dd5641a3b179444cacdcdd2a.pnginventory_tracker booleanTrack inventory or notExample:trueoption2 stringThe variant corresponds to the value of the option2Example:Lid stringVariant idExample:18057039432358082693350282price stringselling priceExample:90title stringVariant titleExample:Red/Lcompare_at_price stringOriginal priceExample:100option3 stringThe variant corresponds to the value of the option3option4 stringThe variant corresponds to the value of the option4barcode stringbarcodeExample:B000000001sku stringSku code , ready-to-shipExample:T00000001weight_unit stringWeight units : g , kg , lb , oz , zh_kgExample:ginventory_policy stringOversold strategy: deny - Oversold is not allowed, continue - Oversold is allowedExample:denyinventory_quantity integerInventory summary for all locationsExample:100spu stringSPU coceExample:S0000000001created_at stringProduct created timeExample:2022-12-06T15:13:50+08:00optionsobject[]
List of optionvalues_images mapThe image of option valueExample:{}id stringOption idExample:16157850264851626133440282name stringOption nameExample:Colorproduct_id stringProduct IDExample:16057039432335097907370282values arrayList of option valueExample:["[\"Red\", \"Green\", \"White”]"]tags stringProduct tagExample:tag1, tag2product_id stringProduct IDExample:16057039432335097907370282body_html stringPproduct descriptionExample:This is the product descriptiontitle stringProduct titleExample:This is a title
API Explorer
Debugger
Examples
Was this article helpful to you?