- [HTTP request](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.request_body)
  - [JSON representation](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.response_body)
- [Authorization scopes](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#body.aspect_1)
- [DataType](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#DataType)
- [Action](https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#Action)

Manages data for a given plugin instance.

### HTTP request

`POST https://apihub.googleapis.com/v1/{name=projects/*/locations/*/plugins/*/instances/*}:manageSourceData`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The name of the plugin instance for which data needs to be managed. Format: `projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance}` |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "dataType": enum (`https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#DataType`), "action": enum (`https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#Action`), "relativePath": string, "data": string } ``` |

| Fields ||
|---|---|
| `dataType` | ``enum (`https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#DataType`)`` Required. Type of data to be managed. |
| `action` | ``enum (`https://docs.cloud.google.com/apigee/docs/reference/apis/apihub/rest/v1/projects.locations.plugins.instances/manageSourceData#Action`)`` Required. Action to be performed. |
| `relativePath` | `string` Required. Relative path of data being managed for a given plugin instance. |
| `data` | `string (https://developers.google.com/discovery/v1/type-format format)` Required. Data to be managed. A base64-encoded string. |

### Response body

If successful, the response body is empty.

### Authorization scopes

Requires one of the following OAuth scopes:

- `https://www.googleapis.com/auth/apihub.readwrite`
- `
  https://www.googleapis.com/auth/cloud-platform`

### IAM Permissions

Requires the following [IAM](https://cloud.google.com/iam/docs) permission on the `name` resource:

- `apihub.plugininstances.managePluginInstanceSourceData`

For more information, see the [IAM documentation](https://cloud.google.com/iam/docs).

## DataType

Type of data to be managed.

| Enums ||
|---|---|
| `DATA_TYPE_UNSPECIFIED` | Default unspecified type. |
| `PROXY_DEPLOYMENT_MANIFEST` | Proxy deployment manifest. |
| `ENVIRONMENT_MANIFEST` | Environment manifest. |
| `PROXY_BUNDLE` | Proxy bundle. |
| `SHARED_FLOW_BUNDLE` | Shared flow bundle. |

## Action

Action to be performed.

| Enums ||
|---|---|
| `ACTION_UNSPECIFIED` | Default unspecified action. |
| `UPLOAD` | Upload or upsert data. |
| `DELETE` | Delete data. |