Configurar um projeto e um ambiente de desenvolvimento
Mantenha tudo organizado com as coleções
Salve e categorize o conteúdo com base nas suas preferências.
Para começar a usar a Vertex AI, esta página mostra como
criar um projeto Google Cloud e ativar as APIs da Vertex AI. Se você
não tiver permissões para executar essas tarefas,
peça a um administrador para configurar
um projeto e ativar a Vertex AI para você. Nesta página, também mostramos como configurar a CLI do Google Cloud no seu ambiente de desenvolvimento local.
Configurar um projeto
Siga estas etapas para configurar um projeto:
Sign in to your Google Cloud account. If you're new to
Google Cloud,
create an account to evaluate how our products perform in
real-world scenarios. New customers also get $300 in free credits to
run, test, and deploy workloads.
In the Google Cloud console, on the project selector page,
select or create a Google Cloud project.
At the bottom of the Google Cloud console, a
Cloud Shell
session starts and displays a command-line prompt. Cloud Shell is a shell environment
with the Google Cloud CLI
already installed and with values already set for
your current project. It can take a few seconds for the session to initialize.
Python
Para usar os exemplos Python desta página em um
ambiente de desenvolvimento local, instale e inicialize a CLI gcloud e
configure o Application Default Credentials com suas credenciais de usuário.
Para mais informações, consulte
Autenticar para usar REST
na documentação de autenticação do Google Cloud .
Pedir a um administrador para configurar um projeto da Vertex AI para você
Nesta seção, descrevemos como um administrador concede os papéis necessários para usar
a Vertex AI.
Determine um nome e ID de projeto significativos para facilitar a identificação.
Se você faz parte de uma organização ou planeja criar vários projetos, considere quais convenções de nomenclatura e hierarquias de
pasta são seguidas ou podem ser seguidas, para deixar a organização do projeto clara.
Papéis necessários:
O acesso à maioria dos recursos da Vertex AI é concedido pelo papel do IAM Usuário da Vertex AI(roles/aiplatform.user) e é suficiente para a maioria dos usuários da Vertex AI. Para ter controle total dos recursos da Vertex AI, solicite o papel (roles/aiplatform.admin)Administrador da Vertex AI.
Para entender as diferenças entre esses e outros papéis da Vertex AI, consulte Controle de acesso da Vertex AI com IAM.
Além disso, para ativar as APIs necessárias, você precisa do papel do IAM de
Administrador do Service Usage(roles/serviceusage.serviceUsageAdmin)
ou seu administrador precisa ativar as APIs para você, seguindo
as primeiras etapas.
Peça para o administrador ativar as APIs Vertex AI para você.
Se você recebeu o papel do IAM de
Administrador do Service Usage(roles/serviceusage.serviceUsageAdmin), poderá fazer isso por conta própria.
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-08-19 UTC."],[],[],null,["# Set up a project and a development environment\n\nTo get you started using Vertex AI, this page guides you through how to\ncreate a Google Cloud project and enable the Vertex AI APIs. If you\ndon't have the permissions to perform these tasks,\n[ask an administrator](#ask_admin) to setup\na project and enable Vertex AI for you. Also covered in this page is\nhow to set up the Google Cloud CLI in your local development environment.\n\nSet up a project\n----------------\n\nFollow these steps to set up a project:\n\n- Sign in to your Google Cloud account. If you're new to Google Cloud, [create an account](https://console.cloud.google.com/freetrial) to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.\n- In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n-\n [Verify that billing is enabled for your Google Cloud project](/billing/docs/how-to/verify-billing-enabled#confirm_billing_is_enabled_on_a_project).\n\n-\n\n\n Enable the Vertex AI API.\n\n\n [Enable the API](https://console.cloud.google.com/flows/enableapi?apiid=aiplatform.googleapis.com)\n\n- In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n-\n [Verify that billing is enabled for your Google Cloud project](/billing/docs/how-to/verify-billing-enabled#confirm_billing_is_enabled_on_a_project).\n\n-\n\n\n Enable the Vertex AI API.\n\n\n [Enable the API](https://console.cloud.google.com/flows/enableapi?apiid=aiplatform.googleapis.com)\n\n| **Note:** If you're an administrator setting up a project for a team, see [Set up a project for a team](/vertex-ai/docs/general/set-up-project).\n\nSet up authentication\n---------------------\n\n1. Select the tab for how you plan to use the samples on this page: \n\n### Console\n\n\nWhen you use the Google Cloud console to access Google Cloud services and\nAPIs, you don't need to set up authentication.\n\n### gcloud\n\nIn the Google Cloud console, activate Cloud Shell.\n\n[Activate Cloud Shell](https://console.cloud.google.com/?cloudshell=true)\n\n\nAt the bottom of the Google Cloud console, a\n[Cloud Shell](/shell/docs/how-cloud-shell-works)\nsession starts and displays a command-line prompt. Cloud Shell is a shell environment\nwith the Google Cloud CLI\nalready installed and with values already set for\nyour current project. It can take a few seconds for the session to initialize.\n\n### Python\n\n\nTo use the Python samples on this page in a local\ndevelopment environment, install and initialize the gcloud CLI, and\nthen set up Application Default Credentials with your user credentials.\n\n1.\n [Install](/sdk/docs/install) the Google Cloud CLI.\n\n2. If you're using an external identity provider (IdP), you must first\n [sign in to the gcloud CLI with your federated identity](/iam/docs/workforce-log-in-gcloud).\n\n3.\n After initializing the gcloud CLI, update it and install the required components:\n\n ```bash\n gcloud components update\n gcloud components install beta\n ```\n4. If you're using a local shell, then create local authentication credentials for your user account: \n\n```bash\ngcloud auth application-default login\n```\n5. You don't need to do this if you're using Cloud Shell.\n6. If an authentication error is returned, and you are using an external identity provider (IdP), confirm that you have [signed in to the gcloud CLI with your federated identity](/iam/docs/workforce-log-in-gcloud).\n\n\nFor more information, see\n[Set up ADC for a local development environment](/docs/authentication/set-up-adc-local-dev-environment)\nin the Google Cloud authentication documentation.\n\n### REST\n\n\nTo use the REST API samples on this page in a local development environment, you use the\ncredentials you provide to the gcloud CLI.\n\n1.\n [Install](/sdk/docs/install) the Google Cloud CLI.\n\n2. If you're using an external identity provider (IdP), you must first\n [sign in to the gcloud CLI with your federated identity](/iam/docs/workforce-log-in-gcloud).\n\n3.\n After initializing the gcloud CLI, update it and install the required components:\n\n ```bash\n gcloud components update\n gcloud components install beta\n ```\n\n\nFor more information, see\n[Authenticate for using REST](/docs/authentication/rest)\nin the Google Cloud authentication documentation.\n\n\u003cbr /\u003e\n\nAsk an administrator to set up a Vertex AI project for you\n----------------------------------------------------------\n\nThis section describes how an administrator grants the roles needed to use\nVertex AI.\n\n1. Determine a meaningful project name and project ID to identify your project. If you are part of an organization or plan to create multiple projects, consider what naming conventions and [folder](/resource-manager/docs/cloud-platform-resource-hierarchy#folders) hierarchies are followed, or could be followed, to make project organization clear.\n2. Required roles:\n 1. Access to most Vertex AI capabilities is granted by the [Vertex AI\n User](/vertex-ai/docs/general/access-control#aiplatform.user) `(roles/aiplatform.user)` IAM role and should suffice for most Vertex AI users. For full control of Vertex AI resources, you can request the [Vertex AI\n Administrator](/vertex-ai/docs/general/access-control#aiplatform.admin) `(roles/aiplatform.admin)` role. To explore the differences between these and other Vertex AI roles, see [Vertex AI access control\n with IAM](/vertex-ai/docs/general/access-control).\n 2. If you also intend to use [Vertex AI Workbench\n instances](/vertex-ai/docs/workbench/introduction) in Google Cloud, ask your administrator to grant you the [Notebooks\n Administrator](/iam/docs/understanding-roles#notebooks.admin) `(roles/notebooks.admin)` IAM role for the project, as well as the [Service\n Account User](/iam/docs/understanding-roles#iam.serviceAccountUser) `(roles/iam.serviceAccountUser)` IAM role on either the project or the [Compute Engine\n default service account](/compute/docs/access/service-accounts#default_service_account).\n 3. Additionally, to enable the necessary APIs, you either need the [Service\n Usage Admin](/iam/docs/understanding-roles#serviceusage.serviceUsageAdmin) `(roles/serviceusage.serviceUsageAdmin)` IAM role or your administrator needs to enable the APIs for you by following the first few steps.\n3. Ask your administrator to enable Vertex AI APIs for you. If you're granted the [Service\n Usage Admin](/iam/docs/understanding-roles#serviceusage.serviceUsageAdmin) `(roles/serviceusage.serviceUsageAdmin)` IAM role, then you'll be able to do this on your own.\n\n| **Note:** Certain tasks in Vertex AI require that you use additional Google Cloud products besides Vertex AI. For example, in most cases, you must use Cloud Storage and Artifact Registry when you create a custom training pipeline. You might need to perform additional setup tasks to use other Google Cloud products.\n\nWhat's next\n-----------\n\n- Read an [overview of\n Vertex AI](/vertex-ai/docs/start/introduction-unified-platform).\n\n- Walk through one of the [tutorials for using\n Vertex AI](/vertex-ai/docs/tutorials).\n\n- Learn how to\n [use the Vertex AI SDK for Python](/vertex-ai/docs/python-sdk/use-vertex-ai-python-sdk),\n which provides another way to interact with Vertex AI."]]