list_guardrails
¶
list_guardrails(
*,
config_overrides: Optional[BedrockClientConfig] = None,
guardrail_identifier: Optional[GuardrailIdentifier] = None,
max_results: Optional[MaxResults] = None,
next_token: Optional[PaginationToken] = None,
) -> ListGuardrailsResponse
Lists details about all the guardrails in an account. To list the DRAFT version of all your guardrails, don't specify the guardrailIdentifier field. To list all versions of a guardrail, specify the ARN of the guardrail in the guardrailIdentifier field.
You can set the maximum number of results to return in a response in the maxResults field. If there are more results than the number you set, the response returns a nextToken that you can send in another ListGuardrails request to see the next batch of results.
Parameters:
-
guardrail_identifier(Optional[GuardrailIdentifier], default:None) –The unique identifier of the guardrail. This can be an ID or the ARN.
-
max_results(Optional[MaxResults], default:None) –The maximum number of results to return in the response.
-
next_token(Optional[PaginationToken], default:None) –If there are more results than were returned in the response, the response returns a
nextTokenthat you can send in anotherListGuardrailsrequest to see the next batch of results.
Raises:
-
AccessDeniedException–The request is denied because of missing access permissions.
-
InternalServerException–An internal server error occurred. Retry your request.
-
ResourceNotFoundException–The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.
-
ThrottlingException–The number of requests exceeds the limit. Resubmit your request later.
-
ValidationException–Input validation failed. Check your request parameters and retry the request.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_bedrock/_services/bedrock.py
5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 | |