r/aws_bedrockagentcore_oauth2_credential_provider: add token_endpoint_auth_methods#2
Open
aidandaly24 wants to merge 3 commits into
Conversation
…_auth_methods Oauth2AuthorizationServerMetadata has a tokenEndpointAuthMethods member (TokenEndpointAuthMethodsType: list of 1-2 TokenAuthMethod strings, client_secret_post / client_secret_basic) that was the last unmodeled Create-input field on the custom provider's authorization_server_metadata block. Add it as a Set attribute (mirroring response_types), with SizeBetween(1,2) and a per-element regex validator mirroring the SDK pattern. The value round-trips via GetOauth2CredentialProvider and is auto-wired through AutoFlex (matching Go field name). Verified: authorizationServerMetadata acceptance test passes against real AWS with both methods set and import-verified; an invalid method is rejected offline by `terraform validate`.
Community GuidelinesThis comment is added to every new Pull Request to provide quick reference to how the Terraform AWS Provider is maintained. Please review the information below, and thank you for contributing to the community that keeps the provider thriving! 🚀 Voting for Prioritization
Pull Request Authors
|
…of token_endpoint_auth_methods Extend the authorizationServerMetadata acceptance test with an update step (two methods -> one, ExpectResourceAction Update) and a clear step (set->unset, ExpectResourceAction Update, count 0) so the mutate and clearing transitions of token_endpoint_auth_methods have a durable regression guard rather than only create+import coverage. Parameterize the config helper for the methods value and add a no-methods variant for the clear step. All 4 steps pass against real AWS (create 2 -> update to 1 -> clear -> import); no perpetual diff or inconsistent-result on the clearing step.
…D032 in provider-config list The included-provider `-> **Note:**` callout was placed between the `included_oauth2_provider_config` and `linkedin_oauth2_provider_config` bullets, splitting the provider-config list so the resumed items were not preceded by a blank line (markdownlint MD032/blanks-around-lists). Keep the list contiguous and move the note to immediately after it.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds
token_endpoint_auth_methodsto the custom provider'sauthorization_server_metadatablock. This isOauth2AuthorizationServerMetadata.tokenEndpointAuthMethodsin the SDK (TokenEndpointAuthMethodsType: a list of 1–2TokenAuthMethodstrings,client_secret_post/client_secret_basic) — the last unmodeled Create-input field on this branch. With it, the resource reaches fullCreateOauth2CredentialProviderinput parity against the pinned SDK (v1.45.2).Modeled as a
Set(consistent with the siblingresponse_types),Optional, withSizeBetween(1, 2)and a per-element regex validator mirroring the SDK'sTokenAuthMethodpattern. The value round-trips viaGetOauth2CredentialProviderand is auto-wired through AutoFlex (matching Go field name), so no hand-rolled Expand/Flatten was needed.Targeting this branch (rather than a standalone PR against
main) so it folds into hashicorp#48517.Relations
Relates hashicorp#48517
Output from Acceptance Testing
Also verified offline: an invalid method (
not_a_valid_method) is rejected atterraform validate—value must match regular expression '^(client_secret_post|client_secret_basic)$'.