# Google Vault

> Manage Google Vault eDiscovery: create and close matters, put people's Gmail, Drive, Groups, Chat and Calendar data on hold, save searches, count results and start exports.

App · 23 actions. Web page: https://docs.lodol.com/docs/integrations/google-vault

## Actions

### Add people to hold

Put more people on an existing hold. Anyone Vault can't add is listed with the reason, and the rest are still added.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Hold (`hold_id`, text, required): The hold in that matter.
- Email addresses (`accounts`, list, required): Email addresses of the people (or groups) to add.

**Outputs**

- `added` (list): The people now on hold
- `added_count` (number): How many were added
- `failed` (list): Those Vault couldn't add, with the reason
- `failed_count` (number): How many couldn't be added

**Example output**

```json
{
  "added": [
    {
      "account_id": "104738291038475610293",
      "email": "jordan.lee@example.com",
      "first_name": "Jordan",
      "held_since": "2026-10-20T15:04:11.402Z",
      "last_name": "Lee"
    }
  ],
  "added_count": 1,
  "failed": [
    {
      "account": "former.employee@example.com",
      "error": "Account not found."
    }
  ],
  "failed_count": 1
}
```

### Close matter

Close a matter once its case or request is over. It stays in Vault as the record of what was done; delete its holds first if their data no longer needs keeping.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.

**Outputs**

- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "collaborator_account_ids": [
    "118273645019283746501"
  ],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "104738291038475610293",
  "state": "closed",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Count search results

Count how many Gmail or Groups messages a search finds, in all and per person, before exporting them. Waits up to 90 seconds for Vault to finish counting.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Service (`corpus`, text): Which service to search. One of: `MAIL` (Gmail), `GROUPS`. Default: `MAIL`.
- Search in (`search_in`, text): Search the people listed, or everyone in your organization. One of: `accounts` (Specific people or groups), `organization` (Everyone in the organization). Default: `accounts`.
- Email addresses (`accounts`, list): Email addresses of the people (or, for Groups, the groups) to search. Only when Search in is Specific people or groups.
- Search terms (`search_terms`, text): Words and Vault search operators to narrow the search, such as `subject:contract from:jordan@example.com`. Leave empty for everything.
- From (`start_date`, date): Only include items from this day on. Leave empty for no start.
- To (`end_date`, date): Only include items up to and including this day. Leave empty for no end.
- Data to search (`data_scope`, text): Search all data, or only what is on hold in this matter. One of: `ALL_DATA` (All data), `HELD_DATA` (Only data on hold), `UNPROCESSED_DATA` (Only data not yet processed (Gmail only)). Default: `ALL_DATA`.
- Include drafts (`include_drafts`, true/false): Include Gmail drafts, which were never sent. On unless you turn it off. Only when Service is Gmail. Default: `true`.

**Outputs**

- `account_counts` (list): Matches per account
- `accounts_not_searched` (list): Accounts left out because they aren't on hold (when searching only held data)
- `items_found` (number): How many messages the search finds
- `matching_accounts` (number): How many accounts have at least one match
- `searched_accounts` (number): How many accounts were searched

**Example output**

```json
{
  "account_counts": [
    {
      "count": 1284,
      "email": "jordan.lee@example.com"
    }
  ],
  "accounts_not_searched": [],
  "items_found": 1284,
  "matching_accounts": 1,
  "searched_accounts": 1
}
```

### Create hold

Put people's Gmail, Drive, Groups, Chat or Calendar data on hold, so Vault keeps it even if they delete it. Gmail and Groups holds can be narrowed by search terms and dates.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Name (`name`, text, required): The hold's name.
- Service (`corpus`, text): Which service's data to hold. One of: `MAIL` (Gmail), `DRIVE`, `GROUPS`, `HANGOUTS_CHAT` (Chat), `CALENDAR`. Default: `MAIL`.
- Email addresses (`accounts`, list, required): Email addresses of the people to hold. For a Groups hold, the groups' email addresses.
- Search terms (`search_terms`, text): Only hold messages matching these words and Vault search operators. Leave empty to hold everything. Only when Service is Gmail or Groups.
- From (`start_date`, date): Only hold messages sent from this day on. Only when Service is Gmail or Groups.
- To (`end_date`, date): Only hold messages sent up to and including this day. Only when Service is Gmail or Groups.
- Include shared drives (`include_shared_drives`, true/false): Also cover files in shared drives the people can access. Only when Service is Drive. Default: `false`.
- Include Chat spaces (`include_chat_spaces`, true/false): Also cover messages in the Chat spaces the people are in. Only when Service is Chat. Default: `false`.

