diff --git a/.release-please-manifest.json b/.release-please-manifest.json
index 1076d54b407..749b93f1e6a 100644
--- a/.release-please-manifest.json
+++ b/.release-please-manifest.json
@@ -9,13 +9,13 @@
"packages/google-appengine": "2.2.2",
"packages/google-area120-tables": "2.2.2",
"packages/google-cloud-accessapproval": "2.2.2",
- "packages/google-cloud-aiplatform": "2.15.0",
+ "packages/google-cloud-aiplatform": "2.16.0",
"packages/google-cloud-apigateway": "2.2.2",
"packages/google-cloud-apigeeconnect": "2.2.2",
- "packages/google-cloud-asset": "4.6.3",
+ "packages/google-cloud-asset": "4.6.4",
"packages/google-cloud-assuredworkloads": "3.6.2",
"packages/google-cloud-baremetalsolution": "0.3.2",
- "packages/google-cloud-batch": "0.9.0",
+ "packages/google-cloud-batch": "0.10.0",
"packages/google-cloud-beyondcorp-appconnections": "0.3.2",
"packages/google-cloud-beyondcorp-appconnectors": "0.4.2",
"packages/google-cloud-beyondcorp-appgateways": "0.3.2",
@@ -27,11 +27,11 @@
"packages/google-cloud-bigquery-datapolicies": "0.3.2",
"packages/google-cloud-bigquery-datatransfer": "3.2.2",
"packages/google-cloud-bigquery-reservation": "2.2.1",
- "packages/google-cloud-billing": "3.3.2",
+ "packages/google-cloud-billing": "3.4.0",
"packages/google-cloud-billing-budgets": "4.3.0",
"packages/google-cloud-binaryauthorization": "2.5.0",
"packages/google-cloud-certificatemanager": "0.7.2",
- "packages/google-cloud-channel": "2.7.0",
+ "packages/google-cloud-channel": "2.8.0",
"packages/google-cloud-clouddms": "2.3.0",
"packages/google-cloud-compute": "3.9.1",
"packages/google-cloud-contactcenterinsights": "2.8.0",
@@ -45,26 +45,26 @@
"packages/google-cloud-dataproc": "4.5.0",
"packages/google-cloud-dataqna": "2.1.2",
"packages/google-cloud-datastream": "2.3.0",
- "packages/google-cloud-deploy": "2.6.0",
- "packages/google-cloud-dialogflow": "5.8.0",
- "packages/google-cloud-dialogflow-cx": "3.6.0",
- "packages/google-cloud-discoveryengine": "0.7.0",
- "packages/google-cloud-documentai": "7.3.1",
+ "packages/google-cloud-deploy": "2.7.0",
+ "packages/google-cloud-dialogflow": "5.9.0",
+ "packages/google-cloud-dialogflow-cx": "3.7.0",
+ "packages/google-cloud-discoveryengine": "0.8.0",
+ "packages/google-cloud-documentai": "7.4.0",
"packages/google-cloud-domains": "2.2.2",
- "packages/google-cloud-essentialcontacts": "2.1.2",
+ "packages/google-cloud-essentialcontacts": "2.1.3",
"packages/google-cloud-eventarc": "2.3.2",
"packages/google-cloud-eventarc-publishing": "2.4.2",
"packages/google-cloud-filestore": "2.4.1",
"packages/google-cloud-functions": "2.5.0",
"packages/google-cloud-gaming": "3.2.2",
- "packages/google-cloud-gkebackup": "0.3.2",
+ "packages/google-cloud-gkebackup": "0.4.0",
"packages/google-cloud-gkeconnect-gateway": "2.1.2",
"packages/google-cloud-gkehub": "3.4.0",
"packages/google-cloud-gkemulticloud": "0.3.2",
"packages/google-cloud-gsuiteaddons": "0.1.2",
"packages/google-cloud-iap": "2.3.1",
"packages/google-cloud-ids": "2.2.2",
- "packages/google-cloud-iot": "3.2.2",
+ "packages/google-cloud-iot": "3.2.3",
"packages/google-cloud-kms": "3.6.0",
"packages/google-cloud-language": "5.3.0",
"packages/google-cloud-lifesciences": "2.3.2",
@@ -72,9 +72,9 @@
"packages/google-cloud-mediatranslation": "3.1.2",
"packages/google-cloud-memcache": "2.3.2",
"packages/google-cloud-metastore": "3.5.0",
- "packages/google-cloud-monitoring": "3.0.4",
+ "packages/google-cloud-monitoring": "3.0.5",
"packages/google-cloud-networkconnectivity": "2.3.3",
- "packages/google-cloud-networkmanagement": "2.4.2",
+ "packages/google-cloud-networkmanagement": "2.5.0",
"packages/google-cloud-networksecurity": "1.1.2",
"packages/google-cloud-notebooks": "2.1.4",
"packages/google-cloud-optimization": "2.2.2",
@@ -96,40 +96,40 @@
"packages/google-cloud-secretmanager": "4.2.2",
"packages/google-cloud-security-privateca": "4.4.0",
"packages/google-cloud-security-publicca": "0.1.5",
- "packages/google-cloud-securitycenter": "7.5.0",
+ "packages/google-cloud-securitycenter": "7.6.0",
"packages/google-cloud-servicedirectory": "4.0.7",
"packages/google-cloud-shell": "2.1.2",
- "packages/google-cloud-speech": "5.5.0",
- "packages/google-cloud-talent": "5.1.3",
+ "packages/google-cloud-speech": "5.5.1",
+ "packages/google-cloud-talent": "5.1.4",
"packages/google-cloud-tasks": "3.1.2",
- "packages/google-cloud-texttospeech": "4.2.2",
+ "packages/google-cloud-texttospeech": "4.2.3",
"packages/google-cloud-tpu": "2.7.0",
- "packages/google-cloud-translate": "7.2.1",
+ "packages/google-cloud-translate": "7.2.2",
"packages/google-cloud-video-livestream": "0.5.1",
"packages/google-cloud-video-stitcher": "0.4.0",
"packages/google-cloud-video-transcoder": "2.6.0",
- "packages/google-cloud-videointelligence": "4.2.2",
- "packages/google-cloud-vision": "3.1.3",
+ "packages/google-cloud-videointelligence": "4.2.3",
+ "packages/google-cloud-vision": "3.1.4",
"packages/google-cloud-vmmigration": "2.3.2",
"packages/google-cloud-vmwareengine": "0.2.0",
"packages/google-cloud-vpcaccess": "2.2.2",
"packages/google-cloud-webrisk": "3.3.0",
"packages/google-cloud-websecurityscanner": "2.1.5",
"packages/google-cloud-workflows-executions": "2.3.2",
- "packages/google-container": "4.13.0",
+ "packages/google-container": "4.14.0",
"packages/google-dataflow": "2.1.2",
"packages/google-devtools-artifactregistry": "2.2.2",
- "packages/google-devtools-cloudbuild": "3.6.0",
+ "packages/google-devtools-cloudbuild": "3.8.0",
"packages/google-devtools-containeranalysis": "4.7.0",
"packages/google-iam": "0.3.2",
"packages/google-iam-credentials": "2.0.4",
"packages/google-identity-accesscontextmanager": "2.3.2",
"packages/google-maps-addressvalidation": "1.0.2",
"packages/google-maps-mapsplatformdatasets": "0.2.0",
- "packages/google-maps-routing": "0.5.1",
+ "packages/google-maps-routing": "0.6.0",
"packages/google-monitoring-dashboard": "2.9.2",
- "packages/google-privacy-dlp": "4.4.2",
- "packages/google-storagetransfer": "2.3.2",
+ "packages/google-privacy-dlp": "4.4.3",
+ "packages/google-storagetransfer": "2.4.0",
"packages/grafeas": "4.5.0",
"packages/typeless-sample-bot": "1.3.3",
"packages/google-cloud-advisorynotifications": "0.2.1",
@@ -137,9 +137,10 @@
"packages/google-cloud-alloydb": "0.2.0",
"packages/google-cloud-workstations": "0.2.0",
"packages/google-cloud-confidentialcomputing": "0.1.0",
- "packages/google-ai-generativelanguage": "0.2.0",
+ "packages/google-ai-generativelanguage": "0.2.1",
"packages/google-cloud-storageinsights": "0.1.1",
"packages/google-maps-places": "0.1.0",
"packages/google-cloud-support": "0.1.0",
- "packages/google-cloud-rapidmigrationassessment": "0.1.0"
+ "packages/google-cloud-rapidmigrationassessment": "0.1.0",
+ "packages/google-cloud-migrationcenter": "0.1.0"
}
diff --git a/README.md b/README.md
index bd3ed9694eb..cdf29ba6581 100644
--- a/README.md
+++ b/README.md
@@ -163,6 +163,7 @@ applications that interact with individual Google Cloud services:
| [Places API (New)](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-maps-places) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@googlemaps/places) |
| [Private Catalog](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-privatecatalog) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@google-cloud/private-catalog) |
| [Public Certificate Authority](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-security-publicca) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@google-cloud/publicca) |
+| [Rapid Migration Assessment API](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-rapidmigrationassessment) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@google-cloud/rapidmigrationassessment) |
| [Storage Insights API](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-storageinsights) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@google-cloud/storageinsights) |
| [Support API](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-support) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@google-cloud/support) |
| [Trace](https://github.com/googleapis/cloud-trace-nodejs) | [![Preview][preview-stability]][launch-stages] | [](https://npm.im/@google-cloud/trace-agent) |
diff --git a/changelog.json b/changelog.json
index 19af3d97253..6e638f9c54a 100644
--- a/changelog.json
+++ b/changelog.json
@@ -1,6 +1,591 @@
{
"repository": "googleapis/google-cloud-node",
"entries": [
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "5951ac077a08fcc427e3cd67c022d21f0040f81c",
+ "message": "Add initial files for google.cloud.migrationcenter.v1",
+ "issues": [
+ "4386"
+ ]
+ }
+ ],
+ "version": "0.1.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/migrationcenter",
+ "id": "b9b11345-f326-45a7-8b72-1422001af4b7",
+ "createTime": "2023-07-04T14:41:00.186Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "d06c733eac7699f2a10853b150cfdeae464a9962",
+ "message": "[generativelanguage] Update safety protos",
+ "issues": [
+ "4382"
+ ]
+ }
+ ],
+ "version": "0.2.1",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-ai/generativelanguage",
+ "id": "d21a7d0d-15db-4ed5-a30d-1097066e8ff4",
+ "createTime": "2023-07-04T14:41:00.181Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "8414c8458133ecc654d25eeb8b0b90c4dac9ff04",
+ "message": "[routing] Add HTML Navigation Instructions feature to ComputeRoutes",
+ "issues": [
+ "4381"
+ ]
+ }
+ ],
+ "version": "0.6.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@googlemaps/routing",
+ "id": "1d60180f-ee0e-4ead-9e58-2d8d01f7f106",
+ "createTime": "2023-07-04T14:41:00.178Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "a425fe255c2e1c002cb58e3c2c074366d7724de9",
+ "message": "[cloudbuild] Add GitLabConfig and fetchGitRefs for Cloud Build Repositories",
+ "issues": [
+ "4380"
+ ]
+ }
+ ],
+ "version": "3.8.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/cloudbuild",
+ "id": "3b6ad957-9b29-47ac-b1e7-926761f19620",
+ "createTime": "2023-07-04T14:41:00.175Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "833a1ae44bab92fbfef8a225947b6d1f482cf099",
+ "message": "[container] Add `KUBE_DNS` option to `DNSConfig.cluster_dns`",
+ "issues": [
+ "4383"
+ ]
+ }
+ ],
+ "version": "4.14.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/container",
+ "id": "f387127b-5fec-41ee-b335-c0b493bddff8",
+ "createTime": "2023-07-04T14:41:00.171Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "ec08d08cd2d8c03b61d9e7a8e7879ecfcb83475f",
+ "message": "[batch] Add gpu driver version field",
+ "issues": [
+ "4391"
+ ]
+ }
+ ],
+ "version": "0.10.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/batch",
+ "id": "9b71c336-47a0-4113-bcbb-b1c762a95555",
+ "createTime": "2023-07-04T14:41:00.167Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "f6f3726caf528c591f55772c23b8836a2657c2c8",
+ "message": "[storagetransfer] add event driven transfer configuration",
+ "issues": [
+ "4376"
+ ]
+ }
+ ],
+ "version": "2.4.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/storage-transfer",
+ "id": "1f44ef3e-9639-4fbf-87e1-e1e411f73fc5",
+ "createTime": "2023-06-28T19:08:57.103Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "4.4.3",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/dlp",
+ "id": "1c26d779-6f70-45bf-97c2-eb3b1ef43dd7",
+ "createTime": "2023-06-28T19:08:57.100Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "5ce24848470ada481a42e7739fdef41928266623",
+ "message": "[cloudbuild] add repositoryevent to buildtrigger",
+ "issues": [
+ "4378"
+ ]
+ }
+ ],
+ "version": "3.7.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/cloudbuild",
+ "id": "6bcf079b-909a-4405-8a57-88835ac1d806",
+ "createTime": "2023-06-28T19:08:57.096Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "3.1.4",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/vision",
+ "id": "23adc029-c0b1-449a-ac0e-bd6b407dec78",
+ "createTime": "2023-06-28T19:08:57.092Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "4.2.3",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/video-intelligence",
+ "id": "50983ac6-f134-4498-b890-2386f0a33a77",
+ "createTime": "2023-06-28T19:08:57.088Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "7.2.2",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/translate",
+ "id": "b37213da-a350-4893-8d69-9847df5175d2",
+ "createTime": "2023-06-28T19:08:57.084Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "4.2.3",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/text-to-speech",
+ "id": "235e35dc-6f8e-47dc-8706-212003be678c",
+ "createTime": "2023-06-28T19:08:57.080Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "5.1.4",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/talent",
+ "id": "beb6888d-121e-45f8-8e50-373a312f88b7",
+ "createTime": "2023-06-28T19:08:57.077Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "5.5.1",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/speech",
+ "id": "3ef0dba7-b1a9-4928-8929-838ceedf9413",
+ "createTime": "2023-06-28T19:08:57.074Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "644e6762afb8653592fe3e4ab988a8e3c6f549a4",
+ "message": "[securitycenter] Mark the Asset APIs as deprecated in client libraries",
+ "issues": [
+ "4370"
+ ]
+ }
+ ],
+ "version": "7.6.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/security-center",
+ "id": "6e8d76d4-8055-4a3a-9591-73d28b997d2b",
+ "createTime": "2023-06-28T19:08:57.070Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "eca06233d65148c564133150c1fa13522988a9af",
+ "message": "[networkmanagement] add forwarding_rule field to Connectivity Test Endpoint proto",
+ "issues": [
+ "4371"
+ ]
+ }
+ ],
+ "version": "2.5.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/network-management",
+ "id": "88de3a3d-2801-4c7a-8dd4-31a2a9e21cf8",
+ "createTime": "2023-06-28T19:08:57.066Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "3.0.5",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/monitoring",
+ "id": "2e0d7e1b-b0e5-4083-b9dc-c87701f8c1be",
+ "createTime": "2023-06-28T19:08:57.062Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "3.2.3",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/iot",
+ "id": "7e73e5f0-f3c0-49a7-9c03-2a5d87a60ce6",
+ "createTime": "2023-06-28T19:08:57.058Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "b2dca930afe3368815935bbc45915fa89ee5cfc3",
+ "message": "[gkebackup] added new restore scope options",
+ "issues": [
+ "4377"
+ ]
+ }
+ ],
+ "version": "0.4.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/gke-backup",
+ "id": "45139f18-6043-49a2-ae39-0e71df83d499",
+ "createTime": "2023-06-28T19:08:57.055Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "aa7da8ca580b7ee92aede81711033e97fc23e396",
+ "message": "[essentialcontacts] mark fields in Contacts message as REQUIRED",
+ "issues": [
+ "4368"
+ ]
+ }
+ ],
+ "version": "2.1.3",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/essential-contacts",
+ "id": "0dd7c88a-88ac-4eab-b7be-6be7a8c1b38a",
+ "createTime": "2023-06-28T19:08:57.052Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "512ef37b330c16029bd0a2721efe07ce9a31f90b",
+ "message": "Add IMPORTING enum to State in processor.proto",
+ "issues": []
+ },
+ {
+ "type": "feat",
+ "sha": "512ef37b330c16029bd0a2721efe07ce9a31f90b",
+ "message": "[documentai] add StyleInfo to document.proto",
+ "issues": [
+ "4352"
+ ]
+ },
+ {
+ "type": "feat",
+ "sha": "512ef37b330c16029bd0a2721efe07ce9a31f90b",
+ "message": "Add REPLACE enum to OperationType in document.proto",
+ "issues": []
+ },
+ {
+ "type": "feat",
+ "sha": "512ef37b330c16029bd0a2721efe07ce9a31f90b",
+ "message": "Add PropertyMetadata and EntityTypeMetadata to document_schema.proto",
+ "issues": []
+ },
+ {
+ "type": "feat",
+ "sha": "512ef37b330c16029bd0a2721efe07ce9a31f90b",
+ "message": "Add IMPORTING enum to State in processor.proto",
+ "issues": []
+ },
+ {
+ "type": "feat",
+ "sha": "512ef37b330c16029bd0a2721efe07ce9a31f90b",
+ "message": "[documentai] add StyleInfo to document.proto",
+ "issues": []
+ }
+ ],
+ "version": "7.4.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/documentai",
+ "id": "2b5ab396-44de-461d-a609-e49f63897892",
+ "createTime": "2023-06-28T19:08:57.048Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "5958cfa56bd5280301f446a8863d6461ea86493e",
+ "message": "[discoveryengine] support extractive content in search",
+ "issues": [
+ "4355"
+ ]
+ }
+ ],
+ "version": "0.8.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/discoveryengine",
+ "id": "23694015-a7ac-4473-8b0f-3554a9154ba9",
+ "createTime": "2023-06-28T19:08:57.042Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "7778345f3d7089e3bdc1294beb4005cfa8793012",
+ "message": "Added session_ttl to SessionProto",
+ "issues": []
+ },
+ {
+ "type": "feat",
+ "sha": "7778345f3d7089e3bdc1294beb4005cfa8793012",
+ "message": "[dialogflow-cx] added include_bigquery_export_settings to ExportAgentRequest",
+ "issues": [
+ "4357"
+ ]
+ },
+ {
+ "type": "feat",
+ "sha": "7778345f3d7089e3bdc1294beb4005cfa8793012",
+ "message": "Added session_ttl to SessionProto",
+ "issues": []
+ },
+ {
+ "type": "feat",
+ "sha": "7778345f3d7089e3bdc1294beb4005cfa8793012",
+ "message": "[dialogflow-cx] added include_bigquery_export_settings to ExportAgentRequest",
+ "issues": []
+ }
+ ],
+ "version": "3.7.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/dialogflow-cx",
+ "id": "99fd5f77-0fdc-4091-8a55-6e6346029be9",
+ "createTime": "2023-06-28T19:08:57.038Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "2339f4d2c62fda48c745f4dde3f071fa4346fc9b",
+ "message": "[dialogflow] added dialogflow_assist_answer",
+ "issues": [
+ "4364"
+ ]
+ },
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "5.9.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/dialogflow",
+ "id": "5bc374aa-c84a-4e40-aa32-edcf445434da",
+ "createTime": "2023-06-28T19:08:57.035Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "dd8b0ec2df1c39330e1a104de55e809d9a31a1a9",
+ "message": "[deploy] Add deploy parameters for cloud deploy",
+ "issues": [
+ "4367"
+ ]
+ }
+ ],
+ "version": "2.7.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/deploy",
+ "id": "919b0dcc-092f-48ae-8da0-105e1a309553",
+ "createTime": "2023-06-28T19:08:57.032Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "926d727f25951f9199e3f02d419a41dbb8e1c824",
+ "message": "[channel] Add support for ListSkuGroups and ListSkuGroupBillableSkus APIs in Cloud Channel APIs",
+ "issues": [
+ "4348"
+ ]
+ }
+ ],
+ "version": "2.8.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/channel",
+ "id": "c0715d6a-81b8-48c2-afec-378dc4acd58a",
+ "createTime": "2023-06-28T19:08:57.028Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "a77e51fe3fc235676189525f6a582844a830cc99",
+ "message": "[billing] added resource_reference for name in GetProjectBillingInfoRequest message",
+ "issues": [
+ "4356"
+ ]
+ }
+ ],
+ "version": "3.4.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/billing",
+ "id": "c45bf071-ac2c-4326-a7a7-0ba564abd257",
+ "createTime": "2023-06-28T19:08:57.021Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "fix",
+ "sha": "4fb528559c204cee33329c4e55021aa1fd0e4974",
+ "message": "Update dependency yargs to v17",
+ "issues": [
+ "4351"
+ ],
+ "scope": "deps"
+ }
+ ],
+ "version": "4.6.4",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/asset",
+ "id": "0204a8ca-fe02-48f4-8e11-1e6ed2b8583b",
+ "createTime": "2023-06-28T19:08:57.017Z"
+ },
+ {
+ "changes": [
+ {
+ "type": "feat",
+ "sha": "c0a3d8a1df6b319e555955dfef8a56ceef54a6e2",
+ "message": "Add UpdateExplanationDataset to aiplatform",
+ "issues": [
+ "4359"
+ ]
+ },
+ {
+ "type": "feat",
+ "sha": "4c047d4a9cdbc08dfb70e3843a54ca73ad1f4e79",
+ "message": "Add bias_configs to ModelEvaluation",
+ "issues": [
+ "4349"
+ ]
+ }
+ ],
+ "version": "2.16.0",
+ "language": "JAVASCRIPT",
+ "artifactName": "@google-cloud/aiplatform",
+ "id": "021b815c-227f-465c-95c2-8c0d3285e366",
+ "createTime": "2023-06-28T19:08:57.014Z"
+ },
{
"changes": [
{
@@ -10297,5 +10882,5 @@
"createTime": "2023-01-28T04:18:24.718Z"
}
],
- "updateTime": "2023-06-14T23:55:54.096Z"
+ "updateTime": "2023-07-04T14:41:00.186Z"
}
\ No newline at end of file
diff --git a/libraries.json b/libraries.json
index 14a2675a06a..144eaeb14d3 100644
--- a/libraries.json
+++ b/libraries.json
@@ -2792,6 +2792,24 @@
"linkToRepoHomepage": "https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-security-publicca",
"support_documentation": "https://cloud.google.com/certificate-manager/docs/getting-support"
},
+ {
+ "name": "rapidmigrationassessment",
+ "name_pretty": "Rapid Migration Assessment API",
+ "product_documentation": "https://cloud.google.com/migration-center/docs",
+ "client_documentation": "https://cloud.google.com/nodejs/docs/reference/rapidmigrationassessment/latest",
+ "issue_tracker": "https://github.com/googleapis/google-cloud-node/issues",
+ "release_level": "preview",
+ "language": "nodejs",
+ "repo": "googleapis/google-cloud-node",
+ "distribution_name": "@google-cloud/rapidmigrationassessment",
+ "api_id": "rapidmigrationassessment.googleapis.com",
+ "default_version": "v1",
+ "requires_billing": true,
+ "library_type": "GAPIC_AUTO",
+ "api_shortname": "rapidmigrationassessment",
+ "linkToRepoHomepage": "https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-rapidmigrationassessment",
+ "support_documentation": "https://cloud.google.com/migration-center/docs/getting-support"
+ },
{
"name": "storageinsights",
"name_pretty": "Storage Insights API",
diff --git a/packages/google-ai-generativelanguage/CHANGELOG.md b/packages/google-ai-generativelanguage/CHANGELOG.md
index e99d90027e4..b644a1b40db 100644
--- a/packages/google-ai-generativelanguage/CHANGELOG.md
+++ b/packages/google-ai-generativelanguage/CHANGELOG.md
@@ -1,5 +1,12 @@
# Changelog
+## [0.2.1](https://github.com/googleapis/google-cloud-node/compare/generativelanguage-v0.2.0...generativelanguage-v0.2.1) (2023-07-04)
+
+
+### Bug Fixes
+
+* [generativelanguage] Update safety protos ([#4382](https://github.com/googleapis/google-cloud-node/issues/4382)) ([d06c733](https://github.com/googleapis/google-cloud-node/commit/d06c733eac7699f2a10853b150cfdeae464a9962))
+
## [0.2.0](https://github.com/googleapis/google-cloud-node/compare/generativelanguage-v0.1.1...generativelanguage-v0.2.0) (2023-05-06)
diff --git a/packages/google-ai-generativelanguage/package.json b/packages/google-ai-generativelanguage/package.json
index 14f8c87c695..ef82602c83f 100644
--- a/packages/google-ai-generativelanguage/package.json
+++ b/packages/google-ai-generativelanguage/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-ai/generativelanguage",
- "version": "0.2.0",
+ "version": "0.2.1",
"description": "Generative Language API client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/discuss_service.proto b/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/discuss_service.proto
index f4d0d6915e7..051e3dc2dd7 100644
--- a/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/discuss_service.proto
+++ b/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/discuss_service.proto
@@ -124,11 +124,6 @@ message GenerateMessageResponse {
// This indicates which `SafetyCategory`(s) blocked a
// candidate from this response, the lowest `HarmProbability`
// that triggered a block, and the HarmThreshold setting for that category.
- // This indicates the smallest change to the `SafetySettings` that would be
- // necessary to unblock at least 1 response.
- //
- // The blocking is configured by the `SafetySettings` in the request (or the
- // default `SafetySettings` of the API).
repeated ContentFilter filters = 3;
}
@@ -211,11 +206,11 @@ message MessagePrompt {
//
// It demonstrates how the model should respond or format its response.
message Example {
- // An example of an input `Message` from the user.
- Message input = 1;
+ // Required. An example of an input `Message` from the user.
+ Message input = 1 [(google.api.field_behavior) = REQUIRED];
- // An example of what the model should output given the input.
- Message output = 2;
+ // Required. An example of what the model should output given the input.
+ Message output = 2 [(google.api.field_behavior) = REQUIRED];
}
// Counts the number of tokens in the `prompt` sent to a model.
diff --git a/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/safety.proto b/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/safety.proto
index 70f420d7d43..697e725d977 100644
--- a/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/safety.proto
+++ b/packages/google-ai-generativelanguage/protos/google/ai/generativelanguage/v1beta2/safety.proto
@@ -144,9 +144,6 @@ message SafetySetting {
// Content with NEGLIGIBLE, LOW, and MEDIUM will be allowed.
BLOCK_ONLY_HIGH = 3;
-
- // All content will be allowed.
- BLOCK_NONE = 4;
}
// Required. The category for this setting.
diff --git a/packages/google-ai-generativelanguage/protos/protos.d.ts b/packages/google-ai-generativelanguage/protos/protos.d.ts
index 3260a9a0d74..fca606c71f8 100644
--- a/packages/google-ai-generativelanguage/protos/protos.d.ts
+++ b/packages/google-ai-generativelanguage/protos/protos.d.ts
@@ -1543,8 +1543,7 @@ export namespace google {
HARM_BLOCK_THRESHOLD_UNSPECIFIED = 0,
BLOCK_LOW_AND_ABOVE = 1,
BLOCK_MEDIUM_AND_ABOVE = 2,
- BLOCK_ONLY_HIGH = 3,
- BLOCK_NONE = 4
+ BLOCK_ONLY_HIGH = 3
}
}
diff --git a/packages/google-ai-generativelanguage/protos/protos.js b/packages/google-ai-generativelanguage/protos/protos.js
index af3afab1ab4..9a9716f513b 100644
--- a/packages/google-ai-generativelanguage/protos/protos.js
+++ b/packages/google-ai-generativelanguage/protos/protos.js
@@ -3705,7 +3705,6 @@
case 1:
case 2:
case 3:
- case 4:
break;
}
return null;
@@ -3782,10 +3781,6 @@
case 3:
message.threshold = 3;
break;
- case "BLOCK_NONE":
- case 4:
- message.threshold = 4;
- break;
}
return message;
};
@@ -3848,7 +3843,6 @@
* @property {number} BLOCK_LOW_AND_ABOVE=1 BLOCK_LOW_AND_ABOVE value
* @property {number} BLOCK_MEDIUM_AND_ABOVE=2 BLOCK_MEDIUM_AND_ABOVE value
* @property {number} BLOCK_ONLY_HIGH=3 BLOCK_ONLY_HIGH value
- * @property {number} BLOCK_NONE=4 BLOCK_NONE value
*/
SafetySetting.HarmBlockThreshold = (function() {
var valuesById = {}, values = Object.create(valuesById);
@@ -3856,7 +3850,6 @@
values[valuesById[1] = "BLOCK_LOW_AND_ABOVE"] = 1;
values[valuesById[2] = "BLOCK_MEDIUM_AND_ABOVE"] = 2;
values[valuesById[3] = "BLOCK_ONLY_HIGH"] = 3;
- values[valuesById[4] = "BLOCK_NONE"] = 4;
return values;
})();
diff --git a/packages/google-ai-generativelanguage/protos/protos.json b/packages/google-ai-generativelanguage/protos/protos.json
index 095935ef9cf..543d72e639c 100644
--- a/packages/google-ai-generativelanguage/protos/protos.json
+++ b/packages/google-ai-generativelanguage/protos/protos.json
@@ -284,11 +284,17 @@
"fields": {
"input": {
"type": "Message",
- "id": 1
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
},
"output": {
"type": "Message",
- "id": 2
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
}
}
},
@@ -425,8 +431,7 @@
"HARM_BLOCK_THRESHOLD_UNSPECIFIED": 0,
"BLOCK_LOW_AND_ABOVE": 1,
"BLOCK_MEDIUM_AND_ABOVE": 2,
- "BLOCK_ONLY_HIGH": 3,
- "BLOCK_NONE": 4
+ "BLOCK_ONLY_HIGH": 3
}
}
}
diff --git a/packages/google-ai-generativelanguage/samples/generated/v1beta2/snippet_metadata.google.ai.generativelanguage.v1beta2.json b/packages/google-ai-generativelanguage/samples/generated/v1beta2/snippet_metadata.google.ai.generativelanguage.v1beta2.json
index a8da09ae8dc..671009e9a5a 100644
--- a/packages/google-ai-generativelanguage/samples/generated/v1beta2/snippet_metadata.google.ai.generativelanguage.v1beta2.json
+++ b/packages/google-ai-generativelanguage/samples/generated/v1beta2/snippet_metadata.google.ai.generativelanguage.v1beta2.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-generativelanguage",
- "version": "0.2.0",
+ "version": "0.2.1",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-ai-generativelanguage/samples/package.json b/packages/google-ai-generativelanguage/samples/package.json
index 917440df604..6ce2387078e 100644
--- a/packages/google-ai-generativelanguage/samples/package.json
+++ b/packages/google-ai-generativelanguage/samples/package.json
@@ -14,7 +14,7 @@
"publish": "echo 'sample test; do not publish'"
},
"dependencies": {
- "@google-ai/generativelanguage": "^0.2.0"
+ "@google-ai/generativelanguage": "^0.2.1"
},
"devDependencies": {
"c8": "^7.1.0",
diff --git a/packages/google-analytics-admin/protos/google/analytics/admin/v1alpha/resources.proto b/packages/google-analytics-admin/protos/google/analytics/admin/v1alpha/resources.proto
index d4f9101cae6..7b2e82a7c6a 100644
--- a/packages/google-analytics-admin/protos/google/analytics/admin/v1alpha/resources.proto
+++ b/packages/google-analytics-admin/protos/google/analytics/admin/v1alpha/resources.proto
@@ -439,17 +439,18 @@ message DataStream {
// Data specific to web streams.
message WebStreamData {
- // Output only. Analytics "Measurement ID", without the "G-" prefix.
- // Example: "G-1A2BCD345E" would just be "1A2BCD345E"
+ // Output only. Analytics Measurement ID.
+ //
+ // Example: "G-1A2BCD345E"
string measurement_id = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
// Output only. ID of the corresponding web app in Firebase, if any.
// This ID can change if the web app is deleted and recreated.
string firebase_app_id = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
- // Immutable. Domain name of the web app being measured, or empty.
+ // Domain name of the web app being measured, or empty.
// Example: "http://www.google.com", "https://www.google.com"
- string default_uri = 3 [(google.api.field_behavior) = IMMUTABLE];
+ string default_uri = 3;
}
// Data specific to Android app streams.
@@ -1380,19 +1381,47 @@ message AttributionSettings {
// for YouTube) before converting.
CROSS_CHANNEL_LAST_CLICK = 2;
+ // Starting in June 2023, new properties can no longer use this model.
+ // See
+ // [Analytics
+ // Help](https://support.google.com/analytics/answer/9164320?hl=en#040623)
+ // for more details.
+ // Starting in September 2023, we will sunset this model for all properties.
+ //
// Gives all credit for the conversion to the first channel that a customer
// clicked (or engaged view through for YouTube) before converting.
CROSS_CHANNEL_FIRST_CLICK = 3;
+ // Starting in June 2023, new properties can no longer use this model.
+ // See
+ // [Analytics
+ // Help](https://support.google.com/analytics/answer/9164320?hl=en#040623)
+ // for more details.
+ // Starting in September 2023, we will sunset this model for all properties.
+ //
// Distributes the credit for the conversion equally across all the channels
// a customer clicked (or engaged view through for YouTube) before
// converting.
CROSS_CHANNEL_LINEAR = 4;
+ // Starting in June 2023, new properties can no longer use this model.
+ // See
+ // [Analytics
+ // Help](https://support.google.com/analytics/answer/9164320?hl=en#040623)
+ // for more details.
+ // Starting in September 2023, we will sunset this model for all properties.
+ //
// Attributes 40% credit to the first and last interaction, and the
// remaining 20% credit is distributed evenly to the middle interactions.
CROSS_CHANNEL_POSITION_BASED = 5;
+ // Starting in June 2023, new properties can no longer use this model.
+ // See
+ // [Analytics
+ // Help](https://support.google.com/analytics/answer/9164320?hl=en#040623)
+ // for more details.
+ // Starting in September 2023, we will sunset this model for all properties.
+ //
// Gives more credit to the touchpoints that happened closer in time to
// the conversion.
CROSS_CHANNEL_TIME_DECAY = 6;
@@ -1402,6 +1431,22 @@ message AttributionSettings {
ADS_PREFERRED_LAST_CLICK = 7;
}
+ // The Conversion Export Scope for data exported to linked Ads Accounts.
+ enum AdsWebConversionDataExportScope {
+ // Default value. This value is unused.
+ ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED = 0;
+
+ // No data export scope selected yet.
+ // Export scope can never be changed back to this value.
+ NOT_SELECTED_YET = 1;
+
+ // The Ads Web Conversion Data export scope is Cross Channel.
+ CROSS_CHANNEL = 2;
+
+ // The Ads Web Conversion Data export scope is Ads Preferred.
+ ADS_PREFERRED = 3;
+ }
+
// Output only. Resource name of this attribution settings resource.
// Format: properties/{property_id}/attributionSettings
// Example: "properties/1000/attributionSettings"
@@ -1426,6 +1471,11 @@ message AttributionSettings {
// revenue data. User and session data will be unaffected.
ReportingAttributionModel reporting_attribution_model = 4
[(google.api.field_behavior) = REQUIRED];
+
+ // Required. The Conversion Export Scope for data exported to linked Ads
+ // Accounts.
+ AdsWebConversionDataExportScope ads_web_conversion_data_export_scope = 5
+ [(google.api.field_behavior) = REQUIRED];
}
// A binding of a user to a set of roles.
@@ -1514,7 +1564,7 @@ message BigQueryLink {
repeated string excluded_events = 8;
}
-// Singleton resource under a WebDataStream, configuring measurement of
+// Singleton resource under a web DataStream, configuring measurement of
// additional site interactions and content.
message EnhancedMeasurementSettings {
option (google.api.resource) = {
diff --git a/packages/google-analytics-admin/protos/protos.d.ts b/packages/google-analytics-admin/protos/protos.d.ts
index cd7f6b230e2..1be3a022d57 100644
--- a/packages/google-analytics-admin/protos/protos.d.ts
+++ b/packages/google-analytics-admin/protos/protos.d.ts
@@ -28277,6 +28277,9 @@ export namespace google {
/** AttributionSettings reportingAttributionModel */
reportingAttributionModel?: (google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel|keyof typeof google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel|null);
+
+ /** AttributionSettings adsWebConversionDataExportScope */
+ adsWebConversionDataExportScope?: (google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope|keyof typeof google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope|null);
}
/** Represents an AttributionSettings. */
@@ -28300,6 +28303,9 @@ export namespace google {
/** AttributionSettings reportingAttributionModel. */
public reportingAttributionModel: (google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel|keyof typeof google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel);
+ /** AttributionSettings adsWebConversionDataExportScope. */
+ public adsWebConversionDataExportScope: (google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope|keyof typeof google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope);
+
/**
* Creates a new AttributionSettings instance using the specified properties.
* @param [properties] Properties to set
@@ -28406,6 +28412,14 @@ export namespace google {
CROSS_CHANNEL_TIME_DECAY = 6,
ADS_PREFERRED_LAST_CLICK = 7
}
+
+ /** AdsWebConversionDataExportScope enum. */
+ enum AdsWebConversionDataExportScope {
+ ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED = 0,
+ NOT_SELECTED_YET = 1,
+ CROSS_CHANNEL = 2,
+ ADS_PREFERRED = 3
+ }
}
/** Properties of an AccessBinding. */
diff --git a/packages/google-analytics-admin/protos/protos.js b/packages/google-analytics-admin/protos/protos.js
index 7c3a29f4aa8..80edd25d5bd 100644
--- a/packages/google-analytics-admin/protos/protos.js
+++ b/packages/google-analytics-admin/protos/protos.js
@@ -65556,6 +65556,7 @@
* @property {google.analytics.admin.v1alpha.AttributionSettings.AcquisitionConversionEventLookbackWindow|null} [acquisitionConversionEventLookbackWindow] AttributionSettings acquisitionConversionEventLookbackWindow
* @property {google.analytics.admin.v1alpha.AttributionSettings.OtherConversionEventLookbackWindow|null} [otherConversionEventLookbackWindow] AttributionSettings otherConversionEventLookbackWindow
* @property {google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel|null} [reportingAttributionModel] AttributionSettings reportingAttributionModel
+ * @property {google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope|null} [adsWebConversionDataExportScope] AttributionSettings adsWebConversionDataExportScope
*/
/**
@@ -65605,6 +65606,14 @@
*/
AttributionSettings.prototype.reportingAttributionModel = 0;
+ /**
+ * AttributionSettings adsWebConversionDataExportScope.
+ * @member {google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope} adsWebConversionDataExportScope
+ * @memberof google.analytics.admin.v1alpha.AttributionSettings
+ * @instance
+ */
+ AttributionSettings.prototype.adsWebConversionDataExportScope = 0;
+
/**
* Creates a new AttributionSettings instance using the specified properties.
* @function create
@@ -65637,6 +65646,8 @@
writer.uint32(/* id 3, wireType 0 =*/24).int32(message.otherConversionEventLookbackWindow);
if (message.reportingAttributionModel != null && Object.hasOwnProperty.call(message, "reportingAttributionModel"))
writer.uint32(/* id 4, wireType 0 =*/32).int32(message.reportingAttributionModel);
+ if (message.adsWebConversionDataExportScope != null && Object.hasOwnProperty.call(message, "adsWebConversionDataExportScope"))
+ writer.uint32(/* id 5, wireType 0 =*/40).int32(message.adsWebConversionDataExportScope);
return writer;
};
@@ -65687,6 +65698,10 @@
message.reportingAttributionModel = reader.int32();
break;
}
+ case 5: {
+ message.adsWebConversionDataExportScope = reader.int32();
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -65758,6 +65773,16 @@
case 7:
break;
}
+ if (message.adsWebConversionDataExportScope != null && message.hasOwnProperty("adsWebConversionDataExportScope"))
+ switch (message.adsWebConversionDataExportScope) {
+ default:
+ return "adsWebConversionDataExportScope: enum value expected";
+ case 0:
+ case 1:
+ case 2:
+ case 3:
+ break;
+ }
return null;
};
@@ -65859,6 +65884,30 @@
message.reportingAttributionModel = 7;
break;
}
+ switch (object.adsWebConversionDataExportScope) {
+ default:
+ if (typeof object.adsWebConversionDataExportScope === "number") {
+ message.adsWebConversionDataExportScope = object.adsWebConversionDataExportScope;
+ break;
+ }
+ break;
+ case "ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED":
+ case 0:
+ message.adsWebConversionDataExportScope = 0;
+ break;
+ case "NOT_SELECTED_YET":
+ case 1:
+ message.adsWebConversionDataExportScope = 1;
+ break;
+ case "CROSS_CHANNEL":
+ case 2:
+ message.adsWebConversionDataExportScope = 2;
+ break;
+ case "ADS_PREFERRED":
+ case 3:
+ message.adsWebConversionDataExportScope = 3;
+ break;
+ }
return message;
};
@@ -65880,6 +65929,7 @@
object.acquisitionConversionEventLookbackWindow = options.enums === String ? "ACQUISITION_CONVERSION_EVENT_LOOKBACK_WINDOW_UNSPECIFIED" : 0;
object.otherConversionEventLookbackWindow = options.enums === String ? "OTHER_CONVERSION_EVENT_LOOKBACK_WINDOW_UNSPECIFIED" : 0;
object.reportingAttributionModel = options.enums === String ? "REPORTING_ATTRIBUTION_MODEL_UNSPECIFIED" : 0;
+ object.adsWebConversionDataExportScope = options.enums === String ? "ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED" : 0;
}
if (message.name != null && message.hasOwnProperty("name"))
object.name = message.name;
@@ -65889,6 +65939,8 @@
object.otherConversionEventLookbackWindow = options.enums === String ? $root.google.analytics.admin.v1alpha.AttributionSettings.OtherConversionEventLookbackWindow[message.otherConversionEventLookbackWindow] === undefined ? message.otherConversionEventLookbackWindow : $root.google.analytics.admin.v1alpha.AttributionSettings.OtherConversionEventLookbackWindow[message.otherConversionEventLookbackWindow] : message.otherConversionEventLookbackWindow;
if (message.reportingAttributionModel != null && message.hasOwnProperty("reportingAttributionModel"))
object.reportingAttributionModel = options.enums === String ? $root.google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel[message.reportingAttributionModel] === undefined ? message.reportingAttributionModel : $root.google.analytics.admin.v1alpha.AttributionSettings.ReportingAttributionModel[message.reportingAttributionModel] : message.reportingAttributionModel;
+ if (message.adsWebConversionDataExportScope != null && message.hasOwnProperty("adsWebConversionDataExportScope"))
+ object.adsWebConversionDataExportScope = options.enums === String ? $root.google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope[message.adsWebConversionDataExportScope] === undefined ? message.adsWebConversionDataExportScope : $root.google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope[message.adsWebConversionDataExportScope] : message.adsWebConversionDataExportScope;
return object;
};
@@ -65978,6 +66030,24 @@
return values;
})();
+ /**
+ * AdsWebConversionDataExportScope enum.
+ * @name google.analytics.admin.v1alpha.AttributionSettings.AdsWebConversionDataExportScope
+ * @enum {number}
+ * @property {number} ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED=0 ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED value
+ * @property {number} NOT_SELECTED_YET=1 NOT_SELECTED_YET value
+ * @property {number} CROSS_CHANNEL=2 CROSS_CHANNEL value
+ * @property {number} ADS_PREFERRED=3 ADS_PREFERRED value
+ */
+ AttributionSettings.AdsWebConversionDataExportScope = (function() {
+ var valuesById = {}, values = Object.create(valuesById);
+ values[valuesById[0] = "ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED"] = 0;
+ values[valuesById[1] = "NOT_SELECTED_YET"] = 1;
+ values[valuesById[2] = "CROSS_CHANNEL"] = 2;
+ values[valuesById[3] = "ADS_PREFERRED"] = 3;
+ return values;
+ })();
+
return AttributionSettings;
})();
diff --git a/packages/google-analytics-admin/protos/protos.json b/packages/google-analytics-admin/protos/protos.json
index 36aea395127..a51804dd447 100644
--- a/packages/google-analytics-admin/protos/protos.json
+++ b/packages/google-analytics-admin/protos/protos.json
@@ -6376,10 +6376,7 @@
},
"defaultUri": {
"type": "string",
- "id": 3,
- "options": {
- "(google.api.field_behavior)": "IMMUTABLE"
- }
+ "id": 3
}
}
},
@@ -7341,6 +7338,13 @@
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
+ },
+ "adsWebConversionDataExportScope": {
+ "type": "AdsWebConversionDataExportScope",
+ "id": 5,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
}
},
"nested": {
@@ -7370,6 +7374,14 @@
"CROSS_CHANNEL_TIME_DECAY": 6,
"ADS_PREFERRED_LAST_CLICK": 7
}
+ },
+ "AdsWebConversionDataExportScope": {
+ "values": {
+ "ADS_WEB_CONVERSION_DATA_EXPORT_SCOPE_UNSPECIFIED": 0,
+ "NOT_SELECTED_YET": 1,
+ "CROSS_CHANNEL": 2,
+ "ADS_PREFERRED": 3
+ }
}
}
},
diff --git a/packages/google-api-servicemanagement/README.md b/packages/google-api-servicemanagement/README.md
index c06de65d8bf..1521d9ac5b5 100644
--- a/packages/google-api-servicemanagement/README.md
+++ b/packages/google-api-servicemanagement/README.md
@@ -2,7 +2,7 @@
[//]: # "To regenerate it, use `python -m synthtool`."
-# [Service Management API: Node.js Client](https://github.com/googleapis/google-cloud-node)
+# [Service Management API: Node.js Client](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-api-servicemanagement)
[](https://cloud.google.com/terms/launch-stages)
[](https://www.npmjs.org/package/@google-cloud/service-management)
@@ -81,27 +81,26 @@ listServices();
## Samples
-Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/tree/main/samples) directory. Each sample's `README.md` has instructions for running its sample.
+Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-api-servicemanagement/samples) directory. Each sample's `README.md` has instructions for running its sample.
| Sample | Source Code | Try it |
| --------------------------- | --------------------------------- | ------ |
-| Service_manager.create_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service.js,samples/README.md) |
-| Service_manager.create_service_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js,samples/README.md) |
-| Service_manager.create_service_rollout | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js,samples/README.md) |
-| Service_manager.delete_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js,samples/README.md) |
-| Service_manager.disable_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.disable_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.disable_service.js,samples/README.md) |
-| Service_manager.enable_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.enable_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.enable_service.js,samples/README.md) |
-| Service_manager.generate_config_report | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.generate_config_report.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.generate_config_report.js,samples/README.md) |
-| Service_manager.get_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service.js,samples/README.md) |
-| Service_manager.get_service_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js,samples/README.md) |
-| Service_manager.get_service_rollout | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js,samples/README.md) |
-| Service_manager.list_service_configs | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js,samples/README.md) |
-| Service_manager.list_service_rollouts | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js,samples/README.md) |
-| Service_manager.list_services | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js,samples/README.md) |
-| Service_manager.submit_config_source | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js,samples/README.md) |
-| Service_manager.undelete_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js,samples/README.md) |
-| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/quickstart.js,samples/README.md) |
-| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/test/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/test/quickstart.js,samples/README.md) |
+| Service_manager.create_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.create_service_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.create_service_rollout | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.delete_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.disable_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.disable_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.disable_service.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.enable_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.enable_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.enable_service.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.generate_config_report | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.generate_config_report.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.generate_config_report.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.get_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.get_service_config | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.get_service_rollout | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.list_service_configs | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.list_service_rollouts | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.list_services | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.submit_config_source | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js,packages/google-api-servicemanagement/samples/README.md) |
+| Service_manager.undelete_service | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js,packages/google-api-servicemanagement/samples/README.md) |
+| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/quickstart.js,packages/google-api-servicemanagement/samples/README.md) |
diff --git a/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/resources.proto b/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/resources.proto
index 4769a8ee006..fd984dd1e07 100644
--- a/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/resources.proto
+++ b/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/resources.proto
@@ -1,4 +1,4 @@
-// Copyright 2022 Google LLC
+// Copyright 2023 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
diff --git a/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/servicemanager.proto b/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/servicemanager.proto
index 1f6d6a9e5cd..0aa966c59bd 100644
--- a/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/servicemanager.proto
+++ b/packages/google-api-servicemanagement/protos/google/api/servicemanagement/v1/servicemanager.proto
@@ -1,4 +1,4 @@
-// Copyright 2022 Google LLC
+// Copyright 2023 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -23,6 +23,7 @@ import "google/api/service.proto";
import "google/api/servicemanagement/v1/resources.proto";
import "google/longrunning/operations.proto";
import "google/protobuf/any.proto";
+import "google/protobuf/empty.proto";
option csharp_namespace = "Google.Cloud.ServiceManagement.V1";
option go_package = "cloud.google.com/go/servicemanagement/apiv1/servicemanagementpb;servicemanagementpb";
@@ -263,7 +264,7 @@ message ListServicesRequest {
string producer_project_id = 1;
// The max number of items to include in the response list. Page size is 50
- // if not specified. Maximum value is 100.
+ // if not specified. Maximum value is 500.
int32 page_size = 5;
// Token identifying which result to start with; returned by a previous list
@@ -303,16 +304,16 @@ message CreateServiceRequest {
// Request message for DeleteService method.
message DeleteServiceRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
}
// Request message for UndeleteService method.
message UndeleteServiceRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
}
@@ -336,8 +337,8 @@ message GetServiceConfigRequest {
}
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// Required. The id of the service configuration resource.
@@ -354,8 +355,8 @@ message GetServiceConfigRequest {
// Request message for ListServiceConfigs method.
message ListServiceConfigsRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// The token of the page to retrieve.
@@ -378,8 +379,8 @@ message ListServiceConfigsResponse {
// Request message for CreateServiceConfig method.
message CreateServiceConfigRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// Required. The service configuration resource.
@@ -390,8 +391,8 @@ message CreateServiceConfigRequest {
// Request message for SubmitConfigSource method.
message SubmitConfigSourceRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// Required. The source configuration for the service.
@@ -409,11 +410,12 @@ message SubmitConfigSourceResponse {
google.api.Service service_config = 1;
}
+//
// Request message for 'CreateServiceRollout'
message CreateServiceRolloutRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// Required. The rollout resource. The `service_name` field is output only.
@@ -423,8 +425,8 @@ message CreateServiceRolloutRequest {
// Request message for 'ListServiceRollouts'
message ListServiceRolloutsRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// The token of the page to retrieve.
@@ -436,12 +438,14 @@ message ListServiceRolloutsRequest {
// Required. Use `filter` to return subset of rollouts.
// The following filters are supported:
- // -- To limit the results to only those in
- // status (google.api.servicemanagement.v1.RolloutStatus) 'SUCCESS',
- // use filter='status=SUCCESS'
- // -- To limit the results to those in
- // status (google.api.servicemanagement.v1.RolloutStatus) 'CANCELLED'
- // or 'FAILED', use filter='status=CANCELLED OR status=FAILED'
+ //
+ // -- By [status]
+ // [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example,
+ // `filter='status=SUCCESS'`
+ //
+ // -- By [strategy]
+ // [google.api.servicemanagement.v1.Rollout.strategy]. For example,
+ // `filter='strategy=TrafficPercentStrategy'`
string filter = 4 [(google.api.field_behavior) = REQUIRED];
}
@@ -457,14 +461,17 @@ message ListServiceRolloutsResponse {
// Request message for GetServiceRollout method.
message GetServiceRolloutRequest {
// Required. The name of the service. See the
- // [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- // example: `example.googleapis.com`.
+ // [overview](https://cloud.google.com/service-management/overview) for naming
+ // requirements. For example: `example.googleapis.com`.
string service_name = 1 [(google.api.field_behavior) = REQUIRED];
// Required. The id of the rollout resource.
string rollout_id = 2 [(google.api.field_behavior) = REQUIRED];
}
+// Operation payload for EnableService method.
+message EnableServiceResponse {}
+
// Request message for GenerateConfigReport method.
message GenerateConfigReportRequest {
// Required. Service configuration for which we want to generate the report.
diff --git a/packages/google-api-servicemanagement/protos/protos.d.ts b/packages/google-api-servicemanagement/protos/protos.d.ts
index 3ed31a4b85f..1a9d7509f73 100644
--- a/packages/google-api-servicemanagement/protos/protos.d.ts
+++ b/packages/google-api-servicemanagement/protos/protos.d.ts
@@ -3298,6 +3298,97 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ /** Properties of an EnableServiceResponse. */
+ interface IEnableServiceResponse {
+ }
+
+ /** Represents an EnableServiceResponse. */
+ class EnableServiceResponse implements IEnableServiceResponse {
+
+ /**
+ * Constructs a new EnableServiceResponse.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.api.servicemanagement.v1.IEnableServiceResponse);
+
+ /**
+ * Creates a new EnableServiceResponse instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns EnableServiceResponse instance
+ */
+ public static create(properties?: google.api.servicemanagement.v1.IEnableServiceResponse): google.api.servicemanagement.v1.EnableServiceResponse;
+
+ /**
+ * Encodes the specified EnableServiceResponse message. Does not implicitly {@link google.api.servicemanagement.v1.EnableServiceResponse.verify|verify} messages.
+ * @param message EnableServiceResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.api.servicemanagement.v1.IEnableServiceResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified EnableServiceResponse message, length delimited. Does not implicitly {@link google.api.servicemanagement.v1.EnableServiceResponse.verify|verify} messages.
+ * @param message EnableServiceResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.api.servicemanagement.v1.IEnableServiceResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes an EnableServiceResponse message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns EnableServiceResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.api.servicemanagement.v1.EnableServiceResponse;
+
+ /**
+ * Decodes an EnableServiceResponse message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns EnableServiceResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.api.servicemanagement.v1.EnableServiceResponse;
+
+ /**
+ * Verifies an EnableServiceResponse message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates an EnableServiceResponse message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns EnableServiceResponse
+ */
+ public static fromObject(object: { [k: string]: any }): google.api.servicemanagement.v1.EnableServiceResponse;
+
+ /**
+ * Creates a plain object from an EnableServiceResponse message. Also converts values to other types if specified.
+ * @param message EnableServiceResponse
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.api.servicemanagement.v1.EnableServiceResponse, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this EnableServiceResponse to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for EnableServiceResponse
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a GenerateConfigReportRequest. */
interface IGenerateConfigReportRequest {
diff --git a/packages/google-api-servicemanagement/protos/protos.js b/packages/google-api-servicemanagement/protos/protos.js
index baabe978cd7..ec053bb953f 100644
--- a/packages/google-api-servicemanagement/protos/protos.js
+++ b/packages/google-api-servicemanagement/protos/protos.js
@@ -7507,6 +7507,181 @@
return GetServiceRolloutRequest;
})();
+ v1.EnableServiceResponse = (function() {
+
+ /**
+ * Properties of an EnableServiceResponse.
+ * @memberof google.api.servicemanagement.v1
+ * @interface IEnableServiceResponse
+ */
+
+ /**
+ * Constructs a new EnableServiceResponse.
+ * @memberof google.api.servicemanagement.v1
+ * @classdesc Represents an EnableServiceResponse.
+ * @implements IEnableServiceResponse
+ * @constructor
+ * @param {google.api.servicemanagement.v1.IEnableServiceResponse=} [properties] Properties to set
+ */
+ function EnableServiceResponse(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * Creates a new EnableServiceResponse instance using the specified properties.
+ * @function create
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {google.api.servicemanagement.v1.IEnableServiceResponse=} [properties] Properties to set
+ * @returns {google.api.servicemanagement.v1.EnableServiceResponse} EnableServiceResponse instance
+ */
+ EnableServiceResponse.create = function create(properties) {
+ return new EnableServiceResponse(properties);
+ };
+
+ /**
+ * Encodes the specified EnableServiceResponse message. Does not implicitly {@link google.api.servicemanagement.v1.EnableServiceResponse.verify|verify} messages.
+ * @function encode
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {google.api.servicemanagement.v1.IEnableServiceResponse} message EnableServiceResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ EnableServiceResponse.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified EnableServiceResponse message, length delimited. Does not implicitly {@link google.api.servicemanagement.v1.EnableServiceResponse.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {google.api.servicemanagement.v1.IEnableServiceResponse} message EnableServiceResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ EnableServiceResponse.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes an EnableServiceResponse message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.api.servicemanagement.v1.EnableServiceResponse} EnableServiceResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ EnableServiceResponse.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.servicemanagement.v1.EnableServiceResponse();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes an EnableServiceResponse message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.api.servicemanagement.v1.EnableServiceResponse} EnableServiceResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ EnableServiceResponse.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies an EnableServiceResponse message.
+ * @function verify
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ EnableServiceResponse.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ return null;
+ };
+
+ /**
+ * Creates an EnableServiceResponse message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.api.servicemanagement.v1.EnableServiceResponse} EnableServiceResponse
+ */
+ EnableServiceResponse.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.api.servicemanagement.v1.EnableServiceResponse)
+ return object;
+ return new $root.google.api.servicemanagement.v1.EnableServiceResponse();
+ };
+
+ /**
+ * Creates a plain object from an EnableServiceResponse message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {google.api.servicemanagement.v1.EnableServiceResponse} message EnableServiceResponse
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ EnableServiceResponse.toObject = function toObject() {
+ return {};
+ };
+
+ /**
+ * Converts this EnableServiceResponse to JSON.
+ * @function toJSON
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ EnableServiceResponse.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for EnableServiceResponse
+ * @function getTypeUrl
+ * @memberof google.api.servicemanagement.v1.EnableServiceResponse
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ EnableServiceResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.api.servicemanagement.v1.EnableServiceResponse";
+ };
+
+ return EnableServiceResponse;
+ })();
+
v1.GenerateConfigReportRequest = (function() {
/**
diff --git a/packages/google-api-servicemanagement/protos/protos.json b/packages/google-api-servicemanagement/protos/protos.json
index ca28824f859..314be75979b 100644
--- a/packages/google-api-servicemanagement/protos/protos.json
+++ b/packages/google-api-servicemanagement/protos/protos.json
@@ -806,6 +806,9 @@
}
}
},
+ "EnableServiceResponse": {
+ "fields": {}
+ },
"GenerateConfigReportRequest": {
"fields": {
"newConfig": {
diff --git a/packages/google-api-servicemanagement/samples/README.md b/packages/google-api-servicemanagement/samples/README.md
index acc7813d869..1c5ad3d32e9 100644
--- a/packages/google-api-servicemanagement/samples/README.md
+++ b/packages/google-api-servicemanagement/samples/README.md
@@ -28,7 +28,6 @@
* [Service_manager.submit_config_source](#service_manager.submit_config_source)
* [Service_manager.undelete_service](#service_manager.undelete_service)
* [Quickstart](#quickstart)
- * [Quickstart](#quickstart)
## Before you begin
@@ -312,23 +311,6 @@ __Usage:__
`node packages/google-api-servicemanagement/samples/quickstart.js`
------
-
-
-
-
-### Quickstart
-
-View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-api-servicemanagement/samples/test/quickstart.js).
-
-[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-api-servicemanagement/samples/test/quickstart.js,samples/README.md)
-
-__Usage:__
-
-
-`node packages/google-api-servicemanagement/samples/test/quickstart.js`
-
-
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js
index 935d221c558..192ef74e466 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_config.js
@@ -30,8 +30,8 @@ function main(serviceName, serviceConfig) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js
index 25c74e35da6..cde5ac42da2 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.create_service_rollout.js
@@ -30,8 +30,8 @@ function main(serviceName, rollout) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js
index 291667737d7..0ade04cc3ba 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.delete_service.js
@@ -30,8 +30,8 @@ function main(serviceName) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js
index 32dd94a7a4a..a37129748b3 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_config.js
@@ -30,8 +30,8 @@ function main(serviceName, configId) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js
index 1c231d799c2..f69e5827dc5 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.get_service_rollout.js
@@ -30,8 +30,8 @@ function main(serviceName, rolloutId) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js
index 121f0abb6d7..72182fd8213 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_configs.js
@@ -30,8 +30,8 @@ function main(serviceName) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js
index 24a25471274..c5ca11d3953 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_service_rollouts.js
@@ -30,8 +30,8 @@ function main(serviceName, filter) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
@@ -46,12 +46,12 @@ function main(serviceName, filter) {
/**
* Required. Use `filter` to return subset of rollouts.
* The following filters are supported:
- * -- To limit the results to only those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'SUCCESS',
- * use filter='status=SUCCESS'
- * -- To limit the results to those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'CANCELLED'
- * or 'FAILED', use filter='status=CANCELLED OR status=FAILED'
+ * -- By status
+ * google.api.servicemanagement.v1.Rollout.RolloutStatus. For example,
+ * `filter='status=SUCCESS'`
+ * -- By strategy
+ * google.api.servicemanagement.v1.Rollout.strategy. For example,
+ * `filter='strategy=TrafficPercentStrategy'`
*/
// const filter = 'abc123'
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js
index bab6da48ede..811119be6ea 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.list_services.js
@@ -34,7 +34,7 @@ function main() {
// const producerProjectId = 'abc123'
/**
* The max number of items to include in the response list. Page size is 50
- * if not specified. Maximum value is 100.
+ * if not specified. Maximum value is 500.
*/
// const pageSize = 1234
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js
index 7e0967187f3..391192df262 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.submit_config_source.js
@@ -30,8 +30,8 @@ function main(serviceName, configSource) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
/**
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js
index 784620a8601..132f09de7d3 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js
+++ b/packages/google-api-servicemanagement/samples/generated/v1/service_manager.undelete_service.js
@@ -30,8 +30,8 @@ function main(serviceName) {
*/
/**
* Required. The name of the service. See the
- * overview (https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * overview (https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
*/
// const serviceName = 'abc123'
diff --git a/packages/google-api-servicemanagement/samples/generated/v1/snippet_metadata.google.api.servicemanagement.v1.json b/packages/google-api-servicemanagement/samples/generated/v1/snippet_metadata.google.api.servicemanagement.v1.json
index b44041b17a7..70b076cee6c 100644
--- a/packages/google-api-servicemanagement/samples/generated/v1/snippet_metadata.google.api.servicemanagement.v1.json
+++ b/packages/google-api-servicemanagement/samples/generated/v1/snippet_metadata.google.api.servicemanagement.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-servicemanagement",
- "version": "1.2.1",
+ "version": "1.2.2",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-api-servicemanagement/src/v1/service_manager_client.ts b/packages/google-api-servicemanagement/src/v1/service_manager_client.ts
index 4889898d61b..7ed815ba301 100644
--- a/packages/google-api-servicemanagement/src/v1/service_manager_client.ts
+++ b/packages/google-api-servicemanagement/src/v1/service_manager_client.ts
@@ -27,6 +27,8 @@ import type {
LROperation,
PaginationCallback,
GaxCall,
+ IamClient,
+ IamProtos,
} from 'google-gax';
import {Transform} from 'stream';
import * as protos from '../../protos/protos';
@@ -62,6 +64,7 @@ export class ServiceManagerClient {
};
warn: (code: string, message: string, warnType?: string) => void;
innerApiCalls: {[name: string]: Function};
+ iamClient: IamClient;
operationsClient: gax.OperationsClient;
serviceManagerStub?: Promise<{[name: string]: Function}>;
@@ -158,6 +161,7 @@ export class ServiceManagerClient {
if (servicePath === staticMembers.servicePath) {
this.auth.defaultScopes = staticMembers.scopes;
}
+ this.iamClient = new this._gaxModule.IamClient(this._gaxGrpc, opts);
// Determine the client header string.
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
@@ -564,8 +568,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.configId
* Required. The id of the service configuration resource.
*
@@ -679,8 +683,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {google.api.Service} request.serviceConfig
* Required. The service configuration resource.
* @param {object} [options]
@@ -781,8 +785,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.rolloutId
* Required. The id of the rollout resource.
* @param {object} [options]
@@ -1148,8 +1152,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
@@ -1293,8 +1297,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
@@ -1446,8 +1450,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {google.api.servicemanagement.v1.ConfigSource} request.configSource
* Required. The source configuration for the service.
* @param {boolean} [request.validateOnly]
@@ -1605,8 +1609,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {google.api.servicemanagement.v1.Rollout} request.rollout
* Required. The rollout resource. The `service_name` field is output only.
* @param {object} [options]
@@ -1753,7 +1757,7 @@ export class ServiceManagerClient {
* Include services produced by the specified project.
* @param {number} request.pageSize
* The max number of items to include in the response list. Page size is 50
- * if not specified. Maximum value is 100.
+ * if not specified. Maximum value is 500.
* @param {string} request.pageToken
* Token identifying which result to start with; returned by a previous list
* call.
@@ -1855,7 +1859,7 @@ export class ServiceManagerClient {
* Include services produced by the specified project.
* @param {number} request.pageSize
* The max number of items to include in the response list. Page size is 50
- * if not specified. Maximum value is 100.
+ * if not specified. Maximum value is 500.
* @param {string} request.pageToken
* Token identifying which result to start with; returned by a previous list
* call.
@@ -1905,7 +1909,7 @@ export class ServiceManagerClient {
* Include services produced by the specified project.
* @param {number} request.pageSize
* The max number of items to include in the response list. Page size is 50
- * if not specified. Maximum value is 100.
+ * if not specified. Maximum value is 500.
* @param {string} request.pageToken
* Token identifying which result to start with; returned by a previous list
* call.
@@ -1953,8 +1957,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.pageToken
* The token of the page to retrieve.
* @param {number} request.pageSize
@@ -2054,8 +2058,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.pageToken
* The token of the page to retrieve.
* @param {number} request.pageSize
@@ -2103,8 +2107,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.pageToken
* The token of the page to retrieve.
* @param {number} request.pageSize
@@ -2152,8 +2156,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.pageToken
* The token of the page to retrieve.
* @param {number} request.pageSize
@@ -2162,12 +2166,14 @@ export class ServiceManagerClient {
* @param {string} request.filter
* Required. Use `filter` to return subset of rollouts.
* The following filters are supported:
- * -- To limit the results to only those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'SUCCESS',
- * use filter='status=SUCCESS'
- * -- To limit the results to those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'CANCELLED'
- * or 'FAILED', use filter='status=CANCELLED OR status=FAILED'
+ *
+ * -- By [status]
+ * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example,
+ * `filter='status=SUCCESS'`
+ *
+ * -- By [strategy]
+ * [google.api.servicemanagement.v1.Rollout.strategy]. For example,
+ * `filter='strategy=TrafficPercentStrategy'`
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
@@ -2262,8 +2268,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.pageToken
* The token of the page to retrieve.
* @param {number} request.pageSize
@@ -2272,12 +2278,14 @@ export class ServiceManagerClient {
* @param {string} request.filter
* Required. Use `filter` to return subset of rollouts.
* The following filters are supported:
- * -- To limit the results to only those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'SUCCESS',
- * use filter='status=SUCCESS'
- * -- To limit the results to those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'CANCELLED'
- * or 'FAILED', use filter='status=CANCELLED OR status=FAILED'
+ *
+ * -- By [status]
+ * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example,
+ * `filter='status=SUCCESS'`
+ *
+ * -- By [strategy]
+ * [google.api.servicemanagement.v1.Rollout.strategy]. For example,
+ * `filter='strategy=TrafficPercentStrategy'`
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Stream}
@@ -2320,8 +2328,8 @@ export class ServiceManagerClient {
* The request object that will be sent.
* @param {string} request.serviceName
* Required. The name of the service. See the
- * [overview](https://cloud.google.com/service-infrastructure/docs/overview) for naming requirements. For
- * example: `example.googleapis.com`.
+ * [overview](https://cloud.google.com/service-management/overview) for naming
+ * requirements. For example: `example.googleapis.com`.
* @param {string} request.pageToken
* The token of the page to retrieve.
* @param {number} request.pageSize
@@ -2330,12 +2338,14 @@ export class ServiceManagerClient {
* @param {string} request.filter
* Required. Use `filter` to return subset of rollouts.
* The following filters are supported:
- * -- To limit the results to only those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'SUCCESS',
- * use filter='status=SUCCESS'
- * -- To limit the results to those in
- * status (google.api.servicemanagement.v1.RolloutStatus) 'CANCELLED'
- * or 'FAILED', use filter='status=CANCELLED OR status=FAILED'
+ *
+ * -- By [status]
+ * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example,
+ * `filter='status=SUCCESS'`
+ *
+ * -- By [strategy]
+ * [google.api.servicemanagement.v1.Rollout.strategy]. For example,
+ * `filter='strategy=TrafficPercentStrategy'`
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Object}
@@ -2370,6 +2380,320 @@ export class ServiceManagerClient {
callSettings
) as AsyncIterable;
}
+ /**
+ * Gets the access control policy for a resource. Returns an empty policy
+ * if the resource exists and does not have a policy set.
+ *
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.resource
+ * REQUIRED: The resource for which the policy is being requested.
+ * See the operation documentation for the appropriate value for this field.
+ * @param {Object} [request.options]
+ * OPTIONAL: A `GetPolicyOptions` object for specifying options to
+ * `GetIamPolicy`. This field is only used by Cloud IAM.
+ *
+ * This object should have the same structure as {@link google.iam.v1.GetPolicyOptions | GetPolicyOptions}.
+ * @param {Object} [options]
+ * Optional parameters. You can override the default settings for this call, e.g, timeout,
+ * retries, paginations, etc. See {@link https://googleapis.github.io/gax-nodejs/interfaces/CallOptions.html | gax.CallOptions} for the details.
+ * @param {function(?Error, ?Object)} [callback]
+ * The function which will be called with the result of the API call.
+ *
+ * The second parameter to the callback is an object representing {@link google.iam.v1.Policy | Policy}.
+ * @returns {Promise} - The promise which resolves to an array.
+ * The first element of the array is an object representing {@link google.iam.v1.Policy | Policy}.
+ * The promise has a method named "cancel" which cancels the ongoing API call.
+ */
+ getIamPolicy(
+ request: IamProtos.google.iam.v1.GetIamPolicyRequest,
+ options?:
+ | gax.CallOptions
+ | Callback<
+ IamProtos.google.iam.v1.Policy,
+ IamProtos.google.iam.v1.GetIamPolicyRequest | null | undefined,
+ {} | null | undefined
+ >,
+ callback?: Callback<
+ IamProtos.google.iam.v1.Policy,
+ IamProtos.google.iam.v1.GetIamPolicyRequest | null | undefined,
+ {} | null | undefined
+ >
+ ): Promise {
+ return this.iamClient.getIamPolicy(request, options, callback);
+ }
+
+ /**
+ * Returns permissions that a caller has on the specified resource. If the
+ * resource does not exist, this will return an empty set of
+ * permissions, not a NOT_FOUND error.
+ *
+ * Note: This operation is designed to be used for building
+ * permission-aware UIs and command-line tools, not for authorization
+ * checking. This operation may "fail open" without warning.
+ *
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.resource
+ * REQUIRED: The resource for which the policy detail is being requested.
+ * See the operation documentation for the appropriate value for this field.
+ * @param {string[]} request.permissions
+ * The set of permissions to check for the `resource`. Permissions with
+ * wildcards (such as '*' or 'storage.*') are not allowed. For more
+ * information see
+ * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
+ * @param {Object} [options]
+ * Optional parameters. You can override the default settings for this call, e.g, timeout,
+ * retries, paginations, etc. See {@link https://googleapis.github.io/gax-nodejs/interfaces/CallOptions.html | gax.CallOptions} for the details.
+ * @param {function(?Error, ?Object)} [callback]
+ * The function which will be called with the result of the API call.
+ *
+ * The second parameter to the callback is an object representing {@link google.iam.v1.TestIamPermissionsResponse | TestIamPermissionsResponse}.
+ * @returns {Promise} - The promise which resolves to an array.
+ * The first element of the array is an object representing {@link google.iam.v1.TestIamPermissionsResponse | TestIamPermissionsResponse}.
+ * The promise has a method named "cancel" which cancels the ongoing API call.
+ */
+ setIamPolicy(
+ request: IamProtos.google.iam.v1.SetIamPolicyRequest,
+ options?:
+ | gax.CallOptions
+ | Callback<
+ IamProtos.google.iam.v1.Policy,
+ IamProtos.google.iam.v1.SetIamPolicyRequest | null | undefined,
+ {} | null | undefined
+ >,
+ callback?: Callback<
+ IamProtos.google.iam.v1.Policy,
+ IamProtos.google.iam.v1.SetIamPolicyRequest | null | undefined,
+ {} | null | undefined
+ >
+ ): Promise {
+ return this.iamClient.setIamPolicy(request, options, callback);
+ }
+
+ /**
+ * Returns permissions that a caller has on the specified resource. If the
+ * resource does not exist, this will return an empty set of
+ * permissions, not a NOT_FOUND error.
+ *
+ * Note: This operation is designed to be used for building
+ * permission-aware UIs and command-line tools, not for authorization
+ * checking. This operation may "fail open" without warning.
+ *
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.resource
+ * REQUIRED: The resource for which the policy detail is being requested.
+ * See the operation documentation for the appropriate value for this field.
+ * @param {string[]} request.permissions
+ * The set of permissions to check for the `resource`. Permissions with
+ * wildcards (such as '*' or 'storage.*') are not allowed. For more
+ * information see
+ * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
+ * @param {Object} [options]
+ * Optional parameters. You can override the default settings for this call, e.g, timeout,
+ * retries, paginations, etc. See {@link https://googleapis.github.io/gax-nodejs/interfaces/CallOptions.html | gax.CallOptions} for the details.
+ * @param {function(?Error, ?Object)} [callback]
+ * The function which will be called with the result of the API call.
+ *
+ * The second parameter to the callback is an object representing {@link google.iam.v1.TestIamPermissionsResponse | TestIamPermissionsResponse}.
+ * @returns {Promise} - The promise which resolves to an array.
+ * The first element of the array is an object representing {@link google.iam.v1.TestIamPermissionsResponse | TestIamPermissionsResponse}.
+ * The promise has a method named "cancel" which cancels the ongoing API call.
+ *
+ */
+ testIamPermissions(
+ request: IamProtos.google.iam.v1.TestIamPermissionsRequest,
+ options?:
+ | gax.CallOptions
+ | Callback<
+ IamProtos.google.iam.v1.TestIamPermissionsResponse,
+ IamProtos.google.iam.v1.TestIamPermissionsRequest | null | undefined,
+ {} | null | undefined
+ >,
+ callback?: Callback<
+ IamProtos.google.iam.v1.TestIamPermissionsResponse,
+ IamProtos.google.iam.v1.TestIamPermissionsRequest | null | undefined,
+ {} | null | undefined
+ >
+ ): Promise {
+ return this.iamClient.testIamPermissions(request, options, callback);
+ }
+
+ /**
+ * Gets the latest state of a long-running operation. Clients can use this
+ * method to poll the operation result at intervals as recommended by the API
+ * service.
+ *
+ * @param {Object} request - The request object that will be sent.
+ * @param {string} request.name - The name of the operation resource.
+ * @param {Object=} options
+ * Optional parameters. You can override the default settings for this call,
+ * e.g, timeout, retries, paginations, etc. See {@link
+ * https://googleapis.github.io/gax-nodejs/global.html#CallOptions | gax.CallOptions}
+ * for the details.
+ * @param {function(?Error, ?Object)=} callback
+ * The function which will be called with the result of the API call.
+ *
+ * The second parameter to the callback is an object representing
+ * {@link google.longrunning.Operation | google.longrunning.Operation}.
+ * @return {Promise} - The promise which resolves to an array.
+ * The first element of the array is an object representing
+ * {@link google.longrunning.Operation | google.longrunning.Operation}.
+ * The promise has a method named "cancel" which cancels the ongoing API call.
+ *
+ * @example
+ * ```
+ * const client = longrunning.operationsClient();
+ * const name = '';
+ * const [response] = await client.getOperation({name});
+ * // doThingsWith(response)
+ * ```
+ */
+ getOperation(
+ request: protos.google.longrunning.GetOperationRequest,
+ options?:
+ | gax.CallOptions
+ | Callback<
+ protos.google.longrunning.Operation,
+ protos.google.longrunning.GetOperationRequest,
+ {} | null | undefined
+ >,
+ callback?: Callback<
+ protos.google.longrunning.Operation,
+ protos.google.longrunning.GetOperationRequest,
+ {} | null | undefined
+ >
+ ): Promise<[protos.google.longrunning.Operation]> {
+ return this.operationsClient.getOperation(request, options, callback);
+ }
+ /**
+ * Lists operations that match the specified filter in the request. If the
+ * server doesn't support this method, it returns `UNIMPLEMENTED`. Returns an iterable object.
+ *
+ * For-await-of syntax is used with the iterable to recursively get response element on-demand.
+ *
+ * @param {Object} request - The request object that will be sent.
+ * @param {string} request.name - The name of the operation collection.
+ * @param {string} request.filter - The standard list filter.
+ * @param {number=} request.pageSize -
+ * The maximum number of resources contained in the underlying API
+ * response. If page streaming is performed per-resource, this
+ * parameter does not affect the return value. If page streaming is
+ * performed per-page, this determines the maximum number of
+ * resources in a page.
+ * @param {Object=} options
+ * Optional parameters. You can override the default settings for this call,
+ * e.g, timeout, retries, paginations, etc. See {@link
+ * https://googleapis.github.io/gax-nodejs/global.html#CallOptions | gax.CallOptions} for the
+ * details.
+ * @returns {Object}
+ * An iterable Object that conforms to {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols | iteration protocols}.
+ *
+ * @example
+ * ```
+ * const client = longrunning.operationsClient();
+ * for await (const response of client.listOperationsAsync(request));
+ * // doThingsWith(response)
+ * ```
+ */
+ listOperationsAsync(
+ request: protos.google.longrunning.ListOperationsRequest,
+ options?: gax.CallOptions
+ ): AsyncIterable {
+ return this.operationsClient.listOperationsAsync(request, options);
+ }
+ /**
+ * Starts asynchronous cancellation on a long-running operation. The server
+ * makes a best effort to cancel the operation, but success is not
+ * guaranteed. If the server doesn't support this method, it returns
+ * `google.rpc.Code.UNIMPLEMENTED`. Clients can use
+ * {@link Operations.GetOperation} or
+ * other methods to check whether the cancellation succeeded or whether the
+ * operation completed despite cancellation. On successful cancellation,
+ * the operation is not deleted; instead, it becomes an operation with
+ * an {@link Operation.error} value with a {@link google.rpc.Status.code} of
+ * 1, corresponding to `Code.CANCELLED`.
+ *
+ * @param {Object} request - The request object that will be sent.
+ * @param {string} request.name - The name of the operation resource to be cancelled.
+ * @param {Object=} options
+ * Optional parameters. You can override the default settings for this call,
+ * e.g, timeout, retries, paginations, etc. See {@link
+ * https://googleapis.github.io/gax-nodejs/global.html#CallOptions | gax.CallOptions} for the
+ * details.
+ * @param {function(?Error)=} callback
+ * The function which will be called with the result of the API call.
+ * @return {Promise} - The promise which resolves when API call finishes.
+ * The promise has a method named "cancel" which cancels the ongoing API
+ * call.
+ *
+ * @example
+ * ```
+ * const client = longrunning.operationsClient();
+ * await client.cancelOperation({name: ''});
+ * ```
+ */
+ cancelOperation(
+ request: protos.google.longrunning.CancelOperationRequest,
+ options?:
+ | gax.CallOptions
+ | Callback<
+ protos.google.protobuf.Empty,
+ protos.google.longrunning.CancelOperationRequest,
+ {} | undefined | null
+ >,
+ callback?: Callback<
+ protos.google.longrunning.CancelOperationRequest,
+ protos.google.protobuf.Empty,
+ {} | undefined | null
+ >
+ ): Promise {
+ return this.operationsClient.cancelOperation(request, options, callback);
+ }
+
+ /**
+ * Deletes a long-running operation. This method indicates that the client is
+ * no longer interested in the operation result. It does not cancel the
+ * operation. If the server doesn't support this method, it returns
+ * `google.rpc.Code.UNIMPLEMENTED`.
+ *
+ * @param {Object} request - The request object that will be sent.
+ * @param {string} request.name - The name of the operation resource to be deleted.
+ * @param {Object=} options
+ * Optional parameters. You can override the default settings for this call,
+ * e.g, timeout, retries, paginations, etc. See {@link
+ * https://googleapis.github.io/gax-nodejs/global.html#CallOptions | gax.CallOptions}
+ * for the details.
+ * @param {function(?Error)=} callback
+ * The function which will be called with the result of the API call.
+ * @return {Promise} - The promise which resolves when API call finishes.
+ * The promise has a method named "cancel" which cancels the ongoing API
+ * call.
+ *
+ * @example
+ * ```
+ * const client = longrunning.operationsClient();
+ * await client.deleteOperation({name: ''});
+ * ```
+ */
+ deleteOperation(
+ request: protos.google.longrunning.DeleteOperationRequest,
+ options?:
+ | gax.CallOptions
+ | Callback<
+ protos.google.protobuf.Empty,
+ protos.google.longrunning.DeleteOperationRequest,
+ {} | null | undefined
+ >,
+ callback?: Callback<
+ protos.google.protobuf.Empty,
+ protos.google.longrunning.DeleteOperationRequest,
+ {} | null | undefined
+ >
+ ): Promise {
+ return this.operationsClient.deleteOperation(request, options, callback);
+ }
/**
* Terminate the gRPC channel and close the client.
@@ -2382,6 +2706,7 @@ export class ServiceManagerClient {
return this.serviceManagerStub.then(stub => {
this._terminated = true;
stub.close();
+ this.iamClient.close();
this.operationsClient.close();
});
}
diff --git a/packages/google-api-servicemanagement/test/gapic_service_manager_v1.ts b/packages/google-api-servicemanagement/test/gapic_service_manager_v1.ts
index 81ffe2d99d0..2e1ff0c3e10 100644
--- a/packages/google-api-servicemanagement/test/gapic_service_manager_v1.ts
+++ b/packages/google-api-servicemanagement/test/gapic_service_manager_v1.ts
@@ -25,7 +25,7 @@ import * as servicemanagerModule from '../src';
import {PassThrough} from 'stream';
-import {protobuf, LROperation, operationsProtos} from 'google-gax';
+import {protobuf, LROperation, operationsProtos, IamProtos} from 'google-gax';
// Dynamically loaded proto JSON is needed to get the type information
// to fill in default values for request objects
@@ -2672,4 +2672,633 @@ describe('v1.ServiceManagerClient', () => {
);
});
});
+ describe('getIamPolicy', () => {
+ it('invokes getIamPolicy without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.GetIamPolicyRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedResponse = generateSampleMessage(
+ new IamProtos.google.iam.v1.Policy()
+ );
+ client.iamClient.getIamPolicy = stubSimpleCall(expectedResponse);
+ const response = await client.getIamPolicy(request, expectedOptions);
+ assert.deepStrictEqual(response, [expectedResponse]);
+ assert(
+ (client.iamClient.getIamPolicy as SinonStub)
+ .getCall(0)
+ .calledWith(request, expectedOptions, undefined)
+ );
+ });
+ it('invokes getIamPolicy without error using callback', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.GetIamPolicyRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedResponse = generateSampleMessage(
+ new IamProtos.google.iam.v1.Policy()
+ );
+ client.iamClient.getIamPolicy = sinon
+ .stub()
+ .callsArgWith(2, null, expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.getIamPolicy(
+ request,
+ expectedOptions,
+ (
+ err?: Error | null,
+ result?: IamProtos.google.iam.v1.Policy | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ assert((client.iamClient.getIamPolicy as SinonStub).getCall(0));
+ });
+ it('invokes getIamPolicy with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.GetIamPolicyRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedError = new Error('expected');
+ client.iamClient.getIamPolicy = stubSimpleCall(undefined, expectedError);
+ await assert.rejects(
+ client.getIamPolicy(request, expectedOptions),
+ expectedError
+ );
+ assert(
+ (client.iamClient.getIamPolicy as SinonStub)
+ .getCall(0)
+ .calledWith(request, expectedOptions, undefined)
+ );
+ });
+ });
+ describe('setIamPolicy', () => {
+ it('invokes setIamPolicy without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.SetIamPolicyRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedResponse = generateSampleMessage(
+ new IamProtos.google.iam.v1.Policy()
+ );
+ client.iamClient.setIamPolicy = stubSimpleCall(expectedResponse);
+ const response = await client.setIamPolicy(request, expectedOptions);
+ assert.deepStrictEqual(response, [expectedResponse]);
+ assert(
+ (client.iamClient.setIamPolicy as SinonStub)
+ .getCall(0)
+ .calledWith(request, expectedOptions, undefined)
+ );
+ });
+ it('invokes setIamPolicy without error using callback', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.SetIamPolicyRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedResponse = generateSampleMessage(
+ new IamProtos.google.iam.v1.Policy()
+ );
+ client.iamClient.setIamPolicy = sinon
+ .stub()
+ .callsArgWith(2, null, expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.setIamPolicy(
+ request,
+ expectedOptions,
+ (
+ err?: Error | null,
+ result?: IamProtos.google.iam.v1.Policy | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ assert((client.iamClient.setIamPolicy as SinonStub).getCall(0));
+ });
+ it('invokes setIamPolicy with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.SetIamPolicyRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedError = new Error('expected');
+ client.iamClient.setIamPolicy = stubSimpleCall(undefined, expectedError);
+ await assert.rejects(
+ client.setIamPolicy(request, expectedOptions),
+ expectedError
+ );
+ assert(
+ (client.iamClient.setIamPolicy as SinonStub)
+ .getCall(0)
+ .calledWith(request, expectedOptions, undefined)
+ );
+ });
+ });
+ describe('testIamPermissions', () => {
+ it('invokes testIamPermissions without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.TestIamPermissionsRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedResponse = generateSampleMessage(
+ new IamProtos.google.iam.v1.TestIamPermissionsResponse()
+ );
+ client.iamClient.testIamPermissions = stubSimpleCall(expectedResponse);
+ const response = await client.testIamPermissions(
+ request,
+ expectedOptions
+ );
+ assert.deepStrictEqual(response, [expectedResponse]);
+ assert(
+ (client.iamClient.testIamPermissions as SinonStub)
+ .getCall(0)
+ .calledWith(request, expectedOptions, undefined)
+ );
+ });
+ it('invokes testIamPermissions without error using callback', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.TestIamPermissionsRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedResponse = generateSampleMessage(
+ new IamProtos.google.iam.v1.TestIamPermissionsResponse()
+ );
+ client.iamClient.testIamPermissions = sinon
+ .stub()
+ .callsArgWith(2, null, expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.testIamPermissions(
+ request,
+ expectedOptions,
+ (
+ err?: Error | null,
+ result?: IamProtos.google.iam.v1.TestIamPermissionsResponse | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ assert((client.iamClient.testIamPermissions as SinonStub).getCall(0));
+ });
+ it('invokes testIamPermissions with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new IamProtos.google.iam.v1.TestIamPermissionsRequest()
+ );
+ request.resource = '';
+ const expectedHeaderRequestParams = 'resource=';
+ const expectedOptions = {
+ otherArgs: {
+ headers: {
+ 'x-goog-request-params': expectedHeaderRequestParams,
+ },
+ },
+ };
+ const expectedError = new Error('expected');
+ client.iamClient.testIamPermissions = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(
+ client.testIamPermissions(request, expectedOptions),
+ expectedError
+ );
+ assert(
+ (client.iamClient.testIamPermissions as SinonStub)
+ .getCall(0)
+ .calledWith(request, expectedOptions, undefined)
+ );
+ });
+ });
+ describe('getOperation', () => {
+ it('invokes getOperation without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.GetOperationRequest()
+ );
+ const expectedResponse = generateSampleMessage(
+ new operationsProtos.google.longrunning.Operation()
+ );
+ client.operationsClient.getOperation = stubSimpleCall(expectedResponse);
+ const response = await client.getOperation(request);
+ assert.deepStrictEqual(response, [expectedResponse]);
+ assert(
+ (client.operationsClient.getOperation as SinonStub)
+ .getCall(0)
+ .calledWith(request)
+ );
+ });
+ it('invokes getOperation without error using callback', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.GetOperationRequest()
+ );
+ const expectedResponse = generateSampleMessage(
+ new operationsProtos.google.longrunning.Operation()
+ );
+ client.operationsClient.getOperation = sinon
+ .stub()
+ .callsArgWith(2, null, expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.operationsClient.getOperation(
+ request,
+ undefined,
+ (
+ err?: Error | null,
+ result?: operationsProtos.google.longrunning.Operation | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ assert((client.operationsClient.getOperation as SinonStub).getCall(0));
+ });
+ it('invokes getOperation with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.GetOperationRequest()
+ );
+ const expectedError = new Error('expected');
+ client.operationsClient.getOperation = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(async () => {
+ await client.getOperation(request);
+ }, expectedError);
+ assert(
+ (client.operationsClient.getOperation as SinonStub)
+ .getCall(0)
+ .calledWith(request)
+ );
+ });
+ });
+ describe('cancelOperation', () => {
+ it('invokes cancelOperation without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.CancelOperationRequest()
+ );
+ const expectedResponse = generateSampleMessage(
+ new protos.google.protobuf.Empty()
+ );
+ client.operationsClient.cancelOperation =
+ stubSimpleCall(expectedResponse);
+ const response = await client.cancelOperation(request);
+ assert.deepStrictEqual(response, [expectedResponse]);
+ assert(
+ (client.operationsClient.cancelOperation as SinonStub)
+ .getCall(0)
+ .calledWith(request)
+ );
+ });
+ it('invokes cancelOperation without error using callback', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.CancelOperationRequest()
+ );
+ const expectedResponse = generateSampleMessage(
+ new protos.google.protobuf.Empty()
+ );
+ client.operationsClient.cancelOperation = sinon
+ .stub()
+ .callsArgWith(2, null, expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.operationsClient.cancelOperation(
+ request,
+ undefined,
+ (
+ err?: Error | null,
+ result?: protos.google.protobuf.Empty | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ assert((client.operationsClient.cancelOperation as SinonStub).getCall(0));
+ });
+ it('invokes cancelOperation with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.CancelOperationRequest()
+ );
+ const expectedError = new Error('expected');
+ client.operationsClient.cancelOperation = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(async () => {
+ await client.cancelOperation(request);
+ }, expectedError);
+ assert(
+ (client.operationsClient.cancelOperation as SinonStub)
+ .getCall(0)
+ .calledWith(request)
+ );
+ });
+ });
+ describe('deleteOperation', () => {
+ it('invokes deleteOperation without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.DeleteOperationRequest()
+ );
+ const expectedResponse = generateSampleMessage(
+ new protos.google.protobuf.Empty()
+ );
+ client.operationsClient.deleteOperation =
+ stubSimpleCall(expectedResponse);
+ const response = await client.deleteOperation(request);
+ assert.deepStrictEqual(response, [expectedResponse]);
+ assert(
+ (client.operationsClient.deleteOperation as SinonStub)
+ .getCall(0)
+ .calledWith(request)
+ );
+ });
+ it('invokes deleteOperation without error using callback', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.DeleteOperationRequest()
+ );
+ const expectedResponse = generateSampleMessage(
+ new protos.google.protobuf.Empty()
+ );
+ client.operationsClient.deleteOperation = sinon
+ .stub()
+ .callsArgWith(2, null, expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.operationsClient.deleteOperation(
+ request,
+ undefined,
+ (
+ err?: Error | null,
+ result?: protos.google.protobuf.Empty | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ assert((client.operationsClient.deleteOperation as SinonStub).getCall(0));
+ });
+ it('invokes deleteOperation with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.DeleteOperationRequest()
+ );
+ const expectedError = new Error('expected');
+ client.operationsClient.deleteOperation = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(async () => {
+ await client.deleteOperation(request);
+ }, expectedError);
+ assert(
+ (client.operationsClient.deleteOperation as SinonStub)
+ .getCall(0)
+ .calledWith(request)
+ );
+ });
+ });
+ describe('listOperationsAsync', () => {
+ it('uses async iteration with listOperations without error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.ListOperationsRequest()
+ );
+ const expectedResponse = [
+ generateSampleMessage(
+ new operationsProtos.google.longrunning.ListOperationsResponse()
+ ),
+ generateSampleMessage(
+ new operationsProtos.google.longrunning.ListOperationsResponse()
+ ),
+ generateSampleMessage(
+ new operationsProtos.google.longrunning.ListOperationsResponse()
+ ),
+ ];
+ client.operationsClient.descriptor.listOperations.asyncIterate =
+ stubAsyncIterationCall(expectedResponse);
+ const responses: operationsProtos.google.longrunning.ListOperationsResponse[] =
+ [];
+ const iterable = client.operationsClient.listOperationsAsync(request);
+ for await (const resource of iterable) {
+ responses.push(resource!);
+ }
+ assert.deepStrictEqual(responses, expectedResponse);
+ assert.deepStrictEqual(
+ (
+ client.operationsClient.descriptor.listOperations
+ .asyncIterate as SinonStub
+ ).getCall(0).args[1],
+ request
+ );
+ });
+ it('uses async iteration with listOperations with error', async () => {
+ const client = new servicemanagerModule.v1.ServiceManagerClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new operationsProtos.google.longrunning.ListOperationsRequest()
+ );
+ const expectedError = new Error('expected');
+ client.operationsClient.descriptor.listOperations.asyncIterate =
+ stubAsyncIterationCall(undefined, expectedError);
+ const iterable = client.operationsClient.listOperationsAsync(request);
+ await assert.rejects(async () => {
+ const responses: operationsProtos.google.longrunning.ListOperationsResponse[] =
+ [];
+ for await (const resource of iterable) {
+ responses.push(resource!);
+ }
+ });
+ assert.deepStrictEqual(
+ (
+ client.operationsClient.descriptor.listOperations
+ .asyncIterate as SinonStub
+ ).getCall(0).args[1],
+ request
+ );
+ });
+ });
});
diff --git a/packages/google-api-servicemanagement/webpack.config.js b/packages/google-api-servicemanagement/webpack.config.js
index e609ac8b03b..3f75927a086 100644
--- a/packages/google-api-servicemanagement/webpack.config.js
+++ b/packages/google-api-servicemanagement/webpack.config.js
@@ -1,4 +1,4 @@
-// Copyright 2023 Google LLC
+// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
diff --git a/packages/google-cloud-aiplatform/CHANGELOG.md b/packages/google-cloud-aiplatform/CHANGELOG.md
index 2e439e44148..8f786fbcd0f 100644
--- a/packages/google-cloud-aiplatform/CHANGELOG.md
+++ b/packages/google-cloud-aiplatform/CHANGELOG.md
@@ -1,5 +1,13 @@
# Changelog
+## [2.16.0](https://github.com/googleapis/google-cloud-node/compare/aiplatform-v2.15.0...aiplatform-v2.16.0) (2023-06-28)
+
+
+### Features
+
+* Add bias_configs to ModelEvaluation ([#4349](https://github.com/googleapis/google-cloud-node/issues/4349)) ([4c047d4](https://github.com/googleapis/google-cloud-node/commit/4c047d4a9cdbc08dfb70e3843a54ca73ad1f4e79))
+* Add UpdateExplanationDataset to aiplatform ([#4359](https://github.com/googleapis/google-cloud-node/issues/4359)) ([c0a3d8a](https://github.com/googleapis/google-cloud-node/commit/c0a3d8a1df6b319e555955dfef8a56ceef54a6e2))
+
## [2.15.0](https://github.com/googleapis/google-cloud-node/compare/aiplatform-v2.14.0...aiplatform-v2.15.0) (2023-06-06)
diff --git a/packages/google-cloud-aiplatform/README.md b/packages/google-cloud-aiplatform/README.md
index c7d91d374e9..ead9658d603 100644
--- a/packages/google-cloud-aiplatform/README.md
+++ b/packages/google-cloud-aiplatform/README.md
@@ -248,6 +248,7 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/
| Model_service.list_model_versions | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.list_model_versions.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.list_model_versions.js,packages/google-cloud-aiplatform/samples/README.md) |
| Model_service.list_models | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.list_models.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.list_models.js,packages/google-cloud-aiplatform/samples/README.md) |
| Model_service.merge_version_aliases | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.merge_version_aliases.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.merge_version_aliases.js,packages/google-cloud-aiplatform/samples/README.md) |
+| Model_service.update_explanation_dataset | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js,packages/google-cloud-aiplatform/samples/README.md) |
| Model_service.update_model | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_model.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_model.js,packages/google-cloud-aiplatform/samples/README.md) |
| Model_service.upload_model | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.upload_model.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.upload_model.js,packages/google-cloud-aiplatform/samples/README.md) |
| Pipeline_service.cancel_pipeline_job | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/pipeline_service.cancel_pipeline_job.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/pipeline_service.cancel_pipeline_job.js,packages/google-cloud-aiplatform/samples/README.md) |
diff --git a/packages/google-cloud-aiplatform/package.json b/packages/google-cloud-aiplatform/package.json
index 491a6ac15df..3dff7d558ba 100644
--- a/packages/google-cloud-aiplatform/package.json
+++ b/packages/google-cloud-aiplatform/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-cloud/aiplatform",
- "version": "2.15.0",
+ "version": "2.16.0",
"description": "Vertex AI client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1/model_service.proto b/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1/model_service.proto
index 3ab66e345c0..b3b3dd7c9ab 100644
--- a/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1/model_service.proto
+++ b/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1/model_service.proto
@@ -22,6 +22,7 @@ import "google/api/field_behavior.proto";
import "google/api/resource.proto";
import "google/cloud/aiplatform/v1/encryption_spec.proto";
import "google/cloud/aiplatform/v1/evaluated_annotation.proto";
+import "google/cloud/aiplatform/v1/explanation.proto";
import "google/cloud/aiplatform/v1/io.proto";
import "google/cloud/aiplatform/v1/model.proto";
import "google/cloud/aiplatform/v1/model_evaluation.proto";
@@ -92,6 +93,20 @@ service ModelService {
option (google.api.method_signature) = "model,update_mask";
}
+ // Incrementally update the dataset used for an examples model.
+ rpc UpdateExplanationDataset(UpdateExplanationDatasetRequest)
+ returns (google.longrunning.Operation) {
+ option (google.api.http) = {
+ post: "/v1/{model=projects/*/locations/*/models/*}:updateExplanationDataset"
+ body: "*"
+ };
+ option (google.api.method_signature) = "model";
+ option (google.longrunning.operation_info) = {
+ response_type: "UpdateExplanationDatasetResponse"
+ metadata_type: "UpdateExplanationDatasetOperationMetadata"
+ };
+ }
+
// Deletes a Model.
//
// A model cannot be deleted if any
@@ -484,6 +499,29 @@ message UpdateModelRequest {
[(google.api.field_behavior) = REQUIRED];
}
+// Request message for
+// [ModelService.UpdateExplanationDataset][google.cloud.aiplatform.v1.ModelService.UpdateExplanationDataset].
+message UpdateExplanationDatasetRequest {
+ // Required. The resource name of the Model to update.
+ // Format: `projects/{project}/locations/{location}/models/{model}`
+ string model = 1 [
+ (google.api.field_behavior) = REQUIRED,
+ (google.api.resource_reference) = {
+ type: "aiplatform.googleapis.com/Model"
+ }
+ ];
+
+ // The example config containing the location of the dataset.
+ Examples examples = 2;
+}
+
+// Runtime operation information for
+// [ModelService.UpdateExplanationDataset][google.cloud.aiplatform.v1.ModelService.UpdateExplanationDataset].
+message UpdateExplanationDatasetOperationMetadata {
+ // The common part of the operation metadata.
+ GenericOperationMetadata generic_metadata = 1;
+}
+
// Request message for
// [ModelService.DeleteModel][google.cloud.aiplatform.v1.ModelService.DeleteModel].
message DeleteModelRequest {
@@ -584,6 +622,11 @@ message ExportModelRequest {
OutputConfig output_config = 2 [(google.api.field_behavior) = REQUIRED];
}
+// Response message of
+// [ModelService.UpdateExplanationDataset][google.cloud.aiplatform.v1.ModelService.UpdateExplanationDataset]
+// operation.
+message UpdateExplanationDatasetResponse {}
+
// Details of
// [ModelService.ExportModel][google.cloud.aiplatform.v1.ModelService.ExportModel]
// operation.
diff --git a/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1beta1/model_evaluation.proto b/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1beta1/model_evaluation.proto
index f636c27ef83..92ce28d468d 100644
--- a/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1beta1/model_evaluation.proto
+++ b/packages/google-cloud-aiplatform/protos/google/cloud/aiplatform/v1beta1/model_evaluation.proto
@@ -19,6 +19,7 @@ package google.cloud.aiplatform.v1beta1;
import "google/api/field_behavior.proto";
import "google/api/resource.proto";
import "google/cloud/aiplatform/v1beta1/explanation.proto";
+import "google/cloud/aiplatform/v1beta1/model_evaluation_slice.proto";
import "google/protobuf/struct.proto";
import "google/protobuf/timestamp.proto";
@@ -51,6 +52,38 @@ message ModelEvaluation {
ExplanationSpec explanation_spec = 2;
}
+ // Configuration for bias detection.
+ message BiasConfig {
+ // Specification for how the data should be sliced for bias. It contains a
+ // list of slices, with limitation of two slices. The first slice of data
+ // will be the slice_a. The second slice in the list (slice_b) will be
+ // compared against the first slice. If only a single slice is provided,
+ // then slice_a will be compared against “not slice_a”.
+ // Below are examples with feature "education" with value "low", "medium",
+ // "high" in the dataset:
+ //
+ // Example 1:
+ //
+ // bias_slices = [{'education': 'low'}]
+ //
+ // A single slice provided. In this case, slice_a is the collection of data
+ // with 'education' equals 'low', and slice_b is the collection of data with
+ // 'education' equals 'medium' or 'high'.
+ //
+ // Example 2:
+ //
+ // bias_slices = [{'education': 'low'},
+ // {'education': 'high'}]
+ //
+ // Two slices provided. In this case, slice_a is the collection of data
+ // with 'education' equals 'low', and slice_b is the collection of data with
+ // 'education' equals 'high'.
+ ModelEvaluationSlice.Slice.SliceSpec bias_slices = 1;
+
+ // Positive labels selection on the target field.
+ repeated string labels = 2;
+ }
+
// Output only. The resource name of the ModelEvaluation.
string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
@@ -94,4 +127,7 @@ message ModelEvaluation {
// structured value with keys of "pipeline_job_id", "evaluation_dataset_type",
// "evaluation_dataset_path".
google.protobuf.Value metadata = 11;
+
+ // Specify the configuration for bias detection.
+ BiasConfig bias_configs = 12;
}
diff --git a/packages/google-cloud-aiplatform/protos/protos.d.ts b/packages/google-cloud-aiplatform/protos/protos.d.ts
index d1297741386..ec2c5093418 100644
--- a/packages/google-cloud-aiplatform/protos/protos.d.ts
+++ b/packages/google-cloud-aiplatform/protos/protos.d.ts
@@ -53070,6 +53070,20 @@ export namespace google {
*/
public updateModel(request: google.cloud.aiplatform.v1.IUpdateModelRequest): Promise;
+ /**
+ * Calls UpdateExplanationDataset.
+ * @param request UpdateExplanationDatasetRequest message or plain object
+ * @param callback Node-style callback called with the error, if any, and Operation
+ */
+ public updateExplanationDataset(request: google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest, callback: google.cloud.aiplatform.v1.ModelService.UpdateExplanationDatasetCallback): void;
+
+ /**
+ * Calls UpdateExplanationDataset.
+ * @param request UpdateExplanationDatasetRequest message or plain object
+ * @returns Promise
+ */
+ public updateExplanationDataset(request: google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest): Promise;
+
/**
* Calls DeleteModel.
* @param request DeleteModelRequest message or plain object
@@ -53276,6 +53290,13 @@ export namespace google {
*/
type UpdateModelCallback = (error: (Error|null), response?: google.cloud.aiplatform.v1.Model) => void;
+ /**
+ * Callback as used by {@link google.cloud.aiplatform.v1.ModelService|updateExplanationDataset}.
+ * @param error Error, if any
+ * @param [response] Operation
+ */
+ type UpdateExplanationDatasetCallback = (error: (Error|null), response?: google.longrunning.Operation) => void;
+
/**
* Callback as used by {@link google.cloud.aiplatform.v1.ModelService|deleteModel}.
* @param error Error, if any
@@ -54342,6 +54363,206 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ /** Properties of an UpdateExplanationDatasetRequest. */
+ interface IUpdateExplanationDatasetRequest {
+
+ /** UpdateExplanationDatasetRequest model */
+ model?: (string|null);
+
+ /** UpdateExplanationDatasetRequest examples */
+ examples?: (google.cloud.aiplatform.v1.IExamples|null);
+ }
+
+ /** Represents an UpdateExplanationDatasetRequest. */
+ class UpdateExplanationDatasetRequest implements IUpdateExplanationDatasetRequest {
+
+ /**
+ * Constructs a new UpdateExplanationDatasetRequest.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest);
+
+ /** UpdateExplanationDatasetRequest model. */
+ public model: string;
+
+ /** UpdateExplanationDatasetRequest examples. */
+ public examples?: (google.cloud.aiplatform.v1.IExamples|null);
+
+ /**
+ * Creates a new UpdateExplanationDatasetRequest instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns UpdateExplanationDatasetRequest instance
+ */
+ public static create(properties?: google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest): google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest;
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetRequest message. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest.verify|verify} messages.
+ * @param message UpdateExplanationDatasetRequest message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetRequest message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest.verify|verify} messages.
+ * @param message UpdateExplanationDatasetRequest message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes an UpdateExplanationDatasetRequest message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns UpdateExplanationDatasetRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest;
+
+ /**
+ * Decodes an UpdateExplanationDatasetRequest message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns UpdateExplanationDatasetRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest;
+
+ /**
+ * Verifies an UpdateExplanationDatasetRequest message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates an UpdateExplanationDatasetRequest message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns UpdateExplanationDatasetRequest
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest;
+
+ /**
+ * Creates a plain object from an UpdateExplanationDatasetRequest message. Also converts values to other types if specified.
+ * @param message UpdateExplanationDatasetRequest
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this UpdateExplanationDatasetRequest to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for UpdateExplanationDatasetRequest
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of an UpdateExplanationDatasetOperationMetadata. */
+ interface IUpdateExplanationDatasetOperationMetadata {
+
+ /** UpdateExplanationDatasetOperationMetadata genericMetadata */
+ genericMetadata?: (google.cloud.aiplatform.v1.IGenericOperationMetadata|null);
+ }
+
+ /** Represents an UpdateExplanationDatasetOperationMetadata. */
+ class UpdateExplanationDatasetOperationMetadata implements IUpdateExplanationDatasetOperationMetadata {
+
+ /**
+ * Constructs a new UpdateExplanationDatasetOperationMetadata.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata);
+
+ /** UpdateExplanationDatasetOperationMetadata genericMetadata. */
+ public genericMetadata?: (google.cloud.aiplatform.v1.IGenericOperationMetadata|null);
+
+ /**
+ * Creates a new UpdateExplanationDatasetOperationMetadata instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns UpdateExplanationDatasetOperationMetadata instance
+ */
+ public static create(properties?: google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata): google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata;
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetOperationMetadata message. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata.verify|verify} messages.
+ * @param message UpdateExplanationDatasetOperationMetadata message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetOperationMetadata message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata.verify|verify} messages.
+ * @param message UpdateExplanationDatasetOperationMetadata message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes an UpdateExplanationDatasetOperationMetadata message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns UpdateExplanationDatasetOperationMetadata
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata;
+
+ /**
+ * Decodes an UpdateExplanationDatasetOperationMetadata message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns UpdateExplanationDatasetOperationMetadata
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata;
+
+ /**
+ * Verifies an UpdateExplanationDatasetOperationMetadata message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates an UpdateExplanationDatasetOperationMetadata message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns UpdateExplanationDatasetOperationMetadata
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata;
+
+ /**
+ * Creates a plain object from an UpdateExplanationDatasetOperationMetadata message. Also converts values to other types if specified.
+ * @param message UpdateExplanationDatasetOperationMetadata
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this UpdateExplanationDatasetOperationMetadata to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for UpdateExplanationDatasetOperationMetadata
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a DeleteModelRequest. */
interface IDeleteModelRequest {
@@ -54854,6 +55075,97 @@ export namespace google {
}
}
+ /** Properties of an UpdateExplanationDatasetResponse. */
+ interface IUpdateExplanationDatasetResponse {
+ }
+
+ /** Represents an UpdateExplanationDatasetResponse. */
+ class UpdateExplanationDatasetResponse implements IUpdateExplanationDatasetResponse {
+
+ /**
+ * Constructs a new UpdateExplanationDatasetResponse.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse);
+
+ /**
+ * Creates a new UpdateExplanationDatasetResponse instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns UpdateExplanationDatasetResponse instance
+ */
+ public static create(properties?: google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse): google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse;
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetResponse message. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse.verify|verify} messages.
+ * @param message UpdateExplanationDatasetResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetResponse message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse.verify|verify} messages.
+ * @param message UpdateExplanationDatasetResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes an UpdateExplanationDatasetResponse message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns UpdateExplanationDatasetResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse;
+
+ /**
+ * Decodes an UpdateExplanationDatasetResponse message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns UpdateExplanationDatasetResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse;
+
+ /**
+ * Verifies an UpdateExplanationDatasetResponse message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates an UpdateExplanationDatasetResponse message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns UpdateExplanationDatasetResponse
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse;
+
+ /**
+ * Creates a plain object from an UpdateExplanationDatasetResponse message. Also converts values to other types if specified.
+ * @param message UpdateExplanationDatasetResponse
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this UpdateExplanationDatasetResponse to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for UpdateExplanationDatasetResponse
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of an ExportModelOperationMetadata. */
interface IExportModelOperationMetadata {
@@ -130658,6 +130970,9 @@ export namespace google {
/** ModelEvaluation metadata */
metadata?: (google.protobuf.IValue|null);
+
+ /** ModelEvaluation biasConfigs */
+ biasConfigs?: (google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig|null);
}
/** Represents a ModelEvaluation. */
@@ -130696,6 +131011,9 @@ export namespace google {
/** ModelEvaluation metadata. */
public metadata?: (google.protobuf.IValue|null);
+ /** ModelEvaluation biasConfigs. */
+ public biasConfigs?: (google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig|null);
+
/**
* Creates a new ModelEvaluation instance using the specified properties.
* @param [properties] Properties to set
@@ -130878,6 +131196,109 @@ export namespace google {
*/
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+
+ /** Properties of a BiasConfig. */
+ interface IBiasConfig {
+
+ /** BiasConfig biasSlices */
+ biasSlices?: (google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.ISliceSpec|null);
+
+ /** BiasConfig labels */
+ labels?: (string[]|null);
+ }
+
+ /** Represents a BiasConfig. */
+ class BiasConfig implements IBiasConfig {
+
+ /**
+ * Constructs a new BiasConfig.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig);
+
+ /** BiasConfig biasSlices. */
+ public biasSlices?: (google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.ISliceSpec|null);
+
+ /** BiasConfig labels. */
+ public labels: string[];
+
+ /**
+ * Creates a new BiasConfig instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns BiasConfig instance
+ */
+ public static create(properties?: google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig): google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig;
+
+ /**
+ * Encodes the specified BiasConfig message. Does not implicitly {@link google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.verify|verify} messages.
+ * @param message BiasConfig message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified BiasConfig message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.verify|verify} messages.
+ * @param message BiasConfig message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a BiasConfig message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns BiasConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig;
+
+ /**
+ * Decodes a BiasConfig message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns BiasConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig;
+
+ /**
+ * Verifies a BiasConfig message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a BiasConfig message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns BiasConfig
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig;
+
+ /**
+ * Creates a plain object from a BiasConfig message. Also converts values to other types if specified.
+ * @param message BiasConfig
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this BiasConfig to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for BiasConfig
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
}
/** Properties of a ModelEvaluationSlice. */
diff --git a/packages/google-cloud-aiplatform/protos/protos.js b/packages/google-cloud-aiplatform/protos/protos.js
index 1140760f22c..4228fab8651 100644
--- a/packages/google-cloud-aiplatform/protos/protos.js
+++ b/packages/google-cloud-aiplatform/protos/protos.js
@@ -129399,6 +129399,39 @@
* @variation 2
*/
+ /**
+ * Callback as used by {@link google.cloud.aiplatform.v1.ModelService|updateExplanationDataset}.
+ * @memberof google.cloud.aiplatform.v1.ModelService
+ * @typedef UpdateExplanationDatasetCallback
+ * @type {function}
+ * @param {Error|null} error Error, if any
+ * @param {google.longrunning.Operation} [response] Operation
+ */
+
+ /**
+ * Calls UpdateExplanationDataset.
+ * @function updateExplanationDataset
+ * @memberof google.cloud.aiplatform.v1.ModelService
+ * @instance
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest} request UpdateExplanationDatasetRequest message or plain object
+ * @param {google.cloud.aiplatform.v1.ModelService.UpdateExplanationDatasetCallback} callback Node-style callback called with the error, if any, and Operation
+ * @returns {undefined}
+ * @variation 1
+ */
+ Object.defineProperty(ModelService.prototype.updateExplanationDataset = function updateExplanationDataset(request, callback) {
+ return this.rpcCall(updateExplanationDataset, $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest, $root.google.longrunning.Operation, request, callback);
+ }, "name", { value: "UpdateExplanationDataset" });
+
+ /**
+ * Calls UpdateExplanationDataset.
+ * @function updateExplanationDataset
+ * @memberof google.cloud.aiplatform.v1.ModelService
+ * @instance
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest} request UpdateExplanationDatasetRequest message or plain object
+ * @returns {Promise} Promise
+ * @variation 2
+ */
+
/**
* Callback as used by {@link google.cloud.aiplatform.v1.ModelService|deleteModel}.
* @memberof google.cloud.aiplatform.v1.ModelService
@@ -132118,6 +132151,446 @@
return UpdateModelRequest;
})();
+ v1.UpdateExplanationDatasetRequest = (function() {
+
+ /**
+ * Properties of an UpdateExplanationDatasetRequest.
+ * @memberof google.cloud.aiplatform.v1
+ * @interface IUpdateExplanationDatasetRequest
+ * @property {string|null} [model] UpdateExplanationDatasetRequest model
+ * @property {google.cloud.aiplatform.v1.IExamples|null} [examples] UpdateExplanationDatasetRequest examples
+ */
+
+ /**
+ * Constructs a new UpdateExplanationDatasetRequest.
+ * @memberof google.cloud.aiplatform.v1
+ * @classdesc Represents an UpdateExplanationDatasetRequest.
+ * @implements IUpdateExplanationDatasetRequest
+ * @constructor
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest=} [properties] Properties to set
+ */
+ function UpdateExplanationDatasetRequest(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * UpdateExplanationDatasetRequest model.
+ * @member {string} model
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @instance
+ */
+ UpdateExplanationDatasetRequest.prototype.model = "";
+
+ /**
+ * UpdateExplanationDatasetRequest examples.
+ * @member {google.cloud.aiplatform.v1.IExamples|null|undefined} examples
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @instance
+ */
+ UpdateExplanationDatasetRequest.prototype.examples = null;
+
+ /**
+ * Creates a new UpdateExplanationDatasetRequest instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest=} [properties] Properties to set
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest} UpdateExplanationDatasetRequest instance
+ */
+ UpdateExplanationDatasetRequest.create = function create(properties) {
+ return new UpdateExplanationDatasetRequest(properties);
+ };
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetRequest message. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest} message UpdateExplanationDatasetRequest message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ UpdateExplanationDatasetRequest.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.model != null && Object.hasOwnProperty.call(message, "model"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.model);
+ if (message.examples != null && Object.hasOwnProperty.call(message, "examples"))
+ $root.google.cloud.aiplatform.v1.Examples.encode(message.examples, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetRequest message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest} message UpdateExplanationDatasetRequest message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ UpdateExplanationDatasetRequest.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes an UpdateExplanationDatasetRequest message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest} UpdateExplanationDatasetRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ UpdateExplanationDatasetRequest.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.model = reader.string();
+ break;
+ }
+ case 2: {
+ message.examples = $root.google.cloud.aiplatform.v1.Examples.decode(reader, reader.uint32());
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes an UpdateExplanationDatasetRequest message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest} UpdateExplanationDatasetRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ UpdateExplanationDatasetRequest.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies an UpdateExplanationDatasetRequest message.
+ * @function verify
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ UpdateExplanationDatasetRequest.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.model != null && message.hasOwnProperty("model"))
+ if (!$util.isString(message.model))
+ return "model: string expected";
+ if (message.examples != null && message.hasOwnProperty("examples")) {
+ var error = $root.google.cloud.aiplatform.v1.Examples.verify(message.examples);
+ if (error)
+ return "examples." + error;
+ }
+ return null;
+ };
+
+ /**
+ * Creates an UpdateExplanationDatasetRequest message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest} UpdateExplanationDatasetRequest
+ */
+ UpdateExplanationDatasetRequest.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest)
+ return object;
+ var message = new $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest();
+ if (object.model != null)
+ message.model = String(object.model);
+ if (object.examples != null) {
+ if (typeof object.examples !== "object")
+ throw TypeError(".google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest.examples: object expected");
+ message.examples = $root.google.cloud.aiplatform.v1.Examples.fromObject(object.examples);
+ }
+ return message;
+ };
+
+ /**
+ * Creates a plain object from an UpdateExplanationDatasetRequest message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest} message UpdateExplanationDatasetRequest
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ UpdateExplanationDatasetRequest.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.model = "";
+ object.examples = null;
+ }
+ if (message.model != null && message.hasOwnProperty("model"))
+ object.model = message.model;
+ if (message.examples != null && message.hasOwnProperty("examples"))
+ object.examples = $root.google.cloud.aiplatform.v1.Examples.toObject(message.examples, options);
+ return object;
+ };
+
+ /**
+ * Converts this UpdateExplanationDatasetRequest to JSON.
+ * @function toJSON
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ UpdateExplanationDatasetRequest.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for UpdateExplanationDatasetRequest
+ * @function getTypeUrl
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ UpdateExplanationDatasetRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest";
+ };
+
+ return UpdateExplanationDatasetRequest;
+ })();
+
+ v1.UpdateExplanationDatasetOperationMetadata = (function() {
+
+ /**
+ * Properties of an UpdateExplanationDatasetOperationMetadata.
+ * @memberof google.cloud.aiplatform.v1
+ * @interface IUpdateExplanationDatasetOperationMetadata
+ * @property {google.cloud.aiplatform.v1.IGenericOperationMetadata|null} [genericMetadata] UpdateExplanationDatasetOperationMetadata genericMetadata
+ */
+
+ /**
+ * Constructs a new UpdateExplanationDatasetOperationMetadata.
+ * @memberof google.cloud.aiplatform.v1
+ * @classdesc Represents an UpdateExplanationDatasetOperationMetadata.
+ * @implements IUpdateExplanationDatasetOperationMetadata
+ * @constructor
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata=} [properties] Properties to set
+ */
+ function UpdateExplanationDatasetOperationMetadata(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * UpdateExplanationDatasetOperationMetadata genericMetadata.
+ * @member {google.cloud.aiplatform.v1.IGenericOperationMetadata|null|undefined} genericMetadata
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @instance
+ */
+ UpdateExplanationDatasetOperationMetadata.prototype.genericMetadata = null;
+
+ /**
+ * Creates a new UpdateExplanationDatasetOperationMetadata instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata=} [properties] Properties to set
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata} UpdateExplanationDatasetOperationMetadata instance
+ */
+ UpdateExplanationDatasetOperationMetadata.create = function create(properties) {
+ return new UpdateExplanationDatasetOperationMetadata(properties);
+ };
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetOperationMetadata message. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata} message UpdateExplanationDatasetOperationMetadata message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ UpdateExplanationDatasetOperationMetadata.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.genericMetadata != null && Object.hasOwnProperty.call(message, "genericMetadata"))
+ $root.google.cloud.aiplatform.v1.GenericOperationMetadata.encode(message.genericMetadata, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetOperationMetadata message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata} message UpdateExplanationDatasetOperationMetadata message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ UpdateExplanationDatasetOperationMetadata.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes an UpdateExplanationDatasetOperationMetadata message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata} UpdateExplanationDatasetOperationMetadata
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ UpdateExplanationDatasetOperationMetadata.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.genericMetadata = $root.google.cloud.aiplatform.v1.GenericOperationMetadata.decode(reader, reader.uint32());
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes an UpdateExplanationDatasetOperationMetadata message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata} UpdateExplanationDatasetOperationMetadata
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ UpdateExplanationDatasetOperationMetadata.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies an UpdateExplanationDatasetOperationMetadata message.
+ * @function verify
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ UpdateExplanationDatasetOperationMetadata.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.genericMetadata != null && message.hasOwnProperty("genericMetadata")) {
+ var error = $root.google.cloud.aiplatform.v1.GenericOperationMetadata.verify(message.genericMetadata);
+ if (error)
+ return "genericMetadata." + error;
+ }
+ return null;
+ };
+
+ /**
+ * Creates an UpdateExplanationDatasetOperationMetadata message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata} UpdateExplanationDatasetOperationMetadata
+ */
+ UpdateExplanationDatasetOperationMetadata.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata)
+ return object;
+ var message = new $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata();
+ if (object.genericMetadata != null) {
+ if (typeof object.genericMetadata !== "object")
+ throw TypeError(".google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata.genericMetadata: object expected");
+ message.genericMetadata = $root.google.cloud.aiplatform.v1.GenericOperationMetadata.fromObject(object.genericMetadata);
+ }
+ return message;
+ };
+
+ /**
+ * Creates a plain object from an UpdateExplanationDatasetOperationMetadata message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata} message UpdateExplanationDatasetOperationMetadata
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ UpdateExplanationDatasetOperationMetadata.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults)
+ object.genericMetadata = null;
+ if (message.genericMetadata != null && message.hasOwnProperty("genericMetadata"))
+ object.genericMetadata = $root.google.cloud.aiplatform.v1.GenericOperationMetadata.toObject(message.genericMetadata, options);
+ return object;
+ };
+
+ /**
+ * Converts this UpdateExplanationDatasetOperationMetadata to JSON.
+ * @function toJSON
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ UpdateExplanationDatasetOperationMetadata.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for UpdateExplanationDatasetOperationMetadata
+ * @function getTypeUrl
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ UpdateExplanationDatasetOperationMetadata.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata";
+ };
+
+ return UpdateExplanationDatasetOperationMetadata;
+ })();
+
v1.DeleteModelRequest = (function() {
/**
@@ -133259,6 +133732,181 @@
return ExportModelRequest;
})();
+ v1.UpdateExplanationDatasetResponse = (function() {
+
+ /**
+ * Properties of an UpdateExplanationDatasetResponse.
+ * @memberof google.cloud.aiplatform.v1
+ * @interface IUpdateExplanationDatasetResponse
+ */
+
+ /**
+ * Constructs a new UpdateExplanationDatasetResponse.
+ * @memberof google.cloud.aiplatform.v1
+ * @classdesc Represents an UpdateExplanationDatasetResponse.
+ * @implements IUpdateExplanationDatasetResponse
+ * @constructor
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse=} [properties] Properties to set
+ */
+ function UpdateExplanationDatasetResponse(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * Creates a new UpdateExplanationDatasetResponse instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse=} [properties] Properties to set
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse} UpdateExplanationDatasetResponse instance
+ */
+ UpdateExplanationDatasetResponse.create = function create(properties) {
+ return new UpdateExplanationDatasetResponse(properties);
+ };
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetResponse message. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse} message UpdateExplanationDatasetResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ UpdateExplanationDatasetResponse.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified UpdateExplanationDatasetResponse message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse} message UpdateExplanationDatasetResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ UpdateExplanationDatasetResponse.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes an UpdateExplanationDatasetResponse message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse} UpdateExplanationDatasetResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ UpdateExplanationDatasetResponse.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes an UpdateExplanationDatasetResponse message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse} UpdateExplanationDatasetResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ UpdateExplanationDatasetResponse.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies an UpdateExplanationDatasetResponse message.
+ * @function verify
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ UpdateExplanationDatasetResponse.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ return null;
+ };
+
+ /**
+ * Creates an UpdateExplanationDatasetResponse message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse} UpdateExplanationDatasetResponse
+ */
+ UpdateExplanationDatasetResponse.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse)
+ return object;
+ return new $root.google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse();
+ };
+
+ /**
+ * Creates a plain object from an UpdateExplanationDatasetResponse message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse} message UpdateExplanationDatasetResponse
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ UpdateExplanationDatasetResponse.toObject = function toObject() {
+ return {};
+ };
+
+ /**
+ * Converts this UpdateExplanationDatasetResponse to JSON.
+ * @function toJSON
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ UpdateExplanationDatasetResponse.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for UpdateExplanationDatasetResponse
+ * @function getTypeUrl
+ * @memberof google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ UpdateExplanationDatasetResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse";
+ };
+
+ return UpdateExplanationDatasetResponse;
+ })();
+
v1.ExportModelOperationMetadata = (function() {
/**
@@ -316119,6 +316767,7 @@
* @property {google.cloud.aiplatform.v1beta1.IModelExplanation|null} [modelExplanation] ModelEvaluation modelExplanation
* @property {Array.|null} [explanationSpecs] ModelEvaluation explanationSpecs
* @property {google.protobuf.IValue|null} [metadata] ModelEvaluation metadata
+ * @property {google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig|null} [biasConfigs] ModelEvaluation biasConfigs
*/
/**
@@ -316210,6 +316859,14 @@
*/
ModelEvaluation.prototype.metadata = null;
+ /**
+ * ModelEvaluation biasConfigs.
+ * @member {google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig|null|undefined} biasConfigs
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation
+ * @instance
+ */
+ ModelEvaluation.prototype.biasConfigs = null;
+
/**
* Creates a new ModelEvaluation instance using the specified properties.
* @function create
@@ -316254,6 +316911,8 @@
writer.uint32(/* id 10, wireType 2 =*/82).string(message.displayName);
if (message.metadata != null && Object.hasOwnProperty.call(message, "metadata"))
$root.google.protobuf.Value.encode(message.metadata, writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim();
+ if (message.biasConfigs != null && Object.hasOwnProperty.call(message, "biasConfigs"))
+ $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.encode(message.biasConfigs, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim();
return writer;
};
@@ -316328,6 +316987,10 @@
message.metadata = $root.google.protobuf.Value.decode(reader, reader.uint32());
break;
}
+ case 12: {
+ message.biasConfigs = $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -316408,6 +317071,11 @@
if (error)
return "metadata." + error;
}
+ if (message.biasConfigs != null && message.hasOwnProperty("biasConfigs")) {
+ var error = $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.verify(message.biasConfigs);
+ if (error)
+ return "biasConfigs." + error;
+ }
return null;
};
@@ -316466,6 +317134,11 @@
throw TypeError(".google.cloud.aiplatform.v1beta1.ModelEvaluation.metadata: object expected");
message.metadata = $root.google.protobuf.Value.fromObject(object.metadata);
}
+ if (object.biasConfigs != null) {
+ if (typeof object.biasConfigs !== "object")
+ throw TypeError(".google.cloud.aiplatform.v1beta1.ModelEvaluation.biasConfigs: object expected");
+ message.biasConfigs = $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.fromObject(object.biasConfigs);
+ }
return message;
};
@@ -316494,6 +317167,7 @@
object.modelExplanation = null;
object.displayName = "";
object.metadata = null;
+ object.biasConfigs = null;
}
if (message.name != null && message.hasOwnProperty("name"))
object.name = message.name;
@@ -316519,6 +317193,8 @@
object.displayName = message.displayName;
if (message.metadata != null && message.hasOwnProperty("metadata"))
object.metadata = $root.google.protobuf.Value.toObject(message.metadata, options);
+ if (message.biasConfigs != null && message.hasOwnProperty("biasConfigs"))
+ object.biasConfigs = $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.toObject(message.biasConfigs, options);
return object;
};
@@ -316780,6 +317456,254 @@
return ModelEvaluationExplanationSpec;
})();
+ ModelEvaluation.BiasConfig = (function() {
+
+ /**
+ * Properties of a BiasConfig.
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation
+ * @interface IBiasConfig
+ * @property {google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.ISliceSpec|null} [biasSlices] BiasConfig biasSlices
+ * @property {Array.|null} [labels] BiasConfig labels
+ */
+
+ /**
+ * Constructs a new BiasConfig.
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation
+ * @classdesc Represents a BiasConfig.
+ * @implements IBiasConfig
+ * @constructor
+ * @param {google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig=} [properties] Properties to set
+ */
+ function BiasConfig(properties) {
+ this.labels = [];
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * BiasConfig biasSlices.
+ * @member {google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.ISliceSpec|null|undefined} biasSlices
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @instance
+ */
+ BiasConfig.prototype.biasSlices = null;
+
+ /**
+ * BiasConfig labels.
+ * @member {Array.} labels
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @instance
+ */
+ BiasConfig.prototype.labels = $util.emptyArray;
+
+ /**
+ * Creates a new BiasConfig instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig=} [properties] Properties to set
+ * @returns {google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig} BiasConfig instance
+ */
+ BiasConfig.create = function create(properties) {
+ return new BiasConfig(properties);
+ };
+
+ /**
+ * Encodes the specified BiasConfig message. Does not implicitly {@link google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig} message BiasConfig message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ BiasConfig.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.biasSlices != null && Object.hasOwnProperty.call(message, "biasSlices"))
+ $root.google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.SliceSpec.encode(message.biasSlices, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
+ if (message.labels != null && message.labels.length)
+ for (var i = 0; i < message.labels.length; ++i)
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.labels[i]);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified BiasConfig message, length delimited. Does not implicitly {@link google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {google.cloud.aiplatform.v1beta1.ModelEvaluation.IBiasConfig} message BiasConfig message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ BiasConfig.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a BiasConfig message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig} BiasConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ BiasConfig.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.biasSlices = $root.google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.SliceSpec.decode(reader, reader.uint32());
+ break;
+ }
+ case 2: {
+ if (!(message.labels && message.labels.length))
+ message.labels = [];
+ message.labels.push(reader.string());
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a BiasConfig message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig} BiasConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ BiasConfig.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a BiasConfig message.
+ * @function verify
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ BiasConfig.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.biasSlices != null && message.hasOwnProperty("biasSlices")) {
+ var error = $root.google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.SliceSpec.verify(message.biasSlices);
+ if (error)
+ return "biasSlices." + error;
+ }
+ if (message.labels != null && message.hasOwnProperty("labels")) {
+ if (!Array.isArray(message.labels))
+ return "labels: array expected";
+ for (var i = 0; i < message.labels.length; ++i)
+ if (!$util.isString(message.labels[i]))
+ return "labels: string[] expected";
+ }
+ return null;
+ };
+
+ /**
+ * Creates a BiasConfig message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig} BiasConfig
+ */
+ BiasConfig.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig)
+ return object;
+ var message = new $root.google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig();
+ if (object.biasSlices != null) {
+ if (typeof object.biasSlices !== "object")
+ throw TypeError(".google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.biasSlices: object expected");
+ message.biasSlices = $root.google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.SliceSpec.fromObject(object.biasSlices);
+ }
+ if (object.labels) {
+ if (!Array.isArray(object.labels))
+ throw TypeError(".google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig.labels: array expected");
+ message.labels = [];
+ for (var i = 0; i < object.labels.length; ++i)
+ message.labels[i] = String(object.labels[i]);
+ }
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a BiasConfig message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig} message BiasConfig
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ BiasConfig.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.arrays || options.defaults)
+ object.labels = [];
+ if (options.defaults)
+ object.biasSlices = null;
+ if (message.biasSlices != null && message.hasOwnProperty("biasSlices"))
+ object.biasSlices = $root.google.cloud.aiplatform.v1beta1.ModelEvaluationSlice.Slice.SliceSpec.toObject(message.biasSlices, options);
+ if (message.labels && message.labels.length) {
+ object.labels = [];
+ for (var j = 0; j < message.labels.length; ++j)
+ object.labels[j] = message.labels[j];
+ }
+ return object;
+ };
+
+ /**
+ * Converts this BiasConfig to JSON.
+ * @function toJSON
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ BiasConfig.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for BiasConfig
+ * @function getTypeUrl
+ * @memberof google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ BiasConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.aiplatform.v1beta1.ModelEvaluation.BiasConfig";
+ };
+
+ return BiasConfig;
+ })();
+
return ModelEvaluation;
})();
diff --git a/packages/google-cloud-aiplatform/protos/protos.json b/packages/google-cloud-aiplatform/protos/protos.json
index 01ba6cca4b4..314cf2a6db0 100644
--- a/packages/google-cloud-aiplatform/protos/protos.json
+++ b/packages/google-cloud-aiplatform/protos/protos.json
@@ -13961,6 +13961,34 @@
}
]
},
+ "UpdateExplanationDataset": {
+ "requestType": "UpdateExplanationDatasetRequest",
+ "responseType": "google.longrunning.Operation",
+ "options": {
+ "(google.api.http).post": "/v1/{model=projects/*/locations/*/models/*}:updateExplanationDataset",
+ "(google.api.http).body": "*",
+ "(google.api.method_signature)": "model",
+ "(google.longrunning.operation_info).response_type": "UpdateExplanationDatasetResponse",
+ "(google.longrunning.operation_info).metadata_type": "UpdateExplanationDatasetOperationMetadata"
+ },
+ "parsedOptions": [
+ {
+ "(google.api.http)": {
+ "post": "/v1/{model=projects/*/locations/*/models/*}:updateExplanationDataset",
+ "body": "*"
+ }
+ },
+ {
+ "(google.api.method_signature)": "model"
+ },
+ {
+ "(google.longrunning.operation_info)": {
+ "response_type": "UpdateExplanationDatasetResponse",
+ "metadata_type": "UpdateExplanationDatasetOperationMetadata"
+ }
+ }
+ ]
+ },
"DeleteModel": {
"requestType": "DeleteModelRequest",
"responseType": "google.longrunning.Operation",
@@ -14409,6 +14437,30 @@
}
}
},
+ "UpdateExplanationDatasetRequest": {
+ "fields": {
+ "model": {
+ "type": "string",
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED",
+ "(google.api.resource_reference).type": "aiplatform.googleapis.com/Model"
+ }
+ },
+ "examples": {
+ "type": "Examples",
+ "id": 2
+ }
+ }
+ },
+ "UpdateExplanationDatasetOperationMetadata": {
+ "fields": {
+ "genericMetadata": {
+ "type": "GenericOperationMetadata",
+ "id": 1
+ }
+ }
+ },
"DeleteModelRequest": {
"fields": {
"name": {
@@ -14490,6 +14542,9 @@
}
}
},
+ "UpdateExplanationDatasetResponse": {
+ "fields": {}
+ },
"ExportModelOperationMetadata": {
"fields": {
"genericMetadata": {
@@ -33640,6 +33695,10 @@
"metadata": {
"type": "google.protobuf.Value",
"id": 11
+ },
+ "biasConfigs": {
+ "type": "BiasConfig",
+ "id": 12
}
},
"nested": {
@@ -33654,6 +33713,19 @@
"id": 2
}
}
+ },
+ "BiasConfig": {
+ "fields": {
+ "biasSlices": {
+ "type": "ModelEvaluationSlice.Slice.SliceSpec",
+ "id": 1
+ },
+ "labels": {
+ "rule": "repeated",
+ "type": "string",
+ "id": 2
+ }
+ }
}
}
},
diff --git a/packages/google-cloud-aiplatform/samples/README.md b/packages/google-cloud-aiplatform/samples/README.md
index 3820254c2b6..cb201739e77 100644
--- a/packages/google-cloud-aiplatform/samples/README.md
+++ b/packages/google-cloud-aiplatform/samples/README.md
@@ -158,6 +158,7 @@
* [Model_service.list_model_versions](#model_service.list_model_versions)
* [Model_service.list_models](#model_service.list_models)
* [Model_service.merge_version_aliases](#model_service.merge_version_aliases)
+ * [Model_service.update_explanation_dataset](#model_service.update_explanation_dataset)
* [Model_service.update_model](#model_service.update_model)
* [Model_service.upload_model](#model_service.upload_model)
* [Pipeline_service.cancel_pipeline_job](#pipeline_service.cancel_pipeline_job)
@@ -2944,6 +2945,23 @@ __Usage:__
+### Model_service.update_explanation_dataset
+
+View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js).
+
+[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js,samples/README.md)
+
+__Usage:__
+
+
+`node packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js`
+
+
+-----
+
+
+
+
### Model_service.update_model
View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_model.js).
diff --git a/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js b/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js
new file mode 100644
index 00000000000..ba7b6417369
--- /dev/null
+++ b/packages/google-cloud-aiplatform/samples/generated/v1/model_service.update_explanation_dataset.js
@@ -0,0 +1,67 @@
+// Copyright 2023 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// https://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// ** This file is automatically generated by gapic-generator-typescript. **
+// ** https://github.com/googleapis/gapic-generator-typescript **
+// ** All changes to this file may be overwritten. **
+
+
+
+'use strict';
+
+function main(model) {
+ // [START aiplatform_v1_generated_ModelService_UpdateExplanationDataset_async]
+ /**
+ * This snippet has been automatically generated and should be regarded as a code template only.
+ * It will require modifications to work.
+ * It may require correct/in-range values for request initialization.
+ * TODO(developer): Uncomment these variables before running the sample.
+ */
+ /**
+ * Required. The resource name of the Model to update.
+ * Format: `projects/{project}/locations/{location}/models/{model}`
+ */
+ // const model = 'abc123'
+ /**
+ * The example config containing the location of the dataset.
+ */
+ // const examples = {}
+
+ // Imports the Aiplatform library
+ const {ModelServiceClient} = require('@google-cloud/aiplatform').v1;
+
+ // Instantiates a client
+ const aiplatformClient = new ModelServiceClient();
+
+ async function callUpdateExplanationDataset() {
+ // Construct request
+ const request = {
+ model,
+ };
+
+ // Run request
+ const [operation] = await aiplatformClient.updateExplanationDataset(request);
+ const [response] = await operation.promise();
+ console.log(response);
+ }
+
+ callUpdateExplanationDataset();
+ // [END aiplatform_v1_generated_ModelService_UpdateExplanationDataset_async]
+}
+
+process.on('unhandledRejection', err => {
+ console.error(err.message);
+ process.exitCode = 1;
+});
+main(...process.argv.slice(2));
diff --git a/packages/google-cloud-aiplatform/samples/generated/v1/snippet_metadata.google.cloud.aiplatform.v1.json b/packages/google-cloud-aiplatform/samples/generated/v1/snippet_metadata.google.cloud.aiplatform.v1.json
index bab650854e3..a395906e327 100644
--- a/packages/google-cloud-aiplatform/samples/generated/v1/snippet_metadata.google.cloud.aiplatform.v1.json
+++ b/packages/google-cloud-aiplatform/samples/generated/v1/snippet_metadata.google.cloud.aiplatform.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-aiplatform",
- "version": "2.15.0",
+ "version": "2.16.0",
"language": "TYPESCRIPT",
"apis": [
{
@@ -6435,6 +6435,50 @@
}
}
},
+ {
+ "regionTag": "aiplatform_v1_generated_ModelService_UpdateExplanationDataset_async",
+ "title": "DatasetService updateExplanationDataset Sample",
+ "origin": "API_DEFINITION",
+ "description": " Incrementally update the dataset used for an examples model.",
+ "canonical": true,
+ "file": "model_service.update_explanation_dataset.js",
+ "language": "JAVASCRIPT",
+ "segments": [
+ {
+ "start": 25,
+ "end": 59,
+ "type": "FULL"
+ }
+ ],
+ "clientMethod": {
+ "shortName": "UpdateExplanationDataset",
+ "fullName": "google.cloud.aiplatform.v1.ModelService.UpdateExplanationDataset",
+ "async": true,
+ "parameters": [
+ {
+ "name": "model",
+ "type": "TYPE_STRING"
+ },
+ {
+ "name": "examples",
+ "type": ".google.cloud.aiplatform.v1.Examples"
+ }
+ ],
+ "resultType": ".google.longrunning.Operation",
+ "client": {
+ "shortName": "ModelServiceClient",
+ "fullName": "google.cloud.aiplatform.v1.ModelServiceClient"
+ },
+ "method": {
+ "shortName": "UpdateExplanationDataset",
+ "fullName": "google.cloud.aiplatform.v1.ModelService.UpdateExplanationDataset",
+ "service": {
+ "shortName": "ModelService",
+ "fullName": "google.cloud.aiplatform.v1.ModelService"
+ }
+ }
+ }
+ },
{
"regionTag": "aiplatform_v1_generated_ModelService_DeleteModel_async",
"title": "DatasetService deleteModel Sample",
diff --git a/packages/google-cloud-aiplatform/samples/generated/v1beta1/snippet_metadata.google.cloud.aiplatform.v1beta1.json b/packages/google-cloud-aiplatform/samples/generated/v1beta1/snippet_metadata.google.cloud.aiplatform.v1beta1.json
index c88f927ec5b..d45c26a3c7c 100644
--- a/packages/google-cloud-aiplatform/samples/generated/v1beta1/snippet_metadata.google.cloud.aiplatform.v1beta1.json
+++ b/packages/google-cloud-aiplatform/samples/generated/v1beta1/snippet_metadata.google.cloud.aiplatform.v1beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-aiplatform",
- "version": "2.15.0",
+ "version": "2.16.0",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-aiplatform/samples/package.json b/packages/google-cloud-aiplatform/samples/package.json
index 3e54b5f9442..3710987efd7 100644
--- a/packages/google-cloud-aiplatform/samples/package.json
+++ b/packages/google-cloud-aiplatform/samples/package.json
@@ -13,7 +13,7 @@
"test": "mocha --timeout 1200000 test/*.js"
},
"dependencies": {
- "@google-cloud/aiplatform": "^2.15.0"
+ "@google-cloud/aiplatform": "^2.16.0"
},
"devDependencies": {
"chai": "^4.2.0",
diff --git a/packages/google-cloud-aiplatform/src/v1/gapic_metadata.json b/packages/google-cloud-aiplatform/src/v1/gapic_metadata.json
index 10d41e70480..a3935f3cf87 100644
--- a/packages/google-cloud-aiplatform/src/v1/gapic_metadata.json
+++ b/packages/google-cloud-aiplatform/src/v1/gapic_metadata.json
@@ -1618,6 +1618,11 @@
"uploadModel"
]
},
+ "UpdateExplanationDataset": {
+ "methods": [
+ "updateExplanationDataset"
+ ]
+ },
"DeleteModel": {
"methods": [
"deleteModel"
@@ -1716,6 +1721,11 @@
"uploadModel"
]
},
+ "UpdateExplanationDataset": {
+ "methods": [
+ "updateExplanationDataset"
+ ]
+ },
"DeleteModel": {
"methods": [
"deleteModel"
diff --git a/packages/google-cloud-aiplatform/src/v1/model_service_client.ts b/packages/google-cloud-aiplatform/src/v1/model_service_client.ts
index 97de9b780c2..1a9851cfe83 100644
--- a/packages/google-cloud-aiplatform/src/v1/model_service_client.ts
+++ b/packages/google-cloud-aiplatform/src/v1/model_service_client.ts
@@ -1371,6 +1371,12 @@ export class ModelServiceClient {
const uploadModelMetadata = protoFilesRoot.lookup(
'.google.cloud.aiplatform.v1.UploadModelOperationMetadata'
) as gax.protobuf.Type;
+ const updateExplanationDatasetResponse = protoFilesRoot.lookup(
+ '.google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse'
+ ) as gax.protobuf.Type;
+ const updateExplanationDatasetMetadata = protoFilesRoot.lookup(
+ '.google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata'
+ ) as gax.protobuf.Type;
const deleteModelResponse = protoFilesRoot.lookup(
'.google.protobuf.Empty'
) as gax.protobuf.Type;
@@ -1402,6 +1408,15 @@ export class ModelServiceClient {
uploadModelResponse.decode.bind(uploadModelResponse),
uploadModelMetadata.decode.bind(uploadModelMetadata)
),
+ updateExplanationDataset: new this._gaxModule.LongrunningDescriptor(
+ this.operationsClient,
+ updateExplanationDatasetResponse.decode.bind(
+ updateExplanationDatasetResponse
+ ),
+ updateExplanationDatasetMetadata.decode.bind(
+ updateExplanationDatasetMetadata
+ )
+ ),
deleteModel: new this._gaxModule.LongrunningDescriptor(
this.operationsClient,
deleteModelResponse.decode.bind(deleteModelResponse),
@@ -1479,6 +1494,7 @@ export class ModelServiceClient {
'listModels',
'listModelVersions',
'updateModel',
+ 'updateExplanationDataset',
'deleteModel',
'deleteModelVersion',
'mergeVersionAliases',
@@ -2549,6 +2565,151 @@ export class ModelServiceClient {
protos.google.cloud.aiplatform.v1.UploadModelOperationMetadata
>;
}
+ /**
+ * Incrementally update the dataset used for an examples model.
+ *
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.model
+ * Required. The resource name of the Model to update.
+ * Format: `projects/{project}/locations/{location}/models/{model}`
+ * @param {google.cloud.aiplatform.v1.Examples} request.examples
+ * The example config containing the location of the dataset.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Promise} - The promise which resolves to an array.
+ * The first element of the array is an object representing
+ * a long running operation. Its `promise()` method returns a promise
+ * you can `await` for.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations)
+ * for more details and examples.
+ * @example include:samples/generated/v1/model_service.update_explanation_dataset.js
+ * region_tag:aiplatform_v1_generated_ModelService_UpdateExplanationDataset_async
+ */
+ updateExplanationDataset(
+ request?: protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest,
+ options?: CallOptions
+ ): Promise<
+ [
+ LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >,
+ protos.google.longrunning.IOperation | undefined,
+ {} | undefined
+ ]
+ >;
+ updateExplanationDataset(
+ request: protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest,
+ options: CallOptions,
+ callback: Callback<
+ LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >,
+ protos.google.longrunning.IOperation | null | undefined,
+ {} | null | undefined
+ >
+ ): void;
+ updateExplanationDataset(
+ request: protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest,
+ callback: Callback<
+ LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >,
+ protos.google.longrunning.IOperation | null | undefined,
+ {} | null | undefined
+ >
+ ): void;
+ updateExplanationDataset(
+ request?: protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetRequest,
+ optionsOrCallback?:
+ | CallOptions
+ | Callback<
+ LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >,
+ protos.google.longrunning.IOperation | null | undefined,
+ {} | null | undefined
+ >,
+ callback?: Callback<
+ LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >,
+ protos.google.longrunning.IOperation | null | undefined,
+ {} | null | undefined
+ >
+ ): Promise<
+ [
+ LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >,
+ protos.google.longrunning.IOperation | undefined,
+ {} | undefined
+ ]
+ > | void {
+ request = request || {};
+ let options: CallOptions;
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
+ callback = optionsOrCallback;
+ options = {};
+ } else {
+ options = optionsOrCallback as CallOptions;
+ }
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ model: request.model ?? '',
+ });
+ this.initialize();
+ return this.innerApiCalls.updateExplanationDataset(
+ request,
+ options,
+ callback
+ );
+ }
+ /**
+ * Check the status of the long running operation returned by `updateExplanationDataset()`.
+ * @param {String} name
+ * The operation name that will be passed.
+ * @returns {Promise} - The promise which resolves to an object.
+ * The decoded operation object has result and metadata field to get information from.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations)
+ * for more details and examples.
+ * @example include:samples/generated/v1/model_service.update_explanation_dataset.js
+ * region_tag:aiplatform_v1_generated_ModelService_UpdateExplanationDataset_async
+ */
+ async checkUpdateExplanationDatasetProgress(
+ name: string
+ ): Promise<
+ LROperation<
+ protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ >
+ > {
+ const request =
+ new this._gaxModule.operationsProtos.google.longrunning.GetOperationRequest(
+ {name}
+ );
+ const [operation] = await this.operationsClient.getOperation(request);
+ const decodeOperation = new this._gaxModule.Operation(
+ operation,
+ this.descriptors.longrunning.updateExplanationDataset,
+ this._gaxModule.createDefaultBackoffSettings()
+ );
+ return decodeOperation as LROperation<
+ protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetOperationMetadata
+ >;
+ }
/**
* Deletes a Model.
*
diff --git a/packages/google-cloud-aiplatform/src/v1/model_service_client_config.json b/packages/google-cloud-aiplatform/src/v1/model_service_client_config.json
index 705668228c5..ff3a5791cbb 100644
--- a/packages/google-cloud-aiplatform/src/v1/model_service_client_config.json
+++ b/packages/google-cloud-aiplatform/src/v1/model_service_client_config.json
@@ -40,6 +40,10 @@
"retry_codes_name": "non_idempotent",
"retry_params_name": "default"
},
+ "UpdateExplanationDataset": {
+ "retry_codes_name": "non_idempotent",
+ "retry_params_name": "default"
+ },
"DeleteModel": {
"retry_codes_name": "non_idempotent",
"retry_params_name": "default"
diff --git a/packages/google-cloud-aiplatform/test/gapic_model_service_v1.ts b/packages/google-cloud-aiplatform/test/gapic_model_service_v1.ts
index f6b1f2c518c..3859802e971 100644
--- a/packages/google-cloud-aiplatform/test/gapic_model_service_v1.ts
+++ b/packages/google-cloud-aiplatform/test/gapic_model_service_v1.ts
@@ -1524,6 +1524,204 @@ describe('v1.ModelServiceClient', () => {
});
});
+ describe('updateExplanationDataset', () => {
+ it('invokes updateExplanationDataset without error', async () => {
+ const client = new modelserviceModule.v1.ModelServiceClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest',
+ ['model']
+ );
+ request.model = defaultValue1;
+ const expectedHeaderRequestParams = `model=${defaultValue1}`;
+ const expectedResponse = generateSampleMessage(
+ new protos.google.longrunning.Operation()
+ );
+ client.innerApiCalls.updateExplanationDataset =
+ stubLongRunningCall(expectedResponse);
+ const [operation] = await client.updateExplanationDataset(request);
+ const [response] = await operation.promise();
+ assert.deepStrictEqual(response, expectedResponse);
+ const actualRequest = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes updateExplanationDataset without error using callback', async () => {
+ const client = new modelserviceModule.v1.ModelServiceClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest',
+ ['model']
+ );
+ request.model = defaultValue1;
+ const expectedHeaderRequestParams = `model=${defaultValue1}`;
+ const expectedResponse = generateSampleMessage(
+ new protos.google.longrunning.Operation()
+ );
+ client.innerApiCalls.updateExplanationDataset =
+ stubLongRunningCallWithCallback(expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.updateExplanationDataset(
+ request,
+ (
+ err?: Error | null,
+ result?: LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ > | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const operation = (await promise) as LROperation<
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetResponse,
+ protos.google.cloud.aiplatform.v1.IUpdateExplanationDatasetOperationMetadata
+ >;
+ const [response] = await operation.promise();
+ assert.deepStrictEqual(response, expectedResponse);
+ const actualRequest = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes updateExplanationDataset with call error', async () => {
+ const client = new modelserviceModule.v1.ModelServiceClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest',
+ ['model']
+ );
+ request.model = defaultValue1;
+ const expectedHeaderRequestParams = `model=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.innerApiCalls.updateExplanationDataset = stubLongRunningCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(
+ client.updateExplanationDataset(request),
+ expectedError
+ );
+ const actualRequest = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes updateExplanationDataset with LRO error', async () => {
+ const client = new modelserviceModule.v1.ModelServiceClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.aiplatform.v1.UpdateExplanationDatasetRequest',
+ ['model']
+ );
+ request.model = defaultValue1;
+ const expectedHeaderRequestParams = `model=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.innerApiCalls.updateExplanationDataset = stubLongRunningCall(
+ undefined,
+ undefined,
+ expectedError
+ );
+ const [operation] = await client.updateExplanationDataset(request);
+ await assert.rejects(operation.promise(), expectedError);
+ const actualRequest = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.updateExplanationDataset as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes checkUpdateExplanationDatasetProgress without error', async () => {
+ const client = new modelserviceModule.v1.ModelServiceClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const expectedResponse = generateSampleMessage(
+ new operationsProtos.google.longrunning.Operation()
+ );
+ expectedResponse.name = 'test';
+ expectedResponse.response = {type_url: 'url', value: Buffer.from('')};
+ expectedResponse.metadata = {type_url: 'url', value: Buffer.from('')};
+
+ client.operationsClient.getOperation = stubSimpleCall(expectedResponse);
+ const decodedOperation =
+ await client.checkUpdateExplanationDatasetProgress(
+ expectedResponse.name
+ );
+ assert.deepStrictEqual(decodedOperation.name, expectedResponse.name);
+ assert(decodedOperation.metadata);
+ assert((client.operationsClient.getOperation as SinonStub).getCall(0));
+ });
+
+ it('invokes checkUpdateExplanationDatasetProgress with error', async () => {
+ const client = new modelserviceModule.v1.ModelServiceClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ const expectedError = new Error('expected');
+
+ client.operationsClient.getOperation = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(
+ client.checkUpdateExplanationDatasetProgress(''),
+ expectedError
+ );
+ assert((client.operationsClient.getOperation as SinonStub).getCall(0));
+ });
+ });
+
describe('deleteModel', () => {
it('invokes deleteModel without error', async () => {
const client = new modelserviceModule.v1.ModelServiceClient({
diff --git a/packages/google-cloud-asset/CHANGELOG.md b/packages/google-cloud-asset/CHANGELOG.md
index e55a9dbe2ea..903e22d8e07 100644
--- a/packages/google-cloud-asset/CHANGELOG.md
+++ b/packages/google-cloud-asset/CHANGELOG.md
@@ -4,6 +4,13 @@
[1]: https://www.npmjs.com/package/@google-cloud/asset?activeTab=versions
+## [4.6.4](https://github.com/googleapis/google-cloud-node/compare/asset-v4.6.3...asset-v4.6.4) (2023-06-28)
+
+
+### Bug Fixes
+
+* **deps:** Update dependency yargs to v17 ([#4351](https://github.com/googleapis/google-cloud-node/issues/4351)) ([4fb5285](https://github.com/googleapis/google-cloud-node/commit/4fb528559c204cee33329c4e55021aa1fd0e4974))
+
## [4.6.3](https://github.com/googleapis/google-cloud-node/compare/asset-v4.6.2...asset-v4.6.3) (2023-04-13)
diff --git a/packages/google-cloud-asset/README.md b/packages/google-cloud-asset/README.md
index 7f5b4ed8ada..b6d832daec5 100644
--- a/packages/google-cloud-asset/README.md
+++ b/packages/google-cloud-asset/README.md
@@ -2,7 +2,7 @@
[//]: # "To regenerate it, use `python -m synthtool`."
-# [Cloud Asset Inventory: Node.js Client](https://github.com/googleapis/google-cloud-node)
+# [Cloud Asset Inventory: Node.js Client](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-asset)
[](https://cloud.google.com/terms/launch-stages)
[](https://www.npmjs.org/package/@google-cloud/asset)
@@ -96,46 +96,45 @@ listAssets();
## Samples
-Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/tree/main/samples) directory. Each sample's `README.md` has instructions for running its sample.
+Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-asset/samples) directory. Each sample's `README.md` has instructions for running its sample.
| Sample | Source Code | Try it |
| --------------------------- | --------------------------------- | ------ |
-| Asset_service.analyze_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy.js,samples/README.md) |
-| Asset_service.analyze_iam_policy_longrunning | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy_longrunning.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy_longrunning.js,samples/README.md) |
-| Asset_service.analyze_move | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_move.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_move.js,samples/README.md) |
-| Asset_service.analyze_org_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policies.js,samples/README.md) |
-| Asset_service.analyze_org_policy_governed_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_assets.js,samples/README.md) |
-| Asset_service.analyze_org_policy_governed_containers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_containers.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_containers.js,samples/README.md) |
-| Asset_service.batch_get_assets_history | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_assets_history.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_assets_history.js,samples/README.md) |
-| Asset_service.batch_get_effective_iam_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_effective_iam_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_effective_iam_policies.js,samples/README.md) |
-| Asset_service.create_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.create_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.create_feed.js,samples/README.md) |
-| Asset_service.create_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.create_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.create_saved_query.js,samples/README.md) |
-| Asset_service.delete_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.delete_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.delete_feed.js,samples/README.md) |
-| Asset_service.delete_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.delete_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.delete_saved_query.js,samples/README.md) |
-| Asset_service.export_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.export_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.export_assets.js,samples/README.md) |
-| Asset_service.get_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.get_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.get_feed.js,samples/README.md) |
-| Asset_service.get_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.get_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.get_saved_query.js,samples/README.md) |
-| Asset_service.list_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.list_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.list_assets.js,samples/README.md) |
-| Asset_service.list_feeds | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.list_feeds.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.list_feeds.js,samples/README.md) |
-| Asset_service.list_saved_queries | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.list_saved_queries.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.list_saved_queries.js,samples/README.md) |
-| Asset_service.query_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.query_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.query_assets.js,samples/README.md) |
-| Asset_service.search_all_iam_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_iam_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_iam_policies.js,samples/README.md) |
-| Asset_service.search_all_resources | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_resources.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_resources.js,samples/README.md) |
-| Asset_service.update_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.update_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.update_feed.js,samples/README.md) |
-| Asset_service.update_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.update_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.update_saved_query.js,samples/README.md) |
-| Asset_service.search_all_iam_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_iam_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_iam_policies.js,samples/README.md) |
-| Asset_service.search_all_resources | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_resources.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_resources.js,samples/README.md) |
-| Asset_service.create_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.create_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.create_feed.js,samples/README.md) |
-| Asset_service.delete_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.delete_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.delete_feed.js,samples/README.md) |
-| Asset_service.get_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.get_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.get_feed.js,samples/README.md) |
-| Asset_service.list_feeds | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.list_feeds.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.list_feeds.js,samples/README.md) |
-| Asset_service.update_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.update_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.update_feed.js,samples/README.md) |
-| Asset_service.analyze_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.analyze_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.analyze_iam_policy.js,samples/README.md) |
-| Asset_service.export_iam_policy_analysis | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.export_iam_policy_analysis.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.export_iam_policy_analysis.js,samples/README.md) |
-| Asset_service.list_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p5beta1/asset_service.list_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p5beta1/asset_service.list_assets.js,samples/README.md) |
-| Asset_service.export_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p7beta1/asset_service.export_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p7beta1/asset_service.export_assets.js,samples/README.md) |
-| List Assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/quickstart.js,samples/README.md) |
-| Sample.test | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/test/sample.test.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/test/sample.test.js,samples/README.md) |
+| Asset_service.analyze_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.analyze_iam_policy_longrunning | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy_longrunning.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_iam_policy_longrunning.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.analyze_move | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_move.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_move.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.analyze_org_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policies.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.analyze_org_policy_governed_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_assets.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.analyze_org_policy_governed_containers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_containers.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.analyze_org_policy_governed_containers.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.batch_get_assets_history | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_assets_history.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_assets_history.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.batch_get_effective_iam_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_effective_iam_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.batch_get_effective_iam_policies.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.create_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.create_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.create_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.create_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.create_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.create_saved_query.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.delete_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.delete_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.delete_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.delete_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.delete_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.delete_saved_query.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.export_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.export_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.export_assets.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.get_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.get_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.get_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.get_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.get_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.get_saved_query.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.list_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.list_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.list_assets.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.list_feeds | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.list_feeds.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.list_feeds.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.list_saved_queries | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.list_saved_queries.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.list_saved_queries.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.query_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.query_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.query_assets.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.search_all_iam_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_iam_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_iam_policies.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.search_all_resources | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_resources.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.search_all_resources.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.update_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.update_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.update_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.update_saved_query | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1/asset_service.update_saved_query.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1/asset_service.update_saved_query.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.search_all_iam_policies | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_iam_policies.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_iam_policies.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.search_all_resources | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_resources.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p1beta1/asset_service.search_all_resources.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.create_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.create_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.create_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.delete_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.delete_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.delete_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.get_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.get_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.get_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.list_feeds | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.list_feeds.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.list_feeds.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.update_feed | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.update_feed.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p2beta1/asset_service.update_feed.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.analyze_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.analyze_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.analyze_iam_policy.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.export_iam_policy_analysis | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.export_iam_policy_analysis.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p4beta1/asset_service.export_iam_policy_analysis.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.list_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p5beta1/asset_service.list_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p5beta1/asset_service.list_assets.js,packages/google-cloud-asset/samples/README.md) |
+| Asset_service.export_assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/generated/v1p7beta1/asset_service.export_assets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/generated/v1p7beta1/asset_service.export_assets.js,packages/google-cloud-asset/samples/README.md) |
+| List Assets | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/quickstart.js,packages/google-cloud-asset/samples/README.md) |
diff --git a/packages/google-cloud-asset/package.json b/packages/google-cloud-asset/package.json
index a7b974ff47f..ab127e57a56 100644
--- a/packages/google-cloud-asset/package.json
+++ b/packages/google-cloud-asset/package.json
@@ -1,7 +1,7 @@
{
"name": "@google-cloud/asset",
"description": "Cloud Asset API client for Node.js",
- "version": "4.6.3",
+ "version": "4.6.4",
"license": "Apache-2.0",
"author": "Google LLC",
"engines": {
diff --git a/packages/google-cloud-asset/samples/README.md b/packages/google-cloud-asset/samples/README.md
index d56af4da3f2..5074a9fbfa4 100644
--- a/packages/google-cloud-asset/samples/README.md
+++ b/packages/google-cloud-asset/samples/README.md
@@ -47,7 +47,6 @@
* [Asset_service.list_assets](#asset_service.list_assets)
* [Asset_service.export_assets](#asset_service.export_assets)
* [List Assets](#list-assets)
- * [Sample.test](#sample.test)
## Before you begin
@@ -656,23 +655,6 @@ __Usage:__
`node listAssets `
------
-
-
-
-
-### Sample.test
-
-View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-asset/samples/test/sample.test.js).
-
-[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-asset/samples/test/sample.test.js,samples/README.md)
-
-__Usage:__
-
-
-`node packages/google-cloud-asset/samples/test/sample.test.js`
-
-
diff --git a/packages/google-cloud-asset/samples/generated/v1/snippet_metadata.google.cloud.asset.v1.json b/packages/google-cloud-asset/samples/generated/v1/snippet_metadata.google.cloud.asset.v1.json
index 7bd010e20ce..4fd32c12683 100644
--- a/packages/google-cloud-asset/samples/generated/v1/snippet_metadata.google.cloud.asset.v1.json
+++ b/packages/google-cloud-asset/samples/generated/v1/snippet_metadata.google.cloud.asset.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-asset",
- "version": "4.6.2",
+ "version": "4.6.4",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-asset/samples/generated/v1p1beta1/snippet_metadata.google.cloud.asset.v1p1beta1.json b/packages/google-cloud-asset/samples/generated/v1p1beta1/snippet_metadata.google.cloud.asset.v1p1beta1.json
index c6711dc30ee..561740419bf 100644
--- a/packages/google-cloud-asset/samples/generated/v1p1beta1/snippet_metadata.google.cloud.asset.v1p1beta1.json
+++ b/packages/google-cloud-asset/samples/generated/v1p1beta1/snippet_metadata.google.cloud.asset.v1p1beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-asset",
- "version": "4.6.2",
+ "version": "4.6.4",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-asset/samples/generated/v1p2beta1/snippet_metadata.google.cloud.asset.v1p2beta1.json b/packages/google-cloud-asset/samples/generated/v1p2beta1/snippet_metadata.google.cloud.asset.v1p2beta1.json
index 026382f07b9..17bbb395f53 100644
--- a/packages/google-cloud-asset/samples/generated/v1p2beta1/snippet_metadata.google.cloud.asset.v1p2beta1.json
+++ b/packages/google-cloud-asset/samples/generated/v1p2beta1/snippet_metadata.google.cloud.asset.v1p2beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-asset",
- "version": "4.6.2",
+ "version": "4.6.4",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-asset/samples/generated/v1p4beta1/snippet_metadata.google.cloud.asset.v1p4beta1.json b/packages/google-cloud-asset/samples/generated/v1p4beta1/snippet_metadata.google.cloud.asset.v1p4beta1.json
index fbe09b25702..9962716fea9 100644
--- a/packages/google-cloud-asset/samples/generated/v1p4beta1/snippet_metadata.google.cloud.asset.v1p4beta1.json
+++ b/packages/google-cloud-asset/samples/generated/v1p4beta1/snippet_metadata.google.cloud.asset.v1p4beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-asset",
- "version": "4.6.2",
+ "version": "4.6.4",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-asset/samples/generated/v1p5beta1/snippet_metadata.google.cloud.asset.v1p5beta1.json b/packages/google-cloud-asset/samples/generated/v1p5beta1/snippet_metadata.google.cloud.asset.v1p5beta1.json
index 64319058fc6..18ec64ca924 100644
--- a/packages/google-cloud-asset/samples/generated/v1p5beta1/snippet_metadata.google.cloud.asset.v1p5beta1.json
+++ b/packages/google-cloud-asset/samples/generated/v1p5beta1/snippet_metadata.google.cloud.asset.v1p5beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-asset",
- "version": "4.6.2",
+ "version": "4.6.4",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-asset/samples/generated/v1p7beta1/snippet_metadata.google.cloud.asset.v1p7beta1.json b/packages/google-cloud-asset/samples/generated/v1p7beta1/snippet_metadata.google.cloud.asset.v1p7beta1.json
index e30f931be84..4db4d28bdb6 100644
--- a/packages/google-cloud-asset/samples/generated/v1p7beta1/snippet_metadata.google.cloud.asset.v1p7beta1.json
+++ b/packages/google-cloud-asset/samples/generated/v1p7beta1/snippet_metadata.google.cloud.asset.v1p7beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-asset",
- "version": "4.6.2",
+ "version": "4.6.4",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-asset/samples/package.json b/packages/google-cloud-asset/samples/package.json
index 537024234f3..d9a12305de8 100644
--- a/packages/google-cloud-asset/samples/package.json
+++ b/packages/google-cloud-asset/samples/package.json
@@ -15,12 +15,12 @@
"test": "mocha --timeout 600000"
},
"dependencies": {
- "@google-cloud/asset": "^4.6.3",
+ "@google-cloud/asset": "^4.6.4",
"@google-cloud/bigquery": "^6.0.0",
"@google-cloud/compute": "^3.0.0",
"@google-cloud/storage": "^6.0.0",
"uuid": "^9.0.0",
- "yargs": "^16.0.0"
+ "yargs": "^17.0.0"
},
"devDependencies": {
"chai": "^4.2.0",
diff --git a/packages/google-cloud-batch/CHANGELOG.md b/packages/google-cloud-batch/CHANGELOG.md
index f9ebedee8f1..afc7f438087 100644
--- a/packages/google-cloud-batch/CHANGELOG.md
+++ b/packages/google-cloud-batch/CHANGELOG.md
@@ -1,5 +1,12 @@
# Changelog
+## [0.10.0](https://github.com/googleapis/google-cloud-node/compare/batch-v0.9.0...batch-v0.10.0) (2023-07-04)
+
+
+### Features
+
+* [batch] Add gpu driver version field ([#4391](https://github.com/googleapis/google-cloud-node/issues/4391)) ([ec08d08](https://github.com/googleapis/google-cloud-node/commit/ec08d08cd2d8c03b61d9e7a8e7879ecfcb83475f))
+
## [0.9.0](https://github.com/googleapis/google-cloud-node/compare/batch-v0.8.0...batch-v0.9.0) (2023-06-14)
diff --git a/packages/google-cloud-batch/package.json b/packages/google-cloud-batch/package.json
index e9f739b553b..d36d4c527ae 100644
--- a/packages/google-cloud-batch/package.json
+++ b/packages/google-cloud-batch/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-cloud/batch",
- "version": "0.9.0",
+ "version": "0.10.0",
"description": "Batch client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-cloud-batch/protos/google/cloud/batch/v1/job.proto b/packages/google-cloud-batch/protos/google/cloud/batch/v1/job.proto
index 3abb5c9f0ab..54c71eba573 100644
--- a/packages/google-cloud-batch/protos/google/cloud/batch/v1/job.proto
+++ b/packages/google-cloud-batch/protos/google/cloud/batch/v1/job.proto
@@ -141,6 +141,7 @@ message JobStatus {
// Valid Job states.
enum State {
+ // Job state unspecified.
STATE_UNSPECIFIED = 0;
// Job is admitted (validated and persisted) and waiting for resources.
@@ -262,6 +263,7 @@ message AllocationPolicy {
// * "batch-debian": use Batch Debian images.
// * "batch-centos": use Batch CentOS images.
// * "batch-cos": use Batch Container-Optimized images.
+ // * "batch-hpc-centos": use Batch HPC CentOS images.
string image = 4;
// Name of a snapshot used as the data source.
diff --git a/packages/google-cloud-batch/protos/google/cloud/batch/v1alpha/job.proto b/packages/google-cloud-batch/protos/google/cloud/batch/v1alpha/job.proto
index 2feda464a54..acb29cd6998 100644
--- a/packages/google-cloud-batch/protos/google/cloud/batch/v1alpha/job.proto
+++ b/packages/google-cloud-batch/protos/google/cloud/batch/v1alpha/job.proto
@@ -191,6 +191,7 @@ message JobStatus {
// Valid Job states.
enum State {
+ // Job state unspecified.
STATE_UNSPECIFIED = 0;
// Job is admitted (validated and persisted) and waiting for resources.
@@ -326,6 +327,7 @@ message AllocationPolicy {
// * "batch-debian": use Batch Debian images.
// * "batch-centos": use Batch CentOS images.
// * "batch-cos": use Batch Container-Optimized images.
+ // * "batch-hpc-centos": use Batch HPC CentOS images.
string image = 4;
// Name of a snapshot used as the data source.
@@ -385,6 +387,11 @@ message AllocationPolicy {
// Deprecated: please use instances[0].install_gpu_drivers instead.
bool install_gpu_drivers = 3 [deprecated = true];
+
+ // The accelerator driver version that will be installed for this type.
+ //
+ // Not yet implemented.
+ string driver_version = 4;
}
// InstancePolicy describes an instance type and resources attached to each VM
diff --git a/packages/google-cloud-batch/protos/protos.d.ts b/packages/google-cloud-batch/protos/protos.d.ts
index 2abda2f25bf..a3baa91c64a 100644
--- a/packages/google-cloud-batch/protos/protos.d.ts
+++ b/packages/google-cloud-batch/protos/protos.d.ts
@@ -8073,6 +8073,9 @@ export namespace google {
/** Accelerator installGpuDrivers */
installGpuDrivers?: (boolean|null);
+
+ /** Accelerator driverVersion */
+ driverVersion?: (string|null);
}
/** Represents an Accelerator. */
@@ -8093,6 +8096,9 @@ export namespace google {
/** Accelerator installGpuDrivers. */
public installGpuDrivers: boolean;
+ /** Accelerator driverVersion. */
+ public driverVersion: string;
+
/**
* Creates a new Accelerator instance using the specified properties.
* @param [properties] Properties to set
diff --git a/packages/google-cloud-batch/protos/protos.js b/packages/google-cloud-batch/protos/protos.js
index 7a08a83a523..5aa98b5b04c 100644
--- a/packages/google-cloud-batch/protos/protos.js
+++ b/packages/google-cloud-batch/protos/protos.js
@@ -21095,6 +21095,7 @@
* @property {string|null} [type] Accelerator type
* @property {number|Long|null} [count] Accelerator count
* @property {boolean|null} [installGpuDrivers] Accelerator installGpuDrivers
+ * @property {string|null} [driverVersion] Accelerator driverVersion
*/
/**
@@ -21136,6 +21137,14 @@
*/
Accelerator.prototype.installGpuDrivers = false;
+ /**
+ * Accelerator driverVersion.
+ * @member {string} driverVersion
+ * @memberof google.cloud.batch.v1alpha.AllocationPolicy.Accelerator
+ * @instance
+ */
+ Accelerator.prototype.driverVersion = "";
+
/**
* Creates a new Accelerator instance using the specified properties.
* @function create
@@ -21166,6 +21175,8 @@
writer.uint32(/* id 2, wireType 0 =*/16).int64(message.count);
if (message.installGpuDrivers != null && Object.hasOwnProperty.call(message, "installGpuDrivers"))
writer.uint32(/* id 3, wireType 0 =*/24).bool(message.installGpuDrivers);
+ if (message.driverVersion != null && Object.hasOwnProperty.call(message, "driverVersion"))
+ writer.uint32(/* id 4, wireType 2 =*/34).string(message.driverVersion);
return writer;
};
@@ -21212,6 +21223,10 @@
message.installGpuDrivers = reader.bool();
break;
}
+ case 4: {
+ message.driverVersion = reader.string();
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -21256,6 +21271,9 @@
if (message.installGpuDrivers != null && message.hasOwnProperty("installGpuDrivers"))
if (typeof message.installGpuDrivers !== "boolean")
return "installGpuDrivers: boolean expected";
+ if (message.driverVersion != null && message.hasOwnProperty("driverVersion"))
+ if (!$util.isString(message.driverVersion))
+ return "driverVersion: string expected";
return null;
};
@@ -21284,6 +21302,8 @@
message.count = new $util.LongBits(object.count.low >>> 0, object.count.high >>> 0).toNumber();
if (object.installGpuDrivers != null)
message.installGpuDrivers = Boolean(object.installGpuDrivers);
+ if (object.driverVersion != null)
+ message.driverVersion = String(object.driverVersion);
return message;
};
@@ -21308,6 +21328,7 @@
} else
object.count = options.longs === String ? "0" : 0;
object.installGpuDrivers = false;
+ object.driverVersion = "";
}
if (message.type != null && message.hasOwnProperty("type"))
object.type = message.type;
@@ -21318,6 +21339,8 @@
object.count = options.longs === String ? $util.Long.prototype.toString.call(message.count) : options.longs === Number ? new $util.LongBits(message.count.low >>> 0, message.count.high >>> 0).toNumber() : message.count;
if (message.installGpuDrivers != null && message.hasOwnProperty("installGpuDrivers"))
object.installGpuDrivers = message.installGpuDrivers;
+ if (message.driverVersion != null && message.hasOwnProperty("driverVersion"))
+ object.driverVersion = message.driverVersion;
return object;
};
diff --git a/packages/google-cloud-batch/protos/protos.json b/packages/google-cloud-batch/protos/protos.json
index 26af10caa15..1f958d861e1 100644
--- a/packages/google-cloud-batch/protos/protos.json
+++ b/packages/google-cloud-batch/protos/protos.json
@@ -1966,6 +1966,10 @@
"options": {
"deprecated": true
}
+ },
+ "driverVersion": {
+ "type": "string",
+ "id": 4
}
}
},
diff --git a/packages/google-cloud-batch/samples/generated/v1/snippet_metadata.google.cloud.batch.v1.json b/packages/google-cloud-batch/samples/generated/v1/snippet_metadata.google.cloud.batch.v1.json
index 1659c6fa77b..dc85170b113 100644
--- a/packages/google-cloud-batch/samples/generated/v1/snippet_metadata.google.cloud.batch.v1.json
+++ b/packages/google-cloud-batch/samples/generated/v1/snippet_metadata.google.cloud.batch.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-batch",
- "version": "0.9.0",
+ "version": "0.10.0",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-batch/samples/generated/v1alpha/snippet_metadata.google.cloud.batch.v1alpha.json b/packages/google-cloud-batch/samples/generated/v1alpha/snippet_metadata.google.cloud.batch.v1alpha.json
index b04e105dd33..0870c11c306 100644
--- a/packages/google-cloud-batch/samples/generated/v1alpha/snippet_metadata.google.cloud.batch.v1alpha.json
+++ b/packages/google-cloud-batch/samples/generated/v1alpha/snippet_metadata.google.cloud.batch.v1alpha.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-batch",
- "version": "0.9.0",
+ "version": "0.10.0",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-batch/samples/package.json b/packages/google-cloud-batch/samples/package.json
index 4143612ea2e..13dd419962d 100644
--- a/packages/google-cloud-batch/samples/package.json
+++ b/packages/google-cloud-batch/samples/package.json
@@ -14,7 +14,7 @@
"publish": "echo 'sample test; do not publish'"
},
"dependencies": {
- "@google-cloud/batch": "^0.9.0"
+ "@google-cloud/batch": "^0.10.0"
},
"devDependencies": {
"c8": "^7.1.0",
diff --git a/packages/google-cloud-billing/CHANGELOG.md b/packages/google-cloud-billing/CHANGELOG.md
index a7458951cbb..d952a402c93 100644
--- a/packages/google-cloud-billing/CHANGELOG.md
+++ b/packages/google-cloud-billing/CHANGELOG.md
@@ -1,5 +1,12 @@
# Changelog
+## [3.4.0](https://github.com/googleapis/google-cloud-node/compare/billing-v3.3.2...billing-v3.4.0) (2023-06-28)
+
+
+### Features
+
+* [billing] added resource_reference for name in GetProjectBillingInfoRequest message ([#4356](https://github.com/googleapis/google-cloud-node/issues/4356)) ([a77e51f](https://github.com/googleapis/google-cloud-node/commit/a77e51fe3fc235676189525f6a582844a830cc99))
+
## [3.3.2](https://github.com/googleapis/google-cloud-node/compare/billing-v3.3.1...billing-v3.3.2) (2023-04-13)
diff --git a/packages/google-cloud-billing/README.md b/packages/google-cloud-billing/README.md
index f91fec725cc..104dc88395a 100644
--- a/packages/google-cloud-billing/README.md
+++ b/packages/google-cloud-billing/README.md
@@ -2,7 +2,7 @@
[//]: # "To regenerate it, use `python -m synthtool`."
-# [Cloud Billing: Node.js Client](https://github.com/googleapis/google-cloud-node)
+# [Cloud Billing: Node.js Client](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-billing)
[](https://cloud.google.com/terms/launch-stages)
[](https://www.npmjs.org/package/@google-cloud/billing)
@@ -84,24 +84,23 @@ listBillingAccounts();
## Samples
-Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/tree/main/samples) directory. Each sample's `README.md` has instructions for running its sample.
+Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-cloud-billing/samples) directory. Each sample's `README.md` has instructions for running its sample.
| Sample | Source Code | Try it |
| --------------------------- | --------------------------------- | ------ |
-| Cloud_billing.create_billing_account | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.create_billing_account.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.create_billing_account.js,samples/README.md) |
-| Cloud_billing.get_billing_account | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_billing_account.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_billing_account.js,samples/README.md) |
-| Cloud_billing.get_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_iam_policy.js,samples/README.md) |
-| Cloud_billing.get_project_billing_info | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_project_billing_info.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_project_billing_info.js,samples/README.md) |
-| Cloud_billing.list_billing_accounts | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_billing_accounts.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_billing_accounts.js,samples/README.md) |
-| Cloud_billing.list_project_billing_info | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_project_billing_info.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_project_billing_info.js,samples/README.md) |
-| Cloud_billing.set_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.set_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.set_iam_policy.js,samples/README.md) |
-| Cloud_billing.test_iam_permissions | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.test_iam_permissions.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.test_iam_permissions.js,samples/README.md) |
-| Cloud_billing.update_billing_account | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_billing_account.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_billing_account.js,samples/README.md) |
-| Cloud_billing.update_project_billing_info | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_project_billing_info.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_project_billing_info.js,samples/README.md) |
-| Cloud_catalog.list_services | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_services.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_services.js,samples/README.md) |
-| Cloud_catalog.list_skus | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_skus.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_skus.js,samples/README.md) |
-| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/quickstart.js,samples/README.md) |
-| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/test/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/test/quickstart.js,samples/README.md) |
+| Cloud_billing.create_billing_account | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.create_billing_account.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.create_billing_account.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.get_billing_account | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_billing_account.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_billing_account.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.get_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_iam_policy.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.get_project_billing_info | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_project_billing_info.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.get_project_billing_info.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.list_billing_accounts | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_billing_accounts.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_billing_accounts.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.list_project_billing_info | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_project_billing_info.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.list_project_billing_info.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.set_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.set_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.set_iam_policy.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.test_iam_permissions | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.test_iam_permissions.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.test_iam_permissions.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.update_billing_account | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_billing_account.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_billing_account.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_billing.update_project_billing_info | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_project_billing_info.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_billing.update_project_billing_info.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_catalog.list_services | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_services.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_services.js,packages/google-cloud-billing/samples/README.md) |
+| Cloud_catalog.list_skus | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_skus.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/generated/v1/cloud_catalog.list_skus.js,packages/google-cloud-billing/samples/README.md) |
+| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/quickstart.js,packages/google-cloud-billing/samples/README.md) |
diff --git a/packages/google-cloud-billing/package.json b/packages/google-cloud-billing/package.json
index 7bbc9ae5557..36e9278dc39 100644
--- a/packages/google-cloud-billing/package.json
+++ b/packages/google-cloud-billing/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-cloud/billing",
- "version": "3.3.2",
+ "version": "3.4.0",
"description": "Billing client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-cloud-billing/protos/google/cloud/billing/v1/cloud_billing.proto b/packages/google-cloud-billing/protos/google/cloud/billing/v1/cloud_billing.proto
index 213967d9eee..ae64248d637 100644
--- a/packages/google-cloud-billing/protos/google/cloud/billing/v1/cloud_billing.proto
+++ b/packages/google-cloud-billing/protos/google/cloud/billing/v1/cloud_billing.proto
@@ -239,26 +239,32 @@ message BillingAccount {
// project has at most one associated billing account at a time (but a billing
// account can be assigned to multiple projects).
message ProjectBillingInfo {
- // The resource name for the `ProjectBillingInfo`; has the form
+ option (google.api.resource) = {
+ type: "cloudbilling.googleapis.com/ProjectBillingInfo"
+ pattern: "projects/{project}/billingInfo"
+ };
+
+ // Output only. The resource name for the `ProjectBillingInfo`; has the form
// `projects/{project_id}/billingInfo`. For example, the resource name for the
// billing information for project `tokyo-rain-123` would be
// `projects/tokyo-rain-123/billingInfo`. This field is read-only.
- string name = 1;
+ string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
- // The ID of the project that this `ProjectBillingInfo` represents, such as
- // `tokyo-rain-123`. This is a convenience field so that you don't need to
- // parse the `name` field to obtain a project ID. This field is read-only.
- string project_id = 2;
+ // Output only. The ID of the project that this `ProjectBillingInfo`
+ // represents, such as `tokyo-rain-123`. This is a convenience field so that
+ // you don't need to parse the `name` field to obtain a project ID. This field
+ // is read-only.
+ string project_id = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
// The resource name of the billing account associated with the project, if
// any. For example, `billingAccounts/012345-567890-ABCDEF`.
string billing_account_name = 3;
- // True if the project is associated with an open billing account, to which
- // usage on the project is charged. False if the project is associated with a
- // closed billing account, or no billing account at all, and therefore cannot
- // use paid services. This field is read-only.
- bool billing_enabled = 4;
+ // Output only. True if the project is associated with an open billing
+ // account, to which usage on the project is charged. False if the project is
+ // associated with a closed billing account, or no billing account at all, and
+ // therefore cannot use paid services. This field is read-only.
+ bool billing_enabled = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
}
// Request message for `GetBillingAccount`.
@@ -370,7 +376,12 @@ message ListProjectBillingInfoResponse {
message GetProjectBillingInfoRequest {
// Required. The resource name of the project for which billing information is
// retrieved. For example, `projects/tokyo-rain-123`.
- string name = 1 [(google.api.field_behavior) = REQUIRED];
+ string name = 1 [
+ (google.api.field_behavior) = REQUIRED,
+ (google.api.resource_reference) = {
+ type: "cloudbilling.googleapis.com/ProjectBillingInfo"
+ }
+ ];
}
// Request message for `UpdateProjectBillingInfo`.
diff --git a/packages/google-cloud-billing/protos/protos.json b/packages/google-cloud-billing/protos/protos.json
index 57e1430804e..cfde46b727b 100644
--- a/packages/google-cloud-billing/protos/protos.json
+++ b/packages/google-cloud-billing/protos/protos.json
@@ -242,14 +242,24 @@
}
},
"ProjectBillingInfo": {
+ "options": {
+ "(google.api.resource).type": "cloudbilling.googleapis.com/ProjectBillingInfo",
+ "(google.api.resource).pattern": "projects/{project}/billingInfo"
+ },
"fields": {
"name": {
"type": "string",
- "id": 1
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "OUTPUT_ONLY"
+ }
},
"projectId": {
"type": "string",
- "id": 2
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "OUTPUT_ONLY"
+ }
},
"billingAccountName": {
"type": "string",
@@ -257,7 +267,10 @@
},
"billingEnabled": {
"type": "bool",
- "id": 4
+ "id": 4,
+ "options": {
+ "(google.api.field_behavior)": "OUTPUT_ONLY"
+ }
}
}
},
@@ -375,7 +388,8 @@
"type": "string",
"id": 1,
"options": {
- "(google.api.field_behavior)": "REQUIRED"
+ "(google.api.field_behavior)": "REQUIRED",
+ "(google.api.resource_reference).type": "cloudbilling.googleapis.com/ProjectBillingInfo"
}
}
}
diff --git a/packages/google-cloud-billing/samples/README.md b/packages/google-cloud-billing/samples/README.md
index e03c9bc784e..4f0048d7f02 100644
--- a/packages/google-cloud-billing/samples/README.md
+++ b/packages/google-cloud-billing/samples/README.md
@@ -25,7 +25,6 @@
* [Cloud_catalog.list_services](#cloud_catalog.list_services)
* [Cloud_catalog.list_skus](#cloud_catalog.list_skus)
* [Quickstart](#quickstart)
- * [Quickstart](#quickstart)
## Before you begin
@@ -258,23 +257,6 @@ __Usage:__
`node packages/google-cloud-billing/samples/quickstart.js`
------
-
-
-
-
-### Quickstart
-
-View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-billing/samples/test/quickstart.js).
-
-[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-billing/samples/test/quickstart.js,samples/README.md)
-
-__Usage:__
-
-
-`node packages/google-cloud-billing/samples/test/quickstart.js`
-
-
diff --git a/packages/google-cloud-billing/samples/generated/v1/snippet_metadata.google.cloud.billing.v1.json b/packages/google-cloud-billing/samples/generated/v1/snippet_metadata.google.cloud.billing.v1.json
index 86471f1dee0..aa164bf58d5 100644
--- a/packages/google-cloud-billing/samples/generated/v1/snippet_metadata.google.cloud.billing.v1.json
+++ b/packages/google-cloud-billing/samples/generated/v1/snippet_metadata.google.cloud.billing.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-billing",
- "version": "3.3.1",
+ "version": "3.4.0",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-billing/samples/package.json b/packages/google-cloud-billing/samples/package.json
index 9b562c74bde..49984ade98e 100644
--- a/packages/google-cloud-billing/samples/package.json
+++ b/packages/google-cloud-billing/samples/package.json
@@ -13,7 +13,7 @@
"test": "c8 mocha --timeout 600000 test/*.js"
},
"dependencies": {
- "@google-cloud/billing": "^3.3.2"
+ "@google-cloud/billing": "^3.4.0"
},
"devDependencies": {
"c8": "^7.1.0",
diff --git a/packages/google-cloud-billing/src/v1/cloud_billing_client.ts b/packages/google-cloud-billing/src/v1/cloud_billing_client.ts
index a775297baeb..1b1edb1d2dc 100644
--- a/packages/google-cloud-billing/src/v1/cloud_billing_client.ts
+++ b/packages/google-cloud-billing/src/v1/cloud_billing_client.ts
@@ -182,6 +182,9 @@ export class CloudBillingClient {
billingAccountPathTemplate: new this._gaxModule.PathTemplate(
'billingAccounts/{billing_account}'
),
+ projectBillingInfoPathTemplate: new this._gaxModule.PathTemplate(
+ 'projects/{project}/billingInfo'
+ ),
servicePathTemplate: new this._gaxModule.PathTemplate(
'services/{service}'
),
@@ -1609,6 +1612,31 @@ export class CloudBillingClient {
).billing_account;
}
+ /**
+ * Return a fully-qualified projectBillingInfo resource name string.
+ *
+ * @param {string} project
+ * @returns {string} Resource name string.
+ */
+ projectBillingInfoPath(project: string) {
+ return this.pathTemplates.projectBillingInfoPathTemplate.render({
+ project: project,
+ });
+ }
+
+ /**
+ * Parse the project from ProjectBillingInfo resource.
+ *
+ * @param {string} projectBillingInfoName
+ * A fully-qualified path representing ProjectBillingInfo resource.
+ * @returns {string} A string representing the project.
+ */
+ matchProjectFromProjectBillingInfoName(projectBillingInfoName: string) {
+ return this.pathTemplates.projectBillingInfoPathTemplate.match(
+ projectBillingInfoName
+ ).project;
+ }
+
/**
* Return a fully-qualified service resource name string.
*
diff --git a/packages/google-cloud-billing/src/v1/cloud_catalog_client.ts b/packages/google-cloud-billing/src/v1/cloud_catalog_client.ts
index a7f63761b12..be58d3310db 100644
--- a/packages/google-cloud-billing/src/v1/cloud_catalog_client.ts
+++ b/packages/google-cloud-billing/src/v1/cloud_catalog_client.ts
@@ -180,6 +180,9 @@ export class CloudCatalogClient {
// identifiers to uniquely identify resources within the API.
// Create useful helper objects for these.
this.pathTemplates = {
+ projectBillingInfoPathTemplate: new this._gaxModule.PathTemplate(
+ 'projects/{project}/billingInfo'
+ ),
servicePathTemplate: new this._gaxModule.PathTemplate(
'services/{service}'
),
@@ -760,6 +763,31 @@ export class CloudCatalogClient {
// -- Path templates --
// --------------------
+ /**
+ * Return a fully-qualified projectBillingInfo resource name string.
+ *
+ * @param {string} project
+ * @returns {string} Resource name string.
+ */
+ projectBillingInfoPath(project: string) {
+ return this.pathTemplates.projectBillingInfoPathTemplate.render({
+ project: project,
+ });
+ }
+
+ /**
+ * Parse the project from ProjectBillingInfo resource.
+ *
+ * @param {string} projectBillingInfoName
+ * A fully-qualified path representing ProjectBillingInfo resource.
+ * @returns {string} A string representing the project.
+ */
+ matchProjectFromProjectBillingInfoName(projectBillingInfoName: string) {
+ return this.pathTemplates.projectBillingInfoPathTemplate.match(
+ projectBillingInfoName
+ ).project;
+ }
+
/**
* Return a fully-qualified service resource name string.
*
diff --git a/packages/google-cloud-billing/test/gapic_cloud_billing_v1.ts b/packages/google-cloud-billing/test/gapic_cloud_billing_v1.ts
index f0625f299a5..fe4d000464c 100644
--- a/packages/google-cloud-billing/test/gapic_cloud_billing_v1.ts
+++ b/packages/google-cloud-billing/test/gapic_cloud_billing_v1.ts
@@ -1860,6 +1860,50 @@ describe('v1.CloudBillingClient', () => {
});
});
+ describe('projectBillingInfo', () => {
+ const fakePath = '/rendered/path/projectBillingInfo';
+ const expectedParameters = {
+ project: 'projectValue',
+ };
+ const client = new cloudbillingModule.v1.CloudBillingClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ client.pathTemplates.projectBillingInfoPathTemplate.render = sinon
+ .stub()
+ .returns(fakePath);
+ client.pathTemplates.projectBillingInfoPathTemplate.match = sinon
+ .stub()
+ .returns(expectedParameters);
+
+ it('projectBillingInfoPath', () => {
+ const result = client.projectBillingInfoPath('projectValue');
+ assert.strictEqual(result, fakePath);
+ assert(
+ (
+ client.pathTemplates.projectBillingInfoPathTemplate
+ .render as SinonStub
+ )
+ .getCall(-1)
+ .calledWith(expectedParameters)
+ );
+ });
+
+ it('matchProjectFromProjectBillingInfoName', () => {
+ const result = client.matchProjectFromProjectBillingInfoName(fakePath);
+ assert.strictEqual(result, 'projectValue');
+ assert(
+ (
+ client.pathTemplates.projectBillingInfoPathTemplate
+ .match as SinonStub
+ )
+ .getCall(-1)
+ .calledWith(fakePath)
+ );
+ });
+ });
+
describe('service', () => {
const fakePath = '/rendered/path/service';
const expectedParameters = {
diff --git a/packages/google-cloud-billing/test/gapic_cloud_catalog_v1.ts b/packages/google-cloud-billing/test/gapic_cloud_catalog_v1.ts
index 5d622d5061c..a82ba426aa2 100644
--- a/packages/google-cloud-billing/test/gapic_cloud_catalog_v1.ts
+++ b/packages/google-cloud-billing/test/gapic_cloud_catalog_v1.ts
@@ -729,6 +729,50 @@ describe('v1.CloudCatalogClient', () => {
});
describe('Path templates', () => {
+ describe('projectBillingInfo', () => {
+ const fakePath = '/rendered/path/projectBillingInfo';
+ const expectedParameters = {
+ project: 'projectValue',
+ };
+ const client = new cloudcatalogModule.v1.CloudCatalogClient({
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ });
+ client.initialize();
+ client.pathTemplates.projectBillingInfoPathTemplate.render = sinon
+ .stub()
+ .returns(fakePath);
+ client.pathTemplates.projectBillingInfoPathTemplate.match = sinon
+ .stub()
+ .returns(expectedParameters);
+
+ it('projectBillingInfoPath', () => {
+ const result = client.projectBillingInfoPath('projectValue');
+ assert.strictEqual(result, fakePath);
+ assert(
+ (
+ client.pathTemplates.projectBillingInfoPathTemplate
+ .render as SinonStub
+ )
+ .getCall(-1)
+ .calledWith(expectedParameters)
+ );
+ });
+
+ it('matchProjectFromProjectBillingInfoName', () => {
+ const result = client.matchProjectFromProjectBillingInfoName(fakePath);
+ assert.strictEqual(result, 'projectValue');
+ assert(
+ (
+ client.pathTemplates.projectBillingInfoPathTemplate
+ .match as SinonStub
+ )
+ .getCall(-1)
+ .calledWith(fakePath)
+ );
+ });
+ });
+
describe('service', () => {
const fakePath = '/rendered/path/service';
const expectedParameters = {
diff --git a/packages/google-cloud-channel/CHANGELOG.md b/packages/google-cloud-channel/CHANGELOG.md
index cc436c2641f..fd3397d0ec2 100644
--- a/packages/google-cloud-channel/CHANGELOG.md
+++ b/packages/google-cloud-channel/CHANGELOG.md
@@ -1,5 +1,12 @@
# Changelog
+## [2.8.0](https://github.com/googleapis/google-cloud-node/compare/channel-v2.7.0...channel-v2.8.0) (2023-06-28)
+
+
+### Features
+
+* [channel] Add support for ListSkuGroups and ListSkuGroupBillableSkus APIs in Cloud Channel APIs ([#4348](https://github.com/googleapis/google-cloud-node/issues/4348)) ([926d727](https://github.com/googleapis/google-cloud-node/commit/926d727f25951f9199e3f02d419a41dbb8e1c824))
+
## [2.7.0](https://github.com/googleapis/google-cloud-node/compare/channel-v2.6.0...channel-v2.7.0) (2023-05-20)
diff --git a/packages/google-cloud-channel/README.md b/packages/google-cloud-channel/README.md
index 0cfc51added..04192f48bb5 100644
--- a/packages/google-cloud-channel/README.md
+++ b/packages/google-cloud-channel/README.md
@@ -207,6 +207,8 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/
| Cloud_channel_service.list_products | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_products.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_products.js,packages/google-cloud-channel/samples/README.md) |
| Cloud_channel_service.list_purchasable_offers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_purchasable_offers.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_purchasable_offers.js,packages/google-cloud-channel/samples/README.md) |
| Cloud_channel_service.list_purchasable_skus | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_purchasable_skus.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_purchasable_skus.js,packages/google-cloud-channel/samples/README.md) |
+| Cloud_channel_service.list_sku_group_billable_skus | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js,packages/google-cloud-channel/samples/README.md) |
+| Cloud_channel_service.list_sku_groups | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js,packages/google-cloud-channel/samples/README.md) |
| Cloud_channel_service.list_skus | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_skus.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_skus.js,packages/google-cloud-channel/samples/README.md) |
| Cloud_channel_service.list_subscribers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_subscribers.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_subscribers.js,packages/google-cloud-channel/samples/README.md) |
| Cloud_channel_service.list_transferable_offers | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_transferable_offers.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_transferable_offers.js,packages/google-cloud-channel/samples/README.md) |
diff --git a/packages/google-cloud-channel/package.json b/packages/google-cloud-channel/package.json
index e01c005770c..2b48daa1b54 100644
--- a/packages/google-cloud-channel/package.json
+++ b/packages/google-cloud-channel/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-cloud/channel",
- "version": "2.7.0",
+ "version": "2.8.0",
"description": "Channel client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-cloud-channel/protos/google/cloud/channel/v1/service.proto b/packages/google-cloud-channel/protos/google/cloud/channel/v1/service.proto
index ec62a437832..eee63aea794 100644
--- a/packages/google-cloud-channel/protos/google/cloud/channel/v1/service.proto
+++ b/packages/google-cloud-channel/protos/google/cloud/channel/v1/service.proto
@@ -1185,6 +1185,59 @@ service CloudChannelService {
option (google.api.method_signature) = "name";
}
+ // Lists the Rebilling supported SKU groups the account is authorized to
+ // sell.
+ // Reference: https://cloud.google.com/skus/sku-groups
+ //
+ // Possible Error Codes:
+ //
+ // * PERMISSION_DENIED: If the account making the request and the account
+ // being queried are different, or the account doesn't exist.
+ // * INTERNAL: Any non-user error related to technical issues in the
+ // backend. In this case, contact Cloud Channel support.
+ //
+ // Return Value:
+ // If successful, the [SkuGroup][google.cloud.channel.v1.SkuGroup] resources.
+ // The data for each resource is displayed in the alphabetical order of SKU
+ // group display name.
+ // The data for each resource is displayed in the ascending order of
+ // [SkuGroup.display_name][google.cloud.channel.v1.SkuGroup.display_name]
+ //
+ // If unsuccessful, returns an error.
+ rpc ListSkuGroups(ListSkuGroupsRequest) returns (ListSkuGroupsResponse) {
+ option (google.api.http) = {
+ get: "/v1/{parent=accounts/*}/skuGroups"
+ };
+ option (google.api.method_signature) = "parent";
+ }
+
+ // Lists the Billable SKUs in a given SKU group.
+ //
+ // Possible error codes:
+ // PERMISSION_DENIED: If the account making the request and the account
+ // being queried for are different, or the account doesn't exist.
+ // INVALID_ARGUMENT: Missing or invalid required parameters in the
+ // request.
+ // INTERNAL: Any non-user error related to technical issue in the
+ // backend. In this case, contact cloud channel support.
+ //
+ // Return Value:
+ // If successful, the [BillableSku][google.cloud.channel.v1.BillableSku]
+ // resources. The data for each resource is displayed in the ascending order
+ // of:
+ //
+ // * [BillableSku.service_display_name][google.cloud.channel.v1.BillableSku.service_display_name]
+ // * [BillableSku.sku_display_name][google.cloud.channel.v1.BillableSku.sku_display_name]
+ //
+ // If unsuccessful, returns an error.
+ rpc ListSkuGroupBillableSkus(ListSkuGroupBillableSkusRequest)
+ returns (ListSkuGroupBillableSkusResponse) {
+ option (google.api.http) = {
+ get: "/v1/{parent=accounts/*/skuGroups/*}/billableSkus"
+ };
+ option (google.api.method_signature) = "parent";
+ }
+
// Returns the requested [Offer][google.cloud.channel.v1.Offer] resource.
//
// Possible error codes:
@@ -2035,6 +2088,110 @@ message DeleteChannelPartnerRepricingConfigRequest {
];
}
+// Request message for ListSkuGroups.
+message ListSkuGroupsRequest {
+ // Required. The resource name of the account from which to list SKU groups.
+ // Parent uses the format: accounts/{account}.
+ string parent = 1 [(google.api.field_behavior) = REQUIRED];
+
+ // Optional. The maximum number of SKU groups to return. The service may
+ // return fewer than this value. If unspecified, returns a maximum of 1000 SKU
+ // groups. The maximum value is 1000; values above 1000 will be coerced to
+ // 1000.
+ int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL];
+
+ // Optional. A token identifying a page of results beyond the first page.
+ // Obtained through
+ // [ListSkuGroups.next_page_token][] of the previous
+ // [CloudChannelService.ListSkuGroups][google.cloud.channel.v1.CloudChannelService.ListSkuGroups]
+ // call.
+ string page_token = 3 [(google.api.field_behavior) = OPTIONAL];
+}
+
+// Request message for ListSkuGroupBillableSkus.
+message ListSkuGroupBillableSkusRequest {
+ // Required. Resource name of the SKU group.
+ // Format: accounts/{account}/skuGroups/{sku_group}.
+ string parent = 1 [
+ (google.api.field_behavior) = REQUIRED,
+ (google.api.resource_reference) = {
+ type: "cloudchannel.googleapis.com/SkuGroup"
+ }
+ ];
+
+ // Optional. The maximum number of SKUs to return. The service may return
+ // fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
+ // The maximum value is 100000; values above 100000 will be coerced to 100000.
+ int32 page_size = 2 [(google.api.field_behavior) = OPTIONAL];
+
+ // Optional. A token identifying a page of results beyond the first page.
+ // Obtained through
+ // [ListSkuGroupBillableSkus.next_page_token][] of the previous
+ // [CloudChannelService.ListSkuGroupBillableSkus][google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus]
+ // call.
+ string page_token = 3 [(google.api.field_behavior) = OPTIONAL];
+}
+
+// Response message for ListSkuGroups.
+message ListSkuGroupsResponse {
+ // The list of SKU groups requested.
+ repeated SkuGroup sku_groups = 1;
+
+ // A token to retrieve the next page of results.
+ // Pass to [ListSkuGroups.page_token][] to obtain that
+ // page.
+ string next_page_token = 2;
+}
+
+// Response message for ListSkuGroupBillableSkus.
+message ListSkuGroupBillableSkusResponse {
+ // The list of billable SKUs in the requested SKU group.
+ repeated BillableSku billable_skus = 1;
+
+ // A token to retrieve the next page of results.
+ // Pass to [ListSkuGroupBillableSkus.page_token][] to obtain that
+ // page.
+ string next_page_token = 2;
+}
+
+// Represents the SKU group information.
+message SkuGroup {
+ option (google.api.resource) = {
+ type: "cloudchannel.googleapis.com/SkuGroup"
+ pattern: "accounts/{account}/skuGroups/{sku_group}"
+ };
+
+ // Resource name of SKU group. Format:
+ // accounts/{account}/skuGroups/{sku_group}.
+ // Example:
+ // "accounts/C01234/skuGroups/3d50fd57-3157-4577-a5a9-a219b8490041".
+ string name = 1;
+
+ // Unique human readable identifier for the SKU group.
+ string display_name = 2;
+}
+
+// Represents the Billable SKU information.
+message BillableSku {
+ // Resource name of Billable SKU. Format:
+ // billableSkus/{sku}.
+ // Example:
+ // billableSkus/6E1B-6634-470F".
+ string sku = 1;
+
+ // Unique human readable name for the SKU.
+ string sku_display_name = 2;
+
+ // Resource name of Service which contains Repricing SKU. Format:
+ // services/{service}.
+ // Example:
+ // "services/B7D9-FDCB-15D8".
+ string service = 3;
+
+ // Unique human readable name for the Service.
+ string service_display_name = 4;
+}
+
// Request message for
// [CloudChannelService.CreateEntitlement][google.cloud.channel.v1.CloudChannelService.CreateEntitlement]
message CreateEntitlementRequest {
diff --git a/packages/google-cloud-channel/protos/protos.d.ts b/packages/google-cloud-channel/protos/protos.d.ts
index 65d67f415aa..82d9b36725d 100644
--- a/packages/google-cloud-channel/protos/protos.d.ts
+++ b/packages/google-cloud-channel/protos/protos.d.ts
@@ -7279,6 +7279,34 @@ export namespace google {
*/
public deleteChannelPartnerRepricingConfig(request: google.cloud.channel.v1.IDeleteChannelPartnerRepricingConfigRequest): Promise;
+ /**
+ * Calls ListSkuGroups.
+ * @param request ListSkuGroupsRequest message or plain object
+ * @param callback Node-style callback called with the error, if any, and ListSkuGroupsResponse
+ */
+ public listSkuGroups(request: google.cloud.channel.v1.IListSkuGroupsRequest, callback: google.cloud.channel.v1.CloudChannelService.ListSkuGroupsCallback): void;
+
+ /**
+ * Calls ListSkuGroups.
+ * @param request ListSkuGroupsRequest message or plain object
+ * @returns Promise
+ */
+ public listSkuGroups(request: google.cloud.channel.v1.IListSkuGroupsRequest): Promise;
+
+ /**
+ * Calls ListSkuGroupBillableSkus.
+ * @param request ListSkuGroupBillableSkusRequest message or plain object
+ * @param callback Node-style callback called with the error, if any, and ListSkuGroupBillableSkusResponse
+ */
+ public listSkuGroupBillableSkus(request: google.cloud.channel.v1.IListSkuGroupBillableSkusRequest, callback: google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkusCallback): void;
+
+ /**
+ * Calls ListSkuGroupBillableSkus.
+ * @param request ListSkuGroupBillableSkusRequest message or plain object
+ * @returns Promise
+ */
+ public listSkuGroupBillableSkus(request: google.cloud.channel.v1.IListSkuGroupBillableSkusRequest): Promise;
+
/**
* Calls LookupOffer.
* @param request LookupOfferRequest message or plain object
@@ -7674,6 +7702,20 @@ export namespace google {
*/
type DeleteChannelPartnerRepricingConfigCallback = (error: (Error|null), response?: google.protobuf.Empty) => void;
+ /**
+ * Callback as used by {@link google.cloud.channel.v1.CloudChannelService|listSkuGroups}.
+ * @param error Error, if any
+ * @param [response] ListSkuGroupsResponse
+ */
+ type ListSkuGroupsCallback = (error: (Error|null), response?: google.cloud.channel.v1.ListSkuGroupsResponse) => void;
+
+ /**
+ * Callback as used by {@link google.cloud.channel.v1.CloudChannelService|listSkuGroupBillableSkus}.
+ * @param error Error, if any
+ * @param [response] ListSkuGroupBillableSkusResponse
+ */
+ type ListSkuGroupBillableSkusCallback = (error: (Error|null), response?: google.cloud.channel.v1.ListSkuGroupBillableSkusResponse) => void;
+
/**
* Callback as used by {@link google.cloud.channel.v1.CloudChannelService|lookupOffer}.
* @param error Error, if any
@@ -11570,6 +11612,648 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ /** Properties of a ListSkuGroupsRequest. */
+ interface IListSkuGroupsRequest {
+
+ /** ListSkuGroupsRequest parent */
+ parent?: (string|null);
+
+ /** ListSkuGroupsRequest pageSize */
+ pageSize?: (number|null);
+
+ /** ListSkuGroupsRequest pageToken */
+ pageToken?: (string|null);
+ }
+
+ /** Represents a ListSkuGroupsRequest. */
+ class ListSkuGroupsRequest implements IListSkuGroupsRequest {
+
+ /**
+ * Constructs a new ListSkuGroupsRequest.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.channel.v1.IListSkuGroupsRequest);
+
+ /** ListSkuGroupsRequest parent. */
+ public parent: string;
+
+ /** ListSkuGroupsRequest pageSize. */
+ public pageSize: number;
+
+ /** ListSkuGroupsRequest pageToken. */
+ public pageToken: string;
+
+ /**
+ * Creates a new ListSkuGroupsRequest instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns ListSkuGroupsRequest instance
+ */
+ public static create(properties?: google.cloud.channel.v1.IListSkuGroupsRequest): google.cloud.channel.v1.ListSkuGroupsRequest;
+
+ /**
+ * Encodes the specified ListSkuGroupsRequest message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsRequest.verify|verify} messages.
+ * @param message ListSkuGroupsRequest message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.channel.v1.IListSkuGroupsRequest, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified ListSkuGroupsRequest message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsRequest.verify|verify} messages.
+ * @param message ListSkuGroupsRequest message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.channel.v1.IListSkuGroupsRequest, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a ListSkuGroupsRequest message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns ListSkuGroupsRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.channel.v1.ListSkuGroupsRequest;
+
+ /**
+ * Decodes a ListSkuGroupsRequest message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns ListSkuGroupsRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.channel.v1.ListSkuGroupsRequest;
+
+ /**
+ * Verifies a ListSkuGroupsRequest message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a ListSkuGroupsRequest message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns ListSkuGroupsRequest
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.channel.v1.ListSkuGroupsRequest;
+
+ /**
+ * Creates a plain object from a ListSkuGroupsRequest message. Also converts values to other types if specified.
+ * @param message ListSkuGroupsRequest
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.channel.v1.ListSkuGroupsRequest, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this ListSkuGroupsRequest to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for ListSkuGroupsRequest
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of a ListSkuGroupBillableSkusRequest. */
+ interface IListSkuGroupBillableSkusRequest {
+
+ /** ListSkuGroupBillableSkusRequest parent */
+ parent?: (string|null);
+
+ /** ListSkuGroupBillableSkusRequest pageSize */
+ pageSize?: (number|null);
+
+ /** ListSkuGroupBillableSkusRequest pageToken */
+ pageToken?: (string|null);
+ }
+
+ /** Represents a ListSkuGroupBillableSkusRequest. */
+ class ListSkuGroupBillableSkusRequest implements IListSkuGroupBillableSkusRequest {
+
+ /**
+ * Constructs a new ListSkuGroupBillableSkusRequest.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.channel.v1.IListSkuGroupBillableSkusRequest);
+
+ /** ListSkuGroupBillableSkusRequest parent. */
+ public parent: string;
+
+ /** ListSkuGroupBillableSkusRequest pageSize. */
+ public pageSize: number;
+
+ /** ListSkuGroupBillableSkusRequest pageToken. */
+ public pageToken: string;
+
+ /**
+ * Creates a new ListSkuGroupBillableSkusRequest instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns ListSkuGroupBillableSkusRequest instance
+ */
+ public static create(properties?: google.cloud.channel.v1.IListSkuGroupBillableSkusRequest): google.cloud.channel.v1.ListSkuGroupBillableSkusRequest;
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusRequest message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusRequest.verify|verify} messages.
+ * @param message ListSkuGroupBillableSkusRequest message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.channel.v1.IListSkuGroupBillableSkusRequest, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusRequest message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusRequest.verify|verify} messages.
+ * @param message ListSkuGroupBillableSkusRequest message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.channel.v1.IListSkuGroupBillableSkusRequest, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusRequest message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns ListSkuGroupBillableSkusRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.channel.v1.ListSkuGroupBillableSkusRequest;
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusRequest message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns ListSkuGroupBillableSkusRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.channel.v1.ListSkuGroupBillableSkusRequest;
+
+ /**
+ * Verifies a ListSkuGroupBillableSkusRequest message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a ListSkuGroupBillableSkusRequest message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns ListSkuGroupBillableSkusRequest
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.channel.v1.ListSkuGroupBillableSkusRequest;
+
+ /**
+ * Creates a plain object from a ListSkuGroupBillableSkusRequest message. Also converts values to other types if specified.
+ * @param message ListSkuGroupBillableSkusRequest
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.channel.v1.ListSkuGroupBillableSkusRequest, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this ListSkuGroupBillableSkusRequest to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for ListSkuGroupBillableSkusRequest
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of a ListSkuGroupsResponse. */
+ interface IListSkuGroupsResponse {
+
+ /** ListSkuGroupsResponse skuGroups */
+ skuGroups?: (google.cloud.channel.v1.ISkuGroup[]|null);
+
+ /** ListSkuGroupsResponse nextPageToken */
+ nextPageToken?: (string|null);
+ }
+
+ /** Represents a ListSkuGroupsResponse. */
+ class ListSkuGroupsResponse implements IListSkuGroupsResponse {
+
+ /**
+ * Constructs a new ListSkuGroupsResponse.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.channel.v1.IListSkuGroupsResponse);
+
+ /** ListSkuGroupsResponse skuGroups. */
+ public skuGroups: google.cloud.channel.v1.ISkuGroup[];
+
+ /** ListSkuGroupsResponse nextPageToken. */
+ public nextPageToken: string;
+
+ /**
+ * Creates a new ListSkuGroupsResponse instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns ListSkuGroupsResponse instance
+ */
+ public static create(properties?: google.cloud.channel.v1.IListSkuGroupsResponse): google.cloud.channel.v1.ListSkuGroupsResponse;
+
+ /**
+ * Encodes the specified ListSkuGroupsResponse message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsResponse.verify|verify} messages.
+ * @param message ListSkuGroupsResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.channel.v1.IListSkuGroupsResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified ListSkuGroupsResponse message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsResponse.verify|verify} messages.
+ * @param message ListSkuGroupsResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.channel.v1.IListSkuGroupsResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a ListSkuGroupsResponse message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns ListSkuGroupsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.channel.v1.ListSkuGroupsResponse;
+
+ /**
+ * Decodes a ListSkuGroupsResponse message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns ListSkuGroupsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.channel.v1.ListSkuGroupsResponse;
+
+ /**
+ * Verifies a ListSkuGroupsResponse message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a ListSkuGroupsResponse message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns ListSkuGroupsResponse
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.channel.v1.ListSkuGroupsResponse;
+
+ /**
+ * Creates a plain object from a ListSkuGroupsResponse message. Also converts values to other types if specified.
+ * @param message ListSkuGroupsResponse
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.channel.v1.ListSkuGroupsResponse, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this ListSkuGroupsResponse to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for ListSkuGroupsResponse
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of a ListSkuGroupBillableSkusResponse. */
+ interface IListSkuGroupBillableSkusResponse {
+
+ /** ListSkuGroupBillableSkusResponse billableSkus */
+ billableSkus?: (google.cloud.channel.v1.IBillableSku[]|null);
+
+ /** ListSkuGroupBillableSkusResponse nextPageToken */
+ nextPageToken?: (string|null);
+ }
+
+ /** Represents a ListSkuGroupBillableSkusResponse. */
+ class ListSkuGroupBillableSkusResponse implements IListSkuGroupBillableSkusResponse {
+
+ /**
+ * Constructs a new ListSkuGroupBillableSkusResponse.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.channel.v1.IListSkuGroupBillableSkusResponse);
+
+ /** ListSkuGroupBillableSkusResponse billableSkus. */
+ public billableSkus: google.cloud.channel.v1.IBillableSku[];
+
+ /** ListSkuGroupBillableSkusResponse nextPageToken. */
+ public nextPageToken: string;
+
+ /**
+ * Creates a new ListSkuGroupBillableSkusResponse instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns ListSkuGroupBillableSkusResponse instance
+ */
+ public static create(properties?: google.cloud.channel.v1.IListSkuGroupBillableSkusResponse): google.cloud.channel.v1.ListSkuGroupBillableSkusResponse;
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusResponse message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusResponse.verify|verify} messages.
+ * @param message ListSkuGroupBillableSkusResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.channel.v1.IListSkuGroupBillableSkusResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusResponse message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusResponse.verify|verify} messages.
+ * @param message ListSkuGroupBillableSkusResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.channel.v1.IListSkuGroupBillableSkusResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusResponse message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns ListSkuGroupBillableSkusResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.channel.v1.ListSkuGroupBillableSkusResponse;
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusResponse message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns ListSkuGroupBillableSkusResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.channel.v1.ListSkuGroupBillableSkusResponse;
+
+ /**
+ * Verifies a ListSkuGroupBillableSkusResponse message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a ListSkuGroupBillableSkusResponse message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns ListSkuGroupBillableSkusResponse
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.channel.v1.ListSkuGroupBillableSkusResponse;
+
+ /**
+ * Creates a plain object from a ListSkuGroupBillableSkusResponse message. Also converts values to other types if specified.
+ * @param message ListSkuGroupBillableSkusResponse
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.channel.v1.ListSkuGroupBillableSkusResponse, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this ListSkuGroupBillableSkusResponse to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for ListSkuGroupBillableSkusResponse
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of a SkuGroup. */
+ interface ISkuGroup {
+
+ /** SkuGroup name */
+ name?: (string|null);
+
+ /** SkuGroup displayName */
+ displayName?: (string|null);
+ }
+
+ /** Represents a SkuGroup. */
+ class SkuGroup implements ISkuGroup {
+
+ /**
+ * Constructs a new SkuGroup.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.channel.v1.ISkuGroup);
+
+ /** SkuGroup name. */
+ public name: string;
+
+ /** SkuGroup displayName. */
+ public displayName: string;
+
+ /**
+ * Creates a new SkuGroup instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns SkuGroup instance
+ */
+ public static create(properties?: google.cloud.channel.v1.ISkuGroup): google.cloud.channel.v1.SkuGroup;
+
+ /**
+ * Encodes the specified SkuGroup message. Does not implicitly {@link google.cloud.channel.v1.SkuGroup.verify|verify} messages.
+ * @param message SkuGroup message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.channel.v1.ISkuGroup, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified SkuGroup message, length delimited. Does not implicitly {@link google.cloud.channel.v1.SkuGroup.verify|verify} messages.
+ * @param message SkuGroup message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.channel.v1.ISkuGroup, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a SkuGroup message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns SkuGroup
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.channel.v1.SkuGroup;
+
+ /**
+ * Decodes a SkuGroup message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns SkuGroup
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.channel.v1.SkuGroup;
+
+ /**
+ * Verifies a SkuGroup message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a SkuGroup message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns SkuGroup
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.channel.v1.SkuGroup;
+
+ /**
+ * Creates a plain object from a SkuGroup message. Also converts values to other types if specified.
+ * @param message SkuGroup
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.channel.v1.SkuGroup, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this SkuGroup to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for SkuGroup
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of a BillableSku. */
+ interface IBillableSku {
+
+ /** BillableSku sku */
+ sku?: (string|null);
+
+ /** BillableSku skuDisplayName */
+ skuDisplayName?: (string|null);
+
+ /** BillableSku service */
+ service?: (string|null);
+
+ /** BillableSku serviceDisplayName */
+ serviceDisplayName?: (string|null);
+ }
+
+ /** Represents a BillableSku. */
+ class BillableSku implements IBillableSku {
+
+ /**
+ * Constructs a new BillableSku.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.channel.v1.IBillableSku);
+
+ /** BillableSku sku. */
+ public sku: string;
+
+ /** BillableSku skuDisplayName. */
+ public skuDisplayName: string;
+
+ /** BillableSku service. */
+ public service: string;
+
+ /** BillableSku serviceDisplayName. */
+ public serviceDisplayName: string;
+
+ /**
+ * Creates a new BillableSku instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns BillableSku instance
+ */
+ public static create(properties?: google.cloud.channel.v1.IBillableSku): google.cloud.channel.v1.BillableSku;
+
+ /**
+ * Encodes the specified BillableSku message. Does not implicitly {@link google.cloud.channel.v1.BillableSku.verify|verify} messages.
+ * @param message BillableSku message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.channel.v1.IBillableSku, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified BillableSku message, length delimited. Does not implicitly {@link google.cloud.channel.v1.BillableSku.verify|verify} messages.
+ * @param message BillableSku message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.channel.v1.IBillableSku, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a BillableSku message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns BillableSku
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.channel.v1.BillableSku;
+
+ /**
+ * Decodes a BillableSku message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns BillableSku
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.channel.v1.BillableSku;
+
+ /**
+ * Verifies a BillableSku message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a BillableSku message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns BillableSku
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.channel.v1.BillableSku;
+
+ /**
+ * Creates a plain object from a BillableSku message. Also converts values to other types if specified.
+ * @param message BillableSku
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.channel.v1.BillableSku, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this BillableSku to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for BillableSku
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a CreateEntitlementRequest. */
interface ICreateEntitlementRequest {
diff --git a/packages/google-cloud-channel/protos/protos.js b/packages/google-cloud-channel/protos/protos.js
index 1720f0346d8..db53a53c11e 100644
--- a/packages/google-cloud-channel/protos/protos.js
+++ b/packages/google-cloud-channel/protos/protos.js
@@ -18873,6 +18873,72 @@
* @variation 2
*/
+ /**
+ * Callback as used by {@link google.cloud.channel.v1.CloudChannelService|listSkuGroups}.
+ * @memberof google.cloud.channel.v1.CloudChannelService
+ * @typedef ListSkuGroupsCallback
+ * @type {function}
+ * @param {Error|null} error Error, if any
+ * @param {google.cloud.channel.v1.ListSkuGroupsResponse} [response] ListSkuGroupsResponse
+ */
+
+ /**
+ * Calls ListSkuGroups.
+ * @function listSkuGroups
+ * @memberof google.cloud.channel.v1.CloudChannelService
+ * @instance
+ * @param {google.cloud.channel.v1.IListSkuGroupsRequest} request ListSkuGroupsRequest message or plain object
+ * @param {google.cloud.channel.v1.CloudChannelService.ListSkuGroupsCallback} callback Node-style callback called with the error, if any, and ListSkuGroupsResponse
+ * @returns {undefined}
+ * @variation 1
+ */
+ Object.defineProperty(CloudChannelService.prototype.listSkuGroups = function listSkuGroups(request, callback) {
+ return this.rpcCall(listSkuGroups, $root.google.cloud.channel.v1.ListSkuGroupsRequest, $root.google.cloud.channel.v1.ListSkuGroupsResponse, request, callback);
+ }, "name", { value: "ListSkuGroups" });
+
+ /**
+ * Calls ListSkuGroups.
+ * @function listSkuGroups
+ * @memberof google.cloud.channel.v1.CloudChannelService
+ * @instance
+ * @param {google.cloud.channel.v1.IListSkuGroupsRequest} request ListSkuGroupsRequest message or plain object
+ * @returns {Promise} Promise
+ * @variation 2
+ */
+
+ /**
+ * Callback as used by {@link google.cloud.channel.v1.CloudChannelService|listSkuGroupBillableSkus}.
+ * @memberof google.cloud.channel.v1.CloudChannelService
+ * @typedef ListSkuGroupBillableSkusCallback
+ * @type {function}
+ * @param {Error|null} error Error, if any
+ * @param {google.cloud.channel.v1.ListSkuGroupBillableSkusResponse} [response] ListSkuGroupBillableSkusResponse
+ */
+
+ /**
+ * Calls ListSkuGroupBillableSkus.
+ * @function listSkuGroupBillableSkus
+ * @memberof google.cloud.channel.v1.CloudChannelService
+ * @instance
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusRequest} request ListSkuGroupBillableSkusRequest message or plain object
+ * @param {google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkusCallback} callback Node-style callback called with the error, if any, and ListSkuGroupBillableSkusResponse
+ * @returns {undefined}
+ * @variation 1
+ */
+ Object.defineProperty(CloudChannelService.prototype.listSkuGroupBillableSkus = function listSkuGroupBillableSkus(request, callback) {
+ return this.rpcCall(listSkuGroupBillableSkus, $root.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest, $root.google.cloud.channel.v1.ListSkuGroupBillableSkusResponse, request, callback);
+ }, "name", { value: "ListSkuGroupBillableSkus" });
+
+ /**
+ * Calls ListSkuGroupBillableSkus.
+ * @function listSkuGroupBillableSkus
+ * @memberof google.cloud.channel.v1.CloudChannelService
+ * @instance
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusRequest} request ListSkuGroupBillableSkusRequest message or plain object
+ * @returns {Promise} Promise
+ * @variation 2
+ */
+
/**
* Callback as used by {@link google.cloud.channel.v1.CloudChannelService|lookupOffer}.
* @memberof google.cloud.channel.v1.CloudChannelService
@@ -28137,6 +28203,1502 @@
return DeleteChannelPartnerRepricingConfigRequest;
})();
+ v1.ListSkuGroupsRequest = (function() {
+
+ /**
+ * Properties of a ListSkuGroupsRequest.
+ * @memberof google.cloud.channel.v1
+ * @interface IListSkuGroupsRequest
+ * @property {string|null} [parent] ListSkuGroupsRequest parent
+ * @property {number|null} [pageSize] ListSkuGroupsRequest pageSize
+ * @property {string|null} [pageToken] ListSkuGroupsRequest pageToken
+ */
+
+ /**
+ * Constructs a new ListSkuGroupsRequest.
+ * @memberof google.cloud.channel.v1
+ * @classdesc Represents a ListSkuGroupsRequest.
+ * @implements IListSkuGroupsRequest
+ * @constructor
+ * @param {google.cloud.channel.v1.IListSkuGroupsRequest=} [properties] Properties to set
+ */
+ function ListSkuGroupsRequest(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * ListSkuGroupsRequest parent.
+ * @member {string} parent
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @instance
+ */
+ ListSkuGroupsRequest.prototype.parent = "";
+
+ /**
+ * ListSkuGroupsRequest pageSize.
+ * @member {number} pageSize
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @instance
+ */
+ ListSkuGroupsRequest.prototype.pageSize = 0;
+
+ /**
+ * ListSkuGroupsRequest pageToken.
+ * @member {string} pageToken
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @instance
+ */
+ ListSkuGroupsRequest.prototype.pageToken = "";
+
+ /**
+ * Creates a new ListSkuGroupsRequest instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupsRequest=} [properties] Properties to set
+ * @returns {google.cloud.channel.v1.ListSkuGroupsRequest} ListSkuGroupsRequest instance
+ */
+ ListSkuGroupsRequest.create = function create(properties) {
+ return new ListSkuGroupsRequest(properties);
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupsRequest message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsRequest.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupsRequest} message ListSkuGroupsRequest message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupsRequest.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.parent != null && Object.hasOwnProperty.call(message, "parent"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent);
+ if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize"))
+ writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize);
+ if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken"))
+ writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupsRequest message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsRequest.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupsRequest} message ListSkuGroupsRequest message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupsRequest.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a ListSkuGroupsRequest message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.channel.v1.ListSkuGroupsRequest} ListSkuGroupsRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupsRequest.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.channel.v1.ListSkuGroupsRequest();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.parent = reader.string();
+ break;
+ }
+ case 2: {
+ message.pageSize = reader.int32();
+ break;
+ }
+ case 3: {
+ message.pageToken = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a ListSkuGroupsRequest message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.channel.v1.ListSkuGroupsRequest} ListSkuGroupsRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupsRequest.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a ListSkuGroupsRequest message.
+ * @function verify
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ ListSkuGroupsRequest.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.parent != null && message.hasOwnProperty("parent"))
+ if (!$util.isString(message.parent))
+ return "parent: string expected";
+ if (message.pageSize != null && message.hasOwnProperty("pageSize"))
+ if (!$util.isInteger(message.pageSize))
+ return "pageSize: integer expected";
+ if (message.pageToken != null && message.hasOwnProperty("pageToken"))
+ if (!$util.isString(message.pageToken))
+ return "pageToken: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a ListSkuGroupsRequest message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.channel.v1.ListSkuGroupsRequest} ListSkuGroupsRequest
+ */
+ ListSkuGroupsRequest.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.channel.v1.ListSkuGroupsRequest)
+ return object;
+ var message = new $root.google.cloud.channel.v1.ListSkuGroupsRequest();
+ if (object.parent != null)
+ message.parent = String(object.parent);
+ if (object.pageSize != null)
+ message.pageSize = object.pageSize | 0;
+ if (object.pageToken != null)
+ message.pageToken = String(object.pageToken);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a ListSkuGroupsRequest message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {google.cloud.channel.v1.ListSkuGroupsRequest} message ListSkuGroupsRequest
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ ListSkuGroupsRequest.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.parent = "";
+ object.pageSize = 0;
+ object.pageToken = "";
+ }
+ if (message.parent != null && message.hasOwnProperty("parent"))
+ object.parent = message.parent;
+ if (message.pageSize != null && message.hasOwnProperty("pageSize"))
+ object.pageSize = message.pageSize;
+ if (message.pageToken != null && message.hasOwnProperty("pageToken"))
+ object.pageToken = message.pageToken;
+ return object;
+ };
+
+ /**
+ * Converts this ListSkuGroupsRequest to JSON.
+ * @function toJSON
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ ListSkuGroupsRequest.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for ListSkuGroupsRequest
+ * @function getTypeUrl
+ * @memberof google.cloud.channel.v1.ListSkuGroupsRequest
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ ListSkuGroupsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.channel.v1.ListSkuGroupsRequest";
+ };
+
+ return ListSkuGroupsRequest;
+ })();
+
+ v1.ListSkuGroupBillableSkusRequest = (function() {
+
+ /**
+ * Properties of a ListSkuGroupBillableSkusRequest.
+ * @memberof google.cloud.channel.v1
+ * @interface IListSkuGroupBillableSkusRequest
+ * @property {string|null} [parent] ListSkuGroupBillableSkusRequest parent
+ * @property {number|null} [pageSize] ListSkuGroupBillableSkusRequest pageSize
+ * @property {string|null} [pageToken] ListSkuGroupBillableSkusRequest pageToken
+ */
+
+ /**
+ * Constructs a new ListSkuGroupBillableSkusRequest.
+ * @memberof google.cloud.channel.v1
+ * @classdesc Represents a ListSkuGroupBillableSkusRequest.
+ * @implements IListSkuGroupBillableSkusRequest
+ * @constructor
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusRequest=} [properties] Properties to set
+ */
+ function ListSkuGroupBillableSkusRequest(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * ListSkuGroupBillableSkusRequest parent.
+ * @member {string} parent
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @instance
+ */
+ ListSkuGroupBillableSkusRequest.prototype.parent = "";
+
+ /**
+ * ListSkuGroupBillableSkusRequest pageSize.
+ * @member {number} pageSize
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @instance
+ */
+ ListSkuGroupBillableSkusRequest.prototype.pageSize = 0;
+
+ /**
+ * ListSkuGroupBillableSkusRequest pageToken.
+ * @member {string} pageToken
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @instance
+ */
+ ListSkuGroupBillableSkusRequest.prototype.pageToken = "";
+
+ /**
+ * Creates a new ListSkuGroupBillableSkusRequest instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusRequest=} [properties] Properties to set
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusRequest} ListSkuGroupBillableSkusRequest instance
+ */
+ ListSkuGroupBillableSkusRequest.create = function create(properties) {
+ return new ListSkuGroupBillableSkusRequest(properties);
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusRequest message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusRequest.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusRequest} message ListSkuGroupBillableSkusRequest message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupBillableSkusRequest.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.parent != null && Object.hasOwnProperty.call(message, "parent"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent);
+ if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize"))
+ writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize);
+ if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken"))
+ writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusRequest message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusRequest.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusRequest} message ListSkuGroupBillableSkusRequest message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupBillableSkusRequest.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusRequest message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusRequest} ListSkuGroupBillableSkusRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupBillableSkusRequest.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.parent = reader.string();
+ break;
+ }
+ case 2: {
+ message.pageSize = reader.int32();
+ break;
+ }
+ case 3: {
+ message.pageToken = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusRequest message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusRequest} ListSkuGroupBillableSkusRequest
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupBillableSkusRequest.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a ListSkuGroupBillableSkusRequest message.
+ * @function verify
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ ListSkuGroupBillableSkusRequest.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.parent != null && message.hasOwnProperty("parent"))
+ if (!$util.isString(message.parent))
+ return "parent: string expected";
+ if (message.pageSize != null && message.hasOwnProperty("pageSize"))
+ if (!$util.isInteger(message.pageSize))
+ return "pageSize: integer expected";
+ if (message.pageToken != null && message.hasOwnProperty("pageToken"))
+ if (!$util.isString(message.pageToken))
+ return "pageToken: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a ListSkuGroupBillableSkusRequest message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusRequest} ListSkuGroupBillableSkusRequest
+ */
+ ListSkuGroupBillableSkusRequest.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest)
+ return object;
+ var message = new $root.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest();
+ if (object.parent != null)
+ message.parent = String(object.parent);
+ if (object.pageSize != null)
+ message.pageSize = object.pageSize | 0;
+ if (object.pageToken != null)
+ message.pageToken = String(object.pageToken);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a ListSkuGroupBillableSkusRequest message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {google.cloud.channel.v1.ListSkuGroupBillableSkusRequest} message ListSkuGroupBillableSkusRequest
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ ListSkuGroupBillableSkusRequest.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.parent = "";
+ object.pageSize = 0;
+ object.pageToken = "";
+ }
+ if (message.parent != null && message.hasOwnProperty("parent"))
+ object.parent = message.parent;
+ if (message.pageSize != null && message.hasOwnProperty("pageSize"))
+ object.pageSize = message.pageSize;
+ if (message.pageToken != null && message.hasOwnProperty("pageToken"))
+ object.pageToken = message.pageToken;
+ return object;
+ };
+
+ /**
+ * Converts this ListSkuGroupBillableSkusRequest to JSON.
+ * @function toJSON
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ ListSkuGroupBillableSkusRequest.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for ListSkuGroupBillableSkusRequest
+ * @function getTypeUrl
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusRequest
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ ListSkuGroupBillableSkusRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.channel.v1.ListSkuGroupBillableSkusRequest";
+ };
+
+ return ListSkuGroupBillableSkusRequest;
+ })();
+
+ v1.ListSkuGroupsResponse = (function() {
+
+ /**
+ * Properties of a ListSkuGroupsResponse.
+ * @memberof google.cloud.channel.v1
+ * @interface IListSkuGroupsResponse
+ * @property {Array.|null} [skuGroups] ListSkuGroupsResponse skuGroups
+ * @property {string|null} [nextPageToken] ListSkuGroupsResponse nextPageToken
+ */
+
+ /**
+ * Constructs a new ListSkuGroupsResponse.
+ * @memberof google.cloud.channel.v1
+ * @classdesc Represents a ListSkuGroupsResponse.
+ * @implements IListSkuGroupsResponse
+ * @constructor
+ * @param {google.cloud.channel.v1.IListSkuGroupsResponse=} [properties] Properties to set
+ */
+ function ListSkuGroupsResponse(properties) {
+ this.skuGroups = [];
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * ListSkuGroupsResponse skuGroups.
+ * @member {Array.} skuGroups
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @instance
+ */
+ ListSkuGroupsResponse.prototype.skuGroups = $util.emptyArray;
+
+ /**
+ * ListSkuGroupsResponse nextPageToken.
+ * @member {string} nextPageToken
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @instance
+ */
+ ListSkuGroupsResponse.prototype.nextPageToken = "";
+
+ /**
+ * Creates a new ListSkuGroupsResponse instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupsResponse=} [properties] Properties to set
+ * @returns {google.cloud.channel.v1.ListSkuGroupsResponse} ListSkuGroupsResponse instance
+ */
+ ListSkuGroupsResponse.create = function create(properties) {
+ return new ListSkuGroupsResponse(properties);
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupsResponse message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsResponse.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupsResponse} message ListSkuGroupsResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupsResponse.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.skuGroups != null && message.skuGroups.length)
+ for (var i = 0; i < message.skuGroups.length; ++i)
+ $root.google.cloud.channel.v1.SkuGroup.encode(message.skuGroups[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
+ if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupsResponse message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupsResponse.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupsResponse} message ListSkuGroupsResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupsResponse.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a ListSkuGroupsResponse message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.channel.v1.ListSkuGroupsResponse} ListSkuGroupsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupsResponse.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.channel.v1.ListSkuGroupsResponse();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ if (!(message.skuGroups && message.skuGroups.length))
+ message.skuGroups = [];
+ message.skuGroups.push($root.google.cloud.channel.v1.SkuGroup.decode(reader, reader.uint32()));
+ break;
+ }
+ case 2: {
+ message.nextPageToken = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a ListSkuGroupsResponse message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.channel.v1.ListSkuGroupsResponse} ListSkuGroupsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupsResponse.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a ListSkuGroupsResponse message.
+ * @function verify
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ ListSkuGroupsResponse.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.skuGroups != null && message.hasOwnProperty("skuGroups")) {
+ if (!Array.isArray(message.skuGroups))
+ return "skuGroups: array expected";
+ for (var i = 0; i < message.skuGroups.length; ++i) {
+ var error = $root.google.cloud.channel.v1.SkuGroup.verify(message.skuGroups[i]);
+ if (error)
+ return "skuGroups." + error;
+ }
+ }
+ if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken"))
+ if (!$util.isString(message.nextPageToken))
+ return "nextPageToken: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a ListSkuGroupsResponse message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.channel.v1.ListSkuGroupsResponse} ListSkuGroupsResponse
+ */
+ ListSkuGroupsResponse.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.channel.v1.ListSkuGroupsResponse)
+ return object;
+ var message = new $root.google.cloud.channel.v1.ListSkuGroupsResponse();
+ if (object.skuGroups) {
+ if (!Array.isArray(object.skuGroups))
+ throw TypeError(".google.cloud.channel.v1.ListSkuGroupsResponse.skuGroups: array expected");
+ message.skuGroups = [];
+ for (var i = 0; i < object.skuGroups.length; ++i) {
+ if (typeof object.skuGroups[i] !== "object")
+ throw TypeError(".google.cloud.channel.v1.ListSkuGroupsResponse.skuGroups: object expected");
+ message.skuGroups[i] = $root.google.cloud.channel.v1.SkuGroup.fromObject(object.skuGroups[i]);
+ }
+ }
+ if (object.nextPageToken != null)
+ message.nextPageToken = String(object.nextPageToken);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a ListSkuGroupsResponse message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {google.cloud.channel.v1.ListSkuGroupsResponse} message ListSkuGroupsResponse
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ ListSkuGroupsResponse.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.arrays || options.defaults)
+ object.skuGroups = [];
+ if (options.defaults)
+ object.nextPageToken = "";
+ if (message.skuGroups && message.skuGroups.length) {
+ object.skuGroups = [];
+ for (var j = 0; j < message.skuGroups.length; ++j)
+ object.skuGroups[j] = $root.google.cloud.channel.v1.SkuGroup.toObject(message.skuGroups[j], options);
+ }
+ if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken"))
+ object.nextPageToken = message.nextPageToken;
+ return object;
+ };
+
+ /**
+ * Converts this ListSkuGroupsResponse to JSON.
+ * @function toJSON
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ ListSkuGroupsResponse.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for ListSkuGroupsResponse
+ * @function getTypeUrl
+ * @memberof google.cloud.channel.v1.ListSkuGroupsResponse
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ ListSkuGroupsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.channel.v1.ListSkuGroupsResponse";
+ };
+
+ return ListSkuGroupsResponse;
+ })();
+
+ v1.ListSkuGroupBillableSkusResponse = (function() {
+
+ /**
+ * Properties of a ListSkuGroupBillableSkusResponse.
+ * @memberof google.cloud.channel.v1
+ * @interface IListSkuGroupBillableSkusResponse
+ * @property {Array.|null} [billableSkus] ListSkuGroupBillableSkusResponse billableSkus
+ * @property {string|null} [nextPageToken] ListSkuGroupBillableSkusResponse nextPageToken
+ */
+
+ /**
+ * Constructs a new ListSkuGroupBillableSkusResponse.
+ * @memberof google.cloud.channel.v1
+ * @classdesc Represents a ListSkuGroupBillableSkusResponse.
+ * @implements IListSkuGroupBillableSkusResponse
+ * @constructor
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusResponse=} [properties] Properties to set
+ */
+ function ListSkuGroupBillableSkusResponse(properties) {
+ this.billableSkus = [];
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * ListSkuGroupBillableSkusResponse billableSkus.
+ * @member {Array.} billableSkus
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @instance
+ */
+ ListSkuGroupBillableSkusResponse.prototype.billableSkus = $util.emptyArray;
+
+ /**
+ * ListSkuGroupBillableSkusResponse nextPageToken.
+ * @member {string} nextPageToken
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @instance
+ */
+ ListSkuGroupBillableSkusResponse.prototype.nextPageToken = "";
+
+ /**
+ * Creates a new ListSkuGroupBillableSkusResponse instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusResponse=} [properties] Properties to set
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusResponse} ListSkuGroupBillableSkusResponse instance
+ */
+ ListSkuGroupBillableSkusResponse.create = function create(properties) {
+ return new ListSkuGroupBillableSkusResponse(properties);
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusResponse message. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusResponse.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusResponse} message ListSkuGroupBillableSkusResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupBillableSkusResponse.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.billableSkus != null && message.billableSkus.length)
+ for (var i = 0; i < message.billableSkus.length; ++i)
+ $root.google.cloud.channel.v1.BillableSku.encode(message.billableSkus[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
+ if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified ListSkuGroupBillableSkusResponse message, length delimited. Does not implicitly {@link google.cloud.channel.v1.ListSkuGroupBillableSkusResponse.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {google.cloud.channel.v1.IListSkuGroupBillableSkusResponse} message ListSkuGroupBillableSkusResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ ListSkuGroupBillableSkusResponse.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusResponse message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusResponse} ListSkuGroupBillableSkusResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupBillableSkusResponse.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.channel.v1.ListSkuGroupBillableSkusResponse();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ if (!(message.billableSkus && message.billableSkus.length))
+ message.billableSkus = [];
+ message.billableSkus.push($root.google.cloud.channel.v1.BillableSku.decode(reader, reader.uint32()));
+ break;
+ }
+ case 2: {
+ message.nextPageToken = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a ListSkuGroupBillableSkusResponse message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusResponse} ListSkuGroupBillableSkusResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ ListSkuGroupBillableSkusResponse.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a ListSkuGroupBillableSkusResponse message.
+ * @function verify
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ ListSkuGroupBillableSkusResponse.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.billableSkus != null && message.hasOwnProperty("billableSkus")) {
+ if (!Array.isArray(message.billableSkus))
+ return "billableSkus: array expected";
+ for (var i = 0; i < message.billableSkus.length; ++i) {
+ var error = $root.google.cloud.channel.v1.BillableSku.verify(message.billableSkus[i]);
+ if (error)
+ return "billableSkus." + error;
+ }
+ }
+ if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken"))
+ if (!$util.isString(message.nextPageToken))
+ return "nextPageToken: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a ListSkuGroupBillableSkusResponse message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.channel.v1.ListSkuGroupBillableSkusResponse} ListSkuGroupBillableSkusResponse
+ */
+ ListSkuGroupBillableSkusResponse.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.channel.v1.ListSkuGroupBillableSkusResponse)
+ return object;
+ var message = new $root.google.cloud.channel.v1.ListSkuGroupBillableSkusResponse();
+ if (object.billableSkus) {
+ if (!Array.isArray(object.billableSkus))
+ throw TypeError(".google.cloud.channel.v1.ListSkuGroupBillableSkusResponse.billableSkus: array expected");
+ message.billableSkus = [];
+ for (var i = 0; i < object.billableSkus.length; ++i) {
+ if (typeof object.billableSkus[i] !== "object")
+ throw TypeError(".google.cloud.channel.v1.ListSkuGroupBillableSkusResponse.billableSkus: object expected");
+ message.billableSkus[i] = $root.google.cloud.channel.v1.BillableSku.fromObject(object.billableSkus[i]);
+ }
+ }
+ if (object.nextPageToken != null)
+ message.nextPageToken = String(object.nextPageToken);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a ListSkuGroupBillableSkusResponse message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {google.cloud.channel.v1.ListSkuGroupBillableSkusResponse} message ListSkuGroupBillableSkusResponse
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ ListSkuGroupBillableSkusResponse.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.arrays || options.defaults)
+ object.billableSkus = [];
+ if (options.defaults)
+ object.nextPageToken = "";
+ if (message.billableSkus && message.billableSkus.length) {
+ object.billableSkus = [];
+ for (var j = 0; j < message.billableSkus.length; ++j)
+ object.billableSkus[j] = $root.google.cloud.channel.v1.BillableSku.toObject(message.billableSkus[j], options);
+ }
+ if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken"))
+ object.nextPageToken = message.nextPageToken;
+ return object;
+ };
+
+ /**
+ * Converts this ListSkuGroupBillableSkusResponse to JSON.
+ * @function toJSON
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ ListSkuGroupBillableSkusResponse.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for ListSkuGroupBillableSkusResponse
+ * @function getTypeUrl
+ * @memberof google.cloud.channel.v1.ListSkuGroupBillableSkusResponse
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ ListSkuGroupBillableSkusResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.channel.v1.ListSkuGroupBillableSkusResponse";
+ };
+
+ return ListSkuGroupBillableSkusResponse;
+ })();
+
+ v1.SkuGroup = (function() {
+
+ /**
+ * Properties of a SkuGroup.
+ * @memberof google.cloud.channel.v1
+ * @interface ISkuGroup
+ * @property {string|null} [name] SkuGroup name
+ * @property {string|null} [displayName] SkuGroup displayName
+ */
+
+ /**
+ * Constructs a new SkuGroup.
+ * @memberof google.cloud.channel.v1
+ * @classdesc Represents a SkuGroup.
+ * @implements ISkuGroup
+ * @constructor
+ * @param {google.cloud.channel.v1.ISkuGroup=} [properties] Properties to set
+ */
+ function SkuGroup(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * SkuGroup name.
+ * @member {string} name
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @instance
+ */
+ SkuGroup.prototype.name = "";
+
+ /**
+ * SkuGroup displayName.
+ * @member {string} displayName
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @instance
+ */
+ SkuGroup.prototype.displayName = "";
+
+ /**
+ * Creates a new SkuGroup instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {google.cloud.channel.v1.ISkuGroup=} [properties] Properties to set
+ * @returns {google.cloud.channel.v1.SkuGroup} SkuGroup instance
+ */
+ SkuGroup.create = function create(properties) {
+ return new SkuGroup(properties);
+ };
+
+ /**
+ * Encodes the specified SkuGroup message. Does not implicitly {@link google.cloud.channel.v1.SkuGroup.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {google.cloud.channel.v1.ISkuGroup} message SkuGroup message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ SkuGroup.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.name != null && Object.hasOwnProperty.call(message, "name"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.name);
+ if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified SkuGroup message, length delimited. Does not implicitly {@link google.cloud.channel.v1.SkuGroup.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {google.cloud.channel.v1.ISkuGroup} message SkuGroup message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ SkuGroup.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a SkuGroup message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.channel.v1.SkuGroup} SkuGroup
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ SkuGroup.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.channel.v1.SkuGroup();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.name = reader.string();
+ break;
+ }
+ case 2: {
+ message.displayName = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a SkuGroup message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.channel.v1.SkuGroup} SkuGroup
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ SkuGroup.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a SkuGroup message.
+ * @function verify
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ SkuGroup.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.name != null && message.hasOwnProperty("name"))
+ if (!$util.isString(message.name))
+ return "name: string expected";
+ if (message.displayName != null && message.hasOwnProperty("displayName"))
+ if (!$util.isString(message.displayName))
+ return "displayName: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a SkuGroup message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.channel.v1.SkuGroup} SkuGroup
+ */
+ SkuGroup.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.channel.v1.SkuGroup)
+ return object;
+ var message = new $root.google.cloud.channel.v1.SkuGroup();
+ if (object.name != null)
+ message.name = String(object.name);
+ if (object.displayName != null)
+ message.displayName = String(object.displayName);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a SkuGroup message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {google.cloud.channel.v1.SkuGroup} message SkuGroup
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ SkuGroup.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.name = "";
+ object.displayName = "";
+ }
+ if (message.name != null && message.hasOwnProperty("name"))
+ object.name = message.name;
+ if (message.displayName != null && message.hasOwnProperty("displayName"))
+ object.displayName = message.displayName;
+ return object;
+ };
+
+ /**
+ * Converts this SkuGroup to JSON.
+ * @function toJSON
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ SkuGroup.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for SkuGroup
+ * @function getTypeUrl
+ * @memberof google.cloud.channel.v1.SkuGroup
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ SkuGroup.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.channel.v1.SkuGroup";
+ };
+
+ return SkuGroup;
+ })();
+
+ v1.BillableSku = (function() {
+
+ /**
+ * Properties of a BillableSku.
+ * @memberof google.cloud.channel.v1
+ * @interface IBillableSku
+ * @property {string|null} [sku] BillableSku sku
+ * @property {string|null} [skuDisplayName] BillableSku skuDisplayName
+ * @property {string|null} [service] BillableSku service
+ * @property {string|null} [serviceDisplayName] BillableSku serviceDisplayName
+ */
+
+ /**
+ * Constructs a new BillableSku.
+ * @memberof google.cloud.channel.v1
+ * @classdesc Represents a BillableSku.
+ * @implements IBillableSku
+ * @constructor
+ * @param {google.cloud.channel.v1.IBillableSku=} [properties] Properties to set
+ */
+ function BillableSku(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * BillableSku sku.
+ * @member {string} sku
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @instance
+ */
+ BillableSku.prototype.sku = "";
+
+ /**
+ * BillableSku skuDisplayName.
+ * @member {string} skuDisplayName
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @instance
+ */
+ BillableSku.prototype.skuDisplayName = "";
+
+ /**
+ * BillableSku service.
+ * @member {string} service
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @instance
+ */
+ BillableSku.prototype.service = "";
+
+ /**
+ * BillableSku serviceDisplayName.
+ * @member {string} serviceDisplayName
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @instance
+ */
+ BillableSku.prototype.serviceDisplayName = "";
+
+ /**
+ * Creates a new BillableSku instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {google.cloud.channel.v1.IBillableSku=} [properties] Properties to set
+ * @returns {google.cloud.channel.v1.BillableSku} BillableSku instance
+ */
+ BillableSku.create = function create(properties) {
+ return new BillableSku(properties);
+ };
+
+ /**
+ * Encodes the specified BillableSku message. Does not implicitly {@link google.cloud.channel.v1.BillableSku.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {google.cloud.channel.v1.IBillableSku} message BillableSku message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ BillableSku.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.sku != null && Object.hasOwnProperty.call(message, "sku"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.sku);
+ if (message.skuDisplayName != null && Object.hasOwnProperty.call(message, "skuDisplayName"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.skuDisplayName);
+ if (message.service != null && Object.hasOwnProperty.call(message, "service"))
+ writer.uint32(/* id 3, wireType 2 =*/26).string(message.service);
+ if (message.serviceDisplayName != null && Object.hasOwnProperty.call(message, "serviceDisplayName"))
+ writer.uint32(/* id 4, wireType 2 =*/34).string(message.serviceDisplayName);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified BillableSku message, length delimited. Does not implicitly {@link google.cloud.channel.v1.BillableSku.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {google.cloud.channel.v1.IBillableSku} message BillableSku message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ BillableSku.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a BillableSku message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.channel.v1.BillableSku} BillableSku
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ BillableSku.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.channel.v1.BillableSku();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.sku = reader.string();
+ break;
+ }
+ case 2: {
+ message.skuDisplayName = reader.string();
+ break;
+ }
+ case 3: {
+ message.service = reader.string();
+ break;
+ }
+ case 4: {
+ message.serviceDisplayName = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a BillableSku message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.channel.v1.BillableSku} BillableSku
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ BillableSku.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a BillableSku message.
+ * @function verify
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ BillableSku.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.sku != null && message.hasOwnProperty("sku"))
+ if (!$util.isString(message.sku))
+ return "sku: string expected";
+ if (message.skuDisplayName != null && message.hasOwnProperty("skuDisplayName"))
+ if (!$util.isString(message.skuDisplayName))
+ return "skuDisplayName: string expected";
+ if (message.service != null && message.hasOwnProperty("service"))
+ if (!$util.isString(message.service))
+ return "service: string expected";
+ if (message.serviceDisplayName != null && message.hasOwnProperty("serviceDisplayName"))
+ if (!$util.isString(message.serviceDisplayName))
+ return "serviceDisplayName: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a BillableSku message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.channel.v1.BillableSku} BillableSku
+ */
+ BillableSku.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.channel.v1.BillableSku)
+ return object;
+ var message = new $root.google.cloud.channel.v1.BillableSku();
+ if (object.sku != null)
+ message.sku = String(object.sku);
+ if (object.skuDisplayName != null)
+ message.skuDisplayName = String(object.skuDisplayName);
+ if (object.service != null)
+ message.service = String(object.service);
+ if (object.serviceDisplayName != null)
+ message.serviceDisplayName = String(object.serviceDisplayName);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a BillableSku message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {google.cloud.channel.v1.BillableSku} message BillableSku
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ BillableSku.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.sku = "";
+ object.skuDisplayName = "";
+ object.service = "";
+ object.serviceDisplayName = "";
+ }
+ if (message.sku != null && message.hasOwnProperty("sku"))
+ object.sku = message.sku;
+ if (message.skuDisplayName != null && message.hasOwnProperty("skuDisplayName"))
+ object.skuDisplayName = message.skuDisplayName;
+ if (message.service != null && message.hasOwnProperty("service"))
+ object.service = message.service;
+ if (message.serviceDisplayName != null && message.hasOwnProperty("serviceDisplayName"))
+ object.serviceDisplayName = message.serviceDisplayName;
+ return object;
+ };
+
+ /**
+ * Converts this BillableSku to JSON.
+ * @function toJSON
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ BillableSku.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for BillableSku
+ * @function getTypeUrl
+ * @memberof google.cloud.channel.v1.BillableSku
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ BillableSku.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.channel.v1.BillableSku";
+ };
+
+ return BillableSku;
+ })();
+
v1.CreateEntitlementRequest = (function() {
/**
diff --git a/packages/google-cloud-channel/protos/protos.json b/packages/google-cloud-channel/protos/protos.json
index aa58a34c4ad..2e41d40f326 100644
--- a/packages/google-cloud-channel/protos/protos.json
+++ b/packages/google-cloud-channel/protos/protos.json
@@ -2452,6 +2452,42 @@
}
]
},
+ "ListSkuGroups": {
+ "requestType": "ListSkuGroupsRequest",
+ "responseType": "ListSkuGroupsResponse",
+ "options": {
+ "(google.api.http).get": "/v1/{parent=accounts/*}/skuGroups",
+ "(google.api.method_signature)": "parent"
+ },
+ "parsedOptions": [
+ {
+ "(google.api.http)": {
+ "get": "/v1/{parent=accounts/*}/skuGroups"
+ }
+ },
+ {
+ "(google.api.method_signature)": "parent"
+ }
+ ]
+ },
+ "ListSkuGroupBillableSkus": {
+ "requestType": "ListSkuGroupBillableSkusRequest",
+ "responseType": "ListSkuGroupBillableSkusResponse",
+ "options": {
+ "(google.api.http).get": "/v1/{parent=accounts/*/skuGroups/*}/billableSkus",
+ "(google.api.method_signature)": "parent"
+ },
+ "parsedOptions": [
+ {
+ "(google.api.http)": {
+ "get": "/v1/{parent=accounts/*/skuGroups/*}/billableSkus"
+ }
+ },
+ {
+ "(google.api.method_signature)": "parent"
+ }
+ ]
+ },
"LookupOffer": {
"requestType": "LookupOfferRequest",
"responseType": "Offer",
@@ -3323,6 +3359,119 @@
}
}
},
+ "ListSkuGroupsRequest": {
+ "fields": {
+ "parent": {
+ "type": "string",
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
+ },
+ "pageSize": {
+ "type": "int32",
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
+ },
+ "pageToken": {
+ "type": "string",
+ "id": 3,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
+ }
+ }
+ },
+ "ListSkuGroupBillableSkusRequest": {
+ "fields": {
+ "parent": {
+ "type": "string",
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED",
+ "(google.api.resource_reference).type": "cloudchannel.googleapis.com/SkuGroup"
+ }
+ },
+ "pageSize": {
+ "type": "int32",
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
+ },
+ "pageToken": {
+ "type": "string",
+ "id": 3,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
+ }
+ }
+ },
+ "ListSkuGroupsResponse": {
+ "fields": {
+ "skuGroups": {
+ "rule": "repeated",
+ "type": "SkuGroup",
+ "id": 1
+ },
+ "nextPageToken": {
+ "type": "string",
+ "id": 2
+ }
+ }
+ },
+ "ListSkuGroupBillableSkusResponse": {
+ "fields": {
+ "billableSkus": {
+ "rule": "repeated",
+ "type": "BillableSku",
+ "id": 1
+ },
+ "nextPageToken": {
+ "type": "string",
+ "id": 2
+ }
+ }
+ },
+ "SkuGroup": {
+ "options": {
+ "(google.api.resource).type": "cloudchannel.googleapis.com/SkuGroup",
+ "(google.api.resource).pattern": "accounts/{account}/skuGroups/{sku_group}"
+ },
+ "fields": {
+ "name": {
+ "type": "string",
+ "id": 1
+ },
+ "displayName": {
+ "type": "string",
+ "id": 2
+ }
+ }
+ },
+ "BillableSku": {
+ "fields": {
+ "sku": {
+ "type": "string",
+ "id": 1
+ },
+ "skuDisplayName": {
+ "type": "string",
+ "id": 2
+ },
+ "service": {
+ "type": "string",
+ "id": 3
+ },
+ "serviceDisplayName": {
+ "type": "string",
+ "id": 4
+ }
+ }
+ },
"CreateEntitlementRequest": {
"fields": {
"parent": {
diff --git a/packages/google-cloud-channel/samples/README.md b/packages/google-cloud-channel/samples/README.md
index 3154027c436..ddbe490b5c9 100644
--- a/packages/google-cloud-channel/samples/README.md
+++ b/packages/google-cloud-channel/samples/README.md
@@ -45,6 +45,8 @@
* [Cloud_channel_service.list_products](#cloud_channel_service.list_products)
* [Cloud_channel_service.list_purchasable_offers](#cloud_channel_service.list_purchasable_offers)
* [Cloud_channel_service.list_purchasable_skus](#cloud_channel_service.list_purchasable_skus)
+ * [Cloud_channel_service.list_sku_group_billable_skus](#cloud_channel_service.list_sku_group_billable_skus)
+ * [Cloud_channel_service.list_sku_groups](#cloud_channel_service.list_sku_groups)
* [Cloud_channel_service.list_skus](#cloud_channel_service.list_skus)
* [Cloud_channel_service.list_subscribers](#cloud_channel_service.list_subscribers)
* [Cloud_channel_service.list_transferable_offers](#cloud_channel_service.list_transferable_offers)
@@ -639,6 +641,40 @@ __Usage:__
+### Cloud_channel_service.list_sku_group_billable_skus
+
+View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js).
+
+[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js,samples/README.md)
+
+__Usage:__
+
+
+`node packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js`
+
+
+-----
+
+
+
+
+### Cloud_channel_service.list_sku_groups
+
+View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js).
+
+[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js,samples/README.md)
+
+__Usage:__
+
+
+`node packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js`
+
+
+-----
+
+
+
+
### Cloud_channel_service.list_skus
View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_skus.js).
diff --git a/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js b/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js
new file mode 100644
index 00000000000..3a9b79e6552
--- /dev/null
+++ b/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js
@@ -0,0 +1,78 @@
+// Copyright 2023 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// https://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// ** This file is automatically generated by gapic-generator-typescript. **
+// ** https://github.com/googleapis/gapic-generator-typescript **
+// ** All changes to this file may be overwritten. **
+
+
+
+'use strict';
+
+function main(parent) {
+ // [START cloudchannel_v1_generated_CloudChannelService_ListSkuGroupBillableSkus_async]
+ /**
+ * This snippet has been automatically generated and should be regarded as a code template only.
+ * It will require modifications to work.
+ * It may require correct/in-range values for request initialization.
+ * TODO(developer): Uncomment these variables before running the sample.
+ */
+ /**
+ * Required. Resource name of the SKU group.
+ * Format: accounts/{account}/skuGroups/{sku_group}.
+ */
+ // const parent = 'abc123'
+ /**
+ * Optional. The maximum number of SKUs to return. The service may return
+ * fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
+ * The maximum value is 100000; values above 100000 will be coerced to 100000.
+ */
+ // const pageSize = 1234
+ /**
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * ListSkuGroupBillableSkus.next_page_token of the previous
+ * CloudChannelService.ListSkuGroupBillableSkus google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus
+ * call.
+ */
+ // const pageToken = 'abc123'
+
+ // Imports the Channel library
+ const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;
+
+ // Instantiates a client
+ const channelClient = new CloudChannelServiceClient();
+
+ async function callListSkuGroupBillableSkus() {
+ // Construct request
+ const request = {
+ parent,
+ };
+
+ // Run request
+ const iterable = await channelClient.listSkuGroupBillableSkusAsync(request);
+ for await (const response of iterable) {
+ console.log(response);
+ }
+ }
+
+ callListSkuGroupBillableSkus();
+ // [END cloudchannel_v1_generated_CloudChannelService_ListSkuGroupBillableSkus_async]
+}
+
+process.on('unhandledRejection', err => {
+ console.error(err.message);
+ process.exitCode = 1;
+});
+main(...process.argv.slice(2));
diff --git a/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js b/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js
new file mode 100644
index 00000000000..a595dfe60dd
--- /dev/null
+++ b/packages/google-cloud-channel/samples/generated/v1/cloud_channel_service.list_sku_groups.js
@@ -0,0 +1,79 @@
+// Copyright 2023 Google LLC
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// https://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+// ** This file is automatically generated by gapic-generator-typescript. **
+// ** https://github.com/googleapis/gapic-generator-typescript **
+// ** All changes to this file may be overwritten. **
+
+
+
+'use strict';
+
+function main(parent) {
+ // [START cloudchannel_v1_generated_CloudChannelService_ListSkuGroups_async]
+ /**
+ * This snippet has been automatically generated and should be regarded as a code template only.
+ * It will require modifications to work.
+ * It may require correct/in-range values for request initialization.
+ * TODO(developer): Uncomment these variables before running the sample.
+ */
+ /**
+ * Required. The resource name of the account from which to list SKU groups.
+ * Parent uses the format: accounts/{account}.
+ */
+ // const parent = 'abc123'
+ /**
+ * Optional. The maximum number of SKU groups to return. The service may
+ * return fewer than this value. If unspecified, returns a maximum of 1000 SKU
+ * groups. The maximum value is 1000; values above 1000 will be coerced to
+ * 1000.
+ */
+ // const pageSize = 1234
+ /**
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * ListSkuGroups.next_page_token of the previous
+ * CloudChannelService.ListSkuGroups google.cloud.channel.v1.CloudChannelService.ListSkuGroups
+ * call.
+ */
+ // const pageToken = 'abc123'
+
+ // Imports the Channel library
+ const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;
+
+ // Instantiates a client
+ const channelClient = new CloudChannelServiceClient();
+
+ async function callListSkuGroups() {
+ // Construct request
+ const request = {
+ parent,
+ };
+
+ // Run request
+ const iterable = await channelClient.listSkuGroupsAsync(request);
+ for await (const response of iterable) {
+ console.log(response);
+ }
+ }
+
+ callListSkuGroups();
+ // [END cloudchannel_v1_generated_CloudChannelService_ListSkuGroups_async]
+}
+
+process.on('unhandledRejection', err => {
+ console.error(err.message);
+ process.exitCode = 1;
+});
+main(...process.argv.slice(2));
diff --git a/packages/google-cloud-channel/samples/generated/v1/snippet_metadata.google.cloud.channel.v1.json b/packages/google-cloud-channel/samples/generated/v1/snippet_metadata.google.cloud.channel.v1.json
index bcd0e05d258..e84ce0e9b89 100644
--- a/packages/google-cloud-channel/samples/generated/v1/snippet_metadata.google.cloud.channel.v1.json
+++ b/packages/google-cloud-channel/samples/generated/v1/snippet_metadata.google.cloud.channel.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-channel",
- "version": "2.7.0",
+ "version": "2.8.0",
"language": "TYPESCRIPT",
"apis": [
{
@@ -1863,6 +1863,102 @@
}
}
},
+ {
+ "regionTag": "cloudchannel_v1_generated_CloudChannelService_ListSkuGroups_async",
+ "title": "CloudChannelReportsService listSkuGroups Sample",
+ "origin": "API_DEFINITION",
+ "description": " Lists the Rebilling supported SKU groups the account is authorized to sell. Reference: https://cloud.google.com/skus/sku-groups Possible Error Codes: * PERMISSION_DENIED: If the account making the request and the account being queried are different, or the account doesn't exist. * INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support. Return Value: If successful, the [SkuGroup][google.cloud.channel.v1.SkuGroup] resources. The data for each resource is displayed in the alphabetical order of SKU group display name. The data for each resource is displayed in the ascending order of [SkuGroup.display_name][google.cloud.channel.v1.SkuGroup.display_name] If unsuccessful, returns an error.",
+ "canonical": true,
+ "file": "cloud_channel_service.list_sku_groups.js",
+ "language": "JAVASCRIPT",
+ "segments": [
+ {
+ "start": 25,
+ "end": 71,
+ "type": "FULL"
+ }
+ ],
+ "clientMethod": {
+ "shortName": "ListSkuGroups",
+ "fullName": "google.cloud.channel.v1.CloudChannelService.ListSkuGroups",
+ "async": true,
+ "parameters": [
+ {
+ "name": "parent",
+ "type": "TYPE_STRING"
+ },
+ {
+ "name": "page_size",
+ "type": "TYPE_INT32"
+ },
+ {
+ "name": "page_token",
+ "type": "TYPE_STRING"
+ }
+ ],
+ "resultType": ".google.cloud.channel.v1.ListSkuGroupsResponse",
+ "client": {
+ "shortName": "CloudChannelServiceClient",
+ "fullName": "google.cloud.channel.v1.CloudChannelServiceClient"
+ },
+ "method": {
+ "shortName": "ListSkuGroups",
+ "fullName": "google.cloud.channel.v1.CloudChannelService.ListSkuGroups",
+ "service": {
+ "shortName": "CloudChannelService",
+ "fullName": "google.cloud.channel.v1.CloudChannelService"
+ }
+ }
+ }
+ },
+ {
+ "regionTag": "cloudchannel_v1_generated_CloudChannelService_ListSkuGroupBillableSkus_async",
+ "title": "CloudChannelReportsService listSkuGroupBillableSkus Sample",
+ "origin": "API_DEFINITION",
+ "description": " Lists the Billable SKUs in a given SKU group. Possible error codes: PERMISSION_DENIED: If the account making the request and the account being queried for are different, or the account doesn't exist. INVALID_ARGUMENT: Missing or invalid required parameters in the request. INTERNAL: Any non-user error related to technical issue in the backend. In this case, contact cloud channel support. Return Value: If successful, the [BillableSku][google.cloud.channel.v1.BillableSku] resources. The data for each resource is displayed in the ascending order of: * [BillableSku.service_display_name][google.cloud.channel.v1.BillableSku.service_display_name] * [BillableSku.sku_display_name][google.cloud.channel.v1.BillableSku.sku_display_name] If unsuccessful, returns an error.",
+ "canonical": true,
+ "file": "cloud_channel_service.list_sku_group_billable_skus.js",
+ "language": "JAVASCRIPT",
+ "segments": [
+ {
+ "start": 25,
+ "end": 70,
+ "type": "FULL"
+ }
+ ],
+ "clientMethod": {
+ "shortName": "ListSkuGroupBillableSkus",
+ "fullName": "google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus",
+ "async": true,
+ "parameters": [
+ {
+ "name": "parent",
+ "type": "TYPE_STRING"
+ },
+ {
+ "name": "page_size",
+ "type": "TYPE_INT32"
+ },
+ {
+ "name": "page_token",
+ "type": "TYPE_STRING"
+ }
+ ],
+ "resultType": ".google.cloud.channel.v1.ListSkuGroupBillableSkusResponse",
+ "client": {
+ "shortName": "CloudChannelServiceClient",
+ "fullName": "google.cloud.channel.v1.CloudChannelServiceClient"
+ },
+ "method": {
+ "shortName": "ListSkuGroupBillableSkus",
+ "fullName": "google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus",
+ "service": {
+ "shortName": "CloudChannelService",
+ "fullName": "google.cloud.channel.v1.CloudChannelService"
+ }
+ }
+ }
+ },
{
"regionTag": "cloudchannel_v1_generated_CloudChannelService_LookupOffer_async",
"title": "CloudChannelReportsService lookupOffer Sample",
diff --git a/packages/google-cloud-channel/samples/package.json b/packages/google-cloud-channel/samples/package.json
index af2de9151f3..c7a0c48e457 100644
--- a/packages/google-cloud-channel/samples/package.json
+++ b/packages/google-cloud-channel/samples/package.json
@@ -13,7 +13,7 @@
"test": "c8 mocha --timeout 600000 test/*.js"
},
"dependencies": {
- "@google-cloud/channel": "^2.7.0",
+ "@google-cloud/channel": "^2.8.0",
"@google-cloud/local-auth": "^2.0.0",
"google-auth-library": "^8.0.0",
"google-gax": "^3.0.0",
diff --git a/packages/google-cloud-channel/src/v1/cloud_channel_reports_service_client.ts b/packages/google-cloud-channel/src/v1/cloud_channel_reports_service_client.ts
index 6a6443a406a..b6cb70200c6 100644
--- a/packages/google-cloud-channel/src/v1/cloud_channel_reports_service_client.ts
+++ b/packages/google-cloud-channel/src/v1/cloud_channel_reports_service_client.ts
@@ -215,6 +215,9 @@ export class CloudChannelReportsServiceClient {
skuPathTemplate: new this._gaxModule.PathTemplate(
'products/{product}/skus/{sku}'
),
+ skuGroupPathTemplate: new this._gaxModule.PathTemplate(
+ 'accounts/{account}/skuGroups/{sku_group}'
+ ),
};
// Some of the methods on this service return "paged" results,
@@ -1675,6 +1678,43 @@ export class CloudChannelReportsServiceClient {
return this.pathTemplates.skuPathTemplate.match(skuName).sku;
}
+ /**
+ * Return a fully-qualified skuGroup resource name string.
+ *
+ * @param {string} account
+ * @param {string} sku_group
+ * @returns {string} Resource name string.
+ */
+ skuGroupPath(account: string, skuGroup: string) {
+ return this.pathTemplates.skuGroupPathTemplate.render({
+ account: account,
+ sku_group: skuGroup,
+ });
+ }
+
+ /**
+ * Parse the account from SkuGroup resource.
+ *
+ * @param {string} skuGroupName
+ * A fully-qualified path representing SkuGroup resource.
+ * @returns {string} A string representing the account.
+ */
+ matchAccountFromSkuGroupName(skuGroupName: string) {
+ return this.pathTemplates.skuGroupPathTemplate.match(skuGroupName).account;
+ }
+
+ /**
+ * Parse the sku_group from SkuGroup resource.
+ *
+ * @param {string} skuGroupName
+ * A fully-qualified path representing SkuGroup resource.
+ * @returns {string} A string representing the sku_group.
+ */
+ matchSkuGroupFromSkuGroupName(skuGroupName: string) {
+ return this.pathTemplates.skuGroupPathTemplate.match(skuGroupName)
+ .sku_group;
+ }
+
/**
* Terminate the gRPC channel and close the client.
*
diff --git a/packages/google-cloud-channel/src/v1/cloud_channel_service_client.ts b/packages/google-cloud-channel/src/v1/cloud_channel_service_client.ts
index 98b0e4ba757..a8592c05226 100644
--- a/packages/google-cloud-channel/src/v1/cloud_channel_service_client.ts
+++ b/packages/google-cloud-channel/src/v1/cloud_channel_service_client.ts
@@ -231,6 +231,9 @@ export class CloudChannelServiceClient {
skuPathTemplate: new this._gaxModule.PathTemplate(
'products/{product}/skus/{sku}'
),
+ skuGroupPathTemplate: new this._gaxModule.PathTemplate(
+ 'accounts/{account}/skuGroups/{sku_group}'
+ ),
};
// Some of the methods on this service return "paged" results,
@@ -272,6 +275,16 @@ export class CloudChannelServiceClient {
'nextPageToken',
'channelPartnerRepricingConfigs'
),
+ listSkuGroups: new this._gaxModule.PageDescriptor(
+ 'pageToken',
+ 'nextPageToken',
+ 'skuGroups'
+ ),
+ listSkuGroupBillableSkus: new this._gaxModule.PageDescriptor(
+ 'pageToken',
+ 'nextPageToken',
+ 'billableSkus'
+ ),
listProducts: new this._gaxModule.PageDescriptor(
'pageToken',
'nextPageToken',
@@ -563,6 +576,8 @@ export class CloudChannelServiceClient {
'createChannelPartnerRepricingConfig',
'updateChannelPartnerRepricingConfig',
'deleteChannelPartnerRepricingConfig',
+ 'listSkuGroups',
+ 'listSkuGroupBillableSkus',
'lookupOffer',
'listProducts',
'listSkus',
@@ -6896,6 +6911,463 @@ export class CloudChannelServiceClient {
callSettings
) as AsyncIterable;
}
+ /**
+ * Lists the Rebilling supported SKU groups the account is authorized to
+ * sell.
+ * Reference: https://cloud.google.com/skus/sku-groups
+ *
+ * Possible Error Codes:
+ *
+ * * PERMISSION_DENIED: If the account making the request and the account
+ * being queried are different, or the account doesn't exist.
+ * * INTERNAL: Any non-user error related to technical issues in the
+ * backend. In this case, contact Cloud Channel support.
+ *
+ * Return Value:
+ * If successful, the {@link google.cloud.channel.v1.SkuGroup|SkuGroup} resources.
+ * The data for each resource is displayed in the alphabetical order of SKU
+ * group display name.
+ * The data for each resource is displayed in the ascending order of
+ * {@link google.cloud.channel.v1.SkuGroup.display_name|SkuGroup.display_name}
+ *
+ * If unsuccessful, returns an error.
+ *
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.parent
+ * Required. The resource name of the account from which to list SKU groups.
+ * Parent uses the format: accounts/{account}.
+ * @param {number} [request.pageSize]
+ * Optional. The maximum number of SKU groups to return. The service may
+ * return fewer than this value. If unspecified, returns a maximum of 1000 SKU
+ * groups. The maximum value is 1000; values above 1000 will be coerced to
+ * 1000.
+ * @param {string} [request.pageToken]
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * {@link |ListSkuGroups.next_page_token} of the previous
+ * {@link google.cloud.channel.v1.CloudChannelService.ListSkuGroups|CloudChannelService.ListSkuGroups}
+ * call.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Promise} - The promise which resolves to an array.
+ * The first element of the array is Array of {@link google.cloud.channel.v1.SkuGroup | SkuGroup}.
+ * The client library will perform auto-pagination by default: it will call the API as many
+ * times as needed and will merge results from all the pages into this array.
+ * Note that it can affect your quota.
+ * We recommend using `listSkuGroupsAsync()`
+ * method described below for async iteration which you can stop as needed.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination)
+ * for more details and examples.
+ */
+ listSkuGroups(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ options?: CallOptions
+ ): Promise<
+ [
+ protos.google.cloud.channel.v1.ISkuGroup[],
+ protos.google.cloud.channel.v1.IListSkuGroupsRequest | null,
+ protos.google.cloud.channel.v1.IListSkuGroupsResponse
+ ]
+ >;
+ listSkuGroups(
+ request: protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ options: CallOptions,
+ callback: PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ protos.google.cloud.channel.v1.IListSkuGroupsResponse | null | undefined,
+ protos.google.cloud.channel.v1.ISkuGroup
+ >
+ ): void;
+ listSkuGroups(
+ request: protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ callback: PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ protos.google.cloud.channel.v1.IListSkuGroupsResponse | null | undefined,
+ protos.google.cloud.channel.v1.ISkuGroup
+ >
+ ): void;
+ listSkuGroups(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ optionsOrCallback?:
+ | CallOptions
+ | PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ | protos.google.cloud.channel.v1.IListSkuGroupsResponse
+ | null
+ | undefined,
+ protos.google.cloud.channel.v1.ISkuGroup
+ >,
+ callback?: PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ protos.google.cloud.channel.v1.IListSkuGroupsResponse | null | undefined,
+ protos.google.cloud.channel.v1.ISkuGroup
+ >
+ ): Promise<
+ [
+ protos.google.cloud.channel.v1.ISkuGroup[],
+ protos.google.cloud.channel.v1.IListSkuGroupsRequest | null,
+ protos.google.cloud.channel.v1.IListSkuGroupsResponse
+ ]
+ > | void {
+ request = request || {};
+ let options: CallOptions;
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
+ callback = optionsOrCallback;
+ options = {};
+ } else {
+ options = optionsOrCallback as CallOptions;
+ }
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ parent: request.parent ?? '',
+ });
+ this.initialize();
+ return this.innerApiCalls.listSkuGroups(request, options, callback);
+ }
+
+ /**
+ * Equivalent to `method.name.toCamelCase()`, but returns a NodeJS Stream object.
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.parent
+ * Required. The resource name of the account from which to list SKU groups.
+ * Parent uses the format: accounts/{account}.
+ * @param {number} [request.pageSize]
+ * Optional. The maximum number of SKU groups to return. The service may
+ * return fewer than this value. If unspecified, returns a maximum of 1000 SKU
+ * groups. The maximum value is 1000; values above 1000 will be coerced to
+ * 1000.
+ * @param {string} [request.pageToken]
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * {@link |ListSkuGroups.next_page_token} of the previous
+ * {@link google.cloud.channel.v1.CloudChannelService.ListSkuGroups|CloudChannelService.ListSkuGroups}
+ * call.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Stream}
+ * An object stream which emits an object representing {@link google.cloud.channel.v1.SkuGroup | SkuGroup} on 'data' event.
+ * The client library will perform auto-pagination by default: it will call the API as many
+ * times as needed. Note that it can affect your quota.
+ * We recommend using `listSkuGroupsAsync()`
+ * method described below for async iteration which you can stop as needed.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination)
+ * for more details and examples.
+ */
+ listSkuGroupsStream(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ options?: CallOptions
+ ): Transform {
+ request = request || {};
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ parent: request.parent ?? '',
+ });
+ const defaultCallSettings = this._defaults['listSkuGroups'];
+ const callSettings = defaultCallSettings.merge(options);
+ this.initialize();
+ return this.descriptors.page.listSkuGroups.createStream(
+ this.innerApiCalls.listSkuGroups as GaxCall,
+ request,
+ callSettings
+ );
+ }
+
+ /**
+ * Equivalent to `listSkuGroups`, but returns an iterable object.
+ *
+ * `for`-`await`-`of` syntax is used with the iterable to get response elements on-demand.
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.parent
+ * Required. The resource name of the account from which to list SKU groups.
+ * Parent uses the format: accounts/{account}.
+ * @param {number} [request.pageSize]
+ * Optional. The maximum number of SKU groups to return. The service may
+ * return fewer than this value. If unspecified, returns a maximum of 1000 SKU
+ * groups. The maximum value is 1000; values above 1000 will be coerced to
+ * 1000.
+ * @param {string} [request.pageToken]
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * {@link |ListSkuGroups.next_page_token} of the previous
+ * {@link google.cloud.channel.v1.CloudChannelService.ListSkuGroups|CloudChannelService.ListSkuGroups}
+ * call.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Object}
+ * An iterable Object that allows [async iteration](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols).
+ * When you iterate the returned iterable, each element will be an object representing
+ * {@link google.cloud.channel.v1.SkuGroup | SkuGroup}. The API will be called under the hood as needed, once per the page,
+ * so you can stop the iteration when you don't need more results.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination)
+ * for more details and examples.
+ * @example include:samples/generated/v1/cloud_channel_service.list_sku_groups.js
+ * region_tag:cloudchannel_v1_generated_CloudChannelService_ListSkuGroups_async
+ */
+ listSkuGroupsAsync(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupsRequest,
+ options?: CallOptions
+ ): AsyncIterable {
+ request = request || {};
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ parent: request.parent ?? '',
+ });
+ const defaultCallSettings = this._defaults['listSkuGroups'];
+ const callSettings = defaultCallSettings.merge(options);
+ this.initialize();
+ return this.descriptors.page.listSkuGroups.asyncIterate(
+ this.innerApiCalls['listSkuGroups'] as GaxCall,
+ request as {},
+ callSettings
+ ) as AsyncIterable;
+ }
+ /**
+ * Lists the Billable SKUs in a given SKU group.
+ *
+ * Possible error codes:
+ * PERMISSION_DENIED: If the account making the request and the account
+ * being queried for are different, or the account doesn't exist.
+ * INVALID_ARGUMENT: Missing or invalid required parameters in the
+ * request.
+ * INTERNAL: Any non-user error related to technical issue in the
+ * backend. In this case, contact cloud channel support.
+ *
+ * Return Value:
+ * If successful, the {@link google.cloud.channel.v1.BillableSku|BillableSku}
+ * resources. The data for each resource is displayed in the ascending order
+ * of:
+ *
+ * * {@link google.cloud.channel.v1.BillableSku.service_display_name|BillableSku.service_display_name}
+ * * {@link google.cloud.channel.v1.BillableSku.sku_display_name|BillableSku.sku_display_name}
+ *
+ * If unsuccessful, returns an error.
+ *
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.parent
+ * Required. Resource name of the SKU group.
+ * Format: accounts/{account}/skuGroups/{sku_group}.
+ * @param {number} [request.pageSize]
+ * Optional. The maximum number of SKUs to return. The service may return
+ * fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
+ * The maximum value is 100000; values above 100000 will be coerced to 100000.
+ * @param {string} [request.pageToken]
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * {@link |ListSkuGroupBillableSkus.next_page_token} of the previous
+ * {@link google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus|CloudChannelService.ListSkuGroupBillableSkus}
+ * call.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Promise} - The promise which resolves to an array.
+ * The first element of the array is Array of {@link google.cloud.channel.v1.BillableSku | BillableSku}.
+ * The client library will perform auto-pagination by default: it will call the API as many
+ * times as needed and will merge results from all the pages into this array.
+ * Note that it can affect your quota.
+ * We recommend using `listSkuGroupBillableSkusAsync()`
+ * method described below for async iteration which you can stop as needed.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination)
+ * for more details and examples.
+ */
+ listSkuGroupBillableSkus(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ options?: CallOptions
+ ): Promise<
+ [
+ protos.google.cloud.channel.v1.IBillableSku[],
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest | null,
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusResponse
+ ]
+ >;
+ listSkuGroupBillableSkus(
+ request: protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ options: CallOptions,
+ callback: PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ | protos.google.cloud.channel.v1.IListSkuGroupBillableSkusResponse
+ | null
+ | undefined,
+ protos.google.cloud.channel.v1.IBillableSku
+ >
+ ): void;
+ listSkuGroupBillableSkus(
+ request: protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ callback: PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ | protos.google.cloud.channel.v1.IListSkuGroupBillableSkusResponse
+ | null
+ | undefined,
+ protos.google.cloud.channel.v1.IBillableSku
+ >
+ ): void;
+ listSkuGroupBillableSkus(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ optionsOrCallback?:
+ | CallOptions
+ | PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ | protos.google.cloud.channel.v1.IListSkuGroupBillableSkusResponse
+ | null
+ | undefined,
+ protos.google.cloud.channel.v1.IBillableSku
+ >,
+ callback?: PaginationCallback<
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ | protos.google.cloud.channel.v1.IListSkuGroupBillableSkusResponse
+ | null
+ | undefined,
+ protos.google.cloud.channel.v1.IBillableSku
+ >
+ ): Promise<
+ [
+ protos.google.cloud.channel.v1.IBillableSku[],
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest | null,
+ protos.google.cloud.channel.v1.IListSkuGroupBillableSkusResponse
+ ]
+ > | void {
+ request = request || {};
+ let options: CallOptions;
+ if (typeof optionsOrCallback === 'function' && callback === undefined) {
+ callback = optionsOrCallback;
+ options = {};
+ } else {
+ options = optionsOrCallback as CallOptions;
+ }
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ parent: request.parent ?? '',
+ });
+ this.initialize();
+ return this.innerApiCalls.listSkuGroupBillableSkus(
+ request,
+ options,
+ callback
+ );
+ }
+
+ /**
+ * Equivalent to `method.name.toCamelCase()`, but returns a NodeJS Stream object.
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.parent
+ * Required. Resource name of the SKU group.
+ * Format: accounts/{account}/skuGroups/{sku_group}.
+ * @param {number} [request.pageSize]
+ * Optional. The maximum number of SKUs to return. The service may return
+ * fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
+ * The maximum value is 100000; values above 100000 will be coerced to 100000.
+ * @param {string} [request.pageToken]
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * {@link |ListSkuGroupBillableSkus.next_page_token} of the previous
+ * {@link google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus|CloudChannelService.ListSkuGroupBillableSkus}
+ * call.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Stream}
+ * An object stream which emits an object representing {@link google.cloud.channel.v1.BillableSku | BillableSku} on 'data' event.
+ * The client library will perform auto-pagination by default: it will call the API as many
+ * times as needed. Note that it can affect your quota.
+ * We recommend using `listSkuGroupBillableSkusAsync()`
+ * method described below for async iteration which you can stop as needed.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination)
+ * for more details and examples.
+ */
+ listSkuGroupBillableSkusStream(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ options?: CallOptions
+ ): Transform {
+ request = request || {};
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ parent: request.parent ?? '',
+ });
+ const defaultCallSettings = this._defaults['listSkuGroupBillableSkus'];
+ const callSettings = defaultCallSettings.merge(options);
+ this.initialize();
+ return this.descriptors.page.listSkuGroupBillableSkus.createStream(
+ this.innerApiCalls.listSkuGroupBillableSkus as GaxCall,
+ request,
+ callSettings
+ );
+ }
+
+ /**
+ * Equivalent to `listSkuGroupBillableSkus`, but returns an iterable object.
+ *
+ * `for`-`await`-`of` syntax is used with the iterable to get response elements on-demand.
+ * @param {Object} request
+ * The request object that will be sent.
+ * @param {string} request.parent
+ * Required. Resource name of the SKU group.
+ * Format: accounts/{account}/skuGroups/{sku_group}.
+ * @param {number} [request.pageSize]
+ * Optional. The maximum number of SKUs to return. The service may return
+ * fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
+ * The maximum value is 100000; values above 100000 will be coerced to 100000.
+ * @param {string} [request.pageToken]
+ * Optional. A token identifying a page of results beyond the first page.
+ * Obtained through
+ * {@link |ListSkuGroupBillableSkus.next_page_token} of the previous
+ * {@link google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus|CloudChannelService.ListSkuGroupBillableSkus}
+ * call.
+ * @param {object} [options]
+ * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
+ * @returns {Object}
+ * An iterable Object that allows [async iteration](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols).
+ * When you iterate the returned iterable, each element will be an object representing
+ * {@link google.cloud.channel.v1.BillableSku | BillableSku}. The API will be called under the hood as needed, once per the page,
+ * so you can stop the iteration when you don't need more results.
+ * Please see the
+ * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination)
+ * for more details and examples.
+ * @example include:samples/generated/v1/cloud_channel_service.list_sku_group_billable_skus.js
+ * region_tag:cloudchannel_v1_generated_CloudChannelService_ListSkuGroupBillableSkus_async
+ */
+ listSkuGroupBillableSkusAsync(
+ request?: protos.google.cloud.channel.v1.IListSkuGroupBillableSkusRequest,
+ options?: CallOptions
+ ): AsyncIterable {
+ request = request || {};
+ options = options || {};
+ options.otherArgs = options.otherArgs || {};
+ options.otherArgs.headers = options.otherArgs.headers || {};
+ options.otherArgs.headers['x-goog-request-params'] =
+ this._gaxModule.routingHeader.fromParams({
+ parent: request.parent ?? '',
+ });
+ const defaultCallSettings = this._defaults['listSkuGroupBillableSkus'];
+ const callSettings = defaultCallSettings.merge(options);
+ this.initialize();
+ return this.descriptors.page.listSkuGroupBillableSkus.asyncIterate(
+ this.innerApiCalls['listSkuGroupBillableSkus'] as GaxCall,
+ request as {},
+ callSettings
+ ) as AsyncIterable;
+ }
/**
* Lists the Products the reseller is authorized to sell.
*
@@ -9102,6 +9574,43 @@ export class CloudChannelServiceClient {
return this.pathTemplates.skuPathTemplate.match(skuName).sku;
}
+ /**
+ * Return a fully-qualified skuGroup resource name string.
+ *
+ * @param {string} account
+ * @param {string} sku_group
+ * @returns {string} Resource name string.
+ */
+ skuGroupPath(account: string, skuGroup: string) {
+ return this.pathTemplates.skuGroupPathTemplate.render({
+ account: account,
+ sku_group: skuGroup,
+ });
+ }
+
+ /**
+ * Parse the account from SkuGroup resource.
+ *
+ * @param {string} skuGroupName
+ * A fully-qualified path representing SkuGroup resource.
+ * @returns {string} A string representing the account.
+ */
+ matchAccountFromSkuGroupName(skuGroupName: string) {
+ return this.pathTemplates.skuGroupPathTemplate.match(skuGroupName).account;
+ }
+
+ /**
+ * Parse the sku_group from SkuGroup resource.
+ *
+ * @param {string} skuGroupName
+ * A fully-qualified path representing SkuGroup resource.
+ * @returns {string} A string representing the sku_group.
+ */
+ matchSkuGroupFromSkuGroupName(skuGroupName: string) {
+ return this.pathTemplates.skuGroupPathTemplate.match(skuGroupName)
+ .sku_group;
+ }
+
/**
* Terminate the gRPC channel and close the client.
*
diff --git a/packages/google-cloud-channel/src/v1/cloud_channel_service_client_config.json b/packages/google-cloud-channel/src/v1/cloud_channel_service_client_config.json
index 4e27eaca3bb..96804dd8776 100644
--- a/packages/google-cloud-channel/src/v1/cloud_channel_service_client_config.json
+++ b/packages/google-cloud-channel/src/v1/cloud_channel_service_client_config.json
@@ -212,6 +212,16 @@
"retry_codes_name": "unavailable",
"retry_params_name": "ce5b960a6ed052e690863808e4f0deff3dc7d49f"
},
+ "ListSkuGroups": {
+ "timeout_millis": 60000,
+ "retry_codes_name": "unavailable",
+ "retry_params_name": "ce5b960a6ed052e690863808e4f0deff3dc7d49f"
+ },
+ "ListSkuGroupBillableSkus": {
+ "timeout_millis": 60000,
+ "retry_codes_name": "unavailable",
+ "retry_params_name": "ce5b960a6ed052e690863808e4f0deff3dc7d49f"
+ },
"LookupOffer": {
"timeout_millis": 60000,
"retry_codes_name": "unavailable",
diff --git a/packages/google-cloud-channel/src/v1/gapic_metadata.json b/packages/google-cloud-channel/src/v1/gapic_metadata.json
index 3a60e147703..7a1eec3f2ba 100644
--- a/packages/google-cloud-channel/src/v1/gapic_metadata.json
+++ b/packages/google-cloud-channel/src/v1/gapic_metadata.json
@@ -271,6 +271,20 @@
"listChannelPartnerRepricingConfigsAsync"
]
},
+ "ListSkuGroups": {
+ "methods": [
+ "listSkuGroups",
+ "listSkuGroupsStream",
+ "listSkuGroupsAsync"
+ ]
+ },
+ "ListSkuGroupBillableSkus": {
+ "methods": [
+ "listSkuGroupBillableSkus",
+ "listSkuGroupBillableSkusStream",
+ "listSkuGroupBillableSkusAsync"
+ ]
+ },
"ListProducts": {
"methods": [
"listProducts",
@@ -534,6 +548,20 @@
"listChannelPartnerRepricingConfigsAsync"
]
},
+ "ListSkuGroups": {
+ "methods": [
+ "listSkuGroups",
+ "listSkuGroupsStream",
+ "listSkuGroupsAsync"
+ ]
+ },
+ "ListSkuGroupBillableSkus": {
+ "methods": [
+ "listSkuGroupBillableSkus",
+ "listSkuGroupBillableSkusStream",
+ "listSkuGroupBillableSkusAsync"
+ ]
+ },
"ListProducts": {
"methods": [
"listProducts",
diff --git a/packages/google-cloud-channel/test/gapic_cloud_channel_reports_service_v1.ts b/packages/google-cloud-channel/test/gapic_cloud_channel_reports_service_v1.ts
index b99b31d929a..d598e52802c 100644
--- a/packages/google-cloud-channel/test/gapic_cloud_channel_reports_service_v1.ts
+++ b/packages/google-cloud-channel/test/gapic_cloud_channel_reports_service_v1.ts
@@ -2066,5 +2066,57 @@ describe('v1.CloudChannelReportsServiceClient', () => {
);
});
});
+
+ describe('skuGroup', () => {
+ const fakePath = '/rendered/path/skuGroup';
+ const expectedParameters = {
+ account: 'accountValue',
+ sku_group: 'skuGroupValue',
+ };
+ const client =
+ new cloudchannelreportsserviceModule.v1.CloudChannelReportsServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ client.pathTemplates.skuGroupPathTemplate.render = sinon
+ .stub()
+ .returns(fakePath);
+ client.pathTemplates.skuGroupPathTemplate.match = sinon
+ .stub()
+ .returns(expectedParameters);
+
+ it('skuGroupPath', () => {
+ const result = client.skuGroupPath('accountValue', 'skuGroupValue');
+ assert.strictEqual(result, fakePath);
+ assert(
+ (client.pathTemplates.skuGroupPathTemplate.render as SinonStub)
+ .getCall(-1)
+ .calledWith(expectedParameters)
+ );
+ });
+
+ it('matchAccountFromSkuGroupName', () => {
+ const result = client.matchAccountFromSkuGroupName(fakePath);
+ assert.strictEqual(result, 'accountValue');
+ assert(
+ (client.pathTemplates.skuGroupPathTemplate.match as SinonStub)
+ .getCall(-1)
+ .calledWith(fakePath)
+ );
+ });
+
+ it('matchSkuGroupFromSkuGroupName', () => {
+ const result = client.matchSkuGroupFromSkuGroupName(fakePath);
+ assert.strictEqual(result, 'skuGroupValue');
+ assert(
+ (client.pathTemplates.skuGroupPathTemplate.match as SinonStub)
+ .getCall(-1)
+ .calledWith(fakePath)
+ );
+ });
+ });
});
});
diff --git a/packages/google-cloud-channel/test/gapic_cloud_channel_service_v1.ts b/packages/google-cloud-channel/test/gapic_cloud_channel_service_v1.ts
index 34959cf1533..c2d06909a9e 100644
--- a/packages/google-cloud-channel/test/gapic_cloud_channel_service_v1.ts
+++ b/packages/google-cloud-channel/test/gapic_cloud_channel_service_v1.ts
@@ -8009,6 +8009,660 @@ describe('v1.CloudChannelServiceClient', () => {
});
});
+ describe('listSkuGroups', () => {
+ it('invokes listSkuGroups without error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ ];
+ client.innerApiCalls.listSkuGroups = stubSimpleCall(expectedResponse);
+ const [response] = await client.listSkuGroups(request);
+ assert.deepStrictEqual(response, expectedResponse);
+ const actualRequest = (
+ client.innerApiCalls.listSkuGroups as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.listSkuGroups as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes listSkuGroups without error using callback', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ ];
+ client.innerApiCalls.listSkuGroups =
+ stubSimpleCallWithCallback(expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.listSkuGroups(
+ request,
+ (
+ err?: Error | null,
+ result?: protos.google.cloud.channel.v1.ISkuGroup[] | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ const actualRequest = (
+ client.innerApiCalls.listSkuGroups as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.listSkuGroups as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes listSkuGroups with error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.innerApiCalls.listSkuGroups = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(client.listSkuGroups(request), expectedError);
+ const actualRequest = (
+ client.innerApiCalls.listSkuGroups as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.listSkuGroups as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes listSkuGroupsStream without error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ ];
+ client.descriptors.page.listSkuGroups.createStream =
+ stubPageStreamingCall(expectedResponse);
+ const stream = client.listSkuGroupsStream(request);
+ const promise = new Promise((resolve, reject) => {
+ const responses: protos.google.cloud.channel.v1.SkuGroup[] = [];
+ stream.on(
+ 'data',
+ (response: protos.google.cloud.channel.v1.SkuGroup) => {
+ responses.push(response);
+ }
+ );
+ stream.on('end', () => {
+ resolve(responses);
+ });
+ stream.on('error', (err: Error) => {
+ reject(err);
+ });
+ });
+ const responses = await promise;
+ assert.deepStrictEqual(responses, expectedResponse);
+ assert(
+ (client.descriptors.page.listSkuGroups.createStream as SinonStub)
+ .getCall(0)
+ .calledWith(client.innerApiCalls.listSkuGroups, request)
+ );
+ assert(
+ (client.descriptors.page.listSkuGroups.createStream as SinonStub)
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+
+ it('invokes listSkuGroupsStream with error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.descriptors.page.listSkuGroups.createStream =
+ stubPageStreamingCall(undefined, expectedError);
+ const stream = client.listSkuGroupsStream(request);
+ const promise = new Promise((resolve, reject) => {
+ const responses: protos.google.cloud.channel.v1.SkuGroup[] = [];
+ stream.on(
+ 'data',
+ (response: protos.google.cloud.channel.v1.SkuGroup) => {
+ responses.push(response);
+ }
+ );
+ stream.on('end', () => {
+ resolve(responses);
+ });
+ stream.on('error', (err: Error) => {
+ reject(err);
+ });
+ });
+ await assert.rejects(promise, expectedError);
+ assert(
+ (client.descriptors.page.listSkuGroups.createStream as SinonStub)
+ .getCall(0)
+ .calledWith(client.innerApiCalls.listSkuGroups, request)
+ );
+ assert(
+ (client.descriptors.page.listSkuGroups.createStream as SinonStub)
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+
+ it('uses async iteration with listSkuGroups without error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.SkuGroup()),
+ ];
+ client.descriptors.page.listSkuGroups.asyncIterate =
+ stubAsyncIterationCall(expectedResponse);
+ const responses: protos.google.cloud.channel.v1.ISkuGroup[] = [];
+ const iterable = client.listSkuGroupsAsync(request);
+ for await (const resource of iterable) {
+ responses.push(resource!);
+ }
+ assert.deepStrictEqual(responses, expectedResponse);
+ assert.deepStrictEqual(
+ (
+ client.descriptors.page.listSkuGroups.asyncIterate as SinonStub
+ ).getCall(0).args[1],
+ request
+ );
+ assert(
+ (client.descriptors.page.listSkuGroups.asyncIterate as SinonStub)
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+
+ it('uses async iteration with listSkuGroups with error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupsRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupsRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.descriptors.page.listSkuGroups.asyncIterate =
+ stubAsyncIterationCall(undefined, expectedError);
+ const iterable = client.listSkuGroupsAsync(request);
+ await assert.rejects(async () => {
+ const responses: protos.google.cloud.channel.v1.ISkuGroup[] = [];
+ for await (const resource of iterable) {
+ responses.push(resource!);
+ }
+ });
+ assert.deepStrictEqual(
+ (
+ client.descriptors.page.listSkuGroups.asyncIterate as SinonStub
+ ).getCall(0).args[1],
+ request
+ );
+ assert(
+ (client.descriptors.page.listSkuGroups.asyncIterate as SinonStub)
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+ });
+
+ describe('listSkuGroupBillableSkus', () => {
+ it('invokes listSkuGroupBillableSkus without error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ ];
+ client.innerApiCalls.listSkuGroupBillableSkus =
+ stubSimpleCall(expectedResponse);
+ const [response] = await client.listSkuGroupBillableSkus(request);
+ assert.deepStrictEqual(response, expectedResponse);
+ const actualRequest = (
+ client.innerApiCalls.listSkuGroupBillableSkus as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.listSkuGroupBillableSkus as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes listSkuGroupBillableSkus without error using callback', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ ];
+ client.innerApiCalls.listSkuGroupBillableSkus =
+ stubSimpleCallWithCallback(expectedResponse);
+ const promise = new Promise((resolve, reject) => {
+ client.listSkuGroupBillableSkus(
+ request,
+ (
+ err?: Error | null,
+ result?: protos.google.cloud.channel.v1.IBillableSku[] | null
+ ) => {
+ if (err) {
+ reject(err);
+ } else {
+ resolve(result);
+ }
+ }
+ );
+ });
+ const response = await promise;
+ assert.deepStrictEqual(response, expectedResponse);
+ const actualRequest = (
+ client.innerApiCalls.listSkuGroupBillableSkus as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.listSkuGroupBillableSkus as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes listSkuGroupBillableSkus with error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.innerApiCalls.listSkuGroupBillableSkus = stubSimpleCall(
+ undefined,
+ expectedError
+ );
+ await assert.rejects(
+ client.listSkuGroupBillableSkus(request),
+ expectedError
+ );
+ const actualRequest = (
+ client.innerApiCalls.listSkuGroupBillableSkus as SinonStub
+ ).getCall(0).args[0];
+ assert.deepStrictEqual(actualRequest, request);
+ const actualHeaderRequestParams = (
+ client.innerApiCalls.listSkuGroupBillableSkus as SinonStub
+ ).getCall(0).args[1].otherArgs.headers['x-goog-request-params'];
+ assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams));
+ });
+
+ it('invokes listSkuGroupBillableSkusStream without error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ ];
+ client.descriptors.page.listSkuGroupBillableSkus.createStream =
+ stubPageStreamingCall(expectedResponse);
+ const stream = client.listSkuGroupBillableSkusStream(request);
+ const promise = new Promise((resolve, reject) => {
+ const responses: protos.google.cloud.channel.v1.BillableSku[] = [];
+ stream.on(
+ 'data',
+ (response: protos.google.cloud.channel.v1.BillableSku) => {
+ responses.push(response);
+ }
+ );
+ stream.on('end', () => {
+ resolve(responses);
+ });
+ stream.on('error', (err: Error) => {
+ reject(err);
+ });
+ });
+ const responses = await promise;
+ assert.deepStrictEqual(responses, expectedResponse);
+ assert(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .createStream as SinonStub
+ )
+ .getCall(0)
+ .calledWith(client.innerApiCalls.listSkuGroupBillableSkus, request)
+ );
+ assert(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .createStream as SinonStub
+ )
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+
+ it('invokes listSkuGroupBillableSkusStream with error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.descriptors.page.listSkuGroupBillableSkus.createStream =
+ stubPageStreamingCall(undefined, expectedError);
+ const stream = client.listSkuGroupBillableSkusStream(request);
+ const promise = new Promise((resolve, reject) => {
+ const responses: protos.google.cloud.channel.v1.BillableSku[] = [];
+ stream.on(
+ 'data',
+ (response: protos.google.cloud.channel.v1.BillableSku) => {
+ responses.push(response);
+ }
+ );
+ stream.on('end', () => {
+ resolve(responses);
+ });
+ stream.on('error', (err: Error) => {
+ reject(err);
+ });
+ });
+ await assert.rejects(promise, expectedError);
+ assert(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .createStream as SinonStub
+ )
+ .getCall(0)
+ .calledWith(client.innerApiCalls.listSkuGroupBillableSkus, request)
+ );
+ assert(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .createStream as SinonStub
+ )
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+
+ it('uses async iteration with listSkuGroupBillableSkus without error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedResponse = [
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ generateSampleMessage(new protos.google.cloud.channel.v1.BillableSku()),
+ ];
+ client.descriptors.page.listSkuGroupBillableSkus.asyncIterate =
+ stubAsyncIterationCall(expectedResponse);
+ const responses: protos.google.cloud.channel.v1.IBillableSku[] = [];
+ const iterable = client.listSkuGroupBillableSkusAsync(request);
+ for await (const resource of iterable) {
+ responses.push(resource!);
+ }
+ assert.deepStrictEqual(responses, expectedResponse);
+ assert.deepStrictEqual(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .asyncIterate as SinonStub
+ ).getCall(0).args[1],
+ request
+ );
+ assert(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .asyncIterate as SinonStub
+ )
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+
+ it('uses async iteration with listSkuGroupBillableSkus with error', async () => {
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ const request = generateSampleMessage(
+ new protos.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest()
+ );
+ const defaultValue1 = getTypeDefaultValue(
+ '.google.cloud.channel.v1.ListSkuGroupBillableSkusRequest',
+ ['parent']
+ );
+ request.parent = defaultValue1;
+ const expectedHeaderRequestParams = `parent=${defaultValue1}`;
+ const expectedError = new Error('expected');
+ client.descriptors.page.listSkuGroupBillableSkus.asyncIterate =
+ stubAsyncIterationCall(undefined, expectedError);
+ const iterable = client.listSkuGroupBillableSkusAsync(request);
+ await assert.rejects(async () => {
+ const responses: protos.google.cloud.channel.v1.IBillableSku[] = [];
+ for await (const resource of iterable) {
+ responses.push(resource!);
+ }
+ });
+ assert.deepStrictEqual(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .asyncIterate as SinonStub
+ ).getCall(0).args[1],
+ request
+ );
+ assert(
+ (
+ client.descriptors.page.listSkuGroupBillableSkus
+ .asyncIterate as SinonStub
+ )
+ .getCall(0)
+ .args[2].otherArgs.headers['x-goog-request-params'].includes(
+ expectedHeaderRequestParams
+ )
+ );
+ });
+ });
+
describe('listProducts', () => {
it('invokes listProducts without error', async () => {
const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
@@ -11131,5 +11785,56 @@ describe('v1.CloudChannelServiceClient', () => {
);
});
});
+
+ describe('skuGroup', () => {
+ const fakePath = '/rendered/path/skuGroup';
+ const expectedParameters = {
+ account: 'accountValue',
+ sku_group: 'skuGroupValue',
+ };
+ const client = new cloudchannelserviceModule.v1.CloudChannelServiceClient(
+ {
+ credentials: {client_email: 'bogus', private_key: 'bogus'},
+ projectId: 'bogus',
+ }
+ );
+ client.initialize();
+ client.pathTemplates.skuGroupPathTemplate.render = sinon
+ .stub()
+ .returns(fakePath);
+ client.pathTemplates.skuGroupPathTemplate.match = sinon
+ .stub()
+ .returns(expectedParameters);
+
+ it('skuGroupPath', () => {
+ const result = client.skuGroupPath('accountValue', 'skuGroupValue');
+ assert.strictEqual(result, fakePath);
+ assert(
+ (client.pathTemplates.skuGroupPathTemplate.render as SinonStub)
+ .getCall(-1)
+ .calledWith(expectedParameters)
+ );
+ });
+
+ it('matchAccountFromSkuGroupName', () => {
+ const result = client.matchAccountFromSkuGroupName(fakePath);
+ assert.strictEqual(result, 'accountValue');
+ assert(
+ (client.pathTemplates.skuGroupPathTemplate.match as SinonStub)
+ .getCall(-1)
+ .calledWith(fakePath)
+ );
+ });
+
+ it('matchSkuGroupFromSkuGroupName', () => {
+ const result = client.matchSkuGroupFromSkuGroupName(fakePath);
+ assert.strictEqual(result, 'skuGroupValue');
+ assert(
+ (client.pathTemplates.skuGroupPathTemplate.match as SinonStub)
+ .getCall(-1)
+ .calledWith(fakePath)
+ );
+ });
+ });
});
});
diff --git a/packages/google-cloud-deploy/CHANGELOG.md b/packages/google-cloud-deploy/CHANGELOG.md
index 9d551846821..2dbc5aa6383 100644
--- a/packages/google-cloud-deploy/CHANGELOG.md
+++ b/packages/google-cloud-deploy/CHANGELOG.md
@@ -1,5 +1,12 @@
# Changelog
+## [2.7.0](https://github.com/googleapis/google-cloud-node/compare/deploy-v2.6.0...deploy-v2.7.0) (2023-06-28)
+
+
+### Features
+
+* [deploy] Add deploy parameters for cloud deploy ([#4367](https://github.com/googleapis/google-cloud-node/issues/4367)) ([dd8b0ec](https://github.com/googleapis/google-cloud-node/commit/dd8b0ec2df1c39330e1a104de55e809d9a31a1a9))
+
## [2.6.0](https://github.com/googleapis/google-cloud-node/compare/deploy-v2.5.0...deploy-v2.6.0) (2023-06-06)
diff --git a/packages/google-cloud-deploy/package.json b/packages/google-cloud-deploy/package.json
index d57153f737a..f1c05c7d38e 100644
--- a/packages/google-cloud-deploy/package.json
+++ b/packages/google-cloud-deploy/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-cloud/deploy",
- "version": "2.6.0",
+ "version": "2.7.0",
"description": "clouddeploy client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-cloud-deploy/protos/google/cloud/deploy/v1/cloud_deploy.proto b/packages/google-cloud-deploy/protos/google/cloud/deploy/v1/cloud_deploy.proto
index 74e47d49601..a466f4c9076 100644
--- a/packages/google-cloud-deploy/protos/google/cloud/deploy/v1/cloud_deploy.proto
+++ b/packages/google-cloud-deploy/protos/google/cloud/deploy/v1/cloud_deploy.proto
@@ -415,6 +415,22 @@ message Stage {
// Optional. The strategy to use for a `Rollout` to this stage.
Strategy strategy = 5 [(google.api.field_behavior) = OPTIONAL];
+
+ // Optional. The deploy parameters to use for the target in this stage.
+ repeated DeployParameters deploy_parameters = 6
+ [(google.api.field_behavior) = OPTIONAL];
+}
+
+// DeployParameters contains deploy parameters information.
+message DeployParameters {
+ // Required. Values are deploy parameters in key-value pairs.
+ map values = 1 [(google.api.field_behavior) = REQUIRED];
+
+ // Optional. Deploy parameters are applied to targets with match labels.
+ // If unspecified, deploy parameters are applied to all targets (including
+ // child targets of a multi-target).
+ map match_target_labels = 2
+ [(google.api.field_behavior) = OPTIONAL];
}
// Strategy contains deployment strategy information.
@@ -877,6 +893,10 @@ message Target {
// When no configurations are specified, execution will use the default
// specified in `DefaultPool`.
repeated ExecutionConfig execution_configs = 16;
+
+ // Optional. The deploy parameters to use for this target.
+ map deploy_parameters = 20
+ [(google.api.field_behavior) = OPTIONAL];
}
// Configuration of the environment to use when calling Skaffold.
@@ -1412,6 +1432,10 @@ message Release {
// Output only. Information around the state of the Release.
ReleaseCondition condition = 24 [(google.api.field_behavior) = OUTPUT_ONLY];
+
+ // Optional. The deploy parameters to use for all targets in this release.
+ map deploy_parameters = 25
+ [(google.api.field_behavior) = OPTIONAL];
}
// Description of an a image to use during Skaffold rendering.
diff --git a/packages/google-cloud-deploy/protos/protos.d.ts b/packages/google-cloud-deploy/protos/protos.d.ts
index 48b59793a50..5179103e0ad 100644
--- a/packages/google-cloud-deploy/protos/protos.d.ts
+++ b/packages/google-cloud-deploy/protos/protos.d.ts
@@ -864,6 +864,9 @@ export namespace google {
/** Stage strategy */
strategy?: (google.cloud.deploy.v1.IStrategy|null);
+
+ /** Stage deployParameters */
+ deployParameters?: (google.cloud.deploy.v1.IDeployParameters[]|null);
}
/** Represents a Stage. */
@@ -884,6 +887,9 @@ export namespace google {
/** Stage strategy. */
public strategy?: (google.cloud.deploy.v1.IStrategy|null);
+ /** Stage deployParameters. */
+ public deployParameters: google.cloud.deploy.v1.IDeployParameters[];
+
/**
* Creates a new Stage instance using the specified properties.
* @param [properties] Properties to set
@@ -962,6 +968,109 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ /** Properties of a DeployParameters. */
+ interface IDeployParameters {
+
+ /** DeployParameters values */
+ values?: ({ [k: string]: string }|null);
+
+ /** DeployParameters matchTargetLabels */
+ matchTargetLabels?: ({ [k: string]: string }|null);
+ }
+
+ /** Represents a DeployParameters. */
+ class DeployParameters implements IDeployParameters {
+
+ /**
+ * Constructs a new DeployParameters.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.deploy.v1.IDeployParameters);
+
+ /** DeployParameters values. */
+ public values: { [k: string]: string };
+
+ /** DeployParameters matchTargetLabels. */
+ public matchTargetLabels: { [k: string]: string };
+
+ /**
+ * Creates a new DeployParameters instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns DeployParameters instance
+ */
+ public static create(properties?: google.cloud.deploy.v1.IDeployParameters): google.cloud.deploy.v1.DeployParameters;
+
+ /**
+ * Encodes the specified DeployParameters message. Does not implicitly {@link google.cloud.deploy.v1.DeployParameters.verify|verify} messages.
+ * @param message DeployParameters message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.deploy.v1.IDeployParameters, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified DeployParameters message, length delimited. Does not implicitly {@link google.cloud.deploy.v1.DeployParameters.verify|verify} messages.
+ * @param message DeployParameters message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.deploy.v1.IDeployParameters, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a DeployParameters message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns DeployParameters
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.deploy.v1.DeployParameters;
+
+ /**
+ * Decodes a DeployParameters message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns DeployParameters
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.deploy.v1.DeployParameters;
+
+ /**
+ * Verifies a DeployParameters message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a DeployParameters message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns DeployParameters
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.deploy.v1.DeployParameters;
+
+ /**
+ * Creates a plain object from a DeployParameters message. Also converts values to other types if specified.
+ * @param message DeployParameters
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.deploy.v1.DeployParameters, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this DeployParameters to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for DeployParameters
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a Strategy. */
interface IStrategy {
@@ -3292,6 +3401,9 @@ export namespace google {
/** Target executionConfigs */
executionConfigs?: (google.cloud.deploy.v1.IExecutionConfig[]|null);
+
+ /** Target deployParameters */
+ deployParameters?: ({ [k: string]: string }|null);
}
/** Represents a Target. */
@@ -3348,6 +3460,9 @@ export namespace google {
/** Target executionConfigs. */
public executionConfigs: google.cloud.deploy.v1.IExecutionConfig[];
+ /** Target deployParameters. */
+ public deployParameters: { [k: string]: string };
+
/** Target deploymentTarget. */
public deploymentTarget?: ("gke"|"anthosCluster"|"run"|"multiTarget");
@@ -4934,6 +5049,9 @@ export namespace google {
/** Release condition */
condition?: (google.cloud.deploy.v1.Release.IReleaseCondition|null);
+
+ /** Release deployParameters */
+ deployParameters?: ({ [k: string]: string }|null);
}
/** Represents a Release. */
@@ -5005,6 +5123,9 @@ export namespace google {
/** Release condition. */
public condition?: (google.cloud.deploy.v1.Release.IReleaseCondition|null);
+ /** Release deployParameters. */
+ public deployParameters: { [k: string]: string };
+
/**
* Creates a new Release instance using the specified properties.
* @param [properties] Properties to set
diff --git a/packages/google-cloud-deploy/protos/protos.js b/packages/google-cloud-deploy/protos/protos.js
index 6ceacdfd5c3..969770a71ff 100644
--- a/packages/google-cloud-deploy/protos/protos.js
+++ b/packages/google-cloud-deploy/protos/protos.js
@@ -1737,6 +1737,7 @@
* @property {string|null} [targetId] Stage targetId
* @property {Array.|null} [profiles] Stage profiles
* @property {google.cloud.deploy.v1.IStrategy|null} [strategy] Stage strategy
+ * @property {Array.|null} [deployParameters] Stage deployParameters
*/
/**
@@ -1749,6 +1750,7 @@
*/
function Stage(properties) {
this.profiles = [];
+ this.deployParameters = [];
if (properties)
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
if (properties[keys[i]] != null)
@@ -1779,6 +1781,14 @@
*/
Stage.prototype.strategy = null;
+ /**
+ * Stage deployParameters.
+ * @member {Array.} deployParameters
+ * @memberof google.cloud.deploy.v1.Stage
+ * @instance
+ */
+ Stage.prototype.deployParameters = $util.emptyArray;
+
/**
* Creates a new Stage instance using the specified properties.
* @function create
@@ -1810,6 +1820,9 @@
writer.uint32(/* id 2, wireType 2 =*/18).string(message.profiles[i]);
if (message.strategy != null && Object.hasOwnProperty.call(message, "strategy"))
$root.google.cloud.deploy.v1.Strategy.encode(message.strategy, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim();
+ if (message.deployParameters != null && message.deployParameters.length)
+ for (var i = 0; i < message.deployParameters.length; ++i)
+ $root.google.cloud.deploy.v1.DeployParameters.encode(message.deployParameters[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim();
return writer;
};
@@ -1858,6 +1871,12 @@
message.strategy = $root.google.cloud.deploy.v1.Strategy.decode(reader, reader.uint32());
break;
}
+ case 6: {
+ if (!(message.deployParameters && message.deployParameters.length))
+ message.deployParameters = [];
+ message.deployParameters.push($root.google.cloud.deploy.v1.DeployParameters.decode(reader, reader.uint32()));
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -1908,6 +1927,15 @@
if (error)
return "strategy." + error;
}
+ if (message.deployParameters != null && message.hasOwnProperty("deployParameters")) {
+ if (!Array.isArray(message.deployParameters))
+ return "deployParameters: array expected";
+ for (var i = 0; i < message.deployParameters.length; ++i) {
+ var error = $root.google.cloud.deploy.v1.DeployParameters.verify(message.deployParameters[i]);
+ if (error)
+ return "deployParameters." + error;
+ }
+ }
return null;
};
@@ -1937,6 +1965,16 @@
throw TypeError(".google.cloud.deploy.v1.Stage.strategy: object expected");
message.strategy = $root.google.cloud.deploy.v1.Strategy.fromObject(object.strategy);
}
+ if (object.deployParameters) {
+ if (!Array.isArray(object.deployParameters))
+ throw TypeError(".google.cloud.deploy.v1.Stage.deployParameters: array expected");
+ message.deployParameters = [];
+ for (var i = 0; i < object.deployParameters.length; ++i) {
+ if (typeof object.deployParameters[i] !== "object")
+ throw TypeError(".google.cloud.deploy.v1.Stage.deployParameters: object expected");
+ message.deployParameters[i] = $root.google.cloud.deploy.v1.DeployParameters.fromObject(object.deployParameters[i]);
+ }
+ }
return message;
};
@@ -1953,8 +1991,10 @@
if (!options)
options = {};
var object = {};
- if (options.arrays || options.defaults)
+ if (options.arrays || options.defaults) {
object.profiles = [];
+ object.deployParameters = [];
+ }
if (options.defaults) {
object.targetId = "";
object.strategy = null;
@@ -1968,6 +2008,11 @@
}
if (message.strategy != null && message.hasOwnProperty("strategy"))
object.strategy = $root.google.cloud.deploy.v1.Strategy.toObject(message.strategy, options);
+ if (message.deployParameters && message.deployParameters.length) {
+ object.deployParameters = [];
+ for (var j = 0; j < message.deployParameters.length; ++j)
+ object.deployParameters[j] = $root.google.cloud.deploy.v1.DeployParameters.toObject(message.deployParameters[j], options);
+ }
return object;
};
@@ -2000,6 +2045,302 @@
return Stage;
})();
+ v1.DeployParameters = (function() {
+
+ /**
+ * Properties of a DeployParameters.
+ * @memberof google.cloud.deploy.v1
+ * @interface IDeployParameters
+ * @property {Object.|null} [values] DeployParameters values
+ * @property {Object.|null} [matchTargetLabels] DeployParameters matchTargetLabels
+ */
+
+ /**
+ * Constructs a new DeployParameters.
+ * @memberof google.cloud.deploy.v1
+ * @classdesc Represents a DeployParameters.
+ * @implements IDeployParameters
+ * @constructor
+ * @param {google.cloud.deploy.v1.IDeployParameters=} [properties] Properties to set
+ */
+ function DeployParameters(properties) {
+ this.values = {};
+ this.matchTargetLabels = {};
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * DeployParameters values.
+ * @member {Object.} values
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @instance
+ */
+ DeployParameters.prototype.values = $util.emptyObject;
+
+ /**
+ * DeployParameters matchTargetLabels.
+ * @member {Object.} matchTargetLabels
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @instance
+ */
+ DeployParameters.prototype.matchTargetLabels = $util.emptyObject;
+
+ /**
+ * Creates a new DeployParameters instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {google.cloud.deploy.v1.IDeployParameters=} [properties] Properties to set
+ * @returns {google.cloud.deploy.v1.DeployParameters} DeployParameters instance
+ */
+ DeployParameters.create = function create(properties) {
+ return new DeployParameters(properties);
+ };
+
+ /**
+ * Encodes the specified DeployParameters message. Does not implicitly {@link google.cloud.deploy.v1.DeployParameters.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {google.cloud.deploy.v1.IDeployParameters} message DeployParameters message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ DeployParameters.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.values != null && Object.hasOwnProperty.call(message, "values"))
+ for (var keys = Object.keys(message.values), i = 0; i < keys.length; ++i)
+ writer.uint32(/* id 1, wireType 2 =*/10).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]).uint32(/* id 2, wireType 2 =*/18).string(message.values[keys[i]]).ldelim();
+ if (message.matchTargetLabels != null && Object.hasOwnProperty.call(message, "matchTargetLabels"))
+ for (var keys = Object.keys(message.matchTargetLabels), i = 0; i < keys.length; ++i)
+ writer.uint32(/* id 2, wireType 2 =*/18).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]).uint32(/* id 2, wireType 2 =*/18).string(message.matchTargetLabels[keys[i]]).ldelim();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified DeployParameters message, length delimited. Does not implicitly {@link google.cloud.deploy.v1.DeployParameters.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {google.cloud.deploy.v1.IDeployParameters} message DeployParameters message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ DeployParameters.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a DeployParameters message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.deploy.v1.DeployParameters} DeployParameters
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ DeployParameters.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.deploy.v1.DeployParameters(), key, value;
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ if (message.values === $util.emptyObject)
+ message.values = {};
+ var end2 = reader.uint32() + reader.pos;
+ key = "";
+ value = "";
+ while (reader.pos < end2) {
+ var tag2 = reader.uint32();
+ switch (tag2 >>> 3) {
+ case 1:
+ key = reader.string();
+ break;
+ case 2:
+ value = reader.string();
+ break;
+ default:
+ reader.skipType(tag2 & 7);
+ break;
+ }
+ }
+ message.values[key] = value;
+ break;
+ }
+ case 2: {
+ if (message.matchTargetLabels === $util.emptyObject)
+ message.matchTargetLabels = {};
+ var end2 = reader.uint32() + reader.pos;
+ key = "";
+ value = "";
+ while (reader.pos < end2) {
+ var tag2 = reader.uint32();
+ switch (tag2 >>> 3) {
+ case 1:
+ key = reader.string();
+ break;
+ case 2:
+ value = reader.string();
+ break;
+ default:
+ reader.skipType(tag2 & 7);
+ break;
+ }
+ }
+ message.matchTargetLabels[key] = value;
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a DeployParameters message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.deploy.v1.DeployParameters} DeployParameters
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ DeployParameters.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a DeployParameters message.
+ * @function verify
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ DeployParameters.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.values != null && message.hasOwnProperty("values")) {
+ if (!$util.isObject(message.values))
+ return "values: object expected";
+ var key = Object.keys(message.values);
+ for (var i = 0; i < key.length; ++i)
+ if (!$util.isString(message.values[key[i]]))
+ return "values: string{k:string} expected";
+ }
+ if (message.matchTargetLabels != null && message.hasOwnProperty("matchTargetLabels")) {
+ if (!$util.isObject(message.matchTargetLabels))
+ return "matchTargetLabels: object expected";
+ var key = Object.keys(message.matchTargetLabels);
+ for (var i = 0; i < key.length; ++i)
+ if (!$util.isString(message.matchTargetLabels[key[i]]))
+ return "matchTargetLabels: string{k:string} expected";
+ }
+ return null;
+ };
+
+ /**
+ * Creates a DeployParameters message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.deploy.v1.DeployParameters} DeployParameters
+ */
+ DeployParameters.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.deploy.v1.DeployParameters)
+ return object;
+ var message = new $root.google.cloud.deploy.v1.DeployParameters();
+ if (object.values) {
+ if (typeof object.values !== "object")
+ throw TypeError(".google.cloud.deploy.v1.DeployParameters.values: object expected");
+ message.values = {};
+ for (var keys = Object.keys(object.values), i = 0; i < keys.length; ++i)
+ message.values[keys[i]] = String(object.values[keys[i]]);
+ }
+ if (object.matchTargetLabels) {
+ if (typeof object.matchTargetLabels !== "object")
+ throw TypeError(".google.cloud.deploy.v1.DeployParameters.matchTargetLabels: object expected");
+ message.matchTargetLabels = {};
+ for (var keys = Object.keys(object.matchTargetLabels), i = 0; i < keys.length; ++i)
+ message.matchTargetLabels[keys[i]] = String(object.matchTargetLabels[keys[i]]);
+ }
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a DeployParameters message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {google.cloud.deploy.v1.DeployParameters} message DeployParameters
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ DeployParameters.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.objects || options.defaults) {
+ object.values = {};
+ object.matchTargetLabels = {};
+ }
+ var keys2;
+ if (message.values && (keys2 = Object.keys(message.values)).length) {
+ object.values = {};
+ for (var j = 0; j < keys2.length; ++j)
+ object.values[keys2[j]] = message.values[keys2[j]];
+ }
+ if (message.matchTargetLabels && (keys2 = Object.keys(message.matchTargetLabels)).length) {
+ object.matchTargetLabels = {};
+ for (var j = 0; j < keys2.length; ++j)
+ object.matchTargetLabels[keys2[j]] = message.matchTargetLabels[keys2[j]];
+ }
+ return object;
+ };
+
+ /**
+ * Converts this DeployParameters to JSON.
+ * @function toJSON
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ DeployParameters.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for DeployParameters
+ * @function getTypeUrl
+ * @memberof google.cloud.deploy.v1.DeployParameters
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ DeployParameters.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.deploy.v1.DeployParameters";
+ };
+
+ return DeployParameters;
+ })();
+
v1.Strategy = (function() {
/**
@@ -7478,6 +7819,7 @@
* @property {google.cloud.deploy.v1.IMultiTarget|null} [multiTarget] Target multiTarget
* @property {string|null} [etag] Target etag
* @property {Array.|null} [executionConfigs] Target executionConfigs
+ * @property {Object.|null} [deployParameters] Target deployParameters
*/
/**
@@ -7492,6 +7834,7 @@
this.annotations = {};
this.labels = {};
this.executionConfigs = [];
+ this.deployParameters = {};
if (properties)
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
if (properties[keys[i]] != null)
@@ -7618,6 +7961,14 @@
*/
Target.prototype.executionConfigs = $util.emptyArray;
+ /**
+ * Target deployParameters.
+ * @member {Object.} deployParameters
+ * @memberof google.cloud.deploy.v1.Target
+ * @instance
+ */
+ Target.prototype.deployParameters = $util.emptyObject;
+
// OneOf field names bound to virtual getters and setters
var $oneOfFields;
@@ -7689,6 +8040,9 @@
$root.google.cloud.deploy.v1.CloudRunLocation.encode(message.run, writer.uint32(/* id 18, wireType 2 =*/146).fork()).ldelim();
if (message.multiTarget != null && Object.hasOwnProperty.call(message, "multiTarget"))
$root.google.cloud.deploy.v1.MultiTarget.encode(message.multiTarget, writer.uint32(/* id 19, wireType 2 =*/154).fork()).ldelim();
+ if (message.deployParameters != null && Object.hasOwnProperty.call(message, "deployParameters"))
+ for (var keys = Object.keys(message.deployParameters), i = 0; i < keys.length; ++i)
+ writer.uint32(/* id 20, wireType 2 =*/162).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]).uint32(/* id 2, wireType 2 =*/18).string(message.deployParameters[keys[i]]).ldelim();
return writer;
};
@@ -7823,6 +8177,29 @@
message.executionConfigs.push($root.google.cloud.deploy.v1.ExecutionConfig.decode(reader, reader.uint32()));
break;
}
+ case 20: {
+ if (message.deployParameters === $util.emptyObject)
+ message.deployParameters = {};
+ var end2 = reader.uint32() + reader.pos;
+ key = "";
+ value = "";
+ while (reader.pos < end2) {
+ var tag2 = reader.uint32();
+ switch (tag2 >>> 3) {
+ case 1:
+ key = reader.string();
+ break;
+ case 2:
+ value = reader.string();
+ break;
+ default:
+ reader.skipType(tag2 & 7);
+ break;
+ }
+ }
+ message.deployParameters[key] = value;
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -7950,6 +8327,14 @@
return "executionConfigs." + error;
}
}
+ if (message.deployParameters != null && message.hasOwnProperty("deployParameters")) {
+ if (!$util.isObject(message.deployParameters))
+ return "deployParameters: object expected";
+ var key = Object.keys(message.deployParameters);
+ for (var i = 0; i < key.length; ++i)
+ if (!$util.isString(message.deployParameters[key[i]]))
+ return "deployParameters: string{k:string} expected";
+ }
return null;
};
@@ -8031,6 +8416,13 @@
message.executionConfigs[i] = $root.google.cloud.deploy.v1.ExecutionConfig.fromObject(object.executionConfigs[i]);
}
}
+ if (object.deployParameters) {
+ if (typeof object.deployParameters !== "object")
+ throw TypeError(".google.cloud.deploy.v1.Target.deployParameters: object expected");
+ message.deployParameters = {};
+ for (var keys = Object.keys(object.deployParameters), i = 0; i < keys.length; ++i)
+ message.deployParameters[keys[i]] = String(object.deployParameters[keys[i]]);
+ }
return message;
};
@@ -8052,6 +8444,7 @@
if (options.objects || options.defaults) {
object.annotations = {};
object.labels = {};
+ object.deployParameters = {};
}
if (options.defaults) {
object.name = "";
@@ -8115,6 +8508,11 @@
if (options.oneofs)
object.deploymentTarget = "multiTarget";
}
+ if (message.deployParameters && (keys2 = Object.keys(message.deployParameters)).length) {
+ object.deployParameters = {};
+ for (var j = 0; j < keys2.length; ++j)
+ object.deployParameters[keys2[j]] = message.deployParameters[keys2[j]];
+ }
return object;
};
@@ -11648,6 +12046,7 @@
* @property {Object.|null} [targetArtifacts] Release targetArtifacts
* @property {Object.|null} [targetRenders] Release targetRenders
* @property {google.cloud.deploy.v1.Release.IReleaseCondition|null} [condition] Release condition
+ * @property {Object.|null} [deployParameters] Release deployParameters
*/
/**
@@ -11665,6 +12064,7 @@
this.targetSnapshots = [];
this.targetArtifacts = {};
this.targetRenders = {};
+ this.deployParameters = {};
if (properties)
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
if (properties[keys[i]] != null)
@@ -11831,6 +12231,14 @@
*/
Release.prototype.condition = null;
+ /**
+ * Release deployParameters.
+ * @member {Object.} deployParameters
+ * @memberof google.cloud.deploy.v1.Release
+ * @instance
+ */
+ Release.prototype.deployParameters = $util.emptyObject;
+
/**
* Creates a new Release instance using the specified properties.
* @function create
@@ -11905,6 +12313,9 @@
writer.uint32(/* id 23, wireType 0 =*/184).bool(message.abandoned);
if (message.condition != null && Object.hasOwnProperty.call(message, "condition"))
$root.google.cloud.deploy.v1.Release.ReleaseCondition.encode(message.condition, writer.uint32(/* id 24, wireType 2 =*/194).fork()).ldelim();
+ if (message.deployParameters != null && Object.hasOwnProperty.call(message, "deployParameters"))
+ for (var keys = Object.keys(message.deployParameters), i = 0; i < keys.length; ++i)
+ writer.uint32(/* id 25, wireType 2 =*/202).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]).uint32(/* id 2, wireType 2 =*/18).string(message.deployParameters[keys[i]]).ldelim();
return writer;
};
@@ -12099,6 +12510,29 @@
message.condition = $root.google.cloud.deploy.v1.Release.ReleaseCondition.decode(reader, reader.uint32());
break;
}
+ case 25: {
+ if (message.deployParameters === $util.emptyObject)
+ message.deployParameters = {};
+ var end2 = reader.uint32() + reader.pos;
+ key = "";
+ value = "";
+ while (reader.pos < end2) {
+ var tag2 = reader.uint32();
+ switch (tag2 >>> 3) {
+ case 1:
+ key = reader.string();
+ break;
+ case 2:
+ value = reader.string();
+ break;
+ default:
+ reader.skipType(tag2 & 7);
+ break;
+ }
+ }
+ message.deployParameters[key] = value;
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -12247,6 +12681,14 @@
if (error)
return "condition." + error;
}
+ if (message.deployParameters != null && message.hasOwnProperty("deployParameters")) {
+ if (!$util.isObject(message.deployParameters))
+ return "deployParameters: object expected";
+ var key = Object.keys(message.deployParameters);
+ for (var i = 0; i < key.length; ++i)
+ if (!$util.isString(message.deployParameters[key[i]]))
+ return "deployParameters: string{k:string} expected";
+ }
return null;
};
@@ -12381,6 +12823,13 @@
throw TypeError(".google.cloud.deploy.v1.Release.condition: object expected");
message.condition = $root.google.cloud.deploy.v1.Release.ReleaseCondition.fromObject(object.condition);
}
+ if (object.deployParameters) {
+ if (typeof object.deployParameters !== "object")
+ throw TypeError(".google.cloud.deploy.v1.Release.deployParameters: object expected");
+ message.deployParameters = {};
+ for (var keys = Object.keys(object.deployParameters), i = 0; i < keys.length; ++i)
+ message.deployParameters[keys[i]] = String(object.deployParameters[keys[i]]);
+ }
return message;
};
@@ -12406,6 +12855,7 @@
object.labels = {};
object.targetArtifacts = {};
object.targetRenders = {};
+ object.deployParameters = {};
}
if (options.defaults) {
object.name = "";
@@ -12482,6 +12932,11 @@
object.abandoned = message.abandoned;
if (message.condition != null && message.hasOwnProperty("condition"))
object.condition = $root.google.cloud.deploy.v1.Release.ReleaseCondition.toObject(message.condition, options);
+ if (message.deployParameters && (keys2 = Object.keys(message.deployParameters)).length) {
+ object.deployParameters = {};
+ for (var j = 0; j < keys2.length; ++j)
+ object.deployParameters[keys2[j]] = message.deployParameters[keys2[j]];
+ }
return object;
};
diff --git a/packages/google-cloud-deploy/protos/protos.json b/packages/google-cloud-deploy/protos/protos.json
index 95f4136ff79..2b39c79cebf 100644
--- a/packages/google-cloud-deploy/protos/protos.json
+++ b/packages/google-cloud-deploy/protos/protos.json
@@ -684,6 +684,34 @@
"options": {
"(google.api.field_behavior)": "OPTIONAL"
}
+ },
+ "deployParameters": {
+ "rule": "repeated",
+ "type": "DeployParameters",
+ "id": 6,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
+ }
+ }
+ },
+ "DeployParameters": {
+ "fields": {
+ "values": {
+ "keyType": "string",
+ "type": "string",
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
+ },
+ "matchTargetLabels": {
+ "keyType": "string",
+ "type": "string",
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
}
},
@@ -1251,6 +1279,14 @@
"rule": "repeated",
"type": "ExecutionConfig",
"id": 16
+ },
+ "deployParameters": {
+ "keyType": "string",
+ "type": "string",
+ "id": 20,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
}
},
@@ -1740,6 +1776,14 @@
"options": {
"(google.api.field_behavior)": "OUTPUT_ONLY"
}
+ },
+ "deployParameters": {
+ "keyType": "string",
+ "type": "string",
+ "id": 25,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
},
"nested": {
diff --git a/packages/google-cloud-deploy/samples/generated/v1/snippet_metadata.google.cloud.deploy.v1.json b/packages/google-cloud-deploy/samples/generated/v1/snippet_metadata.google.cloud.deploy.v1.json
index 0394f75abe1..d0057313793 100644
--- a/packages/google-cloud-deploy/samples/generated/v1/snippet_metadata.google.cloud.deploy.v1.json
+++ b/packages/google-cloud-deploy/samples/generated/v1/snippet_metadata.google.cloud.deploy.v1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-deploy",
- "version": "2.6.0",
+ "version": "2.7.0",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-deploy/samples/package.json b/packages/google-cloud-deploy/samples/package.json
index 33af6feb4f9..552468c901b 100644
--- a/packages/google-cloud-deploy/samples/package.json
+++ b/packages/google-cloud-deploy/samples/package.json
@@ -13,7 +13,7 @@
"test": "c8 mocha --timeout 600000 test/*.js"
},
"dependencies": {
- "@google-cloud/deploy": "^2.6.0"
+ "@google-cloud/deploy": "^2.7.0"
},
"devDependencies": {
"c8": "^7.1.0",
diff --git a/packages/google-cloud-dialogflow-cx/CHANGELOG.md b/packages/google-cloud-dialogflow-cx/CHANGELOG.md
index 456220fd59d..e25c86af32d 100644
--- a/packages/google-cloud-dialogflow-cx/CHANGELOG.md
+++ b/packages/google-cloud-dialogflow-cx/CHANGELOG.md
@@ -1,5 +1,15 @@
# Changelog
+## [3.7.0](https://github.com/googleapis/google-cloud-node/compare/dialogflow-cx-v3.6.0...dialogflow-cx-v3.7.0) (2023-06-28)
+
+
+### Features
+
+* [dialogflow-cx] added include_bigquery_export_settings to ExportAgentRequest ([7778345](https://github.com/googleapis/google-cloud-node/commit/7778345f3d7089e3bdc1294beb4005cfa8793012))
+* [dialogflow-cx] added include_bigquery_export_settings to ExportAgentRequest ([#4357](https://github.com/googleapis/google-cloud-node/issues/4357)) ([7778345](https://github.com/googleapis/google-cloud-node/commit/7778345f3d7089e3bdc1294beb4005cfa8793012))
+* Added session_ttl to SessionProto ([7778345](https://github.com/googleapis/google-cloud-node/commit/7778345f3d7089e3bdc1294beb4005cfa8793012))
+* Added session_ttl to SessionProto ([7778345](https://github.com/googleapis/google-cloud-node/commit/7778345f3d7089e3bdc1294beb4005cfa8793012))
+
## [3.6.0](https://github.com/googleapis/google-cloud-node/compare/dialogflow-cx-v3.5.0...dialogflow-cx-v3.6.0) (2023-06-14)
diff --git a/packages/google-cloud-dialogflow-cx/package.json b/packages/google-cloud-dialogflow-cx/package.json
index f08914495fb..382e1799f76 100644
--- a/packages/google-cloud-dialogflow-cx/package.json
+++ b/packages/google-cloud-dialogflow-cx/package.json
@@ -1,6 +1,6 @@
{
"name": "@google-cloud/dialogflow-cx",
- "version": "3.6.0",
+ "version": "3.7.0",
"description": "Cx client for Node.js",
"repository": {
"type": "git",
diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/agent.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/agent.proto
index a8d95f09718..ba648686489 100644
--- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/agent.proto
+++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/agent.proto
@@ -408,6 +408,10 @@ message ExportAgentRequest {
type: "dialogflow.googleapis.com/Environment"
}
];
+
+ // Optional. Whether to include BigQuery Export setting.
+ bool include_bigquery_export_settings = 7
+ [(google.api.field_behavior) = OPTIONAL];
}
// The response message for
diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/session.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/session.proto
index 924911a705f..fe1315e5b98 100644
--- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/session.proto
+++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3/session.proto
@@ -596,6 +596,13 @@ message QueryParameters {
// [ResponseMessage][google.cloud.dialogflow.cx.v3.ResponseMessage] with
// unspecified channel will be returned.
string channel = 15;
+
+ // Optional. Sets Dialogflow session life time.
+ // By default, a Dialogflow session remains active and its data is stored for
+ // 30 minutes after the last request is sent for the session.
+ // This value should be no longer than 1 day.
+ google.protobuf.Duration session_ttl = 16
+ [(google.api.field_behavior) = OPTIONAL];
}
// Represents the query input. It can contain one of:
diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto
index 403b1859809..42b27051d0b 100644
--- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto
+++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/agent.proto
@@ -408,6 +408,10 @@ message ExportAgentRequest {
type: "dialogflow.googleapis.com/Environment"
}
];
+
+ // Optional. Whether to include BigQuery Export setting.
+ bool include_bigquery_export_settings = 7
+ [(google.api.field_behavior) = OPTIONAL];
}
// The response message for
diff --git a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/session.proto b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/session.proto
index 4e691c5ba4e..dcf2f5a4de7 100644
--- a/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/session.proto
+++ b/packages/google-cloud-dialogflow-cx/protos/google/cloud/dialogflow/cx/v3beta1/session.proto
@@ -598,6 +598,13 @@ message QueryParameters {
// [ResponseMessage][google.cloud.dialogflow.cx.v3beta1.ResponseMessage] with
// unspecified channel will be returned.
string channel = 15;
+
+ // Optional. Sets Dialogflow session life time.
+ // By default, a Dialogflow session remains active and its data is stored for
+ // 30 minutes after the last request is sent for the session.
+ // This value should be no longer than 1 day.
+ google.protobuf.Duration session_ttl = 16
+ [(google.api.field_behavior) = OPTIONAL];
}
// Represents the query input. It can contain one of:
diff --git a/packages/google-cloud-dialogflow-cx/protos/protos.d.ts b/packages/google-cloud-dialogflow-cx/protos/protos.d.ts
index 460cc452d77..edf42ef6073 100644
--- a/packages/google-cloud-dialogflow-cx/protos/protos.d.ts
+++ b/packages/google-cloud-dialogflow-cx/protos/protos.d.ts
@@ -1452,6 +1452,9 @@ export namespace google {
/** ExportAgentRequest environment */
environment?: (string|null);
+
+ /** ExportAgentRequest includeBigqueryExportSettings */
+ includeBigqueryExportSettings?: (boolean|null);
}
/** Represents an ExportAgentRequest. */
@@ -1475,6 +1478,9 @@ export namespace google {
/** ExportAgentRequest environment. */
public environment: string;
+ /** ExportAgentRequest includeBigqueryExportSettings. */
+ public includeBigqueryExportSettings: boolean;
+
/**
* Creates a new ExportAgentRequest instance using the specified properties.
* @param [properties] Properties to set
@@ -19678,6 +19684,9 @@ export namespace google {
/** QueryParameters channel */
channel?: (string|null);
+
+ /** QueryParameters sessionTtl */
+ sessionTtl?: (google.protobuf.IDuration|null);
}
/** Represents a QueryParameters. */
@@ -19722,6 +19731,9 @@ export namespace google {
/** QueryParameters channel. */
public channel: string;
+ /** QueryParameters sessionTtl. */
+ public sessionTtl?: (google.protobuf.IDuration|null);
+
/**
* Creates a new QueryParameters instance using the specified properties.
* @param [properties] Properties to set
@@ -31813,6 +31825,9 @@ export namespace google {
/** ExportAgentRequest environment */
environment?: (string|null);
+
+ /** ExportAgentRequest includeBigqueryExportSettings */
+ includeBigqueryExportSettings?: (boolean|null);
}
/** Represents an ExportAgentRequest. */
@@ -31836,6 +31851,9 @@ export namespace google {
/** ExportAgentRequest environment. */
public environment: string;
+ /** ExportAgentRequest includeBigqueryExportSettings. */
+ public includeBigqueryExportSettings: boolean;
+
/**
* Creates a new ExportAgentRequest instance using the specified properties.
* @param [properties] Properties to set
@@ -50039,6 +50057,9 @@ export namespace google {
/** QueryParameters channel */
channel?: (string|null);
+
+ /** QueryParameters sessionTtl */
+ sessionTtl?: (google.protobuf.IDuration|null);
}
/** Represents a QueryParameters. */
@@ -50083,6 +50104,9 @@ export namespace google {
/** QueryParameters channel. */
public channel: string;
+ /** QueryParameters sessionTtl. */
+ public sessionTtl?: (google.protobuf.IDuration|null);
+
/**
* Creates a new QueryParameters instance using the specified properties.
* @param [properties] Properties to set
diff --git a/packages/google-cloud-dialogflow-cx/protos/protos.js b/packages/google-cloud-dialogflow-cx/protos/protos.js
index ba2c64de63c..195883711db 100644
--- a/packages/google-cloud-dialogflow-cx/protos/protos.js
+++ b/packages/google-cloud-dialogflow-cx/protos/protos.js
@@ -3218,6 +3218,7 @@
* @property {string|null} [agentUri] ExportAgentRequest agentUri
* @property {google.cloud.dialogflow.cx.v3.ExportAgentRequest.DataFormat|null} [dataFormat] ExportAgentRequest dataFormat
* @property {string|null} [environment] ExportAgentRequest environment
+ * @property {boolean|null} [includeBigqueryExportSettings] ExportAgentRequest includeBigqueryExportSettings
*/
/**
@@ -3267,6 +3268,14 @@
*/
ExportAgentRequest.prototype.environment = "";
+ /**
+ * ExportAgentRequest includeBigqueryExportSettings.
+ * @member {boolean} includeBigqueryExportSettings
+ * @memberof google.cloud.dialogflow.cx.v3.ExportAgentRequest
+ * @instance
+ */
+ ExportAgentRequest.prototype.includeBigqueryExportSettings = false;
+
/**
* Creates a new ExportAgentRequest instance using the specified properties.
* @function create
@@ -3299,6 +3308,8 @@
writer.uint32(/* id 3, wireType 0 =*/24).int32(message.dataFormat);
if (message.environment != null && Object.hasOwnProperty.call(message, "environment"))
writer.uint32(/* id 5, wireType 2 =*/42).string(message.environment);
+ if (message.includeBigqueryExportSettings != null && Object.hasOwnProperty.call(message, "includeBigqueryExportSettings"))
+ writer.uint32(/* id 7, wireType 0 =*/56).bool(message.includeBigqueryExportSettings);
return writer;
};
@@ -3349,6 +3360,10 @@
message.environment = reader.string();
break;
}
+ case 7: {
+ message.includeBigqueryExportSettings = reader.bool();
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -3402,6 +3417,9 @@
if (message.environment != null && message.hasOwnProperty("environment"))
if (!$util.isString(message.environment))
return "environment: string expected";
+ if (message.includeBigqueryExportSettings != null && message.hasOwnProperty("includeBigqueryExportSettings"))
+ if (typeof message.includeBigqueryExportSettings !== "boolean")
+ return "includeBigqueryExportSettings: boolean expected";
return null;
};
@@ -3443,6 +3461,8 @@
}
if (object.environment != null)
message.environment = String(object.environment);
+ if (object.includeBigqueryExportSettings != null)
+ message.includeBigqueryExportSettings = Boolean(object.includeBigqueryExportSettings);
return message;
};
@@ -3464,6 +3484,7 @@
object.agentUri = "";
object.dataFormat = options.enums === String ? "DATA_FORMAT_UNSPECIFIED" : 0;
object.environment = "";
+ object.includeBigqueryExportSettings = false;
}
if (message.name != null && message.hasOwnProperty("name"))
object.name = message.name;
@@ -3473,6 +3494,8 @@
object.dataFormat = options.enums === String ? $root.google.cloud.dialogflow.cx.v3.ExportAgentRequest.DataFormat[message.dataFormat] === undefined ? message.dataFormat : $root.google.cloud.dialogflow.cx.v3.ExportAgentRequest.DataFormat[message.dataFormat] : message.dataFormat;
if (message.environment != null && message.hasOwnProperty("environment"))
object.environment = message.environment;
+ if (message.includeBigqueryExportSettings != null && message.hasOwnProperty("includeBigqueryExportSettings"))
+ object.includeBigqueryExportSettings = message.includeBigqueryExportSettings;
return object;
};
@@ -46672,6 +46695,7 @@
* @property {Object.|null} [webhookHeaders] QueryParameters webhookHeaders
* @property {Array.|null} [flowVersions] QueryParameters flowVersions
* @property {string|null} [channel] QueryParameters channel
+ * @property {google.protobuf.IDuration|null} [sessionTtl] QueryParameters sessionTtl
*/
/**
@@ -46780,6 +46804,14 @@
*/
QueryParameters.prototype.channel = "";
+ /**
+ * QueryParameters sessionTtl.
+ * @member {google.protobuf.IDuration|null|undefined} sessionTtl
+ * @memberof google.cloud.dialogflow.cx.v3.QueryParameters
+ * @instance
+ */
+ QueryParameters.prototype.sessionTtl = null;
+
/**
* Creates a new QueryParameters instance using the specified properties.
* @function create
@@ -46829,6 +46861,8 @@
writer.uint32(/* id 14, wireType 2 =*/114).string(message.flowVersions[i]);
if (message.channel != null && Object.hasOwnProperty.call(message, "channel"))
writer.uint32(/* id 15, wireType 2 =*/122).string(message.channel);
+ if (message.sessionTtl != null && Object.hasOwnProperty.call(message, "sessionTtl"))
+ $root.google.protobuf.Duration.encode(message.sessionTtl, writer.uint32(/* id 16, wireType 2 =*/130).fork()).ldelim();
return writer;
};
@@ -46930,6 +46964,10 @@
message.channel = reader.string();
break;
}
+ case 16: {
+ message.sessionTtl = $root.google.protobuf.Duration.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -47019,6 +47057,11 @@
if (message.channel != null && message.hasOwnProperty("channel"))
if (!$util.isString(message.channel))
return "channel: string expected";
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl")) {
+ var error = $root.google.protobuf.Duration.verify(message.sessionTtl);
+ if (error)
+ return "sessionTtl." + error;
+ }
return null;
};
@@ -47083,6 +47126,11 @@
}
if (object.channel != null)
message.channel = String(object.channel);
+ if (object.sessionTtl != null) {
+ if (typeof object.sessionTtl !== "object")
+ throw TypeError(".google.cloud.dialogflow.cx.v3.QueryParameters.sessionTtl: object expected");
+ message.sessionTtl = $root.google.protobuf.Duration.fromObject(object.sessionTtl);
+ }
return message;
};
@@ -47114,6 +47162,7 @@
object.disableWebhook = false;
object.analyzeQueryTextSentiment = false;
object.channel = "";
+ object.sessionTtl = null;
}
if (message.timeZone != null && message.hasOwnProperty("timeZone"))
object.timeZone = message.timeZone;
@@ -47147,6 +47196,8 @@
}
if (message.channel != null && message.hasOwnProperty("channel"))
object.channel = message.channel;
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl"))
+ object.sessionTtl = $root.google.protobuf.Duration.toObject(message.sessionTtl, options);
return object;
};
@@ -75593,6 +75644,7 @@
* @property {string|null} [agentUri] ExportAgentRequest agentUri
* @property {google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest.DataFormat|null} [dataFormat] ExportAgentRequest dataFormat
* @property {string|null} [environment] ExportAgentRequest environment
+ * @property {boolean|null} [includeBigqueryExportSettings] ExportAgentRequest includeBigqueryExportSettings
*/
/**
@@ -75642,6 +75694,14 @@
*/
ExportAgentRequest.prototype.environment = "";
+ /**
+ * ExportAgentRequest includeBigqueryExportSettings.
+ * @member {boolean} includeBigqueryExportSettings
+ * @memberof google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest
+ * @instance
+ */
+ ExportAgentRequest.prototype.includeBigqueryExportSettings = false;
+
/**
* Creates a new ExportAgentRequest instance using the specified properties.
* @function create
@@ -75674,6 +75734,8 @@
writer.uint32(/* id 3, wireType 0 =*/24).int32(message.dataFormat);
if (message.environment != null && Object.hasOwnProperty.call(message, "environment"))
writer.uint32(/* id 5, wireType 2 =*/42).string(message.environment);
+ if (message.includeBigqueryExportSettings != null && Object.hasOwnProperty.call(message, "includeBigqueryExportSettings"))
+ writer.uint32(/* id 7, wireType 0 =*/56).bool(message.includeBigqueryExportSettings);
return writer;
};
@@ -75724,6 +75786,10 @@
message.environment = reader.string();
break;
}
+ case 7: {
+ message.includeBigqueryExportSettings = reader.bool();
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -75777,6 +75843,9 @@
if (message.environment != null && message.hasOwnProperty("environment"))
if (!$util.isString(message.environment))
return "environment: string expected";
+ if (message.includeBigqueryExportSettings != null && message.hasOwnProperty("includeBigqueryExportSettings"))
+ if (typeof message.includeBigqueryExportSettings !== "boolean")
+ return "includeBigqueryExportSettings: boolean expected";
return null;
};
@@ -75818,6 +75887,8 @@
}
if (object.environment != null)
message.environment = String(object.environment);
+ if (object.includeBigqueryExportSettings != null)
+ message.includeBigqueryExportSettings = Boolean(object.includeBigqueryExportSettings);
return message;
};
@@ -75839,6 +75910,7 @@
object.agentUri = "";
object.dataFormat = options.enums === String ? "DATA_FORMAT_UNSPECIFIED" : 0;
object.environment = "";
+ object.includeBigqueryExportSettings = false;
}
if (message.name != null && message.hasOwnProperty("name"))
object.name = message.name;
@@ -75848,6 +75920,8 @@
object.dataFormat = options.enums === String ? $root.google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest.DataFormat[message.dataFormat] === undefined ? message.dataFormat : $root.google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest.DataFormat[message.dataFormat] : message.dataFormat;
if (message.environment != null && message.hasOwnProperty("environment"))
object.environment = message.environment;
+ if (message.includeBigqueryExportSettings != null && message.hasOwnProperty("includeBigqueryExportSettings"))
+ object.includeBigqueryExportSettings = message.includeBigqueryExportSettings;
return object;
};
@@ -119047,6 +119121,7 @@
* @property {Object.|null} [webhookHeaders] QueryParameters webhookHeaders
* @property {Array.|null} [flowVersions] QueryParameters flowVersions
* @property {string|null} [channel] QueryParameters channel
+ * @property {google.protobuf.IDuration|null} [sessionTtl] QueryParameters sessionTtl
*/
/**
@@ -119155,6 +119230,14 @@
*/
QueryParameters.prototype.channel = "";
+ /**
+ * QueryParameters sessionTtl.
+ * @member {google.protobuf.IDuration|null|undefined} sessionTtl
+ * @memberof google.cloud.dialogflow.cx.v3beta1.QueryParameters
+ * @instance
+ */
+ QueryParameters.prototype.sessionTtl = null;
+
/**
* Creates a new QueryParameters instance using the specified properties.
* @function create
@@ -119204,6 +119287,8 @@
writer.uint32(/* id 14, wireType 2 =*/114).string(message.flowVersions[i]);
if (message.channel != null && Object.hasOwnProperty.call(message, "channel"))
writer.uint32(/* id 15, wireType 2 =*/122).string(message.channel);
+ if (message.sessionTtl != null && Object.hasOwnProperty.call(message, "sessionTtl"))
+ $root.google.protobuf.Duration.encode(message.sessionTtl, writer.uint32(/* id 16, wireType 2 =*/130).fork()).ldelim();
return writer;
};
@@ -119305,6 +119390,10 @@
message.channel = reader.string();
break;
}
+ case 16: {
+ message.sessionTtl = $root.google.protobuf.Duration.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -119394,6 +119483,11 @@
if (message.channel != null && message.hasOwnProperty("channel"))
if (!$util.isString(message.channel))
return "channel: string expected";
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl")) {
+ var error = $root.google.protobuf.Duration.verify(message.sessionTtl);
+ if (error)
+ return "sessionTtl." + error;
+ }
return null;
};
@@ -119458,6 +119552,11 @@
}
if (object.channel != null)
message.channel = String(object.channel);
+ if (object.sessionTtl != null) {
+ if (typeof object.sessionTtl !== "object")
+ throw TypeError(".google.cloud.dialogflow.cx.v3beta1.QueryParameters.sessionTtl: object expected");
+ message.sessionTtl = $root.google.protobuf.Duration.fromObject(object.sessionTtl);
+ }
return message;
};
@@ -119489,6 +119588,7 @@
object.disableWebhook = false;
object.analyzeQueryTextSentiment = false;
object.channel = "";
+ object.sessionTtl = null;
}
if (message.timeZone != null && message.hasOwnProperty("timeZone"))
object.timeZone = message.timeZone;
@@ -119522,6 +119622,8 @@
}
if (message.channel != null && message.hasOwnProperty("channel"))
object.channel = message.channel;
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl"))
+ object.sessionTtl = $root.google.protobuf.Duration.toObject(message.sessionTtl, options);
return object;
};
diff --git a/packages/google-cloud-dialogflow-cx/protos/protos.json b/packages/google-cloud-dialogflow-cx/protos/protos.json
index cdc54caff5d..a10d88e40aa 100644
--- a/packages/google-cloud-dialogflow-cx/protos/protos.json
+++ b/packages/google-cloud-dialogflow-cx/protos/protos.json
@@ -461,6 +461,13 @@
"(google.api.field_behavior)": "OPTIONAL",
"(google.api.resource_reference).type": "dialogflow.googleapis.com/Environment"
}
+ },
+ "includeBigqueryExportSettings": {
+ "type": "bool",
+ "id": 7,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
},
"nested": {
@@ -4998,6 +5005,13 @@
"channel": {
"type": "string",
"id": 15
+ },
+ "sessionTtl": {
+ "type": "google.protobuf.Duration",
+ "id": 16,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
}
},
@@ -8183,6 +8197,13 @@
"(google.api.field_behavior)": "OPTIONAL",
"(google.api.resource_reference).type": "dialogflow.googleapis.com/Environment"
}
+ },
+ "includeBigqueryExportSettings": {
+ "type": "bool",
+ "id": 7,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
},
"nested": {
@@ -12720,6 +12741,13 @@
"channel": {
"type": "string",
"id": 15
+ },
+ "sessionTtl": {
+ "type": "google.protobuf.Duration",
+ "id": 16,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
}
},
diff --git a/packages/google-cloud-dialogflow-cx/samples/generated/v3/agents.export_agent.js b/packages/google-cloud-dialogflow-cx/samples/generated/v3/agents.export_agent.js
index 5d83c702a63..cea123ba994 100644
--- a/packages/google-cloud-dialogflow-cx/samples/generated/v3/agents.export_agent.js
+++ b/packages/google-cloud-dialogflow-cx/samples/generated/v3/agents.export_agent.js
@@ -56,6 +56,10 @@ function main(name) {
* ID>/environments/`.
*/
// const environment = 'abc123'
+ /**
+ * Optional. Whether to include BigQuery Export setting.
+ */
+ // const includeBigqueryExportSettings = true
// Imports the Cx library
const {AgentsClient} = require('@google-cloud/dialogflow-cx').v3;
diff --git a/packages/google-cloud-dialogflow-cx/samples/generated/v3/snippet_metadata.google.cloud.dialogflow.cx.v3.json b/packages/google-cloud-dialogflow-cx/samples/generated/v3/snippet_metadata.google.cloud.dialogflow.cx.v3.json
index 25462c5166f..74c9271078f 100644
--- a/packages/google-cloud-dialogflow-cx/samples/generated/v3/snippet_metadata.google.cloud.dialogflow.cx.v3.json
+++ b/packages/google-cloud-dialogflow-cx/samples/generated/v3/snippet_metadata.google.cloud.dialogflow.cx.v3.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-cx",
- "version": "3.6.0",
+ "version": "3.7.0",
"language": "TYPESCRIPT",
"apis": [
{
@@ -238,7 +238,7 @@
"segments": [
{
"start": 25,
- "end": 78,
+ "end": 82,
"type": "FULL"
}
],
@@ -262,6 +262,10 @@
{
"name": "environment",
"type": "TYPE_STRING"
+ },
+ {
+ "name": "include_bigquery_export_settings",
+ "type": "TYPE_BOOL"
}
],
"resultType": ".google.longrunning.Operation",
diff --git a/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/agents.export_agent.js b/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/agents.export_agent.js
index 96626d3ea91..5e706d87060 100644
--- a/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/agents.export_agent.js
+++ b/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/agents.export_agent.js
@@ -56,6 +56,10 @@ function main(name) {
* ID>/environments/`.
*/
// const environment = 'abc123'
+ /**
+ * Optional. Whether to include BigQuery Export setting.
+ */
+ // const includeBigqueryExportSettings = true
// Imports the Cx library
const {AgentsClient} = require('@google-cloud/dialogflow-cx').v3beta1;
diff --git a/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/snippet_metadata.google.cloud.dialogflow.cx.v3beta1.json b/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/snippet_metadata.google.cloud.dialogflow.cx.v3beta1.json
index 59bca0f066f..e7ebb50905b 100644
--- a/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/snippet_metadata.google.cloud.dialogflow.cx.v3beta1.json
+++ b/packages/google-cloud-dialogflow-cx/samples/generated/v3beta1/snippet_metadata.google.cloud.dialogflow.cx.v3beta1.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-cx",
- "version": "3.6.0",
+ "version": "3.7.0",
"language": "TYPESCRIPT",
"apis": [
{
@@ -238,7 +238,7 @@
"segments": [
{
"start": 25,
- "end": 78,
+ "end": 82,
"type": "FULL"
}
],
@@ -262,6 +262,10 @@
{
"name": "environment",
"type": "TYPE_STRING"
+ },
+ {
+ "name": "include_bigquery_export_settings",
+ "type": "TYPE_BOOL"
}
],
"resultType": ".google.longrunning.Operation",
diff --git a/packages/google-cloud-dialogflow-cx/samples/package.json b/packages/google-cloud-dialogflow-cx/samples/package.json
index ad449dca391..c8c29cf4095 100644
--- a/packages/google-cloud-dialogflow-cx/samples/package.json
+++ b/packages/google-cloud-dialogflow-cx/samples/package.json
@@ -13,7 +13,7 @@
"test": "c8 mocha --timeout 600000 test/*.js"
},
"dependencies": {
- "@google-cloud/dialogflow-cx": "^3.6.0",
+ "@google-cloud/dialogflow-cx": "^3.7.0",
"uuid": "^9.0.0"
},
"devDependencies": {
diff --git a/packages/google-cloud-dialogflow-cx/src/v3/agents_client.ts b/packages/google-cloud-dialogflow-cx/src/v3/agents_client.ts
index ac4e5a35fe2..de122aa02be 100644
--- a/packages/google-cloud-dialogflow-cx/src/v3/agents_client.ts
+++ b/packages/google-cloud-dialogflow-cx/src/v3/agents_client.ts
@@ -1100,6 +1100,8 @@ export class AgentsClient {
* Optional. Environment name. If not set, draft environment is assumed.
* Format: `projects//locations//agents//environments/`.
+ * @param {boolean} [request.includeBigqueryExportSettings]
+ * Optional. Whether to include BigQuery Export setting.
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
diff --git a/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts b/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts
index a8fc6334020..1b3f265ded6 100644
--- a/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts
+++ b/packages/google-cloud-dialogflow-cx/src/v3beta1/agents_client.ts
@@ -1114,6 +1114,8 @@ export class AgentsClient {
* Optional. Environment name. If not set, draft environment is assumed.
* Format: `projects//locations//agents//environments/`.
+ * @param {boolean} [request.includeBigqueryExportSettings]
+ * Optional. Whether to include BigQuery Export setting.
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
diff --git a/packages/google-cloud-dialogflow/CHANGELOG.md b/packages/google-cloud-dialogflow/CHANGELOG.md
index 9733a3331b5..4a84ca49999 100644
--- a/packages/google-cloud-dialogflow/CHANGELOG.md
+++ b/packages/google-cloud-dialogflow/CHANGELOG.md
@@ -4,6 +4,18 @@
[1]: https://www.npmjs.com/package/dialogflow?activeTab=versions
+## [5.9.0](https://github.com/googleapis/google-cloud-node/compare/dialogflow-v5.8.0...dialogflow-v5.9.0) (2023-06-28)
+
+
+### Features
+
+* [dialogflow] added dialogflow_assist_answer ([#4364](https://github.com/googleapis/google-cloud-node/issues/4364)) ([2339f4d](https://github.com/googleapis/google-cloud-node/commit/2339f4d2c62fda48c745f4dde3f071fa4346fc9b))
+
+
+### Bug Fixes
+
+* **deps:** Update dependency yargs to v17 ([#4351](https://github.com/googleapis/google-cloud-node/issues/4351)) ([4fb5285](https://github.com/googleapis/google-cloud-node/commit/4fb528559c204cee33329c4e55021aa1fd0e4974))
+
## [5.8.0](https://github.com/googleapis/google-cloud-node/compare/dialogflow-v5.7.1...dialogflow-v5.8.0) (2023-05-20)
diff --git a/packages/google-cloud-dialogflow/package.json b/packages/google-cloud-dialogflow/package.json
index 5f5aedc5fd7..afe8be9ea70 100644
--- a/packages/google-cloud-dialogflow/package.json
+++ b/packages/google-cloud-dialogflow/package.json
@@ -1,7 +1,7 @@
{
"name": "@google-cloud/dialogflow",
"description": "Dialogflow API client for Node.js",
- "version": "5.8.0",
+ "version": "5.9.0",
"license": "Apache-2.0",
"author": "Google LLC",
"engines": {
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/answer_record.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/answer_record.proto
index 8f2587caa95..aa3c271ddf6 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/answer_record.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/answer_record.proto
@@ -208,8 +208,8 @@ message AnswerFeedback {
// Indicates whether the answer/item was clicked by the human agent
// or not. Default to false.
- // For knowledge search, the answer record is considered to be clicked if the
- // answer was copied or any URI was clicked.
+ // For knowledge search and knowledge assist, the answer record is considered
+ // to be clicked if the answer was copied or any URI was clicked.
bool clicked = 3;
// Time when the answer/item was clicked.
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation.proto
index 625fec3a6c1..7863d4267c1 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation.proto
@@ -434,7 +434,7 @@ message SuggestConversationSummaryRequest {
// suggestion. By default 500 and at most 1000.
int32 context_size = 4;
- // Parameters for a human assist query.
+ // Parameters for a human assist query. Only used for POC/demo purpose.
AssistQueryParameters assist_query_params = 5;
}
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation_profile.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation_profile.proto
index 0ab690689e0..79834832dbb 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation_profile.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/conversation_profile.proto
@@ -23,6 +23,7 @@ import "google/api/resource.proto";
import "google/cloud/dialogflow/v2/audio_config.proto";
import "google/cloud/dialogflow/v2/participant.proto";
import "google/longrunning/operations.proto";
+import "google/protobuf/duration.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
@@ -381,6 +382,13 @@ message AutomatedAgentConfig {
type: "dialogflow.googleapis.com/Agent"
}
];
+
+ // Optional. Sets Dialogflow CX session life time.
+ // By default, a Dialogflow CX session remains active and its data is stored
+ // for 30 minutes after the last request is sent for the session. This value
+ // should be no longer than 1 day.
+ google.protobuf.Duration session_ttl = 3
+ [(google.api.field_behavior) = OPTIONAL];
}
// Defines the Human Agent Assist to connect to a conversation.
@@ -479,7 +487,7 @@ message HumanAgentAssistantConfig {
// Supported feature: DIALOGFLOW_ASSIST.
message DialogflowQuerySource {
// Required. The name of a Dialogflow virtual agent used for end user side
- // intent detection and suggestion. Format: `projects//locations//agent`. When multiple agents are allowed in
// the same Dialogflow project.
string agent = 1 [
@@ -540,7 +548,8 @@ message HumanAgentAssistantConfig {
// If this field is not set, it defaults to 0.0, which means that all
// suggestions are returned.
//
- // Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE.
+ // Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE,
+ // KNOWLEDGE_SEARCH, KNOWLEDGE_ASSIST, ENTITY_EXTRACTION.
float confidence_threshold = 5;
// Determines how recent conversation context is filtered when generating
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/document.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/document.proto
index de532fc4ef2..1c4597aec61 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/document.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2/document.proto
@@ -370,7 +370,7 @@ message Document {
//
// If a reload fails with internal errors, the system will try to reload the
// document on the next day.
- // If a reload fails with non-retriable errors (e.g. PERMISION_DENIED), the
+ // If a reload fails with non-retriable errors (e.g. PERMISSION_DENIED), the
// system will not try to reload the document anymore. You need to manually
// reload the document successfully by calling `ReloadDocument` and clear the
// errors.
@@ -500,13 +500,13 @@ message ImportDocumentsRequest {
// Dialogflow supports up to 350 documents in each request. If you try to
// import more, Dialogflow will return an error.
oneof source {
- // The Google Cloud Storage location for the documents.
+ // Optional. The Google Cloud Storage location for the documents.
// The path can include a wildcard.
//
// These URIs may have the forms
// `gs:///`.
// `gs:////*.`.
- GcsSources gcs_source = 2;
+ GcsSources gcs_source = 2 [(google.api.field_behavior) = OPTIONAL];
}
// Required. Document template used for importing all the documents.
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/answer_record.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/answer_record.proto
index f14e61c69cb..b5f3cd9b715 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/answer_record.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/answer_record.proto
@@ -144,6 +144,10 @@ message AgentAssistantRecord {
// Output only. The FAQ answer.
FaqAnswer faq_answer = 6 [(google.api.field_behavior) = OUTPUT_ONLY];
+
+ // Output only. The Dialogflow assist answer.
+ DialogflowAssistAnswer dialogflow_assist_answer = 7
+ [(google.api.field_behavior) = OUTPUT_ONLY];
}
}
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation.proto
index 8627b6ae72c..05edaf62549 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation.proto
@@ -408,7 +408,7 @@ message BatchCreateMessagesRequest {
}
];
- // Required. A maximum of 1000 Messages can be created in a batch.
+ // Required. A maximum of 300 messages can be created in a batch.
// [CreateMessageRequest.message.send_time][] is required. All created
// messages will have identical
// [Message.create_time][google.cloud.dialogflow.v2beta1.Message.create_time].
@@ -494,7 +494,7 @@ message SuggestConversationSummaryRequest {
// suggestion. By default 500 and at most 1000.
int32 context_size = 4;
- // Parameters for a human assist query.
+ // Parameters for a human assist query. Only used for POC/demo purpose.
AssistQueryParameters assist_query_params = 5;
}
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation_profile.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation_profile.proto
index 9015a17a8bd..6d38b89ba93 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation_profile.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/conversation_profile.proto
@@ -23,6 +23,7 @@ import "google/api/resource.proto";
import "google/cloud/dialogflow/v2beta1/audio_config.proto";
import "google/cloud/dialogflow/v2beta1/participant.proto";
import "google/longrunning/operations.proto";
+import "google/protobuf/duration.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
@@ -294,6 +295,13 @@ message AutomatedAgentConfig {
type: "dialogflow.googleapis.com/Agent"
}
];
+
+ // Optional. Sets Dialogflow CX session life time.
+ // By default, a Dialogflow CX session remains active and its data is stored
+ // for 30 minutes after the last request is sent for the session. This value
+ // should be no longer than 1 day.
+ google.protobuf.Duration session_ttl = 3
+ [(google.api.field_behavior) = OPTIONAL];
}
// Defines the Human Agent Assistant to connect to a conversation.
@@ -392,8 +400,22 @@ message HumanAgentAssistantConfig {
//
// Supported feature: DIALOGFLOW_ASSIST.
message DialogflowQuerySource {
+ // The configuration used for human agent side Dialogflow assist
+ // suggestion.
+ message HumanAgentSideConfig {
+ // Optional. The name of a dialogflow virtual agent used for intent
+ // detection and suggestion triggered by human agent.
+ // Format: `projects//locations//agent`.
+ string agent = 1 [
+ (google.api.field_behavior) = OPTIONAL,
+ (google.api.resource_reference) = {
+ type: "dialogflow.googleapis.com/Agent"
+ }
+ ];
+ }
+
// Required. The name of a dialogflow virtual agent used for end user side
- // intent detection and suggestion. Format: `projects//locations//agent`. When multiple agents are allowed in
// the same Dialogflow project.
string agent = 1 [
@@ -402,6 +424,9 @@ message HumanAgentAssistantConfig {
type: "dialogflow.googleapis.com/Agent"
}
];
+
+ // The Dialogflow assist configuration for human agent.
+ HumanAgentSideConfig human_agent_side_config = 3;
}
// Settings that determine how to filter recent conversation context when
@@ -454,7 +479,8 @@ message HumanAgentAssistantConfig {
// If this field is not set, it is default to 0.0, which means that all
// suggestions are returned.
//
- // Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE.
+ // Supported features: ARTICLE_SUGGESTION, FAQ, SMART_REPLY, SMART_COMPOSE,
+ // KNOWLEDGE_SEARCH, KNOWLEDGE_ASSIST, ENTITY_EXTRACTION.
float confidence_threshold = 5;
// Determines how recent conversation context is filtered when generating
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/document.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/document.proto
index 73cf618e61a..2b55a834409 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/document.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/document.proto
@@ -508,13 +508,13 @@ message ImportDocumentsRequest {
// Dialogflow supports up to 350 documents in each request. If you try to
// import more, Dialogflow will return an error.
oneof source {
- // The Google Cloud Storage location for the documents.
+ // Optional. The Google Cloud Storage location for the documents.
// The path can include a wildcard.
//
// These URIs may have the forms
// `gs:///`.
// `gs:////*.`.
- GcsSources gcs_source = 2;
+ GcsSources gcs_source = 2 [(google.api.field_behavior) = OPTIONAL];
}
// Required. Document template used for importing all the documents.
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/environment.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/environment.proto
index a46c1c478b1..1d4809f0142 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/environment.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/environment.proto
@@ -168,9 +168,9 @@ message Environment {
// Output only. The unique identifier of this agent environment.
// Supported formats:
- // - `projects//agent/environments/`
- // - `projects//locations//agent/environments/`
+ // - `projects//agent/environments/`
+ // - `projects//locations//agent/environments/`
string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
// Optional. The developer-provided description for this environment.
@@ -181,7 +181,7 @@ message Environment {
// Supported formats:
// - `projects//agent/versions/`
// - `projects//locations//agent/versions/`
+ // ID>`
string agent_version = 3 [
(google.api.field_behavior) = OPTIONAL,
(google.api.resource_reference) = {
@@ -235,8 +235,8 @@ message TextToSpeechSettings {
message ListEnvironmentsRequest {
// Required. The agent to list all environments from.
// Format:
- // - `projects//agent`
- // - `projects//locations//agent`
+ // - `projects//agent`
+ // - `projects//locations//agent`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
@@ -269,8 +269,8 @@ message ListEnvironmentsResponse {
message GetEnvironmentRequest {
// Required. The name of the environment.
// Supported formats:
- // - `projects//agent/environments/`
- // - `projects//locations//agent/environments/`
+ // - `projects//locations//agent/environments/`
string name = 1 [
(google.api.field_behavior) = REQUIRED,
@@ -285,8 +285,8 @@ message GetEnvironmentRequest {
message CreateEnvironmentRequest {
// Required. The agent to create an environment for.
// Supported formats:
- // - `projects//agent`
- // - `projects//locations//agent`
+ // - `projects//agent`
+ // - `projects//locations//agent`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
@@ -324,8 +324,8 @@ message UpdateEnvironmentRequest {
message DeleteEnvironmentRequest {
// Required. The name of the environment to delete.
// / Format:
- // - `projects//agent/environments/`
- // - `projects//locations//agent/environments/`
+ // - `projects//locations//agent/environments/`
string name = 1 [
(google.api.field_behavior) = REQUIRED,
@@ -340,8 +340,8 @@ message DeleteEnvironmentRequest {
message GetEnvironmentHistoryRequest {
// Required. The name of the environment to retrieve history for.
// Supported formats:
- // - `projects//agent/environments/`
- // - `projects//locations//agent/environments/`
+ // - `projects//locations//agent/environments/`
string parent = 1 [
(google.api.field_behavior) = REQUIRED,
@@ -375,8 +375,8 @@ message EnvironmentHistory {
// Output only. The name of the environment this history is for.
// Supported formats:
- // - `projects//agent/environments/`
- // - `projects//locations//agent/environments/`
+ // - `projects//locations//agent/environments/`
string parent = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
diff --git a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/participant.proto b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/participant.proto
index 59786b579d9..93cfe6ea1d2 100644
--- a/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/participant.proto
+++ b/packages/google-cloud-dialogflow/protos/google/cloud/dialogflow/v2beta1/participant.proto
@@ -286,12 +286,13 @@ message Participant {
// Dialogflow will update
// [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2beta1.Participant.obfuscated_external_user_id].
//
- // Dialogflow uses this user id for following purposes:
- // 1) Billing and measurement. If user with the same
- // obfuscated_external_user_id is created in a later conversation, dialogflow
- // will know it's the same user. 2) Agent assist suggestion personalization.
- // For example, Dialogflow can use it to provide personalized smart reply
- // suggestions for this user.
+ // Dialogflow uses this user id for billing and measurement. If a user with
+ // the same obfuscated_external_user_id is created in a later conversation,
+ // Dialogflow will know it's the same user.
+ //
+ // Dialogflow also uses this user id for Agent Assist suggestion
+ // personalization. For example, Dialogflow can use it to provide personalized
+ // smart reply suggestions for this user.
//
// Note:
//
@@ -538,6 +539,65 @@ message AutomatedAgentReply {
string cx_current_page = 11;
}
+// Represents the selection of a suggestion.
+message SuggestionInput {
+ // Required. The ID of a suggestion selected by the human agent.
+ // The suggestion(s) were generated in a previous call to
+ // request Dialogflow assist.
+ // The format is:
+ // `projects//locations//answerRecords/` where is an alphanumeric string.
+ string answer_record = 1;
+
+ // Optional. If the customer edited the suggestion before using it, include
+ // the revised text here.
+ TextInput text_override = 2;
+
+ // In Dialogflow assist for v3, the user can submit a form by sending
+ // a [SuggestionInput][google.cloud.dialogflow.v2beta1.SuggestionInput]. The
+ // form is uniquely determined by the
+ // [answer_record][google.cloud.dialogflow.v2beta1.SuggestionInput.answer_record]
+ // field, which identifies a v3
+ // [QueryResult][google.cloud.dialogflow.v3alpha1.QueryResult] containing the
+ // current [page][google.cloud.dialogflow.v3alpha1.Page]. The form parameters
+ // are specified via the
+ // [parameters][google.cloud.dialogflow.v2beta1.SuggestionInput.parameters]
+ // field.
+ //
+ // Depending on your protocol or client library language, this is a
+ // map, associative array, symbol table, dictionary, or JSON object
+ // composed of a collection of (MapKey, MapValue) pairs:
+ //
+ // - MapKey type: string
+ // - MapKey value: parameter name
+ // - MapValue type:
+ // - If parameter's entity type is a composite entity: map
+ // - Else: depending on parameter value type, could be one of string,
+ // number, boolean, null, list or map
+ // - MapValue value:
+ // - If parameter's entity type is a composite entity:
+ // map from composite entity property names to property values
+ // - Else: parameter value
+ google.protobuf.Struct parameters = 4;
+
+ // The intent to be triggered on V3 agent.
+ IntentInput intent_input = 6;
+}
+
+// Represents the intent to trigger programmatically rather than as a result of
+// natural language processing. The intent input is only used for V3 agent.
+message IntentInput {
+ // Required. The unique identifier of the intent in V3 agent.
+ // Format: `projects//locations//locations//agents//intents/`.
+ string intent = 1 [(google.api.field_behavior) = REQUIRED];
+
+ // Required. The language of this conversational query. See [Language
+ // Support](https://cloud.google.com/dialogflow/docs/reference/language)
+ // for a list of the currently supported language codes.
+ string language_code = 3 [(google.api.field_behavior) = REQUIRED];
+}
+
// The type of Human Agent Assistant API suggestion to perform, and the maximum
// number of results to return for that type. Multiple `Feature` objects can
// be specified in the `features` list.
@@ -556,6 +616,10 @@ message SuggestionFeature {
// Run smart reply model for chat.
SMART_REPLY = 3;
+ // Run Dialogflow assist model for chat, which will return automated agent
+ // response as suggestion.
+ DIALOGFLOW_ASSIST = 4;
+
// Run conversation summarization model for chat.
CONVERSATION_SUMMARIZATION = 8;
}
@@ -609,6 +673,9 @@ message AnalyzeContentRequest {
// An input event to send to Dialogflow.
EventInput event_input = 8;
+
+ // An input representing the selection of a suggestion.
+ SuggestionInput suggestion_input = 12;
}
// Speech synthesis configuration.
@@ -1054,6 +1121,42 @@ message SmartReplyAnswer {
}];
}
+// Represents an intent suggestion.
+message IntentSuggestion {
+ // The display name of the intent.
+ string display_name = 1;
+
+ // The name of the intent.
+ oneof intent {
+ // The unique identifier of this
+ // [intent][google.cloud.dialogflow.v2beta1.Intent]. Format:
+ // `projects//locations//agent/intents/`.
+ string intent_v2 = 2;
+ }
+
+ // Human readable description for better understanding an intent like its
+ // scope, content, result etc. Maximum character limit: 140 characters.
+ string description = 5;
+}
+
+// Represents a Dialogflow assist answer.
+message DialogflowAssistAnswer {
+ // Result from DetectIntent for one matched intent.
+ oneof result {
+ // Result from v2 agent.
+ QueryResult query_result = 1;
+
+ // An intent suggestion generated from conversation.
+ IntentSuggestion intent_suggestion = 5;
+ }
+
+ // The name of answer record, in the format of
+ // "projects//locations//answerRecords/"
+ string answer_record = 2;
+}
+
// One response of different type of suggestion response which is used in
// the response of
// [Participants.AnalyzeContent][google.cloud.dialogflow.v2beta1.Participants.AnalyzeContent]
@@ -1075,6 +1178,12 @@ message SuggestionResult {
// SuggestSmartRepliesResponse if request is for SMART_REPLY.
SuggestSmartRepliesResponse suggest_smart_replies_response = 4;
+
+ // SuggestDialogflowAssistsResponse if request is for DIALOGFLOW_ASSIST.
+ SuggestDialogflowAssistsResponse suggest_dialogflow_assists_response = 5;
+
+ // SuggestDialogflowAssistsResponse if request is for ENTITY_EXTRACTION.
+ SuggestDialogflowAssistsResponse suggest_entity_extraction_response = 7;
}
}
@@ -1252,6 +1361,28 @@ message SuggestSmartRepliesResponse {
int32 context_size = 3;
}
+// The response message for
+// [Participants.SuggestDialogflowAssists][google.cloud.dialogflow.v2beta1.Participants.SuggestDialogflowAssists].
+message SuggestDialogflowAssistsResponse {
+ // Output only. Multiple reply options provided by Dialogflow assist
+ // service. The order is based on the rank of the model prediction.
+ repeated DialogflowAssistAnswer dialogflow_assist_answers = 1;
+
+ // The name of the latest conversation message used to suggest answer.
+ //
+ // Format: `projects//locations//conversations//messages/`.
+ string latest_message = 2;
+
+ // Number of messages prior to and including
+ // [latest_message][google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.latest_message]
+ // to compile the suggestion. It may be smaller than the
+ // [SuggestDialogflowAssistsRequest.context_size][google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsRequest.context_size]
+ // field in the request if there aren't that many messages in the
+ // conversation.
+ int32 context_size = 3;
+}
+
// Represents a suggestion for a human agent.
message Suggestion {
option deprecated = true;
@@ -1433,6 +1564,7 @@ message ResponseMessage {
// is up to you and your handoff procedures.
//
// You may set this, for example:
+ //
// * In the entry fulfillment of a CX Page if entering the page indicates
// something went extremely wrong in the conversation.
// * In a webhook response when you determine that the customer issue can only
diff --git a/packages/google-cloud-dialogflow/protos/protos.d.ts b/packages/google-cloud-dialogflow/protos/protos.d.ts
index 46b85b923b6..b5524418387 100644
--- a/packages/google-cloud-dialogflow/protos/protos.d.ts
+++ b/packages/google-cloud-dialogflow/protos/protos.d.ts
@@ -20789,6 +20789,9 @@ export namespace google {
/** AutomatedAgentConfig agent */
agent?: (string|null);
+
+ /** AutomatedAgentConfig sessionTtl */
+ sessionTtl?: (google.protobuf.IDuration|null);
}
/** Represents an AutomatedAgentConfig. */
@@ -20803,6 +20806,9 @@ export namespace google {
/** AutomatedAgentConfig agent. */
public agent: string;
+ /** AutomatedAgentConfig sessionTtl. */
+ public sessionTtl?: (google.protobuf.IDuration|null);
+
/**
* Creates a new AutomatedAgentConfig instance using the specified properties.
* @param [properties] Properties to set
@@ -36190,6 +36196,9 @@ export namespace google {
/** AgentAssistantRecord faqAnswer */
faqAnswer?: (google.cloud.dialogflow.v2beta1.IFaqAnswer|null);
+
+ /** AgentAssistantRecord dialogflowAssistAnswer */
+ dialogflowAssistAnswer?: (google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer|null);
}
/** Represents an AgentAssistantRecord. */
@@ -36207,8 +36216,11 @@ export namespace google {
/** AgentAssistantRecord faqAnswer. */
public faqAnswer?: (google.cloud.dialogflow.v2beta1.IFaqAnswer|null);
+ /** AgentAssistantRecord dialogflowAssistAnswer. */
+ public dialogflowAssistAnswer?: (google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer|null);
+
/** AgentAssistantRecord answer. */
- public answer?: ("articleSuggestionAnswer"|"faqAnswer");
+ public answer?: ("articleSuggestionAnswer"|"faqAnswer"|"dialogflowAssistAnswer");
/**
* Creates a new AgentAssistantRecord instance using the specified properties.
@@ -38509,6 +38521,224 @@ export namespace google {
}
}
+ /** Properties of a SuggestionInput. */
+ interface ISuggestionInput {
+
+ /** SuggestionInput answerRecord */
+ answerRecord?: (string|null);
+
+ /** SuggestionInput textOverride */
+ textOverride?: (google.cloud.dialogflow.v2beta1.ITextInput|null);
+
+ /** SuggestionInput parameters */
+ parameters?: (google.protobuf.IStruct|null);
+
+ /** SuggestionInput intentInput */
+ intentInput?: (google.cloud.dialogflow.v2beta1.IIntentInput|null);
+ }
+
+ /** Represents a SuggestionInput. */
+ class SuggestionInput implements ISuggestionInput {
+
+ /**
+ * Constructs a new SuggestionInput.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.dialogflow.v2beta1.ISuggestionInput);
+
+ /** SuggestionInput answerRecord. */
+ public answerRecord: string;
+
+ /** SuggestionInput textOverride. */
+ public textOverride?: (google.cloud.dialogflow.v2beta1.ITextInput|null);
+
+ /** SuggestionInput parameters. */
+ public parameters?: (google.protobuf.IStruct|null);
+
+ /** SuggestionInput intentInput. */
+ public intentInput?: (google.cloud.dialogflow.v2beta1.IIntentInput|null);
+
+ /**
+ * Creates a new SuggestionInput instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns SuggestionInput instance
+ */
+ public static create(properties?: google.cloud.dialogflow.v2beta1.ISuggestionInput): google.cloud.dialogflow.v2beta1.SuggestionInput;
+
+ /**
+ * Encodes the specified SuggestionInput message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestionInput.verify|verify} messages.
+ * @param message SuggestionInput message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.dialogflow.v2beta1.ISuggestionInput, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified SuggestionInput message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestionInput.verify|verify} messages.
+ * @param message SuggestionInput message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.dialogflow.v2beta1.ISuggestionInput, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a SuggestionInput message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns SuggestionInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.dialogflow.v2beta1.SuggestionInput;
+
+ /**
+ * Decodes a SuggestionInput message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns SuggestionInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.dialogflow.v2beta1.SuggestionInput;
+
+ /**
+ * Verifies a SuggestionInput message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a SuggestionInput message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns SuggestionInput
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.dialogflow.v2beta1.SuggestionInput;
+
+ /**
+ * Creates a plain object from a SuggestionInput message. Also converts values to other types if specified.
+ * @param message SuggestionInput
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.dialogflow.v2beta1.SuggestionInput, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this SuggestionInput to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for SuggestionInput
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of an IntentInput. */
+ interface IIntentInput {
+
+ /** IntentInput intent */
+ intent?: (string|null);
+
+ /** IntentInput languageCode */
+ languageCode?: (string|null);
+ }
+
+ /** Represents an IntentInput. */
+ class IntentInput implements IIntentInput {
+
+ /**
+ * Constructs a new IntentInput.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.dialogflow.v2beta1.IIntentInput);
+
+ /** IntentInput intent. */
+ public intent: string;
+
+ /** IntentInput languageCode. */
+ public languageCode: string;
+
+ /**
+ * Creates a new IntentInput instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns IntentInput instance
+ */
+ public static create(properties?: google.cloud.dialogflow.v2beta1.IIntentInput): google.cloud.dialogflow.v2beta1.IntentInput;
+
+ /**
+ * Encodes the specified IntentInput message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentInput.verify|verify} messages.
+ * @param message IntentInput message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.dialogflow.v2beta1.IIntentInput, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified IntentInput message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentInput.verify|verify} messages.
+ * @param message IntentInput message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.dialogflow.v2beta1.IIntentInput, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes an IntentInput message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns IntentInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.dialogflow.v2beta1.IntentInput;
+
+ /**
+ * Decodes an IntentInput message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns IntentInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.dialogflow.v2beta1.IntentInput;
+
+ /**
+ * Verifies an IntentInput message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates an IntentInput message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns IntentInput
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.dialogflow.v2beta1.IntentInput;
+
+ /**
+ * Creates a plain object from an IntentInput message. Also converts values to other types if specified.
+ * @param message IntentInput
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.dialogflow.v2beta1.IntentInput, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this IntentInput to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for IntentInput
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a SuggestionFeature. */
interface ISuggestionFeature {
@@ -38614,6 +38844,7 @@ export namespace google {
ARTICLE_SUGGESTION = 1,
FAQ = 2,
SMART_REPLY = 3,
+ DIALOGFLOW_ASSIST = 4,
CONVERSATION_SUMMARIZATION = 8
}
}
@@ -38730,6 +38961,9 @@ export namespace google {
/** AnalyzeContentRequest eventInput */
eventInput?: (google.cloud.dialogflow.v2beta1.IEventInput|null);
+ /** AnalyzeContentRequest suggestionInput */
+ suggestionInput?: (google.cloud.dialogflow.v2beta1.ISuggestionInput|null);
+
/** AnalyzeContentRequest replyAudioConfig */
replyAudioConfig?: (google.cloud.dialogflow.v2beta1.IOutputAudioConfig|null);
@@ -38773,6 +39007,9 @@ export namespace google {
/** AnalyzeContentRequest eventInput. */
public eventInput?: (google.cloud.dialogflow.v2beta1.IEventInput|null);
+ /** AnalyzeContentRequest suggestionInput. */
+ public suggestionInput?: (google.cloud.dialogflow.v2beta1.ISuggestionInput|null);
+
/** AnalyzeContentRequest replyAudioConfig. */
public replyAudioConfig?: (google.cloud.dialogflow.v2beta1.IOutputAudioConfig|null);
@@ -38795,7 +39032,7 @@ export namespace google {
public requestId: string;
/** AnalyzeContentRequest input. */
- public input?: ("textInput"|"audioInput"|"eventInput");
+ public input?: ("textInput"|"audioInput"|"eventInput"|"suggestionInput");
/**
* Creates a new AnalyzeContentRequest instance using the specified properties.
@@ -40091,6 +40328,230 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ /** Properties of an IntentSuggestion. */
+ interface IIntentSuggestion {
+
+ /** IntentSuggestion displayName */
+ displayName?: (string|null);
+
+ /** IntentSuggestion intentV2 */
+ intentV2?: (string|null);
+
+ /** IntentSuggestion description */
+ description?: (string|null);
+ }
+
+ /** Represents an IntentSuggestion. */
+ class IntentSuggestion implements IIntentSuggestion {
+
+ /**
+ * Constructs a new IntentSuggestion.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.dialogflow.v2beta1.IIntentSuggestion);
+
+ /** IntentSuggestion displayName. */
+ public displayName: string;
+
+ /** IntentSuggestion intentV2. */
+ public intentV2?: (string|null);
+
+ /** IntentSuggestion description. */
+ public description: string;
+
+ /** IntentSuggestion intent. */
+ public intent?: "intentV2";
+
+ /**
+ * Creates a new IntentSuggestion instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns IntentSuggestion instance
+ */
+ public static create(properties?: google.cloud.dialogflow.v2beta1.IIntentSuggestion): google.cloud.dialogflow.v2beta1.IntentSuggestion;
+
+ /**
+ * Encodes the specified IntentSuggestion message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentSuggestion.verify|verify} messages.
+ * @param message IntentSuggestion message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.dialogflow.v2beta1.IIntentSuggestion, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified IntentSuggestion message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentSuggestion.verify|verify} messages.
+ * @param message IntentSuggestion message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.dialogflow.v2beta1.IIntentSuggestion, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes an IntentSuggestion message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns IntentSuggestion
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.dialogflow.v2beta1.IntentSuggestion;
+
+ /**
+ * Decodes an IntentSuggestion message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns IntentSuggestion
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.dialogflow.v2beta1.IntentSuggestion;
+
+ /**
+ * Verifies an IntentSuggestion message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates an IntentSuggestion message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns IntentSuggestion
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.dialogflow.v2beta1.IntentSuggestion;
+
+ /**
+ * Creates a plain object from an IntentSuggestion message. Also converts values to other types if specified.
+ * @param message IntentSuggestion
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.dialogflow.v2beta1.IntentSuggestion, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this IntentSuggestion to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for IntentSuggestion
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
+ /** Properties of a DialogflowAssistAnswer. */
+ interface IDialogflowAssistAnswer {
+
+ /** DialogflowAssistAnswer queryResult */
+ queryResult?: (google.cloud.dialogflow.v2beta1.IQueryResult|null);
+
+ /** DialogflowAssistAnswer intentSuggestion */
+ intentSuggestion?: (google.cloud.dialogflow.v2beta1.IIntentSuggestion|null);
+
+ /** DialogflowAssistAnswer answerRecord */
+ answerRecord?: (string|null);
+ }
+
+ /** Represents a DialogflowAssistAnswer. */
+ class DialogflowAssistAnswer implements IDialogflowAssistAnswer {
+
+ /**
+ * Constructs a new DialogflowAssistAnswer.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer);
+
+ /** DialogflowAssistAnswer queryResult. */
+ public queryResult?: (google.cloud.dialogflow.v2beta1.IQueryResult|null);
+
+ /** DialogflowAssistAnswer intentSuggestion. */
+ public intentSuggestion?: (google.cloud.dialogflow.v2beta1.IIntentSuggestion|null);
+
+ /** DialogflowAssistAnswer answerRecord. */
+ public answerRecord: string;
+
+ /** DialogflowAssistAnswer result. */
+ public result?: ("queryResult"|"intentSuggestion");
+
+ /**
+ * Creates a new DialogflowAssistAnswer instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns DialogflowAssistAnswer instance
+ */
+ public static create(properties?: google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer): google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer;
+
+ /**
+ * Encodes the specified DialogflowAssistAnswer message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.verify|verify} messages.
+ * @param message DialogflowAssistAnswer message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified DialogflowAssistAnswer message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.verify|verify} messages.
+ * @param message DialogflowAssistAnswer message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a DialogflowAssistAnswer message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns DialogflowAssistAnswer
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer;
+
+ /**
+ * Decodes a DialogflowAssistAnswer message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns DialogflowAssistAnswer
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer;
+
+ /**
+ * Verifies a DialogflowAssistAnswer message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a DialogflowAssistAnswer message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns DialogflowAssistAnswer
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer;
+
+ /**
+ * Creates a plain object from a DialogflowAssistAnswer message. Also converts values to other types if specified.
+ * @param message DialogflowAssistAnswer
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this DialogflowAssistAnswer to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for DialogflowAssistAnswer
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a SuggestionResult. */
interface ISuggestionResult {
@@ -40105,6 +40566,12 @@ export namespace google {
/** SuggestionResult suggestSmartRepliesResponse */
suggestSmartRepliesResponse?: (google.cloud.dialogflow.v2beta1.ISuggestSmartRepliesResponse|null);
+
+ /** SuggestionResult suggestDialogflowAssistsResponse */
+ suggestDialogflowAssistsResponse?: (google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null);
+
+ /** SuggestionResult suggestEntityExtractionResponse */
+ suggestEntityExtractionResponse?: (google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null);
}
/** Represents a SuggestionResult. */
@@ -40128,8 +40595,14 @@ export namespace google {
/** SuggestionResult suggestSmartRepliesResponse. */
public suggestSmartRepliesResponse?: (google.cloud.dialogflow.v2beta1.ISuggestSmartRepliesResponse|null);
+ /** SuggestionResult suggestDialogflowAssistsResponse. */
+ public suggestDialogflowAssistsResponse?: (google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null);
+
+ /** SuggestionResult suggestEntityExtractionResponse. */
+ public suggestEntityExtractionResponse?: (google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null);
+
/** SuggestionResult suggestionResponse. */
- public suggestionResponse?: ("error"|"suggestArticlesResponse"|"suggestFaqAnswersResponse"|"suggestSmartRepliesResponse");
+ public suggestionResponse?: ("error"|"suggestArticlesResponse"|"suggestFaqAnswersResponse"|"suggestSmartRepliesResponse"|"suggestDialogflowAssistsResponse"|"suggestEntityExtractionResponse");
/**
* Creates a new SuggestionResult instance using the specified properties.
@@ -40881,6 +41354,115 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ /** Properties of a SuggestDialogflowAssistsResponse. */
+ interface ISuggestDialogflowAssistsResponse {
+
+ /** SuggestDialogflowAssistsResponse dialogflowAssistAnswers */
+ dialogflowAssistAnswers?: (google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer[]|null);
+
+ /** SuggestDialogflowAssistsResponse latestMessage */
+ latestMessage?: (string|null);
+
+ /** SuggestDialogflowAssistsResponse contextSize */
+ contextSize?: (number|null);
+ }
+
+ /** Represents a SuggestDialogflowAssistsResponse. */
+ class SuggestDialogflowAssistsResponse implements ISuggestDialogflowAssistsResponse {
+
+ /**
+ * Constructs a new SuggestDialogflowAssistsResponse.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse);
+
+ /** SuggestDialogflowAssistsResponse dialogflowAssistAnswers. */
+ public dialogflowAssistAnswers: google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer[];
+
+ /** SuggestDialogflowAssistsResponse latestMessage. */
+ public latestMessage: string;
+
+ /** SuggestDialogflowAssistsResponse contextSize. */
+ public contextSize: number;
+
+ /**
+ * Creates a new SuggestDialogflowAssistsResponse instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns SuggestDialogflowAssistsResponse instance
+ */
+ public static create(properties?: google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse): google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse;
+
+ /**
+ * Encodes the specified SuggestDialogflowAssistsResponse message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.verify|verify} messages.
+ * @param message SuggestDialogflowAssistsResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified SuggestDialogflowAssistsResponse message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.verify|verify} messages.
+ * @param message SuggestDialogflowAssistsResponse message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a SuggestDialogflowAssistsResponse message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns SuggestDialogflowAssistsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse;
+
+ /**
+ * Decodes a SuggestDialogflowAssistsResponse message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns SuggestDialogflowAssistsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse;
+
+ /**
+ * Verifies a SuggestDialogflowAssistsResponse message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a SuggestDialogflowAssistsResponse message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns SuggestDialogflowAssistsResponse
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse;
+
+ /**
+ * Creates a plain object from a SuggestDialogflowAssistsResponse message. Also converts values to other types if specified.
+ * @param message SuggestDialogflowAssistsResponse
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this SuggestDialogflowAssistsResponse to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for SuggestDialogflowAssistsResponse
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+
/** Properties of a Suggestion. */
interface ISuggestion {
@@ -58601,6 +59183,9 @@ export namespace google {
/** AutomatedAgentConfig agent */
agent?: (string|null);
+
+ /** AutomatedAgentConfig sessionTtl */
+ sessionTtl?: (google.protobuf.IDuration|null);
}
/** Represents an AutomatedAgentConfig. */
@@ -58615,6 +59200,9 @@ export namespace google {
/** AutomatedAgentConfig agent. */
public agent: string;
+ /** AutomatedAgentConfig sessionTtl. */
+ public sessionTtl?: (google.protobuf.IDuration|null);
+
/**
* Creates a new AutomatedAgentConfig instance using the specified properties.
* @param [properties] Properties to set
@@ -59474,6 +60062,9 @@ export namespace google {
/** DialogflowQuerySource agent */
agent?: (string|null);
+
+ /** DialogflowQuerySource humanAgentSideConfig */
+ humanAgentSideConfig?: (google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig|null);
}
/** Represents a DialogflowQuerySource. */
@@ -59488,6 +60079,9 @@ export namespace google {
/** DialogflowQuerySource agent. */
public agent: string;
+ /** DialogflowQuerySource humanAgentSideConfig. */
+ public humanAgentSideConfig?: (google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig|null);
+
/**
* Creates a new DialogflowQuerySource instance using the specified properties.
* @param [properties] Properties to set
@@ -59566,6 +60160,106 @@ export namespace google {
public static getTypeUrl(typeUrlPrefix?: string): string;
}
+ namespace DialogflowQuerySource {
+
+ /** Properties of a HumanAgentSideConfig. */
+ interface IHumanAgentSideConfig {
+
+ /** HumanAgentSideConfig agent */
+ agent?: (string|null);
+ }
+
+ /** Represents a HumanAgentSideConfig. */
+ class HumanAgentSideConfig implements IHumanAgentSideConfig {
+
+ /**
+ * Constructs a new HumanAgentSideConfig.
+ * @param [properties] Properties to set
+ */
+ constructor(properties?: google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig);
+
+ /** HumanAgentSideConfig agent. */
+ public agent: string;
+
+ /**
+ * Creates a new HumanAgentSideConfig instance using the specified properties.
+ * @param [properties] Properties to set
+ * @returns HumanAgentSideConfig instance
+ */
+ public static create(properties?: google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig): google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig;
+
+ /**
+ * Encodes the specified HumanAgentSideConfig message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.verify|verify} messages.
+ * @param message HumanAgentSideConfig message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encode(message: google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Encodes the specified HumanAgentSideConfig message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.verify|verify} messages.
+ * @param message HumanAgentSideConfig message or plain object to encode
+ * @param [writer] Writer to encode to
+ * @returns Writer
+ */
+ public static encodeDelimited(message: google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig, writer?: $protobuf.Writer): $protobuf.Writer;
+
+ /**
+ * Decodes a HumanAgentSideConfig message from the specified reader or buffer.
+ * @param reader Reader or buffer to decode from
+ * @param [length] Message length if known beforehand
+ * @returns HumanAgentSideConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig;
+
+ /**
+ * Decodes a HumanAgentSideConfig message from the specified reader or buffer, length delimited.
+ * @param reader Reader or buffer to decode from
+ * @returns HumanAgentSideConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig;
+
+ /**
+ * Verifies a HumanAgentSideConfig message.
+ * @param message Plain object to verify
+ * @returns `null` if valid, otherwise the reason why it is not
+ */
+ public static verify(message: { [k: string]: any }): (string|null);
+
+ /**
+ * Creates a HumanAgentSideConfig message from a plain object. Also converts values to their respective internal types.
+ * @param object Plain object
+ * @returns HumanAgentSideConfig
+ */
+ public static fromObject(object: { [k: string]: any }): google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig;
+
+ /**
+ * Creates a plain object from a HumanAgentSideConfig message. Also converts values to other types if specified.
+ * @param message HumanAgentSideConfig
+ * @param [options] Conversion options
+ * @returns Plain object
+ */
+ public static toObject(message: google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig, options?: $protobuf.IConversionOptions): { [k: string]: any };
+
+ /**
+ * Converts this HumanAgentSideConfig to JSON.
+ * @returns JSON object
+ */
+ public toJSON(): { [k: string]: any };
+
+ /**
+ * Gets the default type url for HumanAgentSideConfig
+ * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns The default type url
+ */
+ public static getTypeUrl(typeUrlPrefix?: string): string;
+ }
+ }
+
/** Properties of a ContextFilterSettings. */
interface IContextFilterSettings {
diff --git a/packages/google-cloud-dialogflow/protos/protos.js b/packages/google-cloud-dialogflow/protos/protos.js
index 35a31450be1..00a5187c329 100644
--- a/packages/google-cloud-dialogflow/protos/protos.js
+++ b/packages/google-cloud-dialogflow/protos/protos.js
@@ -51128,6 +51128,7 @@
* @memberof google.cloud.dialogflow.v2
* @interface IAutomatedAgentConfig
* @property {string|null} [agent] AutomatedAgentConfig agent
+ * @property {google.protobuf.IDuration|null} [sessionTtl] AutomatedAgentConfig sessionTtl
*/
/**
@@ -51153,6 +51154,14 @@
*/
AutomatedAgentConfig.prototype.agent = "";
+ /**
+ * AutomatedAgentConfig sessionTtl.
+ * @member {google.protobuf.IDuration|null|undefined} sessionTtl
+ * @memberof google.cloud.dialogflow.v2.AutomatedAgentConfig
+ * @instance
+ */
+ AutomatedAgentConfig.prototype.sessionTtl = null;
+
/**
* Creates a new AutomatedAgentConfig instance using the specified properties.
* @function create
@@ -51179,6 +51188,8 @@
writer = $Writer.create();
if (message.agent != null && Object.hasOwnProperty.call(message, "agent"))
writer.uint32(/* id 1, wireType 2 =*/10).string(message.agent);
+ if (message.sessionTtl != null && Object.hasOwnProperty.call(message, "sessionTtl"))
+ $root.google.protobuf.Duration.encode(message.sessionTtl, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
return writer;
};
@@ -51217,6 +51228,10 @@
message.agent = reader.string();
break;
}
+ case 3: {
+ message.sessionTtl = $root.google.protobuf.Duration.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -51255,6 +51270,11 @@
if (message.agent != null && message.hasOwnProperty("agent"))
if (!$util.isString(message.agent))
return "agent: string expected";
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl")) {
+ var error = $root.google.protobuf.Duration.verify(message.sessionTtl);
+ if (error)
+ return "sessionTtl." + error;
+ }
return null;
};
@@ -51272,6 +51292,11 @@
var message = new $root.google.cloud.dialogflow.v2.AutomatedAgentConfig();
if (object.agent != null)
message.agent = String(object.agent);
+ if (object.sessionTtl != null) {
+ if (typeof object.sessionTtl !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2.AutomatedAgentConfig.sessionTtl: object expected");
+ message.sessionTtl = $root.google.protobuf.Duration.fromObject(object.sessionTtl);
+ }
return message;
};
@@ -51288,10 +51313,14 @@
if (!options)
options = {};
var object = {};
- if (options.defaults)
+ if (options.defaults) {
object.agent = "";
+ object.sessionTtl = null;
+ }
if (message.agent != null && message.hasOwnProperty("agent"))
object.agent = message.agent;
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl"))
+ object.sessionTtl = $root.google.protobuf.Duration.toObject(message.sessionTtl, options);
return object;
};
@@ -87045,6 +87074,7 @@
* @interface IAgentAssistantRecord
* @property {google.cloud.dialogflow.v2beta1.IArticleAnswer|null} [articleSuggestionAnswer] AgentAssistantRecord articleSuggestionAnswer
* @property {google.cloud.dialogflow.v2beta1.IFaqAnswer|null} [faqAnswer] AgentAssistantRecord faqAnswer
+ * @property {google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer|null} [dialogflowAssistAnswer] AgentAssistantRecord dialogflowAssistAnswer
*/
/**
@@ -87078,17 +87108,25 @@
*/
AgentAssistantRecord.prototype.faqAnswer = null;
+ /**
+ * AgentAssistantRecord dialogflowAssistAnswer.
+ * @member {google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer|null|undefined} dialogflowAssistAnswer
+ * @memberof google.cloud.dialogflow.v2beta1.AgentAssistantRecord
+ * @instance
+ */
+ AgentAssistantRecord.prototype.dialogflowAssistAnswer = null;
+
// OneOf field names bound to virtual getters and setters
var $oneOfFields;
/**
* AgentAssistantRecord answer.
- * @member {"articleSuggestionAnswer"|"faqAnswer"|undefined} answer
+ * @member {"articleSuggestionAnswer"|"faqAnswer"|"dialogflowAssistAnswer"|undefined} answer
* @memberof google.cloud.dialogflow.v2beta1.AgentAssistantRecord
* @instance
*/
Object.defineProperty(AgentAssistantRecord.prototype, "answer", {
- get: $util.oneOfGetter($oneOfFields = ["articleSuggestionAnswer", "faqAnswer"]),
+ get: $util.oneOfGetter($oneOfFields = ["articleSuggestionAnswer", "faqAnswer", "dialogflowAssistAnswer"]),
set: $util.oneOfSetter($oneOfFields)
});
@@ -87120,6 +87158,8 @@
$root.google.cloud.dialogflow.v2beta1.ArticleAnswer.encode(message.articleSuggestionAnswer, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim();
if (message.faqAnswer != null && Object.hasOwnProperty.call(message, "faqAnswer"))
$root.google.cloud.dialogflow.v2beta1.FaqAnswer.encode(message.faqAnswer, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim();
+ if (message.dialogflowAssistAnswer != null && Object.hasOwnProperty.call(message, "dialogflowAssistAnswer"))
+ $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.encode(message.dialogflowAssistAnswer, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim();
return writer;
};
@@ -87162,6 +87202,10 @@
message.faqAnswer = $root.google.cloud.dialogflow.v2beta1.FaqAnswer.decode(reader, reader.uint32());
break;
}
+ case 7: {
+ message.dialogflowAssistAnswer = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -87216,6 +87260,16 @@
return "faqAnswer." + error;
}
}
+ if (message.dialogflowAssistAnswer != null && message.hasOwnProperty("dialogflowAssistAnswer")) {
+ if (properties.answer === 1)
+ return "answer: multiple values";
+ properties.answer = 1;
+ {
+ var error = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.verify(message.dialogflowAssistAnswer);
+ if (error)
+ return "dialogflowAssistAnswer." + error;
+ }
+ }
return null;
};
@@ -87241,6 +87295,11 @@
throw TypeError(".google.cloud.dialogflow.v2beta1.AgentAssistantRecord.faqAnswer: object expected");
message.faqAnswer = $root.google.cloud.dialogflow.v2beta1.FaqAnswer.fromObject(object.faqAnswer);
}
+ if (object.dialogflowAssistAnswer != null) {
+ if (typeof object.dialogflowAssistAnswer !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.AgentAssistantRecord.dialogflowAssistAnswer: object expected");
+ message.dialogflowAssistAnswer = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.fromObject(object.dialogflowAssistAnswer);
+ }
return message;
};
@@ -87267,6 +87326,11 @@
if (options.oneofs)
object.answer = "faqAnswer";
}
+ if (message.dialogflowAssistAnswer != null && message.hasOwnProperty("dialogflowAssistAnswer")) {
+ object.dialogflowAssistAnswer = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.toObject(message.dialogflowAssistAnswer, options);
+ if (options.oneofs)
+ object.answer = "dialogflowAssistAnswer";
+ }
return object;
};
@@ -92691,6 +92755,521 @@
return AutomatedAgentReply;
})();
+ v2beta1.SuggestionInput = (function() {
+
+ /**
+ * Properties of a SuggestionInput.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @interface ISuggestionInput
+ * @property {string|null} [answerRecord] SuggestionInput answerRecord
+ * @property {google.cloud.dialogflow.v2beta1.ITextInput|null} [textOverride] SuggestionInput textOverride
+ * @property {google.protobuf.IStruct|null} [parameters] SuggestionInput parameters
+ * @property {google.cloud.dialogflow.v2beta1.IIntentInput|null} [intentInput] SuggestionInput intentInput
+ */
+
+ /**
+ * Constructs a new SuggestionInput.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @classdesc Represents a SuggestionInput.
+ * @implements ISuggestionInput
+ * @constructor
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestionInput=} [properties] Properties to set
+ */
+ function SuggestionInput(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * SuggestionInput answerRecord.
+ * @member {string} answerRecord
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @instance
+ */
+ SuggestionInput.prototype.answerRecord = "";
+
+ /**
+ * SuggestionInput textOverride.
+ * @member {google.cloud.dialogflow.v2beta1.ITextInput|null|undefined} textOverride
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @instance
+ */
+ SuggestionInput.prototype.textOverride = null;
+
+ /**
+ * SuggestionInput parameters.
+ * @member {google.protobuf.IStruct|null|undefined} parameters
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @instance
+ */
+ SuggestionInput.prototype.parameters = null;
+
+ /**
+ * SuggestionInput intentInput.
+ * @member {google.cloud.dialogflow.v2beta1.IIntentInput|null|undefined} intentInput
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @instance
+ */
+ SuggestionInput.prototype.intentInput = null;
+
+ /**
+ * Creates a new SuggestionInput instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestionInput=} [properties] Properties to set
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestionInput} SuggestionInput instance
+ */
+ SuggestionInput.create = function create(properties) {
+ return new SuggestionInput(properties);
+ };
+
+ /**
+ * Encodes the specified SuggestionInput message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestionInput.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestionInput} message SuggestionInput message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ SuggestionInput.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.answerRecord != null && Object.hasOwnProperty.call(message, "answerRecord"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.answerRecord);
+ if (message.textOverride != null && Object.hasOwnProperty.call(message, "textOverride"))
+ $root.google.cloud.dialogflow.v2beta1.TextInput.encode(message.textOverride, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
+ if (message.parameters != null && Object.hasOwnProperty.call(message, "parameters"))
+ $root.google.protobuf.Struct.encode(message.parameters, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim();
+ if (message.intentInput != null && Object.hasOwnProperty.call(message, "intentInput"))
+ $root.google.cloud.dialogflow.v2beta1.IntentInput.encode(message.intentInput, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified SuggestionInput message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestionInput.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestionInput} message SuggestionInput message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ SuggestionInput.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a SuggestionInput message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestionInput} SuggestionInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ SuggestionInput.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.dialogflow.v2beta1.SuggestionInput();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.answerRecord = reader.string();
+ break;
+ }
+ case 2: {
+ message.textOverride = $root.google.cloud.dialogflow.v2beta1.TextInput.decode(reader, reader.uint32());
+ break;
+ }
+ case 4: {
+ message.parameters = $root.google.protobuf.Struct.decode(reader, reader.uint32());
+ break;
+ }
+ case 6: {
+ message.intentInput = $root.google.cloud.dialogflow.v2beta1.IntentInput.decode(reader, reader.uint32());
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a SuggestionInput message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestionInput} SuggestionInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ SuggestionInput.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a SuggestionInput message.
+ * @function verify
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ SuggestionInput.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.answerRecord != null && message.hasOwnProperty("answerRecord"))
+ if (!$util.isString(message.answerRecord))
+ return "answerRecord: string expected";
+ if (message.textOverride != null && message.hasOwnProperty("textOverride")) {
+ var error = $root.google.cloud.dialogflow.v2beta1.TextInput.verify(message.textOverride);
+ if (error)
+ return "textOverride." + error;
+ }
+ if (message.parameters != null && message.hasOwnProperty("parameters")) {
+ var error = $root.google.protobuf.Struct.verify(message.parameters);
+ if (error)
+ return "parameters." + error;
+ }
+ if (message.intentInput != null && message.hasOwnProperty("intentInput")) {
+ var error = $root.google.cloud.dialogflow.v2beta1.IntentInput.verify(message.intentInput);
+ if (error)
+ return "intentInput." + error;
+ }
+ return null;
+ };
+
+ /**
+ * Creates a SuggestionInput message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestionInput} SuggestionInput
+ */
+ SuggestionInput.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.dialogflow.v2beta1.SuggestionInput)
+ return object;
+ var message = new $root.google.cloud.dialogflow.v2beta1.SuggestionInput();
+ if (object.answerRecord != null)
+ message.answerRecord = String(object.answerRecord);
+ if (object.textOverride != null) {
+ if (typeof object.textOverride !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestionInput.textOverride: object expected");
+ message.textOverride = $root.google.cloud.dialogflow.v2beta1.TextInput.fromObject(object.textOverride);
+ }
+ if (object.parameters != null) {
+ if (typeof object.parameters !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestionInput.parameters: object expected");
+ message.parameters = $root.google.protobuf.Struct.fromObject(object.parameters);
+ }
+ if (object.intentInput != null) {
+ if (typeof object.intentInput !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestionInput.intentInput: object expected");
+ message.intentInput = $root.google.cloud.dialogflow.v2beta1.IntentInput.fromObject(object.intentInput);
+ }
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a SuggestionInput message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.SuggestionInput} message SuggestionInput
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ SuggestionInput.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.answerRecord = "";
+ object.textOverride = null;
+ object.parameters = null;
+ object.intentInput = null;
+ }
+ if (message.answerRecord != null && message.hasOwnProperty("answerRecord"))
+ object.answerRecord = message.answerRecord;
+ if (message.textOverride != null && message.hasOwnProperty("textOverride"))
+ object.textOverride = $root.google.cloud.dialogflow.v2beta1.TextInput.toObject(message.textOverride, options);
+ if (message.parameters != null && message.hasOwnProperty("parameters"))
+ object.parameters = $root.google.protobuf.Struct.toObject(message.parameters, options);
+ if (message.intentInput != null && message.hasOwnProperty("intentInput"))
+ object.intentInput = $root.google.cloud.dialogflow.v2beta1.IntentInput.toObject(message.intentInput, options);
+ return object;
+ };
+
+ /**
+ * Converts this SuggestionInput to JSON.
+ * @function toJSON
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ SuggestionInput.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for SuggestionInput
+ * @function getTypeUrl
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionInput
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ SuggestionInput.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.SuggestionInput";
+ };
+
+ return SuggestionInput;
+ })();
+
+ v2beta1.IntentInput = (function() {
+
+ /**
+ * Properties of an IntentInput.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @interface IIntentInput
+ * @property {string|null} [intent] IntentInput intent
+ * @property {string|null} [languageCode] IntentInput languageCode
+ */
+
+ /**
+ * Constructs a new IntentInput.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @classdesc Represents an IntentInput.
+ * @implements IIntentInput
+ * @constructor
+ * @param {google.cloud.dialogflow.v2beta1.IIntentInput=} [properties] Properties to set
+ */
+ function IntentInput(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * IntentInput intent.
+ * @member {string} intent
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @instance
+ */
+ IntentInput.prototype.intent = "";
+
+ /**
+ * IntentInput languageCode.
+ * @member {string} languageCode
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @instance
+ */
+ IntentInput.prototype.languageCode = "";
+
+ /**
+ * Creates a new IntentInput instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IIntentInput=} [properties] Properties to set
+ * @returns {google.cloud.dialogflow.v2beta1.IntentInput} IntentInput instance
+ */
+ IntentInput.create = function create(properties) {
+ return new IntentInput(properties);
+ };
+
+ /**
+ * Encodes the specified IntentInput message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentInput.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IIntentInput} message IntentInput message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ IntentInput.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.intent != null && Object.hasOwnProperty.call(message, "intent"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.intent);
+ if (message.languageCode != null && Object.hasOwnProperty.call(message, "languageCode"))
+ writer.uint32(/* id 3, wireType 2 =*/26).string(message.languageCode);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified IntentInput message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentInput.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IIntentInput} message IntentInput message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ IntentInput.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes an IntentInput message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.dialogflow.v2beta1.IntentInput} IntentInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ IntentInput.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.dialogflow.v2beta1.IntentInput();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.intent = reader.string();
+ break;
+ }
+ case 3: {
+ message.languageCode = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes an IntentInput message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.dialogflow.v2beta1.IntentInput} IntentInput
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ IntentInput.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies an IntentInput message.
+ * @function verify
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ IntentInput.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.intent != null && message.hasOwnProperty("intent"))
+ if (!$util.isString(message.intent))
+ return "intent: string expected";
+ if (message.languageCode != null && message.hasOwnProperty("languageCode"))
+ if (!$util.isString(message.languageCode))
+ return "languageCode: string expected";
+ return null;
+ };
+
+ /**
+ * Creates an IntentInput message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.dialogflow.v2beta1.IntentInput} IntentInput
+ */
+ IntentInput.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.dialogflow.v2beta1.IntentInput)
+ return object;
+ var message = new $root.google.cloud.dialogflow.v2beta1.IntentInput();
+ if (object.intent != null)
+ message.intent = String(object.intent);
+ if (object.languageCode != null)
+ message.languageCode = String(object.languageCode);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from an IntentInput message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IntentInput} message IntentInput
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ IntentInput.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.intent = "";
+ object.languageCode = "";
+ }
+ if (message.intent != null && message.hasOwnProperty("intent"))
+ object.intent = message.intent;
+ if (message.languageCode != null && message.hasOwnProperty("languageCode"))
+ object.languageCode = message.languageCode;
+ return object;
+ };
+
+ /**
+ * Converts this IntentInput to JSON.
+ * @function toJSON
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ IntentInput.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for IntentInput
+ * @function getTypeUrl
+ * @memberof google.cloud.dialogflow.v2beta1.IntentInput
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ IntentInput.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.IntentInput";
+ };
+
+ return IntentInput;
+ })();
+
v2beta1.SuggestionFeature = (function() {
/**
@@ -92830,6 +93409,7 @@
case 1:
case 2:
case 3:
+ case 4:
case 8:
break;
}
@@ -92871,6 +93451,10 @@
case 3:
message.type = 3;
break;
+ case "DIALOGFLOW_ASSIST":
+ case 4:
+ message.type = 4;
+ break;
case "CONVERSATION_SUMMARIZATION":
case 8:
message.type = 8;
@@ -92933,6 +93517,7 @@
* @property {number} ARTICLE_SUGGESTION=1 ARTICLE_SUGGESTION value
* @property {number} FAQ=2 FAQ value
* @property {number} SMART_REPLY=3 SMART_REPLY value
+ * @property {number} DIALOGFLOW_ASSIST=4 DIALOGFLOW_ASSIST value
* @property {number} CONVERSATION_SUMMARIZATION=8 CONVERSATION_SUMMARIZATION value
*/
SuggestionFeature.Type = (function() {
@@ -92941,6 +93526,7 @@
values[valuesById[1] = "ARTICLE_SUGGESTION"] = 1;
values[valuesById[2] = "FAQ"] = 2;
values[valuesById[3] = "SMART_REPLY"] = 3;
+ values[valuesById[4] = "DIALOGFLOW_ASSIST"] = 4;
values[valuesById[8] = "CONVERSATION_SUMMARIZATION"] = 8;
return values;
})();
@@ -93196,6 +93782,7 @@
* @property {google.cloud.dialogflow.v2beta1.ITextInput|null} [textInput] AnalyzeContentRequest textInput
* @property {google.cloud.dialogflow.v2beta1.IAudioInput|null} [audioInput] AnalyzeContentRequest audioInput
* @property {google.cloud.dialogflow.v2beta1.IEventInput|null} [eventInput] AnalyzeContentRequest eventInput
+ * @property {google.cloud.dialogflow.v2beta1.ISuggestionInput|null} [suggestionInput] AnalyzeContentRequest suggestionInput
* @property {google.cloud.dialogflow.v2beta1.IOutputAudioConfig|null} [replyAudioConfig] AnalyzeContentRequest replyAudioConfig
* @property {google.cloud.dialogflow.v2beta1.IQueryParameters|null} [queryParams] AnalyzeContentRequest queryParams
* @property {google.cloud.dialogflow.v2beta1.IAssistQueryParameters|null} [assistQueryParams] AnalyzeContentRequest assistQueryParams
@@ -93252,6 +93839,14 @@
*/
AnalyzeContentRequest.prototype.eventInput = null;
+ /**
+ * AnalyzeContentRequest suggestionInput.
+ * @member {google.cloud.dialogflow.v2beta1.ISuggestionInput|null|undefined} suggestionInput
+ * @memberof google.cloud.dialogflow.v2beta1.AnalyzeContentRequest
+ * @instance
+ */
+ AnalyzeContentRequest.prototype.suggestionInput = null;
+
/**
* AnalyzeContentRequest replyAudioConfig.
* @member {google.cloud.dialogflow.v2beta1.IOutputAudioConfig|null|undefined} replyAudioConfig
@@ -93313,12 +93908,12 @@
/**
* AnalyzeContentRequest input.
- * @member {"textInput"|"audioInput"|"eventInput"|undefined} input
+ * @member {"textInput"|"audioInput"|"eventInput"|"suggestionInput"|undefined} input
* @memberof google.cloud.dialogflow.v2beta1.AnalyzeContentRequest
* @instance
*/
Object.defineProperty(AnalyzeContentRequest.prototype, "input", {
- get: $util.oneOfGetter($oneOfFields = ["textInput", "audioInput", "eventInput"]),
+ get: $util.oneOfGetter($oneOfFields = ["textInput", "audioInput", "eventInput", "suggestionInput"]),
set: $util.oneOfSetter($oneOfFields)
});
@@ -93362,6 +93957,8 @@
$root.google.protobuf.Timestamp.encode(message.messageSendTime, writer.uint32(/* id 10, wireType 2 =*/82).fork()).ldelim();
if (message.requestId != null && Object.hasOwnProperty.call(message, "requestId"))
writer.uint32(/* id 11, wireType 2 =*/90).string(message.requestId);
+ if (message.suggestionInput != null && Object.hasOwnProperty.call(message, "suggestionInput"))
+ $root.google.cloud.dialogflow.v2beta1.SuggestionInput.encode(message.suggestionInput, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim();
if (message.assistQueryParams != null && Object.hasOwnProperty.call(message, "assistQueryParams"))
$root.google.cloud.dialogflow.v2beta1.AssistQueryParameters.encode(message.assistQueryParams, writer.uint32(/* id 14, wireType 2 =*/114).fork()).ldelim();
if (message.cxParameters != null && Object.hasOwnProperty.call(message, "cxParameters"))
@@ -93418,6 +94015,10 @@
message.eventInput = $root.google.cloud.dialogflow.v2beta1.EventInput.decode(reader, reader.uint32());
break;
}
+ case 12: {
+ message.suggestionInput = $root.google.cloud.dialogflow.v2beta1.SuggestionInput.decode(reader, reader.uint32());
+ break;
+ }
case 5: {
message.replyAudioConfig = $root.google.cloud.dialogflow.v2beta1.OutputAudioConfig.decode(reader, reader.uint32());
break;
@@ -93513,6 +94114,16 @@
return "eventInput." + error;
}
}
+ if (message.suggestionInput != null && message.hasOwnProperty("suggestionInput")) {
+ if (properties.input === 1)
+ return "input: multiple values";
+ properties.input = 1;
+ {
+ var error = $root.google.cloud.dialogflow.v2beta1.SuggestionInput.verify(message.suggestionInput);
+ if (error)
+ return "suggestionInput." + error;
+ }
+ }
if (message.replyAudioConfig != null && message.hasOwnProperty("replyAudioConfig")) {
var error = $root.google.cloud.dialogflow.v2beta1.OutputAudioConfig.verify(message.replyAudioConfig);
if (error)
@@ -93576,6 +94187,11 @@
throw TypeError(".google.cloud.dialogflow.v2beta1.AnalyzeContentRequest.eventInput: object expected");
message.eventInput = $root.google.cloud.dialogflow.v2beta1.EventInput.fromObject(object.eventInput);
}
+ if (object.suggestionInput != null) {
+ if (typeof object.suggestionInput !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.AnalyzeContentRequest.suggestionInput: object expected");
+ message.suggestionInput = $root.google.cloud.dialogflow.v2beta1.SuggestionInput.fromObject(object.suggestionInput);
+ }
if (object.replyAudioConfig != null) {
if (typeof object.replyAudioConfig !== "object")
throw TypeError(".google.cloud.dialogflow.v2beta1.AnalyzeContentRequest.replyAudioConfig: object expected");
@@ -93656,6 +94272,11 @@
object.messageSendTime = $root.google.protobuf.Timestamp.toObject(message.messageSendTime, options);
if (message.requestId != null && message.hasOwnProperty("requestId"))
object.requestId = message.requestId;
+ if (message.suggestionInput != null && message.hasOwnProperty("suggestionInput")) {
+ object.suggestionInput = $root.google.cloud.dialogflow.v2beta1.SuggestionInput.toObject(message.suggestionInput, options);
+ if (options.oneofs)
+ object.input = "suggestionInput";
+ }
if (message.assistQueryParams != null && message.hasOwnProperty("assistQueryParams"))
object.assistQueryParams = $root.google.cloud.dialogflow.v2beta1.AssistQueryParameters.toObject(message.assistQueryParams, options);
if (message.cxParameters != null && message.hasOwnProperty("cxParameters"))
@@ -96998,6 +97619,561 @@
return SmartReplyAnswer;
})();
+ v2beta1.IntentSuggestion = (function() {
+
+ /**
+ * Properties of an IntentSuggestion.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @interface IIntentSuggestion
+ * @property {string|null} [displayName] IntentSuggestion displayName
+ * @property {string|null} [intentV2] IntentSuggestion intentV2
+ * @property {string|null} [description] IntentSuggestion description
+ */
+
+ /**
+ * Constructs a new IntentSuggestion.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @classdesc Represents an IntentSuggestion.
+ * @implements IIntentSuggestion
+ * @constructor
+ * @param {google.cloud.dialogflow.v2beta1.IIntentSuggestion=} [properties] Properties to set
+ */
+ function IntentSuggestion(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * IntentSuggestion displayName.
+ * @member {string} displayName
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @instance
+ */
+ IntentSuggestion.prototype.displayName = "";
+
+ /**
+ * IntentSuggestion intentV2.
+ * @member {string|null|undefined} intentV2
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @instance
+ */
+ IntentSuggestion.prototype.intentV2 = null;
+
+ /**
+ * IntentSuggestion description.
+ * @member {string} description
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @instance
+ */
+ IntentSuggestion.prototype.description = "";
+
+ // OneOf field names bound to virtual getters and setters
+ var $oneOfFields;
+
+ /**
+ * IntentSuggestion intent.
+ * @member {"intentV2"|undefined} intent
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @instance
+ */
+ Object.defineProperty(IntentSuggestion.prototype, "intent", {
+ get: $util.oneOfGetter($oneOfFields = ["intentV2"]),
+ set: $util.oneOfSetter($oneOfFields)
+ });
+
+ /**
+ * Creates a new IntentSuggestion instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IIntentSuggestion=} [properties] Properties to set
+ * @returns {google.cloud.dialogflow.v2beta1.IntentSuggestion} IntentSuggestion instance
+ */
+ IntentSuggestion.create = function create(properties) {
+ return new IntentSuggestion(properties);
+ };
+
+ /**
+ * Encodes the specified IntentSuggestion message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentSuggestion.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IIntentSuggestion} message IntentSuggestion message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ IntentSuggestion.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName);
+ if (message.intentV2 != null && Object.hasOwnProperty.call(message, "intentV2"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.intentV2);
+ if (message.description != null && Object.hasOwnProperty.call(message, "description"))
+ writer.uint32(/* id 5, wireType 2 =*/42).string(message.description);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified IntentSuggestion message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.IntentSuggestion.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IIntentSuggestion} message IntentSuggestion message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ IntentSuggestion.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes an IntentSuggestion message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.dialogflow.v2beta1.IntentSuggestion} IntentSuggestion
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ IntentSuggestion.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.dialogflow.v2beta1.IntentSuggestion();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.displayName = reader.string();
+ break;
+ }
+ case 2: {
+ message.intentV2 = reader.string();
+ break;
+ }
+ case 5: {
+ message.description = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes an IntentSuggestion message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.dialogflow.v2beta1.IntentSuggestion} IntentSuggestion
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ IntentSuggestion.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies an IntentSuggestion message.
+ * @function verify
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ IntentSuggestion.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ var properties = {};
+ if (message.displayName != null && message.hasOwnProperty("displayName"))
+ if (!$util.isString(message.displayName))
+ return "displayName: string expected";
+ if (message.intentV2 != null && message.hasOwnProperty("intentV2")) {
+ properties.intent = 1;
+ if (!$util.isString(message.intentV2))
+ return "intentV2: string expected";
+ }
+ if (message.description != null && message.hasOwnProperty("description"))
+ if (!$util.isString(message.description))
+ return "description: string expected";
+ return null;
+ };
+
+ /**
+ * Creates an IntentSuggestion message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.dialogflow.v2beta1.IntentSuggestion} IntentSuggestion
+ */
+ IntentSuggestion.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.dialogflow.v2beta1.IntentSuggestion)
+ return object;
+ var message = new $root.google.cloud.dialogflow.v2beta1.IntentSuggestion();
+ if (object.displayName != null)
+ message.displayName = String(object.displayName);
+ if (object.intentV2 != null)
+ message.intentV2 = String(object.intentV2);
+ if (object.description != null)
+ message.description = String(object.description);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from an IntentSuggestion message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IntentSuggestion} message IntentSuggestion
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ IntentSuggestion.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults) {
+ object.displayName = "";
+ object.description = "";
+ }
+ if (message.displayName != null && message.hasOwnProperty("displayName"))
+ object.displayName = message.displayName;
+ if (message.intentV2 != null && message.hasOwnProperty("intentV2")) {
+ object.intentV2 = message.intentV2;
+ if (options.oneofs)
+ object.intent = "intentV2";
+ }
+ if (message.description != null && message.hasOwnProperty("description"))
+ object.description = message.description;
+ return object;
+ };
+
+ /**
+ * Converts this IntentSuggestion to JSON.
+ * @function toJSON
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ IntentSuggestion.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for IntentSuggestion
+ * @function getTypeUrl
+ * @memberof google.cloud.dialogflow.v2beta1.IntentSuggestion
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ IntentSuggestion.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.IntentSuggestion";
+ };
+
+ return IntentSuggestion;
+ })();
+
+ v2beta1.DialogflowAssistAnswer = (function() {
+
+ /**
+ * Properties of a DialogflowAssistAnswer.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @interface IDialogflowAssistAnswer
+ * @property {google.cloud.dialogflow.v2beta1.IQueryResult|null} [queryResult] DialogflowAssistAnswer queryResult
+ * @property {google.cloud.dialogflow.v2beta1.IIntentSuggestion|null} [intentSuggestion] DialogflowAssistAnswer intentSuggestion
+ * @property {string|null} [answerRecord] DialogflowAssistAnswer answerRecord
+ */
+
+ /**
+ * Constructs a new DialogflowAssistAnswer.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @classdesc Represents a DialogflowAssistAnswer.
+ * @implements IDialogflowAssistAnswer
+ * @constructor
+ * @param {google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer=} [properties] Properties to set
+ */
+ function DialogflowAssistAnswer(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * DialogflowAssistAnswer queryResult.
+ * @member {google.cloud.dialogflow.v2beta1.IQueryResult|null|undefined} queryResult
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @instance
+ */
+ DialogflowAssistAnswer.prototype.queryResult = null;
+
+ /**
+ * DialogflowAssistAnswer intentSuggestion.
+ * @member {google.cloud.dialogflow.v2beta1.IIntentSuggestion|null|undefined} intentSuggestion
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @instance
+ */
+ DialogflowAssistAnswer.prototype.intentSuggestion = null;
+
+ /**
+ * DialogflowAssistAnswer answerRecord.
+ * @member {string} answerRecord
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @instance
+ */
+ DialogflowAssistAnswer.prototype.answerRecord = "";
+
+ // OneOf field names bound to virtual getters and setters
+ var $oneOfFields;
+
+ /**
+ * DialogflowAssistAnswer result.
+ * @member {"queryResult"|"intentSuggestion"|undefined} result
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @instance
+ */
+ Object.defineProperty(DialogflowAssistAnswer.prototype, "result", {
+ get: $util.oneOfGetter($oneOfFields = ["queryResult", "intentSuggestion"]),
+ set: $util.oneOfSetter($oneOfFields)
+ });
+
+ /**
+ * Creates a new DialogflowAssistAnswer instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer=} [properties] Properties to set
+ * @returns {google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer} DialogflowAssistAnswer instance
+ */
+ DialogflowAssistAnswer.create = function create(properties) {
+ return new DialogflowAssistAnswer(properties);
+ };
+
+ /**
+ * Encodes the specified DialogflowAssistAnswer message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer} message DialogflowAssistAnswer message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ DialogflowAssistAnswer.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.queryResult != null && Object.hasOwnProperty.call(message, "queryResult"))
+ $root.google.cloud.dialogflow.v2beta1.QueryResult.encode(message.queryResult, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
+ if (message.answerRecord != null && Object.hasOwnProperty.call(message, "answerRecord"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.answerRecord);
+ if (message.intentSuggestion != null && Object.hasOwnProperty.call(message, "intentSuggestion"))
+ $root.google.cloud.dialogflow.v2beta1.IntentSuggestion.encode(message.intentSuggestion, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim();
+ return writer;
+ };
+
+ /**
+ * Encodes the specified DialogflowAssistAnswer message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.IDialogflowAssistAnswer} message DialogflowAssistAnswer message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ DialogflowAssistAnswer.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a DialogflowAssistAnswer message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer} DialogflowAssistAnswer
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ DialogflowAssistAnswer.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.queryResult = $root.google.cloud.dialogflow.v2beta1.QueryResult.decode(reader, reader.uint32());
+ break;
+ }
+ case 5: {
+ message.intentSuggestion = $root.google.cloud.dialogflow.v2beta1.IntentSuggestion.decode(reader, reader.uint32());
+ break;
+ }
+ case 2: {
+ message.answerRecord = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a DialogflowAssistAnswer message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer} DialogflowAssistAnswer
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ DialogflowAssistAnswer.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a DialogflowAssistAnswer message.
+ * @function verify
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ DialogflowAssistAnswer.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ var properties = {};
+ if (message.queryResult != null && message.hasOwnProperty("queryResult")) {
+ properties.result = 1;
+ {
+ var error = $root.google.cloud.dialogflow.v2beta1.QueryResult.verify(message.queryResult);
+ if (error)
+ return "queryResult." + error;
+ }
+ }
+ if (message.intentSuggestion != null && message.hasOwnProperty("intentSuggestion")) {
+ if (properties.result === 1)
+ return "result: multiple values";
+ properties.result = 1;
+ {
+ var error = $root.google.cloud.dialogflow.v2beta1.IntentSuggestion.verify(message.intentSuggestion);
+ if (error)
+ return "intentSuggestion." + error;
+ }
+ }
+ if (message.answerRecord != null && message.hasOwnProperty("answerRecord"))
+ if (!$util.isString(message.answerRecord))
+ return "answerRecord: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a DialogflowAssistAnswer message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer} DialogflowAssistAnswer
+ */
+ DialogflowAssistAnswer.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer)
+ return object;
+ var message = new $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer();
+ if (object.queryResult != null) {
+ if (typeof object.queryResult !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.queryResult: object expected");
+ message.queryResult = $root.google.cloud.dialogflow.v2beta1.QueryResult.fromObject(object.queryResult);
+ }
+ if (object.intentSuggestion != null) {
+ if (typeof object.intentSuggestion !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.intentSuggestion: object expected");
+ message.intentSuggestion = $root.google.cloud.dialogflow.v2beta1.IntentSuggestion.fromObject(object.intentSuggestion);
+ }
+ if (object.answerRecord != null)
+ message.answerRecord = String(object.answerRecord);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a DialogflowAssistAnswer message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer} message DialogflowAssistAnswer
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ DialogflowAssistAnswer.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults)
+ object.answerRecord = "";
+ if (message.queryResult != null && message.hasOwnProperty("queryResult")) {
+ object.queryResult = $root.google.cloud.dialogflow.v2beta1.QueryResult.toObject(message.queryResult, options);
+ if (options.oneofs)
+ object.result = "queryResult";
+ }
+ if (message.answerRecord != null && message.hasOwnProperty("answerRecord"))
+ object.answerRecord = message.answerRecord;
+ if (message.intentSuggestion != null && message.hasOwnProperty("intentSuggestion")) {
+ object.intentSuggestion = $root.google.cloud.dialogflow.v2beta1.IntentSuggestion.toObject(message.intentSuggestion, options);
+ if (options.oneofs)
+ object.result = "intentSuggestion";
+ }
+ return object;
+ };
+
+ /**
+ * Converts this DialogflowAssistAnswer to JSON.
+ * @function toJSON
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ DialogflowAssistAnswer.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for DialogflowAssistAnswer
+ * @function getTypeUrl
+ * @memberof google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ DialogflowAssistAnswer.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer";
+ };
+
+ return DialogflowAssistAnswer;
+ })();
+
v2beta1.SuggestionResult = (function() {
/**
@@ -97008,6 +98184,8 @@
* @property {google.cloud.dialogflow.v2beta1.ISuggestArticlesResponse|null} [suggestArticlesResponse] SuggestionResult suggestArticlesResponse
* @property {google.cloud.dialogflow.v2beta1.ISuggestFaqAnswersResponse|null} [suggestFaqAnswersResponse] SuggestionResult suggestFaqAnswersResponse
* @property {google.cloud.dialogflow.v2beta1.ISuggestSmartRepliesResponse|null} [suggestSmartRepliesResponse] SuggestionResult suggestSmartRepliesResponse
+ * @property {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null} [suggestDialogflowAssistsResponse] SuggestionResult suggestDialogflowAssistsResponse
+ * @property {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null} [suggestEntityExtractionResponse] SuggestionResult suggestEntityExtractionResponse
*/
/**
@@ -97057,17 +98235,33 @@
*/
SuggestionResult.prototype.suggestSmartRepliesResponse = null;
+ /**
+ * SuggestionResult suggestDialogflowAssistsResponse.
+ * @member {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null|undefined} suggestDialogflowAssistsResponse
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionResult
+ * @instance
+ */
+ SuggestionResult.prototype.suggestDialogflowAssistsResponse = null;
+
+ /**
+ * SuggestionResult suggestEntityExtractionResponse.
+ * @member {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse|null|undefined} suggestEntityExtractionResponse
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestionResult
+ * @instance
+ */
+ SuggestionResult.prototype.suggestEntityExtractionResponse = null;
+
// OneOf field names bound to virtual getters and setters
var $oneOfFields;
/**
* SuggestionResult suggestionResponse.
- * @member {"error"|"suggestArticlesResponse"|"suggestFaqAnswersResponse"|"suggestSmartRepliesResponse"|undefined} suggestionResponse
+ * @member {"error"|"suggestArticlesResponse"|"suggestFaqAnswersResponse"|"suggestSmartRepliesResponse"|"suggestDialogflowAssistsResponse"|"suggestEntityExtractionResponse"|undefined} suggestionResponse
* @memberof google.cloud.dialogflow.v2beta1.SuggestionResult
* @instance
*/
Object.defineProperty(SuggestionResult.prototype, "suggestionResponse", {
- get: $util.oneOfGetter($oneOfFields = ["error", "suggestArticlesResponse", "suggestFaqAnswersResponse", "suggestSmartRepliesResponse"]),
+ get: $util.oneOfGetter($oneOfFields = ["error", "suggestArticlesResponse", "suggestFaqAnswersResponse", "suggestSmartRepliesResponse", "suggestDialogflowAssistsResponse", "suggestEntityExtractionResponse"]),
set: $util.oneOfSetter($oneOfFields)
});
@@ -97103,6 +98297,10 @@
$root.google.cloud.dialogflow.v2beta1.SuggestFaqAnswersResponse.encode(message.suggestFaqAnswersResponse, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
if (message.suggestSmartRepliesResponse != null && Object.hasOwnProperty.call(message, "suggestSmartRepliesResponse"))
$root.google.cloud.dialogflow.v2beta1.SuggestSmartRepliesResponse.encode(message.suggestSmartRepliesResponse, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim();
+ if (message.suggestDialogflowAssistsResponse != null && Object.hasOwnProperty.call(message, "suggestDialogflowAssistsResponse"))
+ $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.encode(message.suggestDialogflowAssistsResponse, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim();
+ if (message.suggestEntityExtractionResponse != null && Object.hasOwnProperty.call(message, "suggestEntityExtractionResponse"))
+ $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.encode(message.suggestEntityExtractionResponse, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim();
return writer;
};
@@ -97153,6 +98351,14 @@
message.suggestSmartRepliesResponse = $root.google.cloud.dialogflow.v2beta1.SuggestSmartRepliesResponse.decode(reader, reader.uint32());
break;
}
+ case 5: {
+ message.suggestDialogflowAssistsResponse = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.decode(reader, reader.uint32());
+ break;
+ }
+ case 7: {
+ message.suggestEntityExtractionResponse = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -97227,6 +98433,26 @@
return "suggestSmartRepliesResponse." + error;
}
}
+ if (message.suggestDialogflowAssistsResponse != null && message.hasOwnProperty("suggestDialogflowAssistsResponse")) {
+ if (properties.suggestionResponse === 1)
+ return "suggestionResponse: multiple values";
+ properties.suggestionResponse = 1;
+ {
+ var error = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.verify(message.suggestDialogflowAssistsResponse);
+ if (error)
+ return "suggestDialogflowAssistsResponse." + error;
+ }
+ }
+ if (message.suggestEntityExtractionResponse != null && message.hasOwnProperty("suggestEntityExtractionResponse")) {
+ if (properties.suggestionResponse === 1)
+ return "suggestionResponse: multiple values";
+ properties.suggestionResponse = 1;
+ {
+ var error = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.verify(message.suggestEntityExtractionResponse);
+ if (error)
+ return "suggestEntityExtractionResponse." + error;
+ }
+ }
return null;
};
@@ -97262,6 +98488,16 @@
throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestionResult.suggestSmartRepliesResponse: object expected");
message.suggestSmartRepliesResponse = $root.google.cloud.dialogflow.v2beta1.SuggestSmartRepliesResponse.fromObject(object.suggestSmartRepliesResponse);
}
+ if (object.suggestDialogflowAssistsResponse != null) {
+ if (typeof object.suggestDialogflowAssistsResponse !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestionResult.suggestDialogflowAssistsResponse: object expected");
+ message.suggestDialogflowAssistsResponse = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.fromObject(object.suggestDialogflowAssistsResponse);
+ }
+ if (object.suggestEntityExtractionResponse != null) {
+ if (typeof object.suggestEntityExtractionResponse !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestionResult.suggestEntityExtractionResponse: object expected");
+ message.suggestEntityExtractionResponse = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.fromObject(object.suggestEntityExtractionResponse);
+ }
return message;
};
@@ -97298,6 +98534,16 @@
if (options.oneofs)
object.suggestionResponse = "suggestSmartRepliesResponse";
}
+ if (message.suggestDialogflowAssistsResponse != null && message.hasOwnProperty("suggestDialogflowAssistsResponse")) {
+ object.suggestDialogflowAssistsResponse = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.toObject(message.suggestDialogflowAssistsResponse, options);
+ if (options.oneofs)
+ object.suggestionResponse = "suggestDialogflowAssistsResponse";
+ }
+ if (message.suggestEntityExtractionResponse != null && message.hasOwnProperty("suggestEntityExtractionResponse")) {
+ object.suggestEntityExtractionResponse = $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.toObject(message.suggestEntityExtractionResponse, options);
+ if (options.oneofs)
+ object.suggestionResponse = "suggestEntityExtractionResponse";
+ }
return object;
};
@@ -98980,6 +100226,278 @@
return SuggestSmartRepliesResponse;
})();
+ v2beta1.SuggestDialogflowAssistsResponse = (function() {
+
+ /**
+ * Properties of a SuggestDialogflowAssistsResponse.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @interface ISuggestDialogflowAssistsResponse
+ * @property {Array.|null} [dialogflowAssistAnswers] SuggestDialogflowAssistsResponse dialogflowAssistAnswers
+ * @property {string|null} [latestMessage] SuggestDialogflowAssistsResponse latestMessage
+ * @property {number|null} [contextSize] SuggestDialogflowAssistsResponse contextSize
+ */
+
+ /**
+ * Constructs a new SuggestDialogflowAssistsResponse.
+ * @memberof google.cloud.dialogflow.v2beta1
+ * @classdesc Represents a SuggestDialogflowAssistsResponse.
+ * @implements ISuggestDialogflowAssistsResponse
+ * @constructor
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse=} [properties] Properties to set
+ */
+ function SuggestDialogflowAssistsResponse(properties) {
+ this.dialogflowAssistAnswers = [];
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * SuggestDialogflowAssistsResponse dialogflowAssistAnswers.
+ * @member {Array.} dialogflowAssistAnswers
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @instance
+ */
+ SuggestDialogflowAssistsResponse.prototype.dialogflowAssistAnswers = $util.emptyArray;
+
+ /**
+ * SuggestDialogflowAssistsResponse latestMessage.
+ * @member {string} latestMessage
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @instance
+ */
+ SuggestDialogflowAssistsResponse.prototype.latestMessage = "";
+
+ /**
+ * SuggestDialogflowAssistsResponse contextSize.
+ * @member {number} contextSize
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @instance
+ */
+ SuggestDialogflowAssistsResponse.prototype.contextSize = 0;
+
+ /**
+ * Creates a new SuggestDialogflowAssistsResponse instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse=} [properties] Properties to set
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse} SuggestDialogflowAssistsResponse instance
+ */
+ SuggestDialogflowAssistsResponse.create = function create(properties) {
+ return new SuggestDialogflowAssistsResponse(properties);
+ };
+
+ /**
+ * Encodes the specified SuggestDialogflowAssistsResponse message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse} message SuggestDialogflowAssistsResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ SuggestDialogflowAssistsResponse.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.dialogflowAssistAnswers != null && message.dialogflowAssistAnswers.length)
+ for (var i = 0; i < message.dialogflowAssistAnswers.length; ++i)
+ $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.encode(message.dialogflowAssistAnswers[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
+ if (message.latestMessage != null && Object.hasOwnProperty.call(message, "latestMessage"))
+ writer.uint32(/* id 2, wireType 2 =*/18).string(message.latestMessage);
+ if (message.contextSize != null && Object.hasOwnProperty.call(message, "contextSize"))
+ writer.uint32(/* id 3, wireType 0 =*/24).int32(message.contextSize);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified SuggestDialogflowAssistsResponse message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.ISuggestDialogflowAssistsResponse} message SuggestDialogflowAssistsResponse message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ SuggestDialogflowAssistsResponse.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a SuggestDialogflowAssistsResponse message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse} SuggestDialogflowAssistsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ SuggestDialogflowAssistsResponse.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ if (!(message.dialogflowAssistAnswers && message.dialogflowAssistAnswers.length))
+ message.dialogflowAssistAnswers = [];
+ message.dialogflowAssistAnswers.push($root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.decode(reader, reader.uint32()));
+ break;
+ }
+ case 2: {
+ message.latestMessage = reader.string();
+ break;
+ }
+ case 3: {
+ message.contextSize = reader.int32();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a SuggestDialogflowAssistsResponse message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse} SuggestDialogflowAssistsResponse
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ SuggestDialogflowAssistsResponse.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a SuggestDialogflowAssistsResponse message.
+ * @function verify
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ SuggestDialogflowAssistsResponse.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.dialogflowAssistAnswers != null && message.hasOwnProperty("dialogflowAssistAnswers")) {
+ if (!Array.isArray(message.dialogflowAssistAnswers))
+ return "dialogflowAssistAnswers: array expected";
+ for (var i = 0; i < message.dialogflowAssistAnswers.length; ++i) {
+ var error = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.verify(message.dialogflowAssistAnswers[i]);
+ if (error)
+ return "dialogflowAssistAnswers." + error;
+ }
+ }
+ if (message.latestMessage != null && message.hasOwnProperty("latestMessage"))
+ if (!$util.isString(message.latestMessage))
+ return "latestMessage: string expected";
+ if (message.contextSize != null && message.hasOwnProperty("contextSize"))
+ if (!$util.isInteger(message.contextSize))
+ return "contextSize: integer expected";
+ return null;
+ };
+
+ /**
+ * Creates a SuggestDialogflowAssistsResponse message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse} SuggestDialogflowAssistsResponse
+ */
+ SuggestDialogflowAssistsResponse.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse)
+ return object;
+ var message = new $root.google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse();
+ if (object.dialogflowAssistAnswers) {
+ if (!Array.isArray(object.dialogflowAssistAnswers))
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.dialogflowAssistAnswers: array expected");
+ message.dialogflowAssistAnswers = [];
+ for (var i = 0; i < object.dialogflowAssistAnswers.length; ++i) {
+ if (typeof object.dialogflowAssistAnswers[i] !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse.dialogflowAssistAnswers: object expected");
+ message.dialogflowAssistAnswers[i] = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.fromObject(object.dialogflowAssistAnswers[i]);
+ }
+ }
+ if (object.latestMessage != null)
+ message.latestMessage = String(object.latestMessage);
+ if (object.contextSize != null)
+ message.contextSize = object.contextSize | 0;
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a SuggestDialogflowAssistsResponse message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse} message SuggestDialogflowAssistsResponse
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ SuggestDialogflowAssistsResponse.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.arrays || options.defaults)
+ object.dialogflowAssistAnswers = [];
+ if (options.defaults) {
+ object.latestMessage = "";
+ object.contextSize = 0;
+ }
+ if (message.dialogflowAssistAnswers && message.dialogflowAssistAnswers.length) {
+ object.dialogflowAssistAnswers = [];
+ for (var j = 0; j < message.dialogflowAssistAnswers.length; ++j)
+ object.dialogflowAssistAnswers[j] = $root.google.cloud.dialogflow.v2beta1.DialogflowAssistAnswer.toObject(message.dialogflowAssistAnswers[j], options);
+ }
+ if (message.latestMessage != null && message.hasOwnProperty("latestMessage"))
+ object.latestMessage = message.latestMessage;
+ if (message.contextSize != null && message.hasOwnProperty("contextSize"))
+ object.contextSize = message.contextSize;
+ return object;
+ };
+
+ /**
+ * Converts this SuggestDialogflowAssistsResponse to JSON.
+ * @function toJSON
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ SuggestDialogflowAssistsResponse.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for SuggestDialogflowAssistsResponse
+ * @function getTypeUrl
+ * @memberof google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ SuggestDialogflowAssistsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.SuggestDialogflowAssistsResponse";
+ };
+
+ return SuggestDialogflowAssistsResponse;
+ })();
+
v2beta1.Suggestion = (function() {
/**
@@ -142780,6 +144298,7 @@
* @memberof google.cloud.dialogflow.v2beta1
* @interface IAutomatedAgentConfig
* @property {string|null} [agent] AutomatedAgentConfig agent
+ * @property {google.protobuf.IDuration|null} [sessionTtl] AutomatedAgentConfig sessionTtl
*/
/**
@@ -142805,6 +144324,14 @@
*/
AutomatedAgentConfig.prototype.agent = "";
+ /**
+ * AutomatedAgentConfig sessionTtl.
+ * @member {google.protobuf.IDuration|null|undefined} sessionTtl
+ * @memberof google.cloud.dialogflow.v2beta1.AutomatedAgentConfig
+ * @instance
+ */
+ AutomatedAgentConfig.prototype.sessionTtl = null;
+
/**
* Creates a new AutomatedAgentConfig instance using the specified properties.
* @function create
@@ -142831,6 +144358,8 @@
writer = $Writer.create();
if (message.agent != null && Object.hasOwnProperty.call(message, "agent"))
writer.uint32(/* id 1, wireType 2 =*/10).string(message.agent);
+ if (message.sessionTtl != null && Object.hasOwnProperty.call(message, "sessionTtl"))
+ $root.google.protobuf.Duration.encode(message.sessionTtl, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
return writer;
};
@@ -142869,6 +144398,10 @@
message.agent = reader.string();
break;
}
+ case 3: {
+ message.sessionTtl = $root.google.protobuf.Duration.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -142907,6 +144440,11 @@
if (message.agent != null && message.hasOwnProperty("agent"))
if (!$util.isString(message.agent))
return "agent: string expected";
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl")) {
+ var error = $root.google.protobuf.Duration.verify(message.sessionTtl);
+ if (error)
+ return "sessionTtl." + error;
+ }
return null;
};
@@ -142924,6 +144462,11 @@
var message = new $root.google.cloud.dialogflow.v2beta1.AutomatedAgentConfig();
if (object.agent != null)
message.agent = String(object.agent);
+ if (object.sessionTtl != null) {
+ if (typeof object.sessionTtl !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.AutomatedAgentConfig.sessionTtl: object expected");
+ message.sessionTtl = $root.google.protobuf.Duration.fromObject(object.sessionTtl);
+ }
return message;
};
@@ -142940,10 +144483,14 @@
if (!options)
options = {};
var object = {};
- if (options.defaults)
+ if (options.defaults) {
object.agent = "";
+ object.sessionTtl = null;
+ }
if (message.agent != null && message.hasOwnProperty("agent"))
object.agent = message.agent;
+ if (message.sessionTtl != null && message.hasOwnProperty("sessionTtl"))
+ object.sessionTtl = $root.google.protobuf.Duration.toObject(message.sessionTtl, options);
return object;
};
@@ -144900,6 +146447,7 @@
* @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig
* @interface IDialogflowQuerySource
* @property {string|null} [agent] DialogflowQuerySource agent
+ * @property {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig|null} [humanAgentSideConfig] DialogflowQuerySource humanAgentSideConfig
*/
/**
@@ -144925,6 +146473,14 @@
*/
DialogflowQuerySource.prototype.agent = "";
+ /**
+ * DialogflowQuerySource humanAgentSideConfig.
+ * @member {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig|null|undefined} humanAgentSideConfig
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource
+ * @instance
+ */
+ DialogflowQuerySource.prototype.humanAgentSideConfig = null;
+
/**
* Creates a new DialogflowQuerySource instance using the specified properties.
* @function create
@@ -144951,6 +146507,8 @@
writer = $Writer.create();
if (message.agent != null && Object.hasOwnProperty.call(message, "agent"))
writer.uint32(/* id 1, wireType 2 =*/10).string(message.agent);
+ if (message.humanAgentSideConfig != null && Object.hasOwnProperty.call(message, "humanAgentSideConfig"))
+ $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.encode(message.humanAgentSideConfig, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim();
return writer;
};
@@ -144989,6 +146547,10 @@
message.agent = reader.string();
break;
}
+ case 3: {
+ message.humanAgentSideConfig = $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.decode(reader, reader.uint32());
+ break;
+ }
default:
reader.skipType(tag & 7);
break;
@@ -145027,6 +146589,11 @@
if (message.agent != null && message.hasOwnProperty("agent"))
if (!$util.isString(message.agent))
return "agent: string expected";
+ if (message.humanAgentSideConfig != null && message.hasOwnProperty("humanAgentSideConfig")) {
+ var error = $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.verify(message.humanAgentSideConfig);
+ if (error)
+ return "humanAgentSideConfig." + error;
+ }
return null;
};
@@ -145044,6 +146611,11 @@
var message = new $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource();
if (object.agent != null)
message.agent = String(object.agent);
+ if (object.humanAgentSideConfig != null) {
+ if (typeof object.humanAgentSideConfig !== "object")
+ throw TypeError(".google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.humanAgentSideConfig: object expected");
+ message.humanAgentSideConfig = $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.fromObject(object.humanAgentSideConfig);
+ }
return message;
};
@@ -145060,10 +146632,14 @@
if (!options)
options = {};
var object = {};
- if (options.defaults)
+ if (options.defaults) {
object.agent = "";
+ object.humanAgentSideConfig = null;
+ }
if (message.agent != null && message.hasOwnProperty("agent"))
object.agent = message.agent;
+ if (message.humanAgentSideConfig != null && message.hasOwnProperty("humanAgentSideConfig"))
+ object.humanAgentSideConfig = $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.toObject(message.humanAgentSideConfig, options);
return object;
};
@@ -145093,6 +146669,209 @@
return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource";
};
+ DialogflowQuerySource.HumanAgentSideConfig = (function() {
+
+ /**
+ * Properties of a HumanAgentSideConfig.
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource
+ * @interface IHumanAgentSideConfig
+ * @property {string|null} [agent] HumanAgentSideConfig agent
+ */
+
+ /**
+ * Constructs a new HumanAgentSideConfig.
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource
+ * @classdesc Represents a HumanAgentSideConfig.
+ * @implements IHumanAgentSideConfig
+ * @constructor
+ * @param {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig=} [properties] Properties to set
+ */
+ function HumanAgentSideConfig(properties) {
+ if (properties)
+ for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
+ if (properties[keys[i]] != null)
+ this[keys[i]] = properties[keys[i]];
+ }
+
+ /**
+ * HumanAgentSideConfig agent.
+ * @member {string} agent
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @instance
+ */
+ HumanAgentSideConfig.prototype.agent = "";
+
+ /**
+ * Creates a new HumanAgentSideConfig instance using the specified properties.
+ * @function create
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig=} [properties] Properties to set
+ * @returns {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig} HumanAgentSideConfig instance
+ */
+ HumanAgentSideConfig.create = function create(properties) {
+ return new HumanAgentSideConfig(properties);
+ };
+
+ /**
+ * Encodes the specified HumanAgentSideConfig message. Does not implicitly {@link google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.verify|verify} messages.
+ * @function encode
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig} message HumanAgentSideConfig message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ HumanAgentSideConfig.encode = function encode(message, writer) {
+ if (!writer)
+ writer = $Writer.create();
+ if (message.agent != null && Object.hasOwnProperty.call(message, "agent"))
+ writer.uint32(/* id 1, wireType 2 =*/10).string(message.agent);
+ return writer;
+ };
+
+ /**
+ * Encodes the specified HumanAgentSideConfig message, length delimited. Does not implicitly {@link google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig.verify|verify} messages.
+ * @function encodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.IHumanAgentSideConfig} message HumanAgentSideConfig message or plain object to encode
+ * @param {$protobuf.Writer} [writer] Writer to encode to
+ * @returns {$protobuf.Writer} Writer
+ */
+ HumanAgentSideConfig.encodeDelimited = function encodeDelimited(message, writer) {
+ return this.encode(message, writer).ldelim();
+ };
+
+ /**
+ * Decodes a HumanAgentSideConfig message from the specified reader or buffer.
+ * @function decode
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @param {number} [length] Message length if known beforehand
+ * @returns {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig} HumanAgentSideConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ HumanAgentSideConfig.decode = function decode(reader, length) {
+ if (!(reader instanceof $Reader))
+ reader = $Reader.create(reader);
+ var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig();
+ while (reader.pos < end) {
+ var tag = reader.uint32();
+ switch (tag >>> 3) {
+ case 1: {
+ message.agent = reader.string();
+ break;
+ }
+ default:
+ reader.skipType(tag & 7);
+ break;
+ }
+ }
+ return message;
+ };
+
+ /**
+ * Decodes a HumanAgentSideConfig message from the specified reader or buffer, length delimited.
+ * @function decodeDelimited
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
+ * @returns {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig} HumanAgentSideConfig
+ * @throws {Error} If the payload is not a reader or valid buffer
+ * @throws {$protobuf.util.ProtocolError} If required fields are missing
+ */
+ HumanAgentSideConfig.decodeDelimited = function decodeDelimited(reader) {
+ if (!(reader instanceof $Reader))
+ reader = new $Reader(reader);
+ return this.decode(reader, reader.uint32());
+ };
+
+ /**
+ * Verifies a HumanAgentSideConfig message.
+ * @function verify
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {Object.} message Plain object to verify
+ * @returns {string|null} `null` if valid, otherwise the reason why it is not
+ */
+ HumanAgentSideConfig.verify = function verify(message) {
+ if (typeof message !== "object" || message === null)
+ return "object expected";
+ if (message.agent != null && message.hasOwnProperty("agent"))
+ if (!$util.isString(message.agent))
+ return "agent: string expected";
+ return null;
+ };
+
+ /**
+ * Creates a HumanAgentSideConfig message from a plain object. Also converts values to their respective internal types.
+ * @function fromObject
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {Object.} object Plain object
+ * @returns {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig} HumanAgentSideConfig
+ */
+ HumanAgentSideConfig.fromObject = function fromObject(object) {
+ if (object instanceof $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig)
+ return object;
+ var message = new $root.google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig();
+ if (object.agent != null)
+ message.agent = String(object.agent);
+ return message;
+ };
+
+ /**
+ * Creates a plain object from a HumanAgentSideConfig message. Also converts values to other types if specified.
+ * @function toObject
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig} message HumanAgentSideConfig
+ * @param {$protobuf.IConversionOptions} [options] Conversion options
+ * @returns {Object.} Plain object
+ */
+ HumanAgentSideConfig.toObject = function toObject(message, options) {
+ if (!options)
+ options = {};
+ var object = {};
+ if (options.defaults)
+ object.agent = "";
+ if (message.agent != null && message.hasOwnProperty("agent"))
+ object.agent = message.agent;
+ return object;
+ };
+
+ /**
+ * Converts this HumanAgentSideConfig to JSON.
+ * @function toJSON
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @instance
+ * @returns {Object.} JSON object
+ */
+ HumanAgentSideConfig.prototype.toJSON = function toJSON() {
+ return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
+ };
+
+ /**
+ * Gets the default type url for HumanAgentSideConfig
+ * @function getTypeUrl
+ * @memberof google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig
+ * @static
+ * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
+ * @returns {string} The default type url
+ */
+ HumanAgentSideConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
+ if (typeUrlPrefix === undefined) {
+ typeUrlPrefix = "type.googleapis.com";
+ }
+ return typeUrlPrefix + "/google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.SuggestionQueryConfig.DialogflowQuerySource.HumanAgentSideConfig";
+ };
+
+ return HumanAgentSideConfig;
+ })();
+
return DialogflowQuerySource;
})();
@@ -149056,6 +150835,7 @@
case 1:
case 2:
case 3:
+ case 4:
case 8:
break;
}
@@ -149123,6 +150903,10 @@
case 3:
message.suggestionFeatureType = 3;
break;
+ case "DIALOGFLOW_ASSIST":
+ case 4:
+ message.suggestionFeatureType = 4;
+ break;
case "CONVERSATION_SUMMARIZATION":
case 8:
message.suggestionFeatureType = 8;
@@ -149384,6 +151168,7 @@
case 1:
case 2:
case 3:
+ case 4:
case 8:
break;
}
@@ -149456,6 +151241,10 @@
case 3:
message.suggestionFeatureType = 3;
break;
+ case "DIALOGFLOW_ASSIST":
+ case 4:
+ message.suggestionFeatureType = 4;
+ break;
case "CONVERSATION_SUMMARIZATION":
case 8:
message.suggestionFeatureType = 8;
@@ -149725,6 +151514,7 @@
case 1:
case 2:
case 3:
+ case 4:
case 8:
break;
}
@@ -149797,6 +151587,10 @@
case 3:
message.suggestionFeatureType = 3;
break;
+ case "DIALOGFLOW_ASSIST":
+ case 4:
+ message.suggestionFeatureType = 4;
+ break;
case "CONVERSATION_SUMMARIZATION":
case 8:
message.suggestionFeatureType = 8;
diff --git a/packages/google-cloud-dialogflow/protos/protos.json b/packages/google-cloud-dialogflow/protos/protos.json
index 5a06ffb8b76..fa24076e9a4 100644
--- a/packages/google-cloud-dialogflow/protos/protos.json
+++ b/packages/google-cloud-dialogflow/protos/protos.json
@@ -6392,6 +6392,13 @@
"(google.api.field_behavior)": "REQUIRED",
"(google.api.resource_reference).type": "dialogflow.googleapis.com/Agent"
}
+ },
+ "sessionTtl": {
+ "type": "google.protobuf.Duration",
+ "id": 3,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
}
},
@@ -8496,7 +8503,10 @@
},
"gcsSource": {
"type": "GcsSources",
- "id": 2
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
},
"documentTemplate": {
"type": "ImportDocumentTemplate",
@@ -10652,7 +10662,8 @@
"answer": {
"oneof": [
"articleSuggestionAnswer",
- "faqAnswer"
+ "faqAnswer",
+ "dialogflowAssistAnswer"
]
}
},
@@ -10670,6 +10681,13 @@
"options": {
"(google.api.field_behavior)": "OUTPUT_ONLY"
}
+ },
+ "dialogflowAssistAnswer": {
+ "type": "DialogflowAssistAnswer",
+ "id": 7,
+ "options": {
+ "(google.api.field_behavior)": "OUTPUT_ONLY"
+ }
}
}
},
@@ -11401,6 +11419,44 @@
}
}
},
+ "SuggestionInput": {
+ "fields": {
+ "answerRecord": {
+ "type": "string",
+ "id": 1
+ },
+ "textOverride": {
+ "type": "TextInput",
+ "id": 2
+ },
+ "parameters": {
+ "type": "google.protobuf.Struct",
+ "id": 4
+ },
+ "intentInput": {
+ "type": "IntentInput",
+ "id": 6
+ }
+ }
+ },
+ "IntentInput": {
+ "fields": {
+ "intent": {
+ "type": "string",
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
+ },
+ "languageCode": {
+ "type": "string",
+ "id": 3,
+ "options": {
+ "(google.api.field_behavior)": "REQUIRED"
+ }
+ }
+ }
+ },
"SuggestionFeature": {
"fields": {
"type": {
@@ -11415,6 +11471,7 @@
"ARTICLE_SUGGESTION": 1,
"FAQ": 2,
"SMART_REPLY": 3,
+ "DIALOGFLOW_ASSIST": 4,
"CONVERSATION_SUMMARIZATION": 8
}
}
@@ -11435,7 +11492,8 @@
"oneof": [
"textInput",
"audioInput",
- "eventInput"
+ "eventInput",
+ "suggestionInput"
]
}
},
@@ -11460,6 +11518,10 @@
"type": "EventInput",
"id": 8
},
+ "suggestionInput": {
+ "type": "SuggestionInput",
+ "id": 12
+ },
"replyAudioConfig": {
"type": "OutputAudioConfig",
"id": 5
@@ -11760,6 +11822,53 @@
}
}
},
+ "IntentSuggestion": {
+ "oneofs": {
+ "intent": {
+ "oneof": [
+ "intentV2"
+ ]
+ }
+ },
+ "fields": {
+ "displayName": {
+ "type": "string",
+ "id": 1
+ },
+ "intentV2": {
+ "type": "string",
+ "id": 2
+ },
+ "description": {
+ "type": "string",
+ "id": 5
+ }
+ }
+ },
+ "DialogflowAssistAnswer": {
+ "oneofs": {
+ "result": {
+ "oneof": [
+ "queryResult",
+ "intentSuggestion"
+ ]
+ }
+ },
+ "fields": {
+ "queryResult": {
+ "type": "QueryResult",
+ "id": 1
+ },
+ "intentSuggestion": {
+ "type": "IntentSuggestion",
+ "id": 5
+ },
+ "answerRecord": {
+ "type": "string",
+ "id": 2
+ }
+ }
+ },
"SuggestionResult": {
"oneofs": {
"suggestionResponse": {
@@ -11767,7 +11876,9 @@
"error",
"suggestArticlesResponse",
"suggestFaqAnswersResponse",
- "suggestSmartRepliesResponse"
+ "suggestSmartRepliesResponse",
+ "suggestDialogflowAssistsResponse",
+ "suggestEntityExtractionResponse"
]
}
},
@@ -11787,6 +11898,14 @@
"suggestSmartRepliesResponse": {
"type": "SuggestSmartRepliesResponse",
"id": 4
+ },
+ "suggestDialogflowAssistsResponse": {
+ "type": "SuggestDialogflowAssistsResponse",
+ "id": 5
+ },
+ "suggestEntityExtractionResponse": {
+ "type": "SuggestDialogflowAssistsResponse",
+ "id": 7
}
}
},
@@ -11939,6 +12058,23 @@
}
}
},
+ "SuggestDialogflowAssistsResponse": {
+ "fields": {
+ "dialogflowAssistAnswers": {
+ "rule": "repeated",
+ "type": "DialogflowAssistAnswer",
+ "id": 1
+ },
+ "latestMessage": {
+ "type": "string",
+ "id": 2
+ },
+ "contextSize": {
+ "type": "int32",
+ "id": 3
+ }
+ }
+ },
"Suggestion": {
"options": {
"deprecated": true
@@ -16803,6 +16939,13 @@
"(google.api.field_behavior)": "REQUIRED",
"(google.api.resource_reference).type": "dialogflow.googleapis.com/Agent"
}
+ },
+ "sessionTtl": {
+ "type": "google.protobuf.Duration",
+ "id": 3,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
}
}
},
@@ -16951,6 +17094,24 @@
"(google.api.field_behavior)": "REQUIRED",
"(google.api.resource_reference).type": "dialogflow.googleapis.com/Agent"
}
+ },
+ "humanAgentSideConfig": {
+ "type": "HumanAgentSideConfig",
+ "id": 3
+ }
+ },
+ "nested": {
+ "HumanAgentSideConfig": {
+ "fields": {
+ "agent": {
+ "type": "string",
+ "id": 1,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL",
+ "(google.api.resource_reference).type": "dialogflow.googleapis.com/Agent"
+ }
+ }
+ }
}
}
},
@@ -17806,7 +17967,10 @@
},
"gcsSource": {
"type": "GcsSources",
- "id": 2
+ "id": 2,
+ "options": {
+ "(google.api.field_behavior)": "OPTIONAL"
+ }
},
"documentTemplate": {
"type": "ImportDocumentTemplate",
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2/conversations.suggest_conversation_summary.js b/packages/google-cloud-dialogflow/samples/generated/v2/conversations.suggest_conversation_summary.js
index c0e3578b265..2d5999b8c6b 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2/conversations.suggest_conversation_summary.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2/conversations.suggest_conversation_summary.js
@@ -49,7 +49,7 @@ function main(conversation) {
*/
// const contextSize = 1234
/**
- * Parameters for a human assist query.
+ * Parameters for a human assist query. Only used for POC/demo purpose.
*/
// const assistQueryParams = {}
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2/documents.import_documents.js b/packages/google-cloud-dialogflow/samples/generated/v2/documents.import_documents.js
index fdf6a2e0bae..31faa2f5349 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2/documents.import_documents.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2/documents.import_documents.js
@@ -35,7 +35,7 @@ function main(parent, documentTemplate) {
*/
// const parent = 'abc123'
/**
- * The Google Cloud Storage location for the documents.
+ * Optional. The Google Cloud Storage location for the documents.
* The path can include a wildcard.
* These URIs may have the forms
* `gs:///`.
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2/snippet_metadata.google.cloud.dialogflow.v2.json b/packages/google-cloud-dialogflow/samples/generated/v2/snippet_metadata.google.cloud.dialogflow.v2.json
index 0e2e1345093..aceff294146 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2/snippet_metadata.google.cloud.dialogflow.v2.json
+++ b/packages/google-cloud-dialogflow/samples/generated/v2/snippet_metadata.google.cloud.dialogflow.v2.json
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-dialogflow",
- "version": "5.8.0",
+ "version": "5.9.0",
"language": "TYPESCRIPT",
"apis": [
{
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.batch_create_messages.js b/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.batch_create_messages.js
index 09d24b388bd..cd2b5034c9c 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.batch_create_messages.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.batch_create_messages.js
@@ -35,7 +35,7 @@ function main(parent, requests) {
*/
// const parent = 'abc123'
/**
- * Required. A maximum of 1000 Messages can be created in a batch.
+ * Required. A maximum of 300 messages can be created in a batch.
* CreateMessageRequest.message.send_time is required. All created
* messages will have identical
* Message.create_time google.cloud.dialogflow.v2beta1.Message.create_time.
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.suggest_conversation_summary.js b/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.suggest_conversation_summary.js
index 5f67ea86cae..8ef1dd9df94 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.suggest_conversation_summary.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2beta1/conversations.suggest_conversation_summary.js
@@ -49,7 +49,7 @@ function main(conversation) {
*/
// const contextSize = 1234
/**
- * Parameters for a human assist query.
+ * Parameters for a human assist query. Only used for POC/demo purpose.
*/
// const assistQueryParams = {}
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2beta1/documents.import_documents.js b/packages/google-cloud-dialogflow/samples/generated/v2beta1/documents.import_documents.js
index 01f548f696b..d9bd3141c8a 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2beta1/documents.import_documents.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2beta1/documents.import_documents.js
@@ -35,7 +35,7 @@ function main(parent, documentTemplate) {
*/
// const parent = 'abc123'
/**
- * The Google Cloud Storage location for the documents.
+ * Optional. The Google Cloud Storage location for the documents.
* The path can include a wildcard.
* These URIs may have the forms
* `gs:///`.
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.create_environment.js b/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.create_environment.js
index dcd3cb13572..7308002d28a 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.create_environment.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.create_environment.js
@@ -31,8 +31,8 @@ function main(parent, environment, environmentId) {
/**
* Required. The agent to create an environment for.
* Supported formats:
- * - `projects//agent`
- * - `projects//locations//agent`
+ * - `projects//agent`
+ * - `projects//locations//agent`
*/
// const parent = 'abc123'
/**
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.delete_environment.js b/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.delete_environment.js
index 11e788d0f1b..b25783de68f 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.delete_environment.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.delete_environment.js
@@ -31,8 +31,8 @@ function main(name) {
/**
* Required. The name of the environment to delete.
* / Format:
- * - `projects//agent/environments/`
- * - `projects//locations//agent/environments/`
+ * - `projects//locations//agent/environments/`
*/
// const name = 'abc123'
diff --git a/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.get_environment.js b/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.get_environment.js
index b49982f1b09..62f42f40007 100644
--- a/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.get_environment.js
+++ b/packages/google-cloud-dialogflow/samples/generated/v2beta1/environments.get_environment.js
@@ -31,8 +31,8 @@ function main(name) {
/**
* Required. The name of the environment.
* Supported formats:
- * - `projects//agent/environments/`
- * - `projects//locations//agent/environments/`
+ * - `projects//locations//agent/environments/