Skip to content
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

feat: Docs update to use custom clients when endpoints have no auth/bearer token auth and Support for PUT method #802

Merged
merged 9 commits into from
Jun 24, 2024

Conversation

AsabuHere
Copy link
Contributor

@AsabuHere AsabuHere commented Jun 21, 2024

Fixes

A short description of what this PR does.
Docs update to use custom clients when endpoints have no auth/bearer token auth and Support for PUT method

Checklist

  • I acknowledge that all my contributions will be made under the project's license
  • I have made a material change to the repo (functionality, testing, spelling, grammar)
  • I have read the Contribution Guidelines and my PR follows them
  • I have titled the PR appropriately
  • I have updated my branch with the main branch
  • I have added tests that prove my fix is effective or that my feature works
  • I have added the necessary documentation about the functionality in the appropriate .md file
  • I have added inline documentation to the code I modified

If you have questions, please file a support ticket, or create a GitHub Issue in this repository.

@AsabuHere AsabuHere changed the title fix: Docs update to use custom clients when endpoints have no auth/bearer token auth feat: Docs update to use custom clients when endpoints have no auth/bearer token auth and Support for PUT method Jun 24, 2024
@AsabuHere AsabuHere requested a review from sbansla June 24, 2024 05:51
@@ -140,7 +140,7 @@ public <T extends IRequest> Response makeRequest(final T request) {
}
}

if (method == HttpMethod.POST) {
if (method == HttpMethod.POST || method == HttpMethod.PUT) {
Copy link
Contributor

Choose a reason for hiding this comment

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

GET does not have body all other methods can have body.
Check with Shubham before adding Delete support.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

checked with Shubham
Adding support for all methods except GET

README.md Outdated
private static final String CLIENT_SECRET = "client_secret_of_organization";

public static void main(String[] args) throws AuthenticationException {
TwilioOrgsTokenAuth.setTokenManager(new CustomTokenManagerImpl(GRANT_TYPE, CLIENT_SID, CLIENT_SECRET));
Copy link
Contributor

Choose a reason for hiding this comment

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

Add this in example and give link. Lets keep readme more readable and concise.
Also give example without custom token manager.

Copy link
Contributor

Choose a reason for hiding this comment

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

This change was added in main, check there as well.
We did not add delete because it was giving some error(I think), but now we can add delete as well.

@AsabuHere AsabuHere merged commit 6c9a757 into auth-rest-client Jun 24, 2024
6 of 7 checks passed
@AsabuHere AsabuHere deleted the orgs_api_docs_update branch June 24, 2024 06:57
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.

2 participants