**Outputs**

- `account_count` (number): How many people (or groups) are on hold
- `accounts` (list): The people (or groups) on hold
- `end_date` (text): The last day a Gmail or Groups hold covers (YYYY-MM-DD)
- `hold_id` (text): The hold's ID
- `include_chat_spaces` (true/false): Whether a Chat hold covers spaces too
- `include_shared_drives` (true/false): Whether a Drive hold covers shared drives too
- `matter_id` (text): The matter it is in
- `name` (text): The hold's name
- `org_unit_id` (text): The organizational unit on hold, for a hold made in Vault for a whole unit; empty otherwise
- `search_terms` (text): The search terms narrowing a Gmail or Groups hold
- `service` (text): The service: MAIL (Gmail), DRIVE, GROUPS, HANGOUTS_CHAT (Chat) or CALENDAR
- `start_date` (text): The first day a Gmail or Groups hold covers (YYYY-MM-DD)
- `updated_at` (text): When the hold last changed

**Example output**

```json
{
  "account_count": 1,
  "accounts": [
    {
      "account_id": "104738291038475610293",
      "email": "jordan.lee@example.com",
      "first_name": "Jordan",
      "held_since": "2026-10-20T15:04:11.402Z",
      "last_name": "Lee"
    }
  ],
  "end_date": "2026-09-30",
  "hold_id": "3f9d2k1m0q7xw",
  "include_chat_spaces": false,
  "include_shared_drives": false,
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Sales team email",
  "org_unit_id": "",
  "search_terms": "subject:contract",
  "service": "MAIL",
  "start_date": "2026-01-01",
  "updated_at": "2026-10-20T15:04:11.402Z"
}
```

### Create matter

Create a matter (a case) in Google Vault, owned by the connected account. It starts open.

**Inputs**

- Name (`name`, text, required): The matter's name.
- Description (`description`, text): What the matter is about.

**Outputs**

- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "collaborator_account_ids": [],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "",
  "state": "open",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Delete export

Delete an export and its files from a matter.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Export (`export_id`, text, required): The export in that matter.

**Outputs**

- `deleted` (true/false): True once it is deleted
- `export_id` (text): The deleted export's ID
- `matter_id` (text): The matter it was in

**Example output**

