Method: projects.batchOptimizeTours
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
하나 이상의 OptimizeToursRequest
메시지에 대해 차량 투어를 일괄적으로 최적화합니다.
이 메서드는 장기 실행 작업 (LRO)입니다. 최적화를 위한 입력 (OptimizeToursRequest
메시지) 및 출력 (OptimizeToursResponse
메시지)은 사용자가 지정한 형식으로 Cloud Storage에서 읽고 씁니다. projects.optimizeTours
메서드와 마찬가지로 각 OptimizeToursRequest
는 ShipmentModel
를 포함하고 전체 비용을 최소화하면서 차량이 실행할 경로 집합인 ShipmentRoute
필드가 포함된 OptimizeToursResponse
를 반환합니다.
사용자는 operations.get
를 폴링하여 LRO 상태를 확인할 수 있습니다.
LRO done
필드가 false이면 하나 이상의 요청이 아직 처리 중인 것입니다. 다른 요청이 성공적으로 완료되었을 수 있으며 Cloud Storage에서 그 결과를 확인할 수 있습니다.
LRO의 done
필드가 true이면 모든 요청이 처리된 것입니다. 성공적으로 처리된 요청은 Cloud Storage에서 결과를 확인할 수 있습니다. 실패한 요청의 결과는 Cloud Storage에서 사용할 수 없습니다. LRO의 error
필드가 설정된 경우 실패한 요청 중 하나의 오류가 포함됩니다.
HTTP 요청
POST https://routeoptimization.googleapis.com/v1/{parent=projects/*}:batchOptimizeTours
URL은 gRPC 트랜스코딩 문법을 사용합니다.
경로 매개변수
매개변수 |
parent |
string
필수 항목입니다. 전화를 걸 프로젝트와 위치를 타겟팅합니다. 형식: * projects/{project-id} * projects/{project-id}/locations/{location-id} 위치를 지정하지 않으면 리전이 자동으로 선택됩니다.
|
요청 본문
요청 본문에는 다음과 같은 구조의 데이터가 포함됩니다.
필드 |
modelConfigs[] |
object (AsyncModelConfig )
필수 항목입니다. 각 구매 모델의 입력/출력 정보(예: 파일 경로, 데이터 형식)
|
응답 본문
성공한 경우 응답 본문에 Operation
의 인스턴스가 포함됩니다.
승인 범위
다음 OAuth 범위가 필요합니다.
https://www.googleapis.com/auth/cloud-platform
IAM 권한
parent
리소스에 대해서는 다음 IAM 권한이 필요합니다.
routeoptimization.operations.create
자세한 내용은 IAM 문서를 참조하세요.
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-08-31(UTC)
[null,null,["최종 업데이트: 2025-08-31(UTC)"],[[["\u003cp\u003eThe \u003ccode\u003ebatchOptimizeTours\u003c/code\u003e method optimizes vehicle tours for multiple requests as a Long Running Operation (LRO), reading inputs and writing outputs to Cloud Storage.\u003c/p\u003e\n"],["\u003cp\u003eUsers can monitor the LRO status using \u003ccode\u003eoperations.get\u003c/code\u003e, with results becoming available in Cloud Storage upon completion.\u003c/p\u003e\n"],["\u003cp\u003eThe request body requires \u003ccode\u003emodelConfigs\u003c/code\u003e which specifies file paths and data formats for each model using the \u003ccode\u003eAsyncModelConfig\u003c/code\u003e structure.\u003c/p\u003e\n"],["\u003cp\u003eAuthorization requires the \u003ccode\u003ehttps://www.googleapis.com/auth/cloud-platform\u003c/code\u003e OAuth scope and the \u003ccode\u003erouteoptimization.operations.create\u003c/code\u003e IAM permission.\u003c/p\u003e\n"],["\u003cp\u003eSuccessful responses contain an \u003ccode\u003eOperation\u003c/code\u003e instance providing information about the ongoing operation.\u003c/p\u003e\n"]]],["This API method `batchOptimizeTours` optimizes vehicle tours for multiple `OptimizeToursRequest` messages via a Long Running Operation (LRO). Inputs and outputs are stored in Cloud Storage. Each request includes a `ShipmentModel`, and returns `ShipmentRoute` fields, minimizing overall cost. Users can check the LRO's status via `operations.get`. The `done` field indicates completion, while the `error` field shows failures. Requires `routeoptimization.operations.create` IAM permission and `cloud-platform` OAuth scope. The parent parameter will be used for routing.\n"],null,["# Method: projects.batchOptimizeTours\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n- [Authorization scopes](#body.aspect)\n- [IAM Permissions](#body.aspect_1)\n\nOptimizes vehicle tours for one or more `OptimizeToursRequest` messages as a batch.\n\nThis method is a Long Running Operation (LRO). The inputs for optimization (`OptimizeToursRequest` messages) and outputs (`OptimizeToursResponse` messages) are read from and written to Cloud Storage in user-specified format. Like the `projects.optimizeTours` method, each `OptimizeToursRequest` contains a `ShipmentModel` and returns an `OptimizeToursResponse` containing `ShipmentRoute` fields, which are a set of routes to be performed by vehicles minimizing the overall cost.\n\nThe user can poll `operations.get` to check the status of the LRO:\n\nIf the LRO `done` field is false, then at least one request is still being processed. Other requests may have completed successfully and their results are available in Cloud Storage.\n\nIf the LRO's `done` field is true, then all requests have been processed. Any successfully processed requests will have their results available in Cloud Storage. Any requests that failed will not have their results available in Cloud Storage. If the LRO's `error` field is set, then it contains the error from one of the failed requests.\n\n### HTTP request\n\n`POST https://routeoptimization.googleapis.com/v1/{parent=projects/*}:batchOptimizeTours`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|----------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `parent` | `string` Required. Target project and location to make a call. Format: \\* `projects/{project-id}` \\* `projects/{project-id}/locations/{location-id}` If no location is specified, a region will be chosen automatically. |\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"modelConfigs\": [ { object (/maps/documentation/route-optimization/reference/rest/v1/AsyncModelConfig) } ] } ``` |\n\n| Fields ||\n|------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `modelConfigs[]` | `object (`[AsyncModelConfig](/maps/documentation/route-optimization/reference/rest/v1/AsyncModelConfig)`)` Required. Input/Output information each purchase model, such as file paths and data formats. |\n\n### Response body\n\nIf successful, the response body contains an instance of [Operation](/maps/documentation/route-optimization/reference/rest/v1/projects.locations.operations#Operation).\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/cloud-platform`\n\n### IAM Permissions\n\nRequires the following [IAM](https://cloud.google.com/iam/docs) permission on the `parent` resource:\n\n- `routeoptimization.operations.create`\n\nFor more information, see the [IAM documentation](https://cloud.google.com/iam/docs)."]]