REST API Explorer: I have to give the POST method url for submiting the catalog item request form
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago - last edited 2 hours ago
Hi Team,
I have a requirement to give the POST HTTP link for submitting the catalog item request form,
I have tried using:
Namespace: sn_sc
API Name: Service Catalog API
Buy Item (POST)
sys_id: (Given sys_id of catalog item)
In Raw Data:
{
"sysparm_quantity": "1",
"requested_by": "sys_id of user",
"requested_for": "sys_id of user",
"discription": "API test",
"assignment_group": "sys_id of group"
}
}
After including the mandate variables value as it throwing an error messge:
Mandatory Variables are required
POST HTTP:
POST https://dev.service-now.com/api/sn_sc/servicecatalog/items/catalog_item_sys_id/order_now
400 Bad Request
Response Body
{
"error": {
"message": "Mandatory Variables are required",
"detail": ""
},
"status": "failure"
}
It would be helpful, if any suggestion provided to send the correct variable format.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
share the variables associated to that catalog item?
are you sure mandatory variables are set via JSON?
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Hi @Ankur Bawiskar ,
Yes, I have mentioned all the mandatory variables in Raw Data and the variable values are also correctly mentioned even though it's says:
Mandatory Variables are required
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
you didn't share screenshots of those variables.
are those mandatory at variable config level or some client script or UI policy is making those mandatory?
The OOTB API should only check mandatory variables at config level.
Check if some customization is added to that.
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
