Skip to content
v2.278.0

OAuthParametersProperty Struct ​

Contains the OAuth authorization parameters to use for the connection.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_events as events } from 'aws-cdk-lib';
const oAuthParametersProperty: events.CfnConnection.OAuthParametersProperty = {
  authorizationEndpoint: 'authorizationEndpoint',
  clientParameters: {
    clientId: 'clientId',
    clientSecret: 'clientSecret',
  },
  httpMethod: 'httpMethod',

  // the properties below are optional
  oAuthHttpParameters: {
    bodyParameters: [{
      key: 'key',
      value: 'value',

      // the properties below are optional
      isValueSecret: false,
    }],
    headerParameters: [{
      key: 'key',
      value: 'value',

      // the properties below are optional
      isValueSecret: false,
    }],
    queryStringParameters: [{
      key: 'key',
      value: 'value',

      // the properties below are optional
      isValueSecret: false,
    }],
  },
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_events as events

o_auth_parameters_property = events.CfnConnection.OAuthParametersProperty(
    authorization_endpoint="authorizationEndpoint",
    client_parameters=events.CfnConnection.ClientParametersProperty(
        client_id="clientId",
        client_secret="clientSecret"
    ),
    http_method="httpMethod",

    # the properties below are optional
    o_auth_http_parameters=events.CfnConnection.ConnectionHttpParametersProperty(
        body_parameters=[events.CfnConnection.ParameterProperty(
            key="key",
            value="value",

            # the properties below are optional
            is_value_secret=False
        )],
        header_parameters=[events.CfnConnection.ParameterProperty(
            key="key",
            value="value",

            # the properties below are optional
            is_value_secret=False
        )],
        query_string_parameters=[events.CfnConnection.ParameterProperty(
            key="key",
            value="value",

            # the properties below are optional
            is_value_secret=False
        )]
    )
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.events.*;

OAuthParametersProperty oAuthParametersProperty = OAuthParametersProperty.builder()
        .authorizationEndpoint("authorizationEndpoint")
        .clientParameters(ClientParametersProperty.builder()
                .clientId("clientId")
                .clientSecret("clientSecret")
                .build())
        .httpMethod("httpMethod")

        // the properties below are optional
        .oAuthHttpParameters(ConnectionHttpParametersProperty.builder()
                .bodyParameters(List.of(ParameterProperty.builder()
                        .key("key")
                        .value("value")

                        // the properties below are optional
                        .isValueSecret(false)
                        .build()))
                .headerParameters(List.of(ParameterProperty.builder()
                        .key("key")
                        .value("value")

                        // the properties below are optional
                        .isValueSecret(false)
                        .build()))
                .queryStringParameters(List.of(ParameterProperty.builder()
                        .key("key")
                        .value("value")

                        // the properties below are optional
                        .isValueSecret(false)
                        .build()))
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Events;

var oAuthParametersProperty = new OAuthParametersProperty {
    AuthorizationEndpoint = "authorizationEndpoint",
    ClientParameters = new ClientParametersProperty {
        ClientId = "clientId",
        ClientSecret = "clientSecret"
    },
    HttpMethod = "httpMethod",

    // the properties below are optional
    OAuthHttpParameters = new ConnectionHttpParametersProperty {
        BodyParameters = new [] { new ParameterProperty {
            Key = "key",
            Value = "value",

            // the properties below are optional
            IsValueSecret = false
        } },
        HeaderParameters = new [] { new ParameterProperty {
            Key = "key",
            Value = "value",

            // the properties below are optional
            IsValueSecret = false
        } },
        QueryStringParameters = new [] { new ParameterProperty {
            Key = "key",
            Value = "value",

            // the properties below are optional
            IsValueSecret = false
        } }
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

oAuthParametersProperty := &OAuthParametersProperty{
	AuthorizationEndpoint: jsii.String("authorizationEndpoint"),
	ClientParameters: &ClientParametersProperty{
		ClientId: jsii.String("clientId"),
		ClientSecret: jsii.String("clientSecret"),
	},
	HttpMethod: jsii.String("httpMethod"),

	// the properties below are optional
	OAuthHttpParameters: &ConnectionHttpParametersProperty{
		BodyParameters: []interface{}{
			&ParameterProperty{
				Key: jsii.String("key"),
				Value: jsii.String("value"),

				// the properties below are optional
				IsValueSecret: jsii.Boolean(false),
			},
		},
		HeaderParameters: []interface{}{
			&ParameterProperty{
				Key: jsii.String("key"),
				Value: jsii.String("value"),

				// the properties below are optional
				IsValueSecret: jsii.Boolean(false),
			},
		},
		QueryStringParameters: []interface{}{
			&ParameterProperty{
				Key: jsii.String("key"),
				Value: jsii.String("value"),

				// the properties below are optional
				IsValueSecret: jsii.Boolean(false),
			},
		},
	},
}

Properties ​

authorizationEndpointstringauthorization_endpointstrauthorizationEndpointStringAuthorizationEndpointstringAuthorizationEndpoint*string required #
The URL to the authorization endpoint when OAuth is specified as the authorization type.
clientParametersIResolvable | CfnConnection.ClientParametersPropertyclient_parameterstyping.Union[IResolvable, ClientParametersProperty]clientParametersIResolvableClientParametersIResolvableClientParametersinterface{} required #
The client parameters for OAuth authorization.
httpMethodstringhttp_methodstrhttpMethodStringHttpMethodstringHttpMethod*string required #
The method to use for the authorization request.
oAuthHttpParametersoptionalIResolvable | CfnConnection.ConnectionHttpParametersPropertyo_auth_http_parametersoptionaltyping.Union[IResolvable, ConnectionHttpParametersProperty]oAuthHttpParametersoptionalIResolvableOAuthHttpParametersoptionalIResolvableOAuthHttpParametersoptionalinterface{} #
Details about the additional parameters to use for the connection.