Skip to content

Feature/client access tokens #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 27, 2025
Merged

Conversation

janhenckens
Copy link
Member

Description

Reason for this change

Signed-off-by: Jan Henckens <jan@henckens.be>
Signed-off-by: Jan Henckens <jan@henckens.be>
@janhenckens janhenckens requested a review from Copilot June 27, 2025 09:01
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR replaces the JWT-based authentication mechanism with client access tokens. Key changes include updating AuthService to use clientId/clientSecret and OAuth endpoints, revising ApiService and EntryAPI constructors accordingly, and refreshing documentation and changelog to reflect the new authentication process.

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/services/entry/AuthService.php Updated constructor parameters, token refresh logic, and token persistence using the OAuth endpoint.
src/services/entry/ApiService.php Updated constructor parameters and removed the deprecated X-Api-Key header.
src/Environments.php Replaced getJWTUrl with getOAuthUrl and updated endpoint URLs accordingly.
src/EntryAPI.php Modified constructor to accept clientId and clientSecret.
README.md Updated environment variable names and removed outdated JWT token instructions.
CHANGELOG.md Documented the switch from JWT authentication to client access tokens.
Comments suppressed due to low confidence (1)

src/services/entry/AuthService.php:95

  • The updateAccessToken() method now writes the raw response body to the storage file. Ensure that the body format (e.g., a JSON with an 'access_token' key) is consistently maintained so that getAccessToken() can parse it correctly.
                    $body

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@janhenckens janhenckens merged commit 53262cd into develop Jun 27, 2025
@janhenckens janhenckens deleted the feature/client-access-tokens branch June 27, 2025 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant