pc70
pc70

Reputation: 701

JFrog Artifactory REST API access using X-JFrog-Art-Api

We are using JFrog artifactory 4.1.0. From their docs (https://www.jfrog.com/confluence/display/RTF/Artifactory+REST+API), we can either use basic authentication or specify X-JFrog-Art-Api header using API key.

Tried the following call

curl -X GET -H "X-JFrog-Art-Api:<my-key>" https:/<host>/artifactory/api/build

I am getting a message saying authentication is required (shown below). How can i access REST API calls using token alone? Is there anything else i need to do?

{
  "errors" : [ {
    "status" : 401,
    "message" : "Authentication is required"
  } ]
}

Upvotes: 1

Views: 4992

Answers (1)

Dror Bereznitsky
Dror Bereznitsky

Reputation: 20376

The use of "X-JFrog-Art-Api" for authentication is supported since version 4.4.3. It will not work with older versions.

Upvotes: 2

Related Questions