View a markdown version of this page

ListProjects - Amazon Bedrock

ListProjects

Lists the account's projects. Results are paginated: when the response includes nextToken, pass it in the next request to fetch the following page. Page size is 1-100, default 20. By default every project is returned regardless of status; set statusFilter to list only active or only archived projects.

Request Syntax

GET /projects?maxResults=maxResults&nextToken=nextToken&statusFilter=statusFilter HTTP/1.1

URI Request Parameters

The request uses the following URI parameters.

maxResults

The maximum number of projects to return in one response, from 1 to 100. The default is 20.

Valid Range: Minimum value of 1. Maximum value of 100.

nextToken

Continuation token from a previous ListProjects response.

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

Pattern: \S*

statusFilter

Returns only the projects in this lifecycle status. When absent, no status filtering is applied and every project is returned. New lifecycle states extend the ProjectStatus enum, and with it this filter, compatibly.

Valid Values: active | archived

Request Body

The request does not have a request body.

Response Syntax

HTTP/1.1 200 Content-type: application/json { "nextToken": "string", "projectSummaries": [ { "archivedAt": "string", "arn": "string", "createdAt": "string", "dataRetention": { "mode": "string" }, "id": "string", "name": "string", "status": "string" } ] }

Response Elements

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

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

nextToken

Continuation token; present only when more results exist. Pass it in the next request to fetch the following page.

Type: String

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

Pattern: \S*

projectSummaries

The projects returned for this page, including their details and data retention settings.

Type: Array of ProjectSummary objects

Errors

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

AccessDeniedException

The request is denied because of missing access permissions.

HTTP Status Code: 403

InternalServerException

An internal server error occurred. Retry your request.

HTTP Status Code: 500

ThrottlingException

The number of requests exceeds the limit. Resubmit your request later.

HTTP Status Code: 429

ValidationException

Input validation failed. Check your request parameters and retry the request.

HTTP Status Code: 400

See Also

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