🔑Create Google Cloud Vertex AI API Key

Step 1: Create new project

Go to https://console.cloud.google.com/projectcreate, enter project name and click Create.

Step 2: Create new service account

Go to https://console.cloud.google.com/iam-admin/serviceaccounts, select the project just created in Step 1: Create new project.

Click Create Service Account.

Enter name, description for service account and click Create and Continue.

Click Select a role and search for Vertex AI Service Agent, then select it.

Click Continue.

Click Done.

Step 3: Generate new key

Click on the service account just created, then select Keys tab.

Click Add Key and select Create new key.

Select JSON and click Create.

A JSON file will be downloaded into your machine. Keep that file secret. Open that file and copy whole file content.

Key file content looks like below:

  "type": "service_account",
  "project_id": "mindmac-300128",
  "private_key_id": "12efb3bcc7u7dbf111842f27415d37454c6d6fa012",
  "private_key": "-----BEGIN PRIVATE KEY-----\nMIIE...8XI3A=\n-----END PRIVATE KEY-----\n",
  "client_email": "[email protected]",
  "client_id": "208453549200948148846",
  "auth_uri": "https://accounts.google.com/o/oauth2/auth",
  "token_uri": "https://oauth2.googleapis.com/token",
  "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
  "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/mindmac-service-account%40mindmac-300128.iam.gserviceaccount.com",
  "universe_domain": "googleapis.com"

Step 4: Enable Vertex AI API

Go to https://console.cloud.google.com/marketplace/product/google/aiplatform.googleapis.com, select the project just created and click Enable to activate Vertex AI API.

Step 5: Grab information to construct API URL

Go to https://console.cloud.google.com/vertex-ai, select project just created and take note region name.

Go to https://console.cloud.google.com/welcome, select project just created and copy the project ID.

Vertex AI API URL has format:

  • LOCATION is the region name above, for example us-central1

  • PROJECT_ID is the ID of the project above

In this case it should be:


Add Google Vertex AI key

Go to MindMac -> Settings... -> Account or press ⌘ + , to open Account Setting.

Select Vertex AI provider, enter name and your custom URL from Step 5: Grab information to construct API URL, paste Service Account key content from Step 2: Create new service account and click Save to finish.

Last updated