REST API - Finding asset by asset ID fails


We have set up a webhook from our Nexus Repository Manager that calls another system every time a new asset is added to nexus, we would like to download the asset using the information contained in the webhook request.

A sample webhook request might look like this:


I am able to find the download link of the asset using the GAV in the following query:

However, when I try to find the same asset using the asset id, generated by base 64 encoding this string:
which results in this string:

And then querying using this url:

I get the following response:
ERROR: (ID 2fa0ae24-7dd0-4b06-beda-12e11187d3af) java.lang.IllegalStateException: Timed out reading query result from queue 67b11e2 after 60 seconds

I do not have access to the corresponding server log at this time, but that can be acquired if needed.

So my question is this: Does anyone here have any clue what may be the issue here, and if yes, any tips to resolve this problem?


The request timed out. Which doesn’t tell us a whole lot, other than that the either the query is running slowly, or the request isn’t reaching Nexus Repo at all. Is the system it is running on meeting our requirements?

Hi Andres,
Before going into the API details, if you’re simply trying to download the file, you should be able to construct the download URL directly from the webhook response; it contains the repository name and file name. Append those together along with your instance base url and you should be all set.

I am able to do this lookup successfully. So, a couple things come to mind. First, 3.13 moved the API to /v1/. So, your integrations will need to update their url when you upgrade. Second, this could be a bug in the older version. Third, this may be a copy/paste or forum issue, but there should be an equals sign (=) at the end of your encoded string. Even so, I get a HTTP 422 response code with an invalid encoded string, not a timeout issue.

If you do decide to continue down this route, we’ll need the full nexus.log to determine what might be going on.

Hi, thanks for the replies.

After a little more research I discovered what @mworthington suggested, that I can download the file using the information I received in the webhook request, forming the url:

As this solves my problem, I will not be pursuing this issue any further.

Thank you for you feedback.

1 Like