Batch update stock levels for the provided SKUs
code examples curl request post \\ \ url /api/v1/batch update stock \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ header 'site id jones climbing' \\ \ data '\[ { "sku" "", "stock location external id" "warehouse 1" } ]'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); myheaders append("site id", "jones climbing"); var raw = json stringify(\[ { "sku" "", "stock location external id" "warehouse 1" } ]); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("/api/v1/batch update stock", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));require "uri" require "json" require "net/http" url = uri("/api/v1/batch update stock") http = net http new(url host, url port); request = net http post new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request\["site id"] = "jones climbing" request body = json dump(\[ { "sku" "", "stock location external id" "warehouse 1" } ]) response = http request(request) puts response read body import requests import json url = "/api/v1/batch update stock" payload = json dumps(\[ { "sku" "", "stock location external id" "warehouse 1" } ]) headers = { 'accept' 'application/json', 'content type' 'application/json', 'site id' 'jones climbing' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses // success no content // error response