Adding parameters in URL

JPSS
Tera Contributor

When a user is clicking a url from external application then it should redirect to a catalog item in servicenow with short description 'SAP'

 

 

I tried passing paramenters as below but its not working .

 

Can anyone helo me please

https://{INSTANCE NAME}.service-now.com/sp?id=sc_cat_item&sys_id=482c8a621bdb0510ccbb6202b24bcb2a&sysparm_variables="short_description":"SAP"

9 REPLIES 9

Z_Lawrence
Tera Expert

Hi JPSS,

You can use the following URL structure to redirect a user to a specific catalog item in ServiceNow when they click on a link from an external application:

https://{INSTANCE NAME}.service-now.com/sp?id=sc_cat_item&sysparm_query=short_description=SAP


This URL will redirect the user to the ServiceNow Service Catalog page, and will automatically filter the catalog items to show only those with the short description "SAP".


You can also use the following URL structure to redirect a user to the specific item https://{INSTANCE NAME}.service-now.com/sp?id=sc_cat_item&sys_id=482c8a621bdb0510ccbb6202b24bcb2a&sysparm_variables="short_description":"SAP"


This URL will redirect the user to the specific catalog item with the sys_id=482c8a621bdb0510ccbb6202b24bcb2a and will also filter the catalog items to show only those with the short description "SAP".


You can also use the following URL structure to redirect a user to the specific item https://{INSTANCE NAME}.service-now.com/sc_cat_item.do?sys_id=482c8a621bdb0510ccbb6202b24bcb2a

This URL will redirect the user to the specific catalog item with the sys_id=482c8a621bdb0510ccbb6202b24bcb2a without filtering.


Make sure to replace {INSTANCE NAME} with your specific ServiceNow instance name.


Please also note that the sys_id provided in the URL should be the valid sys_id of the catalog item in your instance, otherwise the user will get an error page.



Please mark my answer as helpful and correct, if it really helps you.
Regards,

Zoltan

JPSS
Tera Contributor

Hi Lawrance

 

https://xxx.service-now.com/sp?id=sc_cat_item&sys_id=482c8a621bdb0510ccbb6202b24bcb2a&sysparm_variab...

 

 

 

 

i tried using the below url.. its redirecting to the catalog item page. But short description is not automatically mapped

 

 

Hi there,

You can modify the URL as following:

https://{INSTANCE NAME}.service-now.com/sp?id=sc_cat_item&sys_id=482c8a621bdb0510ccbb6202b24bcb2a&sysparm_query=short_description=SAP

This URL will redirect the user to the specific catalog item with the sys_id=482c8a621bdb0510ccbb6202b24bcb2a and also filter the catalog items to show only those with the short description "SAP".

Alternatively, you can use JavaScript or client script to filter the catalog items by short description after the page is loaded.

Regards,

Zoltán

JPSS
Tera Contributor

.