0

curl command...

> curl --header "PRIVATE-TOKEN: my-private-token"
> "https://gitlab.com/gitlab-user-name/api/v4/projects/my-project-id/releases"

response...

You are being redirected.

I am sure it is the wrong url but not sure how to correct it...

gitlab docs example bellow..

> curl --header "PRIVATE-TOKEN: gDybLx3yrUK_HLp3qPjS"
> "https://gitlab.example.com/api/v4/projects/24/releases"

gitlab doc for this...

https://docs.gitlab.com/ce/api/releases/index.html#list-releases

user3755946
  • 804
  • 1
  • 10
  • 22

1 Answers1

0

The “you’re being redirected” message means it’s an authentication/authorization issue, not a problem with the uri or project.

Double check your access token has the correct scopes, isn’t revoked or expired, and that the user who owns the token has access to the project.

Adam Marshall
  • 6,369
  • 1
  • 29
  • 45