View a markdown version of this page

CreateConsentPortal - Amazon Bedrock AgentCore Control Plane

CreateConsentPortal

Creates a new consent portal.

Request Syntax

POST /identities/CreateConsentPortal HTTP/1.1 Content-type: application/json { "description": "string", "executionRoleArn": "string", "idpConfig": { "audience": "string", "credentialProviderArn": "string", "scopes": [ "string" ] }, "name": "string", "sources": [ { "identifier": "string", "type": "string" } ], "tags": { "string" : "string" } }

URI Request Parameters

The request does not use any URI parameters.

Request Body

The request accepts the following data in JSON format.

description

The description of the consent portal.

Type: String

Length Constraints: Minimum length of 0. Maximum length of 512.

Required: No

executionRoleArn

The Amazon Resource Name (ARN) of the IAM role that the consent portal assumes to access the resources defined in its sources.

Type: String

Pattern: arn:aws(-[a-z-]+)?:iam::[0-9]{12}:role/[a-zA-Z0-9+=,.@\-_/]+

Required: Yes

idpConfig

The identity provider configuration that the consent portal uses to authenticate end users.

Type: ConsentPortalIdpConfig object

Required: Yes

name

The name of the consent portal. The name must be unique within your account.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 50.

Pattern: [a-zA-Z0-9_-]{1,50}

Required: Yes

sources

The resources served by the consent portal. Currently, we only support type agentcore-gateway.

Type: Array of ConsentPortalSource objects

Array Members: Fixed number of 1 item.

Required: Yes

tags

A map of tag keys and values to assign to the consent portal. Tags enable you to categorize your resources in different ways, for example, by purpose, owner, or environment.

Type: String to string map

Map Entries: Minimum number of 0 items. Maximum number of 50 items.

Key Length Constraints: Minimum length of 1. Maximum length of 128.

Key Pattern: [a-zA-Z0-9\s._:/=+@-]*

Value Length Constraints: Minimum length of 0. Maximum length of 256.

Value Pattern: [a-zA-Z0-9\s._:/=+@-]*

Required: No

Response Syntax

HTTP/1.1 202 Content-type: application/json { "consentPortalArn": "string", "consentPortalId": "string", "createdAt": number, "description": "string", "executionRoleArn": "string", "idpConfig": { "audience": "string", "credentialProviderArn": "string", "scopes": [ "string" ] }, "name": "string", "portalUrl": "string", "sources": [ { "identifier": "string", "type": "string" } ], "status": "string", "statusReason": "string", "updatedAt": number }

Response Elements

If the action is successful, the service sends back an HTTP 202 response.

The following data is returned in JSON format by the service.

consentPortalArn

The Amazon Resource Name (ARN) of the consent portal.

Type: String

Pattern: arn:aws[^:]*:bedrock-agentcore:[a-z0-9-]+:[0-9]{12}:consent-portal/[a-zA-Z0-9\-_]{1,50}-[A-Za-z0-9]{10}

consentPortalId

The unique identifier of the consent portal.

Type: String

Pattern: [a-zA-Z0-9\-_]{1,50}-[A-Za-z0-9]{10}

createdAt

The timestamp for when the consent portal was created.

Type: Timestamp

description

The description of the consent portal.

Type: String

Length Constraints: Minimum length of 0. Maximum length of 512.

executionRoleArn

The Amazon Resource Name (ARN) of the IAM role that the consent portal assumes to access the resources defined in its sources.

Type: String

Pattern: arn:aws(-[a-z-]+)?:iam::[0-9]{12}:role/[a-zA-Z0-9+=,.@\-_/]+

idpConfig

The identity provider configuration that the consent portal uses to authenticate end users.

Type: ConsentPortalIdpConfig object

name

The name of the consent portal.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 50.

Pattern: [a-zA-Z0-9_-]{1,50}

portalUrl

The URL used to access the consent portal.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 2000.

sources

The resources served by the consent portal.

Type: Array of ConsentPortalSource objects

Array Members: Fixed number of 1 item.

status

The current status of the consent portal.

Type: String

Valid Values: CREATING | ACTIVE | UPDATING | UPDATE_FAILED | DELETING | FAILED

statusReason

A message that provides additional information about the current status of the consent portal.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1024.

updatedAt

The timestamp for when the consent portal was last updated.

Type: Timestamp

Errors

For information about the errors that are common to all actions, see Common Error Types.

AccessDeniedException

This exception is thrown when a request is denied per access permissions

HTTP Status Code: 403

ConflictException

This exception is thrown when there is a conflict performing an operation

HTTP Status Code: 409

InternalServerException

This exception is thrown if there was an unexpected error during processing of request

HTTP Status Code: 500

ResourceNotFoundException

This exception is thrown when a resource referenced by the operation does not exist

HTTP Status Code: 404

ServiceQuotaExceededException

This exception is thrown when a request is made beyond the service quota

HTTP Status Code: 402

ThrottlingException

This exception is thrown when the number of requests exceeds the limit

HTTP Status Code: 429

UnauthorizedException

This exception is thrown when the JWT bearer token is invalid or not found for OAuth bearer token based access

HTTP Status Code: 401

ValidationException

The input fails to satisfy the constraints specified by the service.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: