I'm attempting to pass a token as a query parameter in my POST call. I am not able to get vRO to interpret my query parameter I have configured in my REST Operation call.
Note: I cannot pass the authentication token as a header, as the only allowed headers by this REST API are: Origin, X-Requested-With, Content-Type, Accept
I created the REST Operation as follows that is giving me the error: POST "https://pronghorn.internal/getNetworkStats?token={{token}}"
FYI: Pronghorn (by itential) is the REST Host I am working with.
I am hoping this is simply a syntax issue. I have yet to figure out the proper syntax to make this work however.
My REST Operation is: https:/pronghorn.internal/getNetworkStats?token="{{token}}"
My error log shows the Request URL as: https:/pronghorn.internal/getNetworkStats?token="}" with a message of "Illegal character in query at index xx.
I have attempted single brackets which errors out with a message token must be passed as a query parameter.
Here is the flow of my workflows as an FYI:
My workflow is as follows: (Using JSON with headers set appropriately)
Get Token Workflow:
- Capture username and password from input and format into json string.
- Pass credentials to REST Operation Workflow of "POST 'https://pronghorn.internal/login"
- Parse response as output attribute called 'token'
Call to Get Network Stats Workflow:
- Capture network input from user and format into json string (body).
- Pass json string (body) and token to execute REST Operation Workflow of POST "https://pronghorn.internal/getNetworkStats?token={{token}}"
- Parse response and display network stats
This attempt fails on attempting the POST.
I have logging enable to verify the steps along the way.
The Request URL shows as: https:/pronghorn.internal/getNetworkStats?token="}" with a message of "Illegal character in query at index xx.
Any help would be greatly appreciated. I've been banging my head against the wall on this for a while!
Thanks,
Jerry