```json
{
  "deleted": true,
  "export_id": "8cb7e9a1d2f34c05",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Delete hold

Delete a hold. Its data is no longer kept for this matter, so people's deleted items may be purged.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Hold (`hold_id`, text, required): The hold in that matter.

**Outputs**

- `deleted` (true/false): True once it is deleted
- `hold_id` (text): The deleted hold's ID
- `matter_id` (text): The matter it was in

**Example output**

```json
{
  "deleted": true,
  "hold_id": "3f9d2k1m0q7xw",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Delete matter

Delete a matter. An open matter is closed first. Vault keeps a deleted matter for a while, so 'Restore matter' can bring it back.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.

**Outputs**

- `closed_first` (true/false): Whether the matter was open and had to be closed first
- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "closed_first": true,
  "collaborator_account_ids": [
    "118273645019283746501"
  ],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "104738291038475610293",
  "state": "deleted",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Delete saved search

Delete a saved search from a matter.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Saved search (`saved_query_id`, text, required): The saved search to delete.

**Outputs**

- `deleted` (true/false): True once it is deleted
- `matter_id` (text): The matter it was in
- `saved_query_id` (text): The deleted saved search's ID

**Example output**

```json
{
  "deleted": true,
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "saved_query_id": "9284710395"
}
```

### Get export

Read an export: whether it is still in progress, has completed or failed, how many items its search found and it holds, and its files.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Export (`export_id`, text, required): The export in that matter.

**Outputs**

- `created_at` (text): When it was started
- `export_id` (text): The export's ID
- `files` (list): The export's files, once it is complete
- `items_exported` (number): How many of them have been exported so far
- `items_found` (number): How many messages or files the search found
- `matter_id` (text): The matter it is in
- `name` (text): The export's name
- `requester_email` (text): Email address of whoever started it
- `requester_name` (text): Name of whoever started it
- `search_terms` (text): The search terms it exported
- `service` (text): The service: MAIL (Gmail), DRIVE, GROUPS, HANGOUTS_CHAT (Chat) or CALENDAR
- `size_bytes` (number): The export's size in bytes
- `status` (text): in progress, completed or failed
- `url` (text): The matter's exports in Google Vault, to download from

**Example output**

```json
{
  "created_at": "2026-10-21T09:12:44.118Z",
  "export_id": "8cb7e9a1d2f34c05",
  "files": [
    {
      "bucket_name": "vault-export-example-1234",
      "md5_hash": "0f9a8b7c6d5e4f3a2b1c0d9e8f7a6b5c",
      "object_name": "a1b2c3d4/8cb7e9a1d2f34c05/Sales_team_email_Q3-1.zip",
      "size_bytes": 48211904
    }
  ],
  "items_exported": 1284,
  "items_found": 1284,
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Sales team email Q3",
  "requester_email": "counsel@example.com",
  "requester_name": "Riley Morgan",
  "search_terms": "subject:contract",
  "service": "MAIL",
  "size_bytes": 48211904,
  "status": "completed",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/exports"
}
```

### Get hold

Read a hold: the service it covers, its search terms and dates, and the people on it.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Hold (`hold_id`, text, required): The hold in that matter.

**Outputs**

- `account_count` (number): How many people (or groups) are on hold
- `accounts` (list): The people (or groups) on hold
- `end_date` (text): The last day a Gmail or Groups hold covers (YYYY-MM-DD)
- `hold_id` (text): The hold's ID
- `include_chat_spaces` (true/false): Whether a Chat hold covers spaces too
- `include_shared_drives` (true/false): Whether a Drive hold covers shared drives too
- `matter_id` (text): The matter it is in
- `name` (text): The hold's name
- `org_unit_id` (text): The organizational unit on hold, for a hold made in Vault for a whole unit; empty otherwise
- `search_terms` (text): The search terms narrowing a Gmail or Groups hold
- `service` (text): The service: MAIL (Gmail), DRIVE, GROUPS, HANGOUTS_CHAT (Chat) or CALENDAR
- `start_date` (text): The first day a Gmail or Groups hold covers (YYYY-MM-DD)
- `updated_at` (text): When the hold last changed

**Example output**

```json
{
  "account_count": 1,
  "accounts": [
    {
      "account_id": "104738291038475610293",
      "email": "jordan.lee@example.com",
      "first_name": "Jordan",
      "held_since": "2026-10-20T15:04:11.402Z",
      "last_name": "Lee"
    }
  ],
  "end_date": "2026-09-30",
  "hold_id": "3f9d2k1m0q7xw",
  "include_chat_spaces": false,
  "include_shared_drives": false,
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Sales team email",
  "org_unit_id": "",
  "search_terms": "subject:contract",
  "service": "MAIL",
  "start_date": "2026-01-01",
  "updated_at": "2026-10-20T15:04:11.402Z"
}
```

### Get matter

Read a matter: its name, description, state, owner and who it is shared with.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.

**Outputs**

- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "collaborator_account_ids": [
    "118273645019283746501"
  ],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "104738291038475610293",
  "state": "open",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### List exports

List the exports in a matter, with how far each has got and its files once it is complete.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Most to return (`max_results`, number): How many to return at most (1 to 500). Defaults to 100. From 1 to 500. Default: `100`.

**Outputs**

- `count` (number): How many are returned
- `exports` (list): The exports

**Example output**

```json
{
  "count": 1,
  "exports": [
    {
      "created_at": "2026-10-21T09:12:44.118Z",
      "export_id": "8cb7e9a1d2f34c05",
      "files": [
        {
          "bucket_name": "vault-export-example-1234",
          "md5_hash": "0f9a8b7c6d5e4f3a2b1c0d9e8f7a6b5c",
          "object_name": "a1b2c3d4/8cb7e9a1d2f34c05/Sales_team_email_Q3-1.zip",
          "size_bytes": 48211904
        }
      ],
      "items_exported": 1284,
      "items_found": 1284,
      "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
      "name": "Sales team email Q3",
      "requester_email": "counsel@example.com",
      "requester_name": "Riley Morgan",
      "search_terms": "subject:contract",
      "service": "MAIL",
      "size_bytes": 48211904,
      "status": "completed",
      "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/exports"
    }
  ]
}
```

### List holds

List the holds in a matter, with the people on each.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Most to return (`max_results`, number): How many to return at most (1 to 500). Defaults to 100. From 1 to 500. Default: `100`.

**Outputs**

- `count` (number): How many are returned
- `holds` (list): The holds

**Example output**

```json
{
  "count": 1,
  "holds": [
    {
      "account_count": 1,
      "accounts": [
        {
          "account_id": "104738291038475610293",
          "email": "jordan.lee@example.com",
          "first_name": "Jordan",
          "held_since": "2026-10-20T15:04:11.402Z",
          "last_name": "Lee"
        }
      ],
      "end_date": "2026-09-30",
      "hold_id": "3f9d2k1m0q7xw",
      "include_chat_spaces": false,
      "include_shared_drives": false,
      "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
      "name": "Sales team email",
      "org_unit_id": "",
      "search_terms": "subject:contract",
      "service": "MAIL",
      "start_date": "2026-01-01",
      "updated_at": "2026-10-20T15:04:11.402Z"
    }
  ]
}
```

### List matters

List the Vault matters the connected account can see.

**Inputs**

- State (`state`, text): Which matters to list. One of: `open`, `closed`, `deleted`, `all`. Default: `open`.
- Most to return (`max_results`, number): How many to return at most (1 to 500). Defaults to 100. From 1 to 500. Default: `100`.

**Outputs**

- `count` (number): How many are returned
- `matters` (list): The matters

**Example output**

```json
{
  "count": 1,
  "matters": [
    {
      "collaborator_account_ids": [
        "118273645019283746501"
      ],
      "description": "Preservation for the Q3 contract dispute.",
      "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
      "name": "Acme v. Example Corp",
      "owner_account_id": "104738291038475610293",
      "state": "open",
      "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
    }
  ]
}
```

### List saved searches

List the searches saved in a matter, with what each one searches.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Most to return (`max_results`, number): How many to return at most (1 to 500). Defaults to 100. From 1 to 500. Default: `100`.

**Outputs**

- `count` (number): How many are returned
- `saved_queries` (list): The saved searches

**Example output**

```json
{
  "count": 1,
  "saved_queries": [
    {
      "accounts": [
        "jordan.lee@example.com"
      ],
      "created_at": "2026-10-21T09:05:02.331Z",
      "data_scope": "ALL_DATA",
      "end_date": "2026-09-30",
      "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
      "name": "Contract emails, Q3",
      "saved_query_id": "9284710395",
      "search_in": "accounts",
      "search_terms": "subject:contract",
      "service": "MAIL",
      "start_date": "2026-07-01"
    }
  ]
}
```

### Remove people from hold

Take people off a hold, so their data is no longer kept for it.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Hold (`hold_id`, text, required): The hold in that matter.
- People (`accounts`, list, required): The people (or groups) to take off the hold.

**Outputs**

- `failed` (list): Those that couldn't be removed, with the reason
- `failed_count` (number): How many couldn't be removed
- `removed` (list): The email addresses or account IDs taken off the hold
- `removed_count` (number): How many were removed

**Example output**

```json
{
  "failed": [],
  "failed_count": 0,
  "removed": [
    "jordan.lee@example.com"
  ],
  "removed_count": 1
}
```

### Reopen matter

Reopen a closed matter so it can be worked on again.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.

**Outputs**

- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "collaborator_account_ids": [
    "118273645019283746501"
  ],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "104738291038475610293",
  "state": "open",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Restore matter

Bring back a deleted matter. It comes back closed.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.

**Outputs**

- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "collaborator_account_ids": [
    "118273645019283746501"
  ],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "104738291038475610293",
  "state": "closed",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```

### Save search

Save a search in a matter, so it can be rerun and exported from Vault later.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Name (`name`, text, required): The saved search's name.
- Service (`corpus`, text): Which service to search. One of: `MAIL` (Gmail), `DRIVE`, `GROUPS`, `HANGOUTS_CHAT` (Chat), `CALENDAR`. Default: `MAIL`.
- Search in (`search_in`, text): Search the people listed, or everyone in your organization. One of: `accounts` (Specific people or groups), `organization` (Everyone in the organization). Default: `accounts`.
- Email addresses (`accounts`, list): Email addresses of the people (or, for Groups, the groups) to search. Only when Search in is Specific people or groups.
- Search terms (`search_terms`, text): Words and Vault search operators to narrow the search, such as `subject:contract from:jordan@example.com`. Leave empty for everything.
- From (`start_date`, date): Only include items from this day on. Leave empty for no start.
- To (`end_date`, date): Only include items up to and including this day. Leave empty for no end.
- Data to search (`data_scope`, text): Search all data, or only what is on hold in this matter. One of: `ALL_DATA` (All data), `HELD_DATA` (Only data on hold), `UNPROCESSED_DATA` (Only data not yet processed (Gmail only)). Default: `ALL_DATA`.
- Include drafts (`include_drafts`, true/false): Include Gmail drafts, which were never sent. On unless you turn it off. Only when Service is Gmail. Default: `true`.
- Include shared drives (`include_shared_drives`, true/false): Also search files in shared drives the people can access. On unless turned off. Only when Service is Drive. Default: `true`.
- Include Chat spaces (`include_chat_spaces`, true/false): Also cover messages in the Chat spaces the people are in. Only when Service is Chat. Default: `false`.

**Outputs**

- `accounts` (list): The email addresses it searches
- `created_at` (text): When it was saved
- `data_scope` (text): ALL_DATA, HELD_DATA or UNPROCESSED_DATA
- `end_date` (text): The last day it covers (YYYY-MM-DD)
- `matter_id` (text): The matter it is in
- `name` (text): The saved search's name
- `saved_query_id` (text): The saved search's ID
- `search_in` (text): accounts (the listed accounts) or organization (everyone)
- `search_terms` (text): Its search terms
- `service` (text): The service: MAIL (Gmail), DRIVE, GROUPS, HANGOUTS_CHAT (Chat) or CALENDAR
- `start_date` (text): The first day it covers (YYYY-MM-DD)

**Example output**

```json
{
  "accounts": [
    "jordan.lee@example.com"
  ],
  "created_at": "2026-10-21T09:05:02.331Z",
  "data_scope": "ALL_DATA",
  "end_date": "2026-09-30",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Contract emails, Q3",
  "saved_query_id": "9284710395",
  "search_in": "accounts",
  "search_terms": "subject:contract",
  "service": "MAIL",
  "start_date": "2026-07-01"
}
```

### Start export

Search a service and export what it finds, for download from Vault. Exports run in the background: 'Get export' tells you when one is ready.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Name (`name`, text, required): The export's name. Avoid the characters ~ ! $ ' ( ) , ; @ : / ?, which can stop it from downloading.
- Service (`corpus`, text): Which service to search. One of: `MAIL` (Gmail), `DRIVE`, `GROUPS`, `HANGOUTS_CHAT` (Chat), `CALENDAR`. Default: `MAIL`.
- Search in (`search_in`, text): Search the people listed, or everyone in your organization. One of: `accounts` (Specific people or groups), `organization` (Everyone in the organization). Default: `accounts`.
- Email addresses (`accounts`, list): Email addresses of the people (or, for Groups, the groups) to search. Only when Search in is Specific people or groups.
- Search terms (`search_terms`, text): Words and Vault search operators to narrow the search, such as `subject:contract from:jordan@example.com`. Leave empty for everything.
- From (`start_date`, date): Only include items from this day on. Leave empty for no start.
- To (`end_date`, date): Only include items up to and including this day. Leave empty for no end.
- Data to search (`data_scope`, text): Search all data, or only what is on hold in this matter. One of: `ALL_DATA` (All data), `HELD_DATA` (Only data on hold), `UNPROCESSED_DATA` (Only data not yet processed (Gmail only)). Default: `ALL_DATA`.
- Include drafts (`include_drafts`, true/false): Include Gmail drafts, which were never sent. On unless you turn it off. Only when Service is Gmail. Default: `true`.
- File format (`export_format`, text): The format of the exported messages or events. Only when Service is Gmail, Groups, Chat or Calendar. One of: `standard` (Standard (MBOX for email and chat, ICS for Calendar)), `PST` (PST (for Outlook)). Default: `standard`.
- Include shared drives (`include_shared_drives`, true/false): Also search files in shared drives the people can access. On unless turned off. Only when Service is Drive. Default: `true`.
- Include Chat spaces (`include_chat_spaces`, true/false): Also cover messages in the Chat spaces the people are in. Only when Service is Chat. Default: `false`.

**Outputs**

- `created_at` (text): When it was started
- `export_id` (text): The export's ID
- `files` (list): The export's files, once it is complete
- `items_exported` (number): How many of them have been exported so far
- `items_found` (number): How many messages or files the search found
- `matter_id` (text): The matter it is in
- `name` (text): The export's name
- `requester_email` (text): Email address of whoever started it
- `requester_name` (text): Name of whoever started it
- `search_terms` (text): The search terms it exported
- `service` (text): The service: MAIL (Gmail), DRIVE, GROUPS, HANGOUTS_CHAT (Chat) or CALENDAR
- `size_bytes` (number): The export's size in bytes
- `status` (text): in progress, completed or failed
- `url` (text): The matter's exports in Google Vault, to download from

**Example output**

```json
{
  "created_at": "2026-10-21T09:12:44.118Z",
  "export_id": "8cb7e9a1d2f34c05",
  "files": [],
  "items_exported": 0,
  "items_found": 0,
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Sales team email Q3",
  "requester_email": "counsel@example.com",
  "requester_name": "Riley Morgan",
  "search_terms": "subject:contract",
  "service": "MAIL",
  "size_bytes": 0,
  "status": "in progress",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d/exports"
}
```

### Update hold

Rename a hold, or change the search terms and dates of a Gmail or Groups hold. Fields left empty stay as they are.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- Hold (`hold_id`, text, required): The hold in that matter.
- New name (`name`, text): The hold's new name. Leave empty to keep it.
- Search terms (`search_terms`, text): New search terms (Gmail and Groups holds only). Leave empty to keep them.
- From (`start_date`, date): New first day covered (Gmail and Groups holds only). Leave empty to keep it.
- To (`end_date`, date): New last day covered (Gmail and Groups holds only). Leave empty to keep it.

**Outputs**

- `account_count` (number): How many people (or groups) are on hold
- `accounts` (list): The people (or groups) on hold
- `end_date` (text): The last day a Gmail or Groups hold covers (YYYY-MM-DD)
- `hold_id` (text): The hold's ID
- `include_chat_spaces` (true/false): Whether a Chat hold covers spaces too
- `include_shared_drives` (true/false): Whether a Drive hold covers shared drives too
- `matter_id` (text): The matter it is in
- `name` (text): The hold's name
- `org_unit_id` (text): The organizational unit on hold, for a hold made in Vault for a whole unit; empty otherwise
- `search_terms` (text): The search terms narrowing a Gmail or Groups hold
- `service` (text): The service: MAIL (Gmail), DRIVE, GROUPS, HANGOUTS_CHAT (Chat) or CALENDAR
- `start_date` (text): The first day a Gmail or Groups hold covers (YYYY-MM-DD)
- `updated_at` (text): When the hold last changed

**Example output**

```json
{
  "account_count": 1,
  "accounts": [
    {
      "account_id": "104738291038475610293",
      "email": "jordan.lee@example.com",
      "first_name": "Jordan",
      "held_since": "2026-10-20T15:04:11.402Z",
      "last_name": "Lee"
    }
  ],
  "end_date": "2026-09-30",
  "hold_id": "3f9d2k1m0q7xw",
  "include_chat_spaces": false,
  "include_shared_drives": false,
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Sales team email",
  "org_unit_id": "",
  "search_terms": "subject:contract",
  "service": "MAIL",
  "start_date": "2026-01-01",
  "updated_at": "2026-10-20T15:04:11.402Z"
}
```

### Update matter

Rename a matter or change its description. Fields left empty stay as they are.

**Inputs**

- Matter (`matter_id`, text, required): The Vault matter (case) to work in.
- New name (`name`, text): The matter's new name. Leave empty to keep it.
- New description (`description`, text): The new description. Leave empty to keep it.

**Outputs**

- `collaborator_account_ids` (list): Google account IDs of the people the matter is shared with
- `description` (text): The matter's description
- `matter_id` (text): The matter's ID. Use it with the other Vault steps.
- `name` (text): The matter's name
- `owner_account_id` (text): The owner's Google account ID (empty when Vault doesn't say, as on a matter just created)
- `state` (text): open, closed or deleted
- `url` (text): The matter in Google Vault

**Example output**

```json
{
  "collaborator_account_ids": [
    "118273645019283746501"
  ],
  "description": "Preservation for the Q3 contract dispute.",
  "matter_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "name": "Acme v. Example Corp",
  "owner_account_id": "104738291038475610293",
  "state": "open",
  "url": "https://vault.google.com/matter/a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
```
