Deploy Artifact by Checksum

JFrog REST APIs

Content Type
REST API
ft:sourceType
Paligo

Description: Deploy an artifact to the specified destination by checking if the artifact content already exists in Artifactory.

If Artifactory already contains a user-readable artifact with the same checksum the artifact content is copied over to the new location and returns a response without requiring content transfer.

Otherwise, a 404 error is returned to indicate that content upload is expected in order to deploy the artifact.

If the X-Checksum-Deploy header is set to false, the artifact will be uploaded successfully with a 201 response, even if it didn't exist before, and submitted checksums will have status Uploaded: Identical.

Notes: You can also Attach Properties as part of deploying artifacts.Using Properties in Deployment and Resolution

Security: Requires a user with 'deploy' permissions (can be anonymous)

Usage: PUT /repo-key/path/to/artifact.ext

Headers: X-Checksum-Deploy: true, X-Checksum-Sha1: sha1Value, X-Checksum-Sha256: sha256Value, X-Checksum: checksum value (type is resolved by length)

Produces: application/json (application/vnd.org.jfrog.artifactory.storage.ItemCreated+json)

Since: 2.5.1

Sample Output:

PUT /libs-release-local/my/jar/1.0/jar-1.0.jar
{
"uri": "http://localhost:8081/artifactory/libs-release-local/my/jar/1.0/jar-1.0.jar",
"downloadUri": "http://localhost:8081/artifactory/libs-release-local/my/jar/1.0/jar-1.0.jar",
"repo": "libs-release-local",
"path": "/my/jar/1.0/jar-1.0.jar",
"created": ISO8601 (yyyy-MM-dd'T'HH:mm:ss.SSSZ),
"createdBy": "userY",
"size": "1024", //bytes
"mimeType": "application/java-archive",
"checksums":
{
        "md5" : string,
        "sha1" : string
    },
"originalChecksums":{
        "md5" : string,
        "sha1" : string
    }
}