BigQuery DTS MCP server provides tools to interact with BigQuery DTS

A [Model Context Protocol (MCP) server](https://modelcontextprotocol.io/docs/learn/server-concepts) acts as a proxy between an external service that provides context, data, or capabilities to a Large Language Model (LLM) or AI application. MCP servers connect AI applications to external systems such as databases and web services, translating their responses into a format that the AI application can understand.

### Server Setup


You must [enable MCP servers](https://docs.cloud.google.com/mcp/enable-disable-mcp-servers) and [set up authentication](https://docs.cloud.google.com/mcp/authenticate-mcp) before use. For more information about using Google and Google Cloud remote MCP servers, see [Google Cloud MCP servers overview](https://docs.cloud.google.com/mcp/overview).

### Server Endpoints

An MCP service endpoint is the network address and communication interface (usually a URL) of the MCP server that an AI application (the Host for the MCP client) uses to establish a secure, standardized connection. It is the point of contact for the LLM to request context, call a tool, or access a resource.

The BigQuery Data Transfer API MCP server has the following global MCP endpoint:

- https://bigquerydatatransfer.googleapis.com/mcp

## MCP Tools

An [MCP tool](https://modelcontextprotocol.io/legacy/concepts/tools) is a function or executable capability that an MCP server exposes to a LLM or AI application to perform an action in the real world.

### Tools

The bigquerydatatransfer.googleapis.com MCP server has the following tools:

| MCP Tools ||
|---|---|
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/list_data_sources` | List all the data sources that the project has access to. The following example shows a MCP call to list all data sources in the project `myproject` in the location `myregion`. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. `list_data_sources(project_id="myproject", location="myregion")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/get_data_source` | Get details about a data source. |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/create_transfer_config` | Create a transfer configuration. To create a transfer configuration, do the following: - Provide the `required_fields`. Parameters allowed for Secret Manager must be set with Secret Manager. Plaintext is strictly disallowed in requests. - Specify how often you want your transfer to run by specifying `schedule_options` - Provide the `optional_fields`. - If you want to use a service account to create this transfer, provide a `service_account_name`. If the request fails due to missing valid credentials, do the following: \* Find your `client_id` and `data_source_scopes` from your data source definition. \* Authorize your data source by navigating to the following link: https://bigquery.cloud.google.com/datatransfer/oauthz/auth?redirect_uri=urn:ietf:wg:oauth:2.0:oob&response_type=version_info&client_id=CLIENT_ID&scope=DATA_SOURCE_1%20DATA_SOURCE_2 - Provide the `version_info`. |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/update_transfer_config` | Update a transfer configuration. - When updating params, parameters allowed for Secret Manager must be set with Secret Manager. Plaintext is strictly disallowed in requests. The following example shows a MCP call to update a transfer configuration named `transfer_config_id` in the project `myproject` in the location `myregion`. `update_transfer_config(data_source=GOOGLE_ADS, project_id="myproject", location="myregion", transfer_config_id="mytransferconfig", display_name="Updated Name")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/delete_transfer_config` | Delete a transfer configuration. The following example shows a MCP call to delete a transfer configuration by its resource name. `delete_transfer_config(name="projects/myproject/locations/myregion/transferConfigs/mytransferconfig")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/get_transfer_config` | Get details about a transfer config. The following example shows a MCP call to get details about a transfer configuration named `transfer_config_id` in the project `myproject` in the location `myregion`. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. `get_transfer_config(project_id="myproject", location="myregion", transfer_config_id="mytransferconfig")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/list_transfer_configs` | List all transfer configurations for a project. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. `list_transfer_configs(project_id="myproject", location="myregion")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/start_manual_transfer_runs` | Start manual transfer runs for a transfer config. The following example shows a MCP call to start manual transfer runs for a transfer configuration named `transfer_config_id` in the project `myproject` in the location `myregion`. If the transfer configuration was a manual transfer without a schedule, then request for a single run date. Otherwise ask for either a run date or run date range. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. `start_manual_transfer_runs(project_id="myproject", location="myregion", transfer_config_id="mytransferconfig", run_date="2024-01-01", run_date_range=("2024-01-01", "2024-01-02"))` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/list_transfer_runs` | List all the transfer runs for a transfer config. The following example shows a MCP call to list all transfer runs for a transfer configuration named `transfer_config_id` in the project `myproject` in the location `myregion`. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. `list_transfer_runs(project_id="myproject", location="myregion", transfer_config_id="mytransferconfig")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/get_transfer_run` | Get details about a transfer run. The following example shows a MCP call to get details about a transfer run named `transfer_run_id` in the project `myproject` in the location `myregion`. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. `get_transfer_run(project_id="myproject", location="myregion", transfer_config_id="mytransferconfig", transfer_run_id="mytransferrun")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/delete_transfer_run` | Delete a transfer run. The following example shows an MCP call to delete a transfer run by its resource name. `delete_transfer_run(name="projects/myproject/locations/myregion/transferConfigs/mytransferconfig/runs/mytransferrun")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/list_transfer_logs` | List transfer logs for a transfer run by its resource name. The following example shows a MCP call to list transfer logs for a transfer run. `list_transfer_logs(parent="projects/myproject/locations/myregion/transferConfigs/mytransferconfig/runs/mytransferrun")` |
| `https://docs.cloud.google.com/bigquery/docs/reference/datatransfer/mcp/tools_list/check_valid_creds` | Check for valid credentials for a data source. The following example shows a MCP call to check for valid credentials for a data source with the ID `data_source_id` in the project `myproject` in the location `myregion`. If the location isn't explicitly specified, and it can't be determined from the resources in the request, then the [default location](https://docs.cloud.google.com/bigquery/docs/locations#default_location) is used. If the default location isn't set, then the job runs in the `US` multi-region. If `has_valid_creds` is true, then the credentials are valid. Otherwise, the credentials are not valid. `check_valid_creds(project_id="myproject", location="myregion", data_source_id="mydatasource")` |

### Get MCP tool specifications


To get the MCP tool specifications for all tools in an MCP server, use the `tools/list` method. The following example demonstrates how to use `curl` to list all tools and their specifications currently available within the MCP server.

| Curl Request |
|---|
| ```bash curl --location 'https://bigquerydatatransfer.googleapis.com/mcp' \ --header 'content-type: application/json' \ --header 'accept: application/json, text/event-stream' \ --data '{ "method": "tools/list", "jsonrpc": "2.0", "id": 1 }' ``` |