Looking for updating Context Values using API just like an Action - Set Context Value.
Hello, so unfortunately this is not a documented API call. Reference the Swagger doc that is available on all instances for the official API. Saying that, you can use developer tools on your browser to determine what API endpoint is being called and more importantly what the payload is. I did this with a manual action that adds a new context value.Basically I opened dev tools when making the manual action.
Set Context value - this should overwrite/update the existing value. Is that what you're after?
Hello, so unfortunately this is not a documented API call. Reference the Swagger doc that is available on all instances for the official API. Saying that, you can use developer tools on your browser to determine what API endpoint is being called and more importantly what the payload is. I did this with a manual action that adds a new context value.Basically I opened dev tools when making the manual action.
@ipninichuck Thanks for this insight. Could you please help me better understand the payload structure? I’m seeing a lot of information, and I'm a bit confused about how to format the POST method correctly. Any guidance would be greatly appreciated.
Set Context value - this should overwrite/update the existing value. Is that what you're after?
@SoarAndy Yes, but by using API. So I can use HTML Widget to modify ContextValues on the fly.
Hello skadav,
Thanks for the follow-up on your question. I'm ooo but I'll get back to this for you once I'm back. If Andy beats me to it all the better, otherwise I'll sort the answer for you.
@ipninichuck @SoarAndy can you please help me.
Below details I am able to capture:
Request URL: https://XXXXXXXXX.siemplify-soar.com/api/external/v1/cases/ExecuteManualAction?format=camel
Payload:
{alertGroupIdentifiers: [,…], scope: "All entities", targetEntities: :], caseId: 9923,…}
actionName: "Tools_Set Context Value"
actionProvider: "Scripts"
alertGroupIdentifiers: r,…]
0: "RULE_RULE_NAME_DETECTION_MONITORINGQGp5E7Z5ngvXevbIMImaIjrXXXXZMagXXXy5CJ9CCFE=_1c2ad9df-e8b1-4df8-a956-d4640a6896d9"
caseId: 9923
isPredefinedScope: true
properties: {ScriptName: "Tools_Set Context Value",…}
IntegrationInstance: "52d7b3da-xxxx-xxxx-xxxx-a36827c3XXXX"
ScriptName: "Tools_Set Context Value"
ScriptParametersEntityFields: "{\\"Value\\":\\"Test\\",\\"Key\\":\\"InitialCaseType\\",\\"Scope\\":\\"Case\\"}"
scope: "All entities"
targetEntities: t]
@ipninichuck @SoarAndy can you please help me.
Below details I am able to capture:
Request URL: https://XXXXXXXXX.siemplify-soar.com/api/external/v1/cases/ExecuteManualAction?format=camel
Payload:
{alertGroupIdentifiers: [,…], scope: "All entities", targetEntities: :], caseId: 9923,…}
actionName: "Tools_Set Context Value"
actionProvider: "Scripts"
alertGroupIdentifiers: r,…]
0: "RULE_RULE_NAME_DETECTION_MONITORINGQGp5E7Z5ngvXevbIMImaIjrXXXXZMagXXXy5CJ9CCFE=_1c2ad9df-e8b1-4df8-a956-d4640a6896d9"
caseId: 9923
isPredefinedScope: true
properties: {ScriptName: "Tools_Set Context Value",…}
IntegrationInstance: "52d7b3da-xxxx-xxxx-xxxx-a36827c3XXXX"
ScriptName: "Tools_Set Context Value"
ScriptParametersEntityFields: "{\\"Value\\":\\"Test\\",\\"Key\\":\\"InitialCaseType\\",\\"Scope\\":\\"Case\\"}"
scope: "All entities"
targetEntities: t]
https://____.siemplify-soar.com/api/external/v1/cases/ExecuteManualAction?format=camel

LMK 🙂
https://____.siemplify-soar.com/api/external/v1/cases/ExecuteManualAction?format=camel

LMK 🙂
Hi I am having this same issue. I captured the payload in the same way but when trying to run the POST method, I get a 400 error every time. Can you show an example of this API action working within the IDE, rather than just via the manual action button? Not sure what about the payload is malformed.
Hi I am having this same issue. I captured the payload in the same way but when trying to run the POST method, I get a 400 error every time. Can you show an example of this API action working within the IDE, rather than just via the manual action button? Not sure what about the payload is malformed.
I just copied and pasted the above into my postman and it worked first time
Auth
Manual Action audit on the case wall
I then did a 'Case Comment' to prove the value of it
HTH
I just copied and pasted the above into my postman and it worked first time
Auth
Manual Action audit on the case wall
I then did a 'Case Comment' to prove the value of it
HTH
Hello @SoarAndy
Thank you. This worked for me on Postman as well.
can you please guide how I can get below highlighted value dynamically? I tried to search key in context value which can give me this value, but unable to find the same.
Thanks,
Suraj Kadav
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.