diff options
author | Ben Bodenmiller <bbodenmiller@hotmail.com> | 2019-08-31 10:21:29 +0000 |
---|---|---|
committer | Ben Bodenmiller <bbodenmiller@hotmail.com> | 2019-08-31 10:21:29 +0000 |
commit | 8898ea87bae5b171ec2d22772e3b0d10a2f73975 (patch) | |
tree | d66514b646191d79f95346886be9481ec0cb2d64 /doc/api/README.md | |
parent | cc70c6a54aa64425dfa8a3896625b308a83536c3 (diff) | |
parent | 195ac30514e98b0f97bd191183124f06d1d221fc (diff) | |
download | gitlab-ce-patch-73-move-storage-shards.tar.gz |
Merge branch 'master' into 'patch-73-move-storage-shards'patch-73-move-storage-shards
# Conflicts:
# app/models/project.rb
# spec/models/project_spec.rb
Diffstat (limited to 'doc/api/README.md')
-rw-r--r-- | doc/api/README.md | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/doc/api/README.md b/doc/api/README.md index b7ee710b87a..036b46da6e5 100644 --- a/doc/api/README.md +++ b/doc/api/README.md @@ -77,11 +77,12 @@ authentication is not provided. For those cases where it is not required, this will be mentioned in the documentation for each individual endpoint. For example, the [`/projects/:id` endpoint](projects.md). -There are three ways to authenticate with the GitLab API: +There are four ways to authenticate with the GitLab API: 1. [OAuth2 tokens](#oauth2-tokens) 1. [Personal access tokens](#personal-access-tokens) 1. [Session cookie](#session-cookie) +1. [GitLab CI job token](#gitlab-ci-job-token-premium) **(PREMIUM)** For admins who want to authenticate with the API as a specific user, or who want to build applications or scripts that do so, two options are available: @@ -151,6 +152,14 @@ The primary user of this authentication method is the web frontend of GitLab its which can use the API as the authenticated user to get a list of their projects, for example, without needing to explicitly pass an access token. +### GitLab CI job token **(PREMIUM)** + +With a few API endpoints you can use a [GitLab CI job token](../user/project/new_ci_build_permissions_model.md#job-token) +to authenticate with the API: + +- [Get job artifacts](jobs.md#get-job-artifacts) +- [Pipeline triggers](pipeline_triggers.md) + ### Impersonation tokens > [Introduced][ce-9099] in GitLab 9.0. Needs admin permissions. @@ -387,7 +396,7 @@ GET /api/v4/projects/diaspora%2Fdiaspora NOTE: **Note:** A project's **path** is not necessarily the same as its **name**. A -project's path can found in the project's URL or in the project's settings +project's path can be found in the project's URL or in the project's settings under **General > Advanced > Change path**. ## Branches and tags name encoding @@ -413,7 +422,7 @@ We can call the API with `array` and `hash` types parameters as shown below: curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" \ -d "import_sources[]=github" \ -d "import_sources[]=bitbucket" \ -"https://gitlab.example.com/api/v4/some_endpoint +https://gitlab.example.com/api/v4/some_endpoint ``` ### `hash` |