The REST call is:
GET http://server/restServices/archivaServices/browseService/artifactDownloadInfos/{group}/{artifact}/{version}
The response contains a list of entries whose 'url' key is the link to download the artifact. There's an entry for each downloadable resource, e.g. one for jar, another for pom, etc. The 'type' key can be used to tell which.
Example response:
[
{
"context": "internal",
"url": "http://server/repository/internal/group/artifact/version/artifact-version.jar",
"groupId": "group",
"artifactId": "obs.interfaces",
"repositoryId": "internal",
"version": "version",
"prefix": null,
"goals": null,
"bundleVersion": null,
"bundleSymbolicName": null,
"bundleExportPackage": null,
"bundleExportService": null,
"bundleDescription": null,
"bundleName": null,
"bundleLicense": null,
"bundleDocUrl": null,
"bundleImportPackage": null,
"bundleRequireBundle": null,
"classifier": null,
"packaging": "jar",
"fileExtension": "jar",
"size": "31.78 K",
"type": "jar",
"path": "group/artifact/version/artifact-version.jar",
"id": "artifact-version.jar",
"scope": null
},
{
"context": "internal",
"url": "http://server/repository/internal/group/artifact/version/artifact-version.pom",
"groupId": "group",
"artifactId": "artifact",
"repositoryId": "internal",
"version": "version",
"prefix": null,
"goals": null,
"bundleVersion": null,
"bundleSymbolicName": null,
"bundleExportPackage": null,
"bundleExportService": null,
"bundleDescription": null,
"bundleName": null,
"bundleLicense": null,
"bundleDocUrl": null,
"bundleImportPackage": null,
"bundleRequireBundle": null,
"classifier": null,
"packaging": "pom",
"fileExtension": "pom",
"size": "1.58 K",
"type": "pom",
"path": "group/artifact/version/artifact-version.pom",
"id": "artifact-version.pom",
"scope": null
}
]
Enjoy!