Method: projects.models.list

Lists the models in a project.

Each project can contain multiple models, and each model can have multiple versions.

If there are no models that match the request parameters, the list request returns an empty response body: {}.

HTTP request

GET https://{endpoint}/v1/{parent=projects/*}/models

Where {endpoint} is one of the supported service endpoints.

The URLs use gRPC Transcoding syntax.

Path parameters

Parameters
parent

string

Required. The name of the project whose models are to be listed.

Authorization requires the following IAM permission on the specified resource parent:

  • ml.models.list

Query parameters

Parameters
filter

string

Optional. Specifies the subset of models to retrieve.

pageToken

string

Optional. A page token to request the next page of results.

You get the token from the nextPageToken field of the response from the previous call.

pageSize

integer

Optional. The number of models to retrieve per "page" of results. If there are more remaining results than this number, the response message will contain a valid value in the nextPageToken field.

The default value is 20, and the maximum page size is 100.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

Response message for the models.list method.

JSON representation
{
  "models": [
    {
      object (Model)
    }
  ],
  "nextPageToken": string
}
Fields
models[]

object (Model)

The list of models.

nextPageToken

string

Optional. Pass this token as the pageToken field of the request for a subsequent call.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/cloud-platform.read-only
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.