Load App APIs
Load Line Items
Delete load line item
1 min
code examples curl location globoff request delete 'https //{tenantsubdomain}/tms/api/v1/demands/load line items/{line item id}' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ header 'x coreos tid string' \\ \ header 'x coreos access string' \\ \ header 'x coreos userinfo string'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); myheaders append("x coreos tid", "string"); myheaders append("x coreos access", "string"); myheaders append("x coreos userinfo", "string"); var requestoptions = { method 'delete', headers myheaders, redirect 'follow' }; fetch("https //{tenantsubdomain}/tms/api/v1/demands/load line items/{line item id}", 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("https //{tenantsubdomain}/tms/api/v1/demands/load line items/{line item id}") https = net http new(url host, url port) https use ssl = true request = net http delete new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request\["x coreos tid"] = "string" request\["x coreos access"] = "string" request\["x coreos userinfo"] = "string" response = https request(request) puts response read body import requests import json url = "https //{tenantsubdomain}/tms/api/v1/demands/load line items/{line item id}" payload = {} headers = { 'accept' 'application/json', 'content type' 'application/json', 'x coreos tid' 'string', 'x coreos access' 'string', 'x coreos userinfo' 'string' } response = requests request("delete", url, headers=headers, data=payload) print(response text) responses // load line item deletion initiated successfully { "success" false, "data" { "id" "", "requestid" "" } }// line item not found { "success" false, "error" "", "error code" "" }// internal server error { "success" false, "error" "", "error code" "" }
