API Reference
Products
Create an issuing schedule
1min
code examples curl location globoff request post 'https //api fictive com/rest/api/products/{productreference}/schedules' \\ \ header 'accept application/json' \\ \ header 'content type application/json'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var requestoptions = { method 'post', headers myheaders, redirect 'follow' }; fetch("https //api fictive com/rest/api/products/{productreference}/schedules", 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 fictive com/rest/api/products/{productreference}/schedules") 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" response = https request(request) puts response read body import requests import json url = "https //api fictive com/rest/api/products/{productreference}/schedules" payload = {} headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses { "schedulereference" "001ca72ibxwwav51m2", "entitlementformat" "entitlementformat1", "friendlyname" "example name 1", "scheduletype" "daily", "dailyschedule" { "issuingtime" "05 33", "monday" true, "tuesday" true, "wednesday" true, "thursday" true, "friday" true, "saturday" false, "sunday" false }, "nonissuingdates" \[ "2021 09 21", "2021 11 21" ], "issuepriortostart" false, "entitlementends" { "endsnever" false, "endsaftertimeunit" "days", "endsafternumberoftimeunits" 2 } }// an entitlement format must be provided \<br /> an entitlement format cannot exceed 850 characters \<br /> a friendly name is required to identify the purpose of the entitlement \<br /> a friendly name cannot exceed 256 characters \<br /> invalid schedule frequency provided please provide one of the following values none, daily, monthly, annual, irregular or custom \<br /> issuing day cannot exceed 31 \<br /> issuing day must be 1 or more \<br /> issuing time must be between 00 00 23 59 and specified as hours and minutes only \<br /> invalid month provided please provide the full string value e g january \<br /> invalid issuingunit provided please provide a value between 1 999 \<br /> invalid frequency provided please provide daily, weekly, monthly or annual \<br /> invalid date format non issuing dates \<br /> the date provided is invalid \<br /> invalid start date provided \<br /> invalid dates provided, please provide a date in the future // not authorized // product cannot be found // a single product can only have 1 physical schedule configured \<br /> a schedule exists with the provided entitlement format an entitlement format must be unique on a product \<br /> a schedule exists with the provided friendly name a friendly name must be unique on a product // to configure an issuing schedule, your product must be of type physical or digital \<br /> a schedule type of daily is required to allow the passing of a daily schedule \<br /> a schedule type of monthly is required to allow the passing of a monthly schedule \<br /> a schedule type of annual is required to allow the passing of an annual schedule \<br /> a schedule type of custom is required to allow the passing of an custom schedule \<br /> a schedule type of custom is required to allow the passing of a custom dates \<br /> a schedule type of irregular is required to allow the passing of a irregular dates \<br /> entitlement format is not supported for physical products // internal server error
π€
Have a question?
Our super-smart AI,knowledgeable support team and an awesome community will get you an answer in a flash.
To ask a question or participate in discussions, you'll need to authenticate first.