|
| 1 | +# Copyright 2024 Google Inc. |
| 2 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 3 | +# you may not use this file except in compliance with the License. |
| 4 | +# You may obtain a copy of the License at |
| 5 | +# |
| 6 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 7 | +# |
| 8 | +# Unless required by applicable law or agreed to in writing, software |
| 9 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | +# See the License for the specific language governing permissions and |
| 12 | +# limitations under the License. |
| 13 | + |
| 14 | +--- |
| 15 | +name: Curation |
| 16 | +description: Description |
| 17 | +base_url: projects/{{project}}/locations/{{location}}/curations |
| 18 | +update_mask: true |
| 19 | +self_link: projects/{{project}}/locations/{{location}}/curations/{{curation_id}} |
| 20 | +create_url: projects/{{project}}/locations/{{location}}/curations?curationId={{curation_id}} |
| 21 | +update_verb: PATCH |
| 22 | +id_format: projects/{{project}}/locations/{{location}}/curations/{{curation_id}} |
| 23 | +import_format: |
| 24 | + - projects/{{project}}/locations/{{location}}/curations/{{curation_id}} |
| 25 | +autogen_async: true |
| 26 | +autogen_status: Q3VyYXRpb24= |
| 27 | +examples: |
| 28 | + - name: apihub_curation_basic |
| 29 | + primary_resource_id: apihub_curation_basic |
| 30 | + vars: |
| 31 | + curation_id: 'test' |
| 32 | + # API hub instance needs to be created before this, and end to end creation of that resource using Terraform is not yet supported. |
| 33 | + exclude_test: true |
| 34 | + external_providers: ["time"] |
| 35 | +parameters: |
| 36 | + - name: location |
| 37 | + type: String |
| 38 | + description: Resource ID segment making up resource `name`. It identifies the resource within its parent collection as described in https://google.aip.dev/122. |
| 39 | + immutable: true |
| 40 | + url_param_only: true |
| 41 | + required: true |
| 42 | + - name: curationId |
| 43 | + type: String |
| 44 | + description: |- |
| 45 | + The ID to use for the curation resource, which will become the final |
| 46 | + component of the curations's resource name. This field is optional. |
| 47 | +
|
| 48 | + * If provided, the same will be used. The service will throw an error if |
| 49 | + the specified ID is already used by another curation resource in the API |
| 50 | + hub. |
| 51 | + * If not provided, a system generated ID will be used. |
| 52 | +
|
| 53 | + This value should be 4-500 characters, and valid characters |
| 54 | + are /a-z[0-9]-_/. |
| 55 | + immutable: true |
| 56 | + url_param_only: true |
| 57 | + required: true |
| 58 | +properties: |
| 59 | + - name: name |
| 60 | + type: String |
| 61 | + description: |- |
| 62 | + Identifier. The name of the curation. |
| 63 | +
|
| 64 | + Format: |
| 65 | + `projects/{project}/locations/{location}/curations/{curation}` |
| 66 | + output: true |
| 67 | + - name: displayName |
| 68 | + type: String |
| 69 | + description: The display name of the curation. |
| 70 | + required: true |
| 71 | + - name: endpoint |
| 72 | + type: NestedObject |
| 73 | + description: |- |
| 74 | + The endpoint to be triggered for curation. |
| 75 | + The endpoint will be invoked with a request payload containing |
| 76 | + ApiMetadata. |
| 77 | + Response should contain curated data in the form of |
| 78 | + ApiMetadata. |
| 79 | + required: true |
| 80 | + immutable: true |
| 81 | + properties: |
| 82 | + - name: applicationIntegrationEndpointDetails |
| 83 | + type: NestedObject |
| 84 | + description: |- |
| 85 | + The details of the Application Integration endpoint to be triggered for |
| 86 | + curation. |
| 87 | + required: true |
| 88 | + immutable: true |
| 89 | + properties: |
| 90 | + - name: triggerId |
| 91 | + type: String |
| 92 | + description: The API trigger ID of the Application Integration workflow. |
| 93 | + required: true |
| 94 | + immutable: true |
| 95 | + - name: uri |
| 96 | + type: String |
| 97 | + description: |- |
| 98 | + The endpoint URI should be a valid REST URI for triggering an Application |
| 99 | + Integration. |
| 100 | + Format: |
| 101 | + `https://integrations.googleapis.com/v1/{name=projects/*/locations/*/integrations/*}:execute` |
| 102 | + or |
| 103 | + `https://{location}-integrations.googleapis.com/v1/{name=projects/*/locations/*/integrations/*}:execute` |
| 104 | + required: true |
| 105 | + immutable: true |
| 106 | + - name: lastExecutionState |
| 107 | + type: String |
| 108 | + description: |- |
| 109 | + The last execution state of the curation. |
| 110 | + Possible values: |
| 111 | + LAST_EXECUTION_STATE_UNSPECIFIED |
| 112 | + SUCCEEDED |
| 113 | + FAILED |
| 114 | + output: true |
| 115 | + - name: lastExecutionErrorMessage |
| 116 | + type: String |
| 117 | + description: |- |
| 118 | + Error message describing the failure, if any, during the last execution of |
| 119 | + the curation. |
| 120 | + output: true |
| 121 | + - name: description |
| 122 | + type: String |
| 123 | + description: The description of the curation. |
| 124 | + - name: pluginInstanceActions |
| 125 | + type: Array |
| 126 | + description: |- |
| 127 | + The plugin instances and associated actions that are using the curation. |
| 128 | + Note: A particular curation could be used by multiple plugin instances or |
| 129 | + multiple actions in a plugin instance. |
| 130 | + output: true |
| 131 | + item_type: |
| 132 | + type: NestedObject |
| 133 | + properties: |
| 134 | + - name: pluginInstance |
| 135 | + type: String |
| 136 | + description: |- |
| 137 | + Plugin instance that is using the curation. |
| 138 | + Format is |
| 139 | + `projects/{project}/locations/{locati on}/plugins/{plugin}/instances/{instance}` |
| 140 | + output: true |
| 141 | + - name: actionId |
| 142 | + type: String |
| 143 | + description: |- |
| 144 | + The action ID that is using the curation. |
| 145 | + This should map to one of the action IDs specified |
| 146 | + in action configs in the plugin. |
| 147 | + output: true |
| 148 | + - name: lastExecutionErrorCode |
| 149 | + type: String |
| 150 | + description: |- |
| 151 | + The error code of the last execution of the curation. The error code is |
| 152 | + populated only when the last execution state is failed. |
| 153 | + Possible values: |
| 154 | + ERROR_CODE_UNSPECIFIED |
| 155 | + INTERNAL_ERROR |
| 156 | + UNAUTHORIZED |
| 157 | + output: true |
| 158 | + - name: createTime |
| 159 | + type: String |
| 160 | + description: The time at which the curation was created. |
| 161 | + output: true |
| 162 | + - name: updateTime |
| 163 | + type: String |
| 164 | + description: The time at which the curation was last updated. |
| 165 | + output: true |
0 commit comments