API References
...
Orders
Activate Draft Order
1 min
code examples curl location globoff 'https //api nue io/orders/{draftorderid}' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data '{ "options" {} }'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var raw = json stringify({ "options" {} }); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("https //api nue io/orders/{draftorderid}", 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 //api nue io/orders/{draftorderid}") 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 body = json dump({ "options" {} }) response = https request(request) puts response read body import requests import json url = "https //api nue io/orders/{draftorderid}" payload = json dumps({ "options" {} }) headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses // created { "status" "", "data" { "assets" \[ { "assetcompositeid" "", "assetlevel" 0, "assetnumber" "", "assetprovidedbyid" "", "assetservicedbyid" "", "assetversion" 0, "billcycleday" "", "billcyclestartmonth" "", "billingperiod" "", "billingtiming" "", "cancellationdate" "", "contactid" "", "createdbyid" "", "createddate" "", "customerid" "", "description" "", "entityid" "", "externalid" "", "id" "", "installdate" "", "internalasset" false, "iscompetitorproduct" false, "lastmodifiedbyid" "", "lastmodifieddate" "", "lastversionedassetid" "", "lifecycleenddate" "", "lifecyclestartdate" "", "listprice" 0, "locationid" "", "name" "", "orderproductid" "", "originalassetid" "", "parentassetobject" "", "parentid" "", "price" 0, "pricebookentryid" "", "pricebookid" "", "productcode" "", "productdescription" "", "productfamily" "", "productid" "", "purchasedate" "", "quantity" 0, "reconfigureeffectivedate" "", "rootid" "", "salesprice" 0, "serialnumber" "", "sku" "", "startdate" "", "status" "", "statusreason" "", "taxamount" 0, "tcv" 0, "totalacv" 0, "totalamount" 0, "totalprice" 0, "totaltcv" 0, "uniqueidentifier" "", "uomid" "", "usageenddate" "" } ], "entitlements" \[ { "billingperiod" "", "billingtiming" "", "cancellationdate" "", "createdbyid" "", "createddate" "", "customerid" "", "enddate" "", "entitlementcompositeid" "", "entitlementlevel" 0, "entitlementnumber" "", "entitlementversion" 0, "id" "", "isdeleted" false, "lastmodifiedbyid" "", "lastmodifieddate" "", "lastversionedentitlementid" "", "lifecycleenddate" "", "lifecyclestartdate" "", "listprice" 0, "name" "", "netsalesprice" 0, "ordernumber" "", "orderondate" "", "orderproductid" "", "originalentitlementid" "", "originalentitlementnumber" "", "parententitlementobject" "", "parentid" "", "pricebookentryid" "", "pricebookid" "", "productid" "", "productname" "", "quantity" 0, "quantitydimension" "", "reconfigureeffectivedate" "", "rootid" "", "salesprice" 0, "startdate" "", "status" "", "taxamount" 0, "tcv" 0, "termdimension" "", "totalacv" 0, "totalamount" 0, "totalprice" 0, "totaltcv" 0, "uomid" "" } ], "invoices" \[ { "invoice" { "activatedbyid" "", "salesaccountid" "", "enddate" "", "duedate" "", "source" "", "taxstatus" "", "shippingandhandling" 0, "balance" 0, "vatmessages" "", "id" "", "billtocontactid" "", "einvoicingmandateid" "", "createdbyid" "", "einvoicingdocstatus" "", "appliedbyobject" "", "targetdate" "", "name" "", "externaltaxid" "", "currencyisocode" "", "taxamount" 0, "iscatchup" false, "startdate" "", "status" "", "synctime" "", "ponumbers" "", "customfields" "", "podates" "", "taxerrormessage" "", "appliedbyid" "", "lastmodifiedbyid" "", "customerid" "", "paymentdetails" "", "einvoicingmessage" "", "paymentstatus" "", "cancellationdate" "", "amountwithouttax" 0, "amount" 0, "comments" "", "lastmodifieddate" "", "recordtype" "", "entityid" "", "einvoicingmandatecode" "", "invoicedate" "", "accountingstatus" "", "paymenthostedurl" "", "invoicepdf" "", "createddate" "", "activatedtime" "", "tenantid" "", "externalinvoiceid" "", "einvoicingdocid" "" }, "items" \[ { "transactionquantity" 0, "salesaccountid" "", "enddate" "", "customfields" "", "description" "", "productname" "", "shippingandhandling" 0, "transactionamountwithouttax" 0, "assetnumber" "", "balance" 0, "lastmodifiedbyid" "", "appliedbyitemid" "", "transactionamount" 0, "invoicenumber" "", "taxpercent" 0, "id" "", "createdbyid" "", "appliedbyobject" "", "productid" "", "lastmodifieddate" "", "recordtype" "", "billingtiming" "", "entityid" "", "uomid" "", "transactiondate" "", "assettype" "", "appliedcredits" 0, "accountid" "", "createddate" "", "tenantid" "", "name" "", "invoiceid" "", "currencyisocode" "", "taxamount" 0, "iscatchup" false, "startdate" "", "ratedcredits" 0 } ] } ], "order" { "activatedbyid" "", "activateddate" "", "billingaccountid" "", "billingaddress" "", "billingperiod" "", "cancelonpaymentfail" false, "createdbyid" "", "customerid" "", "discount" 0, "discountamount" 0, "id" "", "isshippingaddresssameasbilling" false, "lastmodifiedbyid" "", "lastmodifieddate" "", "listtotal" 0, "orderacv" 0, "ordernumber" "", "orderplaceddate" "", "orderstartdate" "", "ordertcv" 0, "ownerid" "", "platformorigin" "", "podate" "", "ponumber" "", "pricebookid" "", "status" "", "subscriptionenddate" "", "subscriptionstartdate" "", "subscriptionterm" 0, "subtotal" 0, "systemdiscount" 0, "systemdiscountamount" 0, "totalamount" 0, "totalprice" 0 }, "orderproducts" \[ { "accountid" "", "actualquantity" 0, "actualsubscriptionterm" 0, "autorenew" false, "billingaccountid" "", "billingperiod" "", "billingtiming" "", "carveseligible" false, "createdbyid" "", "deltaacv" 0, "deltaarr" 0, "deltacmrr" 0, "deltatcv" 0, "discount" 0, "discountamount" 0, "evergreen" false, "id" "", "lastmodifiedbyid" "", "lastmodifieddate" "", "linetype" "", "listprice" 0, "listtotalprice" 0, "name" "", "netsalesprice" 0, "orderid" "", "parentorderproductid" "", "podate" "", "ponumber" "", "pricebookentryid" "", "productid" "", "productname" "", "quantity" 0, "rootorderproductid" "", "sku" "", "sortorder" 0, "status" "", "subscriptionenddate" "", "subscriptionstartdate" "", "subscriptionterm" 0, "subtotal" 0, "systemdiscount" 0, "systemdiscountamount" 0, "tax" 0, "totalamount" 0, "totalprice" 0, "uomid" "" } ], "subscriptions" \[ { "actualsubscriptionterm" 0, "autorenew" false, "billingperiod" "", "billingtiming" "", "createdbyid" "", "customerid" "", "evergreen" false, "id" "", "lastmodifiedbyid" "", "listprice" 0, "name" "", "orderondate" "", "orderproductid" "", "parentid" "", "parentobjecttype" "", "pricebookentryid" "", "pricebookid" "", "productid" "", "quantity" 0, "renewalterm" 0, "rootid" "", "salesprice" 0, "status" "", "subscriptioncompositeid" "", "subscriptionenddate" "", "subscriptionlevel" 0, "subscriptionstartdate" "", "subscriptionterm" 0, "subscriptionversion" 0, "taxamount" 0, "tcv" 0, "totalacv" 0, "totalamount" 0, "totalprice" 0, "totaltcv" 0, "uomid" "" } ], "transactionhub" { "transactiontype" "", "externalid" "", "externalsystem" "" } }, "warnings" \[ "" ] }