As noted in https://github.com/openfga/java-sdk/issues/47, the OAuth2 credentials should be sent as a url-encoded form post. #281 fixed the content-type, but the request body was still being sent as JSON, which caused the request to fail. This change updates the request to be sent as a application/x-www-form-urlencode form post.
[ ] I have added documentation for new/changed functionality in this PR or in a PR to openfga.dev [Provide a link to any relevant PRs in the references section above]
[x] The correct base branch is being used, if not main
[x] I have added tests to validate that the change in functionality is working as expected
Description
As noted in https://github.com/openfga/java-sdk/issues/47, the OAuth2 credentials should be sent as a url-encoded form post. #281 fixed the content-type, but the request body was still being sent as JSON, which caused the request to fail. This change updates the request to be sent as a
application/x-www-form-urlencode
form post.References
281
Review Checklist
main