on 2024 Aug 19 6:11 PM
I'm trying to use the HttpRequest to run an Incentive Management Pipeline using POST request. The command uses the clientId, clientSecret, body with the parameters needed, and the tokenUrl.
I can run the request in Postman successfully but in Automation Pilot, I'm getting a 500 (Internal Server Error) response.
When I run a GET request, such as searching for a specific period, it completes successfully. Not with the POST request.
How can I figure out what's causing this error so that I can fix it? Any and all suggestions are welcome. 😊
These APIs are in GCP.
Thanks in advance!
Ron
Request clarification before answering.
Hello Ron,
Sorry for experiencing such an issue. What I was able to find is that the authentication request succeeds, but the main request returns 500.
Since we do not have very helpful logs for the main request, I am looking at the REST API documentation and you can try the following:
- If not already, double check the headers in the request - if the 'Content-Type': 'application/json' or 'Accept': 'application/json' or both headers should be used (or any other).
- Try setting the timeout of the http request from the default 3 seconds to 10 seconds.
- Since it is a POST request, the body parameter could be problematic. Try to escape special characters if there are any (using dynamic expressions like toEscapedJson/toUrlEncoded/toPercentEncoded)
I hope these suggestions prove useful
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 6 | |
| 6 | |
| 6 | |
| 5 | |
| 4 | |
| 3 | |
| 3 | |
| 3 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.