Open
Enhancement
1 of 3 issues completed
Description
Description
For clients using OAuth2 credentials, the token endpoint is currently hardcoded in all SDKs (with /oauth/token
value).
Could it be possible to make it configurable? Or even better support oidc discovery?
I'm willing to contribute if that's something you would be interested in :)
Steps to take
Change the apiTokenIssuer
field in the configuration to accept a full URL.
So:
ApiTokenIssuer |
Endpoint SDK will hit |
---|---|
issuer.fga.example |
https://issuer.fga.example/oauth/token |
https://issuer.fga.example |
https://issuer.fga.example/oauth/token |
https://issuer.fga.example:8080 |
https://issuer.fga.example:8080/oauth/token |
issuer.fga.example/some_endpoint |
https://issuer.fga.example/some_endpoint |
https://issuer.fga.example/some_endpoint |
https://issuer.fga.example/some_endpoint |
https://issuer.fga.example:8080/some_endpoint |
https://issuer.fga.example:8080/some_endpoint |
Of course, we'll need to do some of the validations to ensure e.g. users are passing fields with https
or http
(and not e.g. ftp) and that the full url is valid
Related Issues
- .NET SDK issue: PathTemplate auth/token hardcoded in OAuth2Client ExchangeTokenAsync method dotnet-sdk#30
- (duplicate) SDKs should get the token exchange endpoint from the issuer's configuration #197
SDKs to be updated
- .NET SDK
Sub-issues
Sub-issues
- Manage this item control shift u
- Manage this item control shift u
- Manage this item control shift u
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Ready
Milestone
Relationships
Development
No branches or pull requests
Activity
le-yams commentedon Nov 30, 2023
I opened the PR #240 for the Java SDK. I have prepared all other SDKs (go, js, dotnet and python) but I'll wait your review on this one before submitting them 😃.
16 remaining items