Connect Gemini Enterprise
Create a Gemini Enterprise app in Google Cloud, add Stensul as an MCP data store with OAuth and PKCE, add your users, and sign in.
Gemini works differently from other hosts. You don’t add a connector inside the Gemini app: a Google Cloud (GCP) admin creates a Gemini Enterprise app in Google Cloud, adds Stensul to it as an MCP server, and gives people access. They then use Gemini, connected to Stensul, from that app’s link.
Before you start
| Who | What they need |
|---|---|
| Stensul admin | Admin access, the external API enabled, and the access_admin_api_connections permission (ask your customer success manager). |
| GCP admin | A Google Cloud project where they can enable the Gemini Enterprise app product, create apps and manage IAM roles. A Gemini Enterprise Plus license is required for the MCP to work as expected. The product isn’t free and adds to your Google Cloud costs. |
| Everyone else | A Stensul login, and access to the Gemini Enterprise app (step 4). |
1. Create the API connection in Stensul
-
Go to Admin > Settings > API connections and click Add connection.
-
Set Authorization Type to Authorization Code. Name it, for example
mcp-gemini. -
Add the redirect URI:
https://mcp.stensul.com/<your-instance>/oauth/callback -
Enable PKCE (Public).
-
Select the scopes your team needs. The first four cover drafting. The last three turn on the image gallery and audience versions; a tool whose scope is missing returns a 403. See scopes.
libraries:read: read librariesemails:read: read emailsemails:write: write emailsimages:write: upload images (labeled Write images)dam:read: browse the image gallery (labeled Read Dam images)dynamic-content:read: read segment setsdynamic-content:write: apply segment sets and write segment content
The list shows other scopes too, such as
capabilities:read,modules:write,users:readandroles:read. Leave them unchecked: the MCP doesn’t use them. -
Save. Copy the Client ID from the Credentials dialog, then click I’m finished. There is no secret: with PKCE, the Client ID is all Gemini needs.
2. Enable the Gemini Enterprise app product
Done once, by a GCP admin. In Google Cloud, create a project or pick an existing one, and enable the Gemini Enterprise app product in it. Gemini Enterprise is Google Cloud’s product for building AI agents that work with your organization’s data and systems.
3. Create the app and add Stensul
- Click Create app and enter the app name and location. Selecting the app shows its link, where people will use Gemini connected to Stensul.
- Go to Connected data stores > New data store.
- Select Add MCP server and enter:
| Field | Value |
|---|---|
| Authentication method | OAuth 2.0 |
| MCP Server URL | https://mcp.stensul.com/<your-instance>/mcp |
| Authorization URL | https://mcp.stensul.com/<your-instance>/oauth/authorize |
| Access Token URL | https://mcp.stensul.com/<your-instance>/oauth/token |
| OAuth2 Client ID | From step 1 |
| Enable PKCE Support | Enabled |
- Click Verify OAuth, complete the Stensul sign-in and click Continue.
- Add a description for the MCP server and these recommended instructions:
You build and edit Stensul emails using the MCP for stensul.com.
Always read the tool description and resources with instruction to understand how to use them. Before responding, if the user ask it complete the entire email creation process and update the content.
- Enter a name for the data connector and click Create.
- Go to the Actions section, reload the custom actions and approve the sign-in.
- Select all the actions and enable them.
The app’s Overview section shows the link people use to reach Gemini connected to Stensul.
4. Add users and roles
- In the app, go to Manage users > Add users and add each person’s email address.
- In the project’s IAM settings, give those people the Gemini Enterprise User role.
5. Sign in and draft an email
Each person opens the app’s link, goes to Connectors, enables the Stensul connector and completes the Stensul sign-in. Then:
Using Stensul, create a draft email in the <library name> library inviting
customers to our winter webinar. Start from the most relevant approved
template, write real copy for every editable text and button, and give me the
edit link.
You’re done when Gemini returns an edit link that opens the draft in Stensul.
If something goes wrong
| What you see | Fix |
|---|---|
| The sign-in screen has no Approve button | You aren’t signed in to Stensul. Sign in to Stensul, then retry the sign-in from Gemini |
| Redirect error at sign-in | The redirect URI must be exactly https://mcp.stensul.com/<your-instance>/oauth/callback |
| Gemini can’t reach Stensul | Check the MCP Server URL is https://mcp.stensul.com/<your-instance>/mcp, with your instance name and a single slash before mcp |
| No API connections page in Stensul | The external API is off, or you lack access_admin_api_connections. Ask your Stensul customer success manager |