-
Notifications
You must be signed in to change notification settings - Fork 549
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feature: oauth update client api (#1020)
* fix/change annotations for configs * feat: oauth2 auth API - WIP * fix: hidefromdashboard to oauth_provider service url configs * feat: OAuthAPI input parsing, basic flow * feat: first test in progress * fix: review fixes * feat: tables for oauth in sqlite * fix: remove unnecessary tables * fix: store only the necessary data in the client table * feat: oauth client - app exists check in db, a few tests * fix: review fixes * fix: review fixes * feat: new configs for handling errors from hydra * feat: using the new configs for oauth provider * fix: CHANGELOG * fix: tests for the new Util method * fix: changelog changes * fix: changelog migration section fix * fix: fixing repeated header handling in HttpRequest#sendGETRequestWithResponseHeaders * fix: more tests for oauth auth * fix: review fix - more checks for the oauth config validity * fix: review fix - throwing expection if there is no location header in response from hydra * fix: review fix - renamed exception * feat: oauth2 register client API * feat: oauth2 get clients API * feat: OAuth2 DELETE clients API * fix: following the already existing response pattern with the oauth2 apis * fix: renaming exception to be more expressive * fix: review fixes * feat: oauth2 client update support * fix: using BadRequestException instead of custom format for hydra invalid input errors * fix: renaming method * fix: remove unused constant * fix: returning 500 when oauth update client goes wrong * fix: fixing test after changing error response * chore: removing TODO from code
- Loading branch information
1 parent
7e98ed2
commit aee7e88
Showing
11 changed files
with
445 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
src/main/java/io/supertokens/oauth/exceptions/OAuthClientUpdateException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* Copyright (c) 2024, VRAI Labs and/or its affiliates. All rights reserved. | ||
* | ||
* This software is licensed under the Apache License, Version 2.0 (the | ||
* "License") as published by the Apache Software Foundation. | ||
* | ||
* You may not use this file except in compliance with the License. You may | ||
* obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT | ||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the | ||
* License for the specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
|
||
package io.supertokens.oauth.exceptions; | ||
|
||
import java.io.Serial; | ||
|
||
public class OAuthClientUpdateException extends OAuthException{ | ||
@Serial | ||
private static final long serialVersionUID = -5191044905397936167L; | ||
|
||
public OAuthClientUpdateException(String error, String errorDescription) { | ||
super(error, errorDescription); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.