An error occurs because the URI defined in the query is longer than the URI length limit set on the web serve: Request-URI Too Large - When Running a Vault API Query.
To bypass this limitation, do the following:
- Use POST instead of GET.
- Place the query in the request body (still using the "q" parameter).
GET requests are made to request a particular resource from the server. Whatever information is required to fetch the desired resource are passed as query string parameters. The GET Method must not be used for passing very long strings, containing more than 2000 characters.
POST Requests are made to post some data to a particular resource for processing and also request a response.
Send us your feedback: We are always looking for feedback to help improve our Knowledge Base! Please let us know if this article is helpful or provide feedback on how we can improve your experience by clicking here.