The https://gitlab.example.com/api/v4/ is API address of your GitLab instance (if you are using GitLab.com, choose https://gitlab.com/api/v4/ instead) , and /api/v4/ is a prefix and should be used for all scenarios!
GitLab API provides so many resources, see: GitLab API
Some examples:
You need to get your project's releases (Projects API):
curl --header "PRIVATE-TOKEN`:` ${YOUR_TOKEN}" http://gitlab.example.com/api/v4/projects/${PROJECT_ID}/releases/
You want to create a new Issue (Issue API):
curl --header 'Content-Type:application/json' --header "PRIVATE-TOKEN`:` ${YOUR_TOKEN}" --request POST "http://gitlab.example.com/api/v4/projects/${PROJECT_ID}/issues?title=${ISSUE_TITLE}&labels=${LABELS}&description=${ISSUE_DESCRIPTION}"
Answer from MrRolling on Stack OverflowThe https://gitlab.example.com/api/v4/ is API address of your GitLab instance (if you are using GitLab.com, choose https://gitlab.com/api/v4/ instead) , and /api/v4/ is a prefix and should be used for all scenarios!
GitLab API provides so many resources, see: GitLab API
Some examples:
You need to get your project's releases (Projects API):
curl --header "PRIVATE-TOKEN`:` ${YOUR_TOKEN}" http://gitlab.example.com/api/v4/projects/${PROJECT_ID}/releases/
You want to create a new Issue (Issue API):
curl --header 'Content-Type:application/json' --header "PRIVATE-TOKEN`:` ${YOUR_TOKEN}" --request POST "http://gitlab.example.com/api/v4/projects/${PROJECT_ID}/issues?title=${ISSUE_TITLE}&labels=${LABELS}&description=${ISSUE_DESCRIPTION}"
Be careful about access tokens. You have to create a personal access token, not a deploy token.
How to create access token