Lists the registry record associations that your account created. Specify publisherArn to list only the associations for that publisher, or omit it to list associations across all of your publishers. Results are eventually consistent, so an association that you just created or removed can take a few seconds to appear in or disappear from the list.
Parameters:
-
publisher_arn
(Optional[PublisherIdentifierArn], default:
None
)
–
The Amazon Resource Name (ARN) of a publisher. If you specify it, only the associations for this publisher are returned.
-
max_results
(Optional[MaxResults], default:
None
)
–
The maximum number of results to return in a single call.
-
next_token
(Optional[NextToken], default:
None
)
–
The token for the next page of results. Use the value returned in the previous response.
Raises:
Source code in docs_src/capo_agent_registry_control/_services/agent_registry_control.py
| def list_publisher_associations(
self,
*,
config_overrides: Optional[AgentRegistryControlClientConfig] = None,
publisher_arn: Optional[
"capo_agent_registry_control.types.publisher_identifier_arn.PublisherIdentifierArn"
] = None,
max_results: Optional[
"capo_agent_registry_control.types.max_results.MaxResults"
] = None,
next_token: Optional[
"capo_agent_registry_control.types.next_token.NextToken"
] = None,
) -> "capo_agent_registry_control.types.list_publisher_associations_response.ListPublisherAssociationsResponse":
"""<p>Lists the registry record associations that your account created. Specify <code>publisherArn</code> to list only the associations for that publisher, or omit it to list associations across all of your publishers. Results are eventually consistent, so an association that you just created or removed can take a few seconds to appear in or disappear from the list.</p>
Args:
publisher_arn: <p>The Amazon Resource Name (ARN) of a publisher. If you specify it, only the associations for this publisher are returned.</p>
max_results: <p>The maximum number of results to return in a single call.</p>
next_token: <p>The token for the next page of results. Use the value returned in the previous response.</p>
Raises:
capo_agent_registry_control.errors.access_denied_exception.AccessDeniedException: <p>The caller is not authorized to perform the requested action.</p>
capo_agent_registry_control.errors.internal_server_exception.InternalServerException: <p>The request failed due to an unexpected internal error; the caller may retry.</p>
capo_agent_registry_control.errors.throttling_exception.ThrottlingException: <p>The request was denied due to request throttling; the caller may retry after a delay.</p>
capo_agent_registry_control.errors.validation_exception.ValidationException: <p>The request failed validation of one or more input fields.</p>
capo_agent_registry_control.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_agent_registry_control.types.list_publisher_associations_request.ListPublisherAssociationsRequest]",
) -> OperationResponse[
"capo_agent_registry_control.types.list_publisher_associations_response.ListPublisherAssociationsResponse"
]:
import capo_agent_registry_control._operations.agent_registry_control.list_publisher_associations
output, http_response = (
capo_agent_registry_control._operations.agent_registry_control.list_publisher_associations.list_publisher_associations(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
def _redact_output(
output: "capo_agent_registry_control.types.list_publisher_associations_response.ListPublisherAssociationsResponse",
) -> dict[str, Any]:
import capo_agent_registry_control.types.list_publisher_associations_response
return capo_agent_registry_control.types.list_publisher_associations_response.redact_sensitive(
output
)
interceptors_, options_ = self.operation_options(
config_overrides,
OperationLogging("ListPublisherAssociations", redact_output=_redact_output),
)
input_: capo_agent_registry_control.types.list_publisher_associations_request.ListPublisherAssociationsRequest = {}
if publisher_arn is not None:
input_["publisher_arn"] = publisher_arn
if max_results is not None:
input_["max_results"] = max_results
if next_token is not None:
input_["next_token"] = next_token
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|