Skip to content

rotate_payment_connector_credentials

Operation

rotate_payment_connector_credentials

Replaces the service-managed credentials of a payment connector with newly issued credentials.

Use this operation only for payment connectors with a provisionMode of QUICK_CREATE. For payment connectors with a provisionMode of MANUAL, call UpdatePaymentCredentialProvider instead after rotating credentials with the payment provider directly.

The rotation finishes before the response is returned, and only one rotation runs at a time for a given payment connector. When it succeeds, the new credential is in effect and the payment connector stays in the READY state. When it fails, an error is returned, the payment connector and its existing credential are left unchanged, and you can retry the request.

Rotation replaces the credential on the connector's credential provider, so every payment connector that uses that provider is affected. Replace any copy of the previous credential that you use outside AgentCore.

Parameters:

Name Type Description Default
request RotatePaymentConnectorCredentialsInput | RotatePaymentConnectorCredentialsInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[RotatePaymentConnectorCredentialsInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
RotatePaymentConnectorCredentialsOutput

An instance of RotatePaymentConnectorCredentialsOutput.

rotate_payment_connector_credentials async

Replaces the service-managed credentials of a payment connector with newly issued credentials.

Use this operation only for payment connectors with a provisionMode of QUICK_CREATE. For payment connectors with a provisionMode of MANUAL, call UpdatePaymentCredentialProvider instead after rotating credentials with the payment provider directly.

The rotation finishes before the response is returned, and only one rotation runs at a time for a given payment connector. When it succeeds, the new credential is in effect and the payment connector stays in the READY state. When it fails, an error is returned, the payment connector and its existing credential are left unchanged, and you can retry the request.

Rotation replaces the credential on the connector's credential provider, so every payment connector that uses that provider is affected. Replace any copy of the previous credential that you use outside AgentCore.

Parameters:

Name Type Description Default
request RotatePaymentConnectorCredentialsInput | RotatePaymentConnectorCredentialsInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[RotatePaymentConnectorCredentialsInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
RotatePaymentConnectorCredentialsOutput

An instance of RotatePaymentConnectorCredentialsOutput.

Input

Pass the input as keyword arguments, a positional dictionary, or a positional model object. Pass plugins separately as a keyword argument.

RotatePaymentConnectorCredentialsInputDict

Bases: TypedDict

Dictionary form of RotatePaymentConnectorCredentialsInput.

Attributes

client_token instance-attribute
client_token: str | None

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If you don't specify this field, a value is randomly generated for you. If this token matches a previous request, the service ignores the request, but doesn't return an error. For more information, see Ensuring idempotency.

This field is autopopulated if not provided.

credentials_to_rotate instance-attribute

The credentials to rotate. Specify the member that matches the payment connector's type. Each credential that you select is rotated independently.

payment_connector_id instance-attribute
payment_connector_id: Required[str]

The unique identifier of the payment connector whose credentials you want to rotate.

payment_manager_id instance-attribute
payment_manager_id: Required[str]

The unique identifier of the parent payment manager.

RotatePaymentConnectorCredentialsInput dataclass

Bases: _SerdeShape

Dataclass for RotatePaymentConnectorCredentialsInput structure.

Attributes

client_token class-attribute instance-attribute
client_token: str | None = ...

A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If you don't specify this field, a value is randomly generated for you. If this token matches a previous request, the service ignores the request, but doesn't return an error. For more information, see Ensuring idempotency.

This field is autopopulated if not provided.

credentials_to_rotate class-attribute instance-attribute
credentials_to_rotate: CredentialRotationConfig | None = ...

The credentials to rotate. Specify the member that matches the payment connector's type. Each credential that you select is rotated independently.

payment_connector_id class-attribute instance-attribute
payment_connector_id: str | None = ...

The unique identifier of the payment connector whose credentials you want to rotate.

payment_manager_id class-attribute instance-attribute
payment_manager_id: str | None = ...

The unique identifier of the parent payment manager.

Output

RotatePaymentConnectorCredentialsOutput dataclass

Bases: _SerdeShape

Dataclass for RotatePaymentConnectorCredentialsOutput structure.

Attributes

last_updated_at instance-attribute
last_updated_at: datetime

The timestamp when the payment connector was last updated, which is when the rotation completed.

payment_connector_id instance-attribute
payment_connector_id: str

The unique identifier of the payment connector.

payment_manager_id instance-attribute
payment_manager_id: str

The unique identifier of the parent payment manager.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.

status instance-attribute
status: str

The current status of the payment connector, which is READY after a successful rotation.