Planning App APIs
Plans
Create a new plan
1 min
code examples curl location globoff 'https //{tenantsubdomain}/tms/api/v1/planning/plan' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ header 'x coreos request id string' \\ \ header 'x coreos tid string' \\ \ header 'x coreos access string' \\ \ header 'x coreos userinfo string' \\ \ data '{ "autoconfirmloads" true, "starttime" 1754543645702, "plansettings" { "minweightutilization" 1, "minvolumeutilization" 1, "detourkms" 1, "customersplit" true, "ordersplit" true, "planltl" false, "consolidateltl" false, "replanexistingload" true, "maxstops" 1, "stacking" false, "movementtype" \[], "orderids" \[] }, "facilitylist" \[] }'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); myheaders append("x coreos request id", "string"); myheaders append("x coreos tid", "string"); myheaders append("x coreos access", "string"); myheaders append("x coreos userinfo", "string"); var raw = json stringify({ "autoconfirmloads" true, "starttime" 1754543645702, "plansettings" { "minweightutilization" 1, "minvolumeutilization" 1, "detourkms" 1, "customersplit" true, "ordersplit" true, "planltl" false, "consolidateltl" false, "replanexistingload" true, "maxstops" 1, "stacking" false, "movementtype" \[], "orderids" \[] }, "facilitylist" \[] }); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("https //{tenantsubdomain}/tms/api/v1/planning/plan", 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/planning/plan") https = net http new(url host, url port) https use ssl = true request = net http post new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request\["x coreos request id"] = "string" request\["x coreos tid"] = "string" request\["x coreos access"] = "string" request\["x coreos userinfo"] = "string" request body = json dump({ "autoconfirmloads" true, "starttime" 1754543645702, "plansettings" { "minweightutilization" 1, "minvolumeutilization" 1, "detourkms" 1, "customersplit" true, "ordersplit" true, "planltl" false, "consolidateltl" false, "replanexistingload" true, "maxstops" 1, "stacking" false, "movementtype" \[], "orderids" \[] }, "facilitylist" \[] }) response = https request(request) puts response read body import requests import json url = "https //{tenantsubdomain}/tms/api/v1/planning/plan" payload = json dumps({ "autoconfirmloads" true, "starttime" 1754543645702, "plansettings" { "minweightutilization" 1, "minvolumeutilization" 1, "detourkms" 1, "customersplit" true, "ordersplit" true, "planltl" false, "consolidateltl" false, "replanexistingload" true, "maxstops" 1, "stacking" false, "movementtype" \[], "orderids" \[] }, "facilitylist" \[] }) headers = { 'accept' 'application/json', 'content type' 'application/json', 'x coreos request id' 'string', 'x coreos tid' 'string', 'x coreos access' 'string', 'x coreos userinfo' 'string' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses // plan creation response { "success" true, "data" { "id" "string", "requestid" "string" } }// plan creation error { "success" false, "error" { "code" 400, "message" "error creating plan" } }// internal server error
