Skip to content

SecretsManagerClient.tag_resource

rboto-secrets-manager==0.4.0 · Service index · Types

Model summary (excerpt): Attaches tags to a secret. Tags consist of a key name and a value. Tags are part of the secret's metadata. They are not associated with specific versions of the secret. This operation appends tags to the existing list of tags. For tag quotas and naming restrictions, see Service quotas for Tagging in the Amazon Web Services General Reference guide . If you use tags as part of your security...

Install and imports

python -m pip install "rboto[secrets-manager]==0.4.0"
from rboto import SecretsManagerClient
from collections.abc import Sequence
from rboto_secrets_manager.types import (
    Tag,
)

Signature

async def tag_resource(
    *,
    secret_id: str,
    tags: Sequence[Tag],
) -> None: ...

Arguments without defaults are required. None omits an optional request argument. Static types do not validate resource existence, permissions, lengths, ranges, or conditional service requirements.

Arguments

Argument Required Model notes (excerpt)
secret_id Yes The identifier for the secret to attach tags to. You can specify either the Amazon Resource Name (ARN) or the friendly name of the secret. For an ARN, we recommend that you specify a complete ARN rather than a partial ARN. See Finding a secret from a partial ARN .
tags Yes The tags to attach to the secret as a JSON text string argument. Each element in the list consists of a Key and a Value . For storing multiple values, we recommend that you use a JSON text string argument and specify key/value pairs. For more information, see Specifying parameter values for the Amazon Web Services CLI in the Amazon Web Services CLI User Guide.

Output

None.

| None means a value can be absent. Output mappings include every declared key; optional input keys may be omitted. Unknown output enum/union variants are not automatically valid inputs.

Tag

Follow these links for nested inputs and outputs; recursive types link back to the same type page.

Pagination and streaming

No generated paginator for this operation.

No output stream.

Errors

Import from rboto_secrets_manager.exceptions:

InternalServiceError, InvalidParameterError, InvalidRequestError, ResourceNotFoundError.

Other service failures use the service base error; credential, transport and timeout failures use shared errors.

Service guide · Pinned model