시작하기
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
Google API는 Google Cloud 프로젝트에서 사용됩니다. 이 가이드에서는
이러한 환경에서 OR API를 활성화하여 Google Cloud 프로젝트를
API 엔드포인트를 호출하기 위해 API 키를 가져오는 방법,
Google Cloud 프로젝트 만들기
Google 호스팅 계정을 사용하여
만들기
Google Cloud 콘솔에서 프로젝트를
생성할 수 있습니다 사용하려는 솔버가
신뢰할 수 있는 테스터 프로그램에 따라
가이드를 먼저 읽어보세요.
API 사용 설정
API 키 가져오기
다음으로 이동합니다.
사용자 인증 정보
선택합니다.
'+ 사용자 인증 정보 만들기'를 클릭합니다.
API 키 선택
API 키를 다음 본문과 함께 credentials.json
파일에 저장합니다.
{
"key": "your_api_key"
}
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2024-08-29(UTC)
[null,null,["최종 업데이트: 2024-08-29(UTC)"],[[["\u003cp\u003eGoogle Cloud projects are necessary to utilize Google APIs, and this guide outlines the setup process for accessing the Optimization Routing API (OR API).\u003c/p\u003e\n"],["\u003cp\u003eThe process involves three main steps: creating a Google Cloud project, enabling the OR API within the project, and generating an API key for authentication.\u003c/p\u003e\n"],["\u003cp\u003eBefore proceeding, ensure you have a Google account, and if utilizing a solver under a trusted tester program, refer to the provided guide for specific instructions.\u003c/p\u003e\n"],["\u003cp\u003eOnce enabled, you'll need to obtain an API key through the Google Cloud console and securely store it in a 'credentials.json' file for API access.\u003c/p\u003e\n"]]],["The process involves three core steps: creating a Google Cloud project, enabling the OR API within that project, and obtaining an API key. First, create a project via the Google Cloud console. Second, enable the OR API by navigating to the APIs library and clicking \"Enable.\" Finally, generate an API key through the credentials menu, saving it to a `credentials.json` file with the specified format. This API key is needed to call the API endpoints.\n"],null,["# Get started\n\nGoogle APIs are consumed from Google Cloud projects. This guide walks through\nthe process of creating a Google Cloud Project, enabling the OR API in such a\nproject, and obtaining an API key to call the API endpoints.\n\n1. Create a Google Cloud project\n\n Using a Google hosted account,\n [create](https://console.cloud.google.com/projectcreate)\n a project in the Google Cloud console. If the solver you intend to use is\n under a trusted tester program, follow this\n [guide](/optimization/service/trusted_testers) first.\n2. Enable the API\n\n - Navigate to the [APIs\n library](https://console.cloud.google.com/apis/library/optimization.googleapis.com).\n\n - Click \"Enable\".\n\n3. Get an API key\n\n - Navigate to the\n [credentials](https://console.cloud.google.com/apis/credentials)\n menu.\n\n - Click \"+ CREATE CREDENTIALS\"\n\n - Select API key\n\n - Save the API key in a `credentials.json` file with the following body\n\n {\n \"key\": \"your_api_key\"\n }"]]