Skip to content
English
  • There are no suggestions because the search field is empty.

How Do I Connect Dataslayer MCP to Gemini?

Connect Dataslayer MCP to Gemini and ask questions about your connected marketing data in natural language.

You can connect Dataslayer MCP to Gemini in two ways:

  • Gemini Enterprise through Google Cloud
  • Gemini CLI through an interactive terminal session

Choose the option that matches the way you use Gemini.

Before you start

You need:

  • An active Dataslayer account with MCP access.
  • At least one marketing data source connected in Dataslayer.
  • The Dataslayer MCP server URL:
https://agents.dataslayer.ai/mcp
  • Access to Gemini Enterprise or Gemini CLI.
  • OAuth authentication support in your Gemini setup.

Option 1: Connect Dataslayer MCP to Gemini Enterprise

Use this option if your organization uses Gemini Enterprise through Google Cloud.

Before you begin

Your Google Cloud administrator may need to:

  • Grant you the Discovery Engine Editor role.
  • Allow Custom MCP data stores through your organization policies.
  • Allow the domains used by the MCP server and OAuth endpoints.
  • Register Gemini Enterprise as an OAuth client application.

Use this redirect URL when configuring the OAuth application:

https://vertexaisearch.cloud.google.com/oauth-redirect

You will also need the OAuth values from your Dataslayer MCP OAuth setup. If Google Cloud asks you to register Gemini Enterprise as an OAuth client, follow the registration flow provided by Google Cloud.

Create the Gemini Enterprise connection

  1. Open the Google Cloud Console.
  2. Go to Gemini Enterprise.
  3. In the navigation menu, select Data stores.
  4. Click Create data store.
  5. Search for Custom MCP Server.
  6. Select Custom MCP Server and click Add MCP server.
  7. In Authentication settings, select OAuth 2.0.
  8. Enter the following values:
    • MCP Server URL: https://agents.dataslayer.ai/mcp
    • Authorization URL: Use the value from your Dataslayer MCP OAuth setup.
    • Token URL:  Use the value from your Dataslayer MCP OAuth setup.
    • Client ID:  Use the value from your Dataslayer MCP OAuth setup.
    • Client Secret:  Use the value from your Dataslayer MCP OAuth setup.
    • Scopes: Use the Dataslayer MCP scopes allowed by your OAuth application.
    • Add offline_access if refresh tokens are required.
  9. Enable PKCE if your OAuth application supports it.
  10. Click Verify Auth.
  11. Complete the remaining data store settings.
  12. Create the data store.
  13. Open the new data store and wait until its status is Active.
  14. Enable the Dataslayer MCP actions or tools you want Gemini Enterprise to use.
  15. Connect the data store to the Gemini Enterprise app used by your organization.

Gemini Enterprise uses the Streamable HTTP transport for custom MCP servers. Older SSE-only configurations are not supported.

Test the connection

Open Gemini Enterprise and ask a question such as:

Compare Google Ads and Meta Ads performance over the last 30 days.

If the connection is working, Gemini will use Dataslayer MCP to retrieve the requested data from your connected marketing sources.

Option 2: Connect Dataslayer MCP to Gemini CLI

Use this option if you use Gemini from the terminal and want to ask questions in an interactive Gemini session.

Add Dataslayer MCP with the CLI

Run:

gemini mcp add dataslayer https://agents.dataslayer.ai/mcp --transport http

This adds Dataslayer MCP as a remote HTTP MCP server.

Start Gemini CLI

Run:

gemini

Inside the Gemini session, check the MCP connection:

/mcp list

If authentication is required, start the OAuth flow with:

/mcp auth dataslayer

Complete the Dataslayer login in your browser and return to Gemini CLI.

Configure Dataslayer MCP manually

You can also add Dataslayer MCP to your Gemini CLI settings.json file:

{   "mcpServers": {     "dataslayer": {       "httpUrl": "https://agents.dataslayer.ai/mcp"     }   } }

After saving the file, restart Gemini CLI and run:

/mcp list

The Dataslayer MCP server should appear as connected.

Test the connection

Ask Gemini a question such as:

Which campaigns generated the highest ROAS last month?

You can then ask follow-up questions:

Compare those campaigns with the previous month.

Questions you can ask

Try questions such as:

Show me total spend, clicks and conversions by campaign for Google Ads.
Compare Meta Ads and Google Ads by ROAS for the last 90 days.
Which campaigns spent more than €5,000 and generated less than 2x ROAS?
Explain the difference between CTR and link CTR in my Meta Ads data.

Tips for better answers

For more accurate results:

  • Mention the marketing platform you want to use.
  • Specify the account if you have multiple accounts connected.
  • Include a date range.
  • Name the metrics and dimensions you need.
  • Start with a simple question before asking for a complex comparison.
  • Use follow-up questions to investigate the result further.

Troubleshooting

Dataslayer MCP does not appear in Gemini CLI

Restart Gemini CLI and run:

/mcp list

If the server is still missing, check that it was added to the correct settings.json file or add it again with:

gemini mcp add dataslayer https://agents.dataslayer.ai/mcp --transport http

OAuth authentication does not complete

Make sure that:

  • The Dataslayer MCP URL is exactly https://agents.dataslayer.ai/mcp.
  • The OAuth application uses the correct redirect URL.
  • The client ID, client secret and scopes are correct.
  • Your browser can open the authentication page.

Gemini Enterprise cannot create the data store

Ask your Google Cloud administrator to verify:

  • The Discovery Engine Editor role.
  • The organization policy for Custom MCP data stores.
  • The allowed egress domains.
  • The custom_mcp data source policy when required.

Gemini is connected but returns no data

Check that:

  • Your Dataslayer account has active marketing data sources.
  • The correct accounts are connected.
  • The requested date range contains data.
  • The relevant actions are enabled in Gemini Enterprise.
  • Your question specifies the platform, account or metric you want to use.

 

As always, please contact us via our live chat on our website or via email if you still have doubts or questions. We are happy to help!