REST API Issue for service-now catalog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2017 10:56 AM
Hi I am planning to use REST API for service catalog in C# and facing below issue while testing. Please help me to fix this issue -
To test I navigated to "REST API Explorer" in service now. While testing Add Item To Cart (POST) call fails. Please refer attached screen short.
Error -
{
"error": {
"detail": "",
"message": "Invalid Quantity value"
},
"status": "failure"
}
Please help me what the issue is?
- Labels:
-
Integrations
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2017 08:24 AM
Did you ever get this error resolved? I'm having the same issue. Adding a catalog item to the cart with the API getting the same error. When I set the sysparm_quantity value to 1 I get the same error.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2017 08:48 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2017 09:33 AM
Hi Eric,
--request POST \
--header "Accept:application/json" \
--header "Content-Type:application/json" \
--data "{\"sysparm_quantity\":\"1\"}" \
--user 'admin':'admin'
gave this response:
{
"result": {
"cart_id": "ad08fe9413b04b00125ad8228144b0bc",
"subtotal": "$1,100.00",
"items": [
{
"catalog_item_id": "04b7e94b4f7b4200086eeed18110c7fd",
"quantity": "1",
"localized_price": "$1,100.00",
"price": "$1,100.00",
"recurring_frequency": "Annually",
"localized_recurring_price": "$100.00",
"recurring_price": "$100.00",
"item_name": "Standard Laptop",
"cart_item_id": "40838c6713894300125ad8228144b0e0"
}
]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2017 09:35 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-14-2017 10:22 AM
Using the REST API Explorer withing ServiceNow I was able to get the sysparm_quantity variable to be passed, but now it's giving me another error:
Mandatory Variables are required
I looked at the catalog item. When I go to that catalog item's form and right-click and select Configure variables, there is only one variable listed: service_offering.