Skip to content

Commit eb8c017

Browse files
adjust commentary
1 parent bc47a48 commit eb8c017

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/main/java/org/gitlab4j/api/PersonalAccessTokenApi.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public PersonalAccessToken rotatePersonalAccessToken() throws GitLabApiException
3434

3535
/**
3636
* Rotates the given personal access token.
37-
* The token is revoked and a new one which will expire in one week is created to replace it.
37+
* The token is revoked and a new one which will expire at the given expiresAt-date is created to replace it.
3838
* Only working with GitLab 16.0 and above.
3939
*
4040
* <pre><code>GitLab Endpoint: POST /personal_access_tokens/self/rotate</code></pre>
@@ -48,12 +48,13 @@ public PersonalAccessToken rotatePersonalAccessToken(Date expiresAt) throws GitL
4848
}
4949

5050
/**
51-
* Rotates the given personal access token.
52-
* The token is revoked and a new one which will expire in one week is created to replace it.
51+
* Rotates a specific personal access token.
52+
* The token is revoked and a new one which will expire at the given expiresAt-date is created to replace it.
5353
* Only working with GitLab 16.0 and above.
5454
*
55-
* <pre><code>GitLab Endpoint: POST /personal_access_tokens/:id/rotate</code></pre>
55+
* <pre><code>GitLab Endpoint: POST /personal_access_tokens/:id</code></pre>
5656
*
57+
* @param id ID of the personal access token
5758
* @param expiresAt Expiration date of the access token
5859
* @return the newly created PersonalAccessToken.
5960
* @throws GitLabApiException if any exception occurs

0 commit comments

Comments
 (0)