How can I can use the Sonatype REST Api to fetch the build with the highest version (latest temporal build)?
http://MY_REPOSITORY/nexus/service/local/lucene/search?a=ARTIFACT_NAME&v=ARTIFACT_VERSION
Passing a build version as ARTIFACT_VERSION works. Passing v=LATEST or v=latest does NOT return the latest build.
It is not documented that /service/local/lucene/search support “LATEST” as version parameter [link]
The OSS rest api documentation states that
/service/local/artifact/maven[link] (to get the artifact pom file) and/service/local/artifact/maven/content[link] (to get the actual file content) does support it:So I think you should use one of them (you will have to supply them also with repositoryId and groupId)
for example: