Skip to main content

Build an OAuth app for Grain

Learn how OAuth apps connect to Grain, when to build one, and what to use instead.

OAuth lets people connect your product to their Grain account by signing in and approving it, with no API tokens to copy and paste. If you're building a tool that other Grain users will connect to, it's the safest way to give each person's account access to your app. The step-by-step setup lives in the OAuth2 Flow reference on developers.grain.com.


What an OAuth app does

An OAuth app is any product that asks Grain users for permission to access their meeting data. From the user's side, connecting takes a few clicks:

  1. They click a connect button in your product, such as 'Connect Grain'.

  2. They sign in to Grain, if they aren't already.

  3. Grain shows an approval screen with your app's name and what it will be able to access.

  4. They approve, and Grain sends them back to your product, connected.

From then on, your app can read and act on that person's Grain data through the API, within the access they approved. The connection stays active until the user or a workspace admin disconnects it.

You don't need to register your app with Grain or request credentials first. Grain supports Client ID Metadata Documents (CIMD), which means your app describes itself in a small file you host on your own domain. Grain reads that file the first time someone connects. See the Client ID Metadata Document reference for what the file needs to include.


Is an OAuth app the right fit?

Build an OAuth app when other Grain users will connect their accounts to something you make. Good use cases include:

  • Products and integrations: a CRM, sales tool, or project management app that pulls in meeting notes, transcripts, or clips for its users.

  • AI agents and assistants: a tool that reads a user's meetings to answer questions, write follow-ups, or run workflows on their behalf.

  • Automation platforms: a service that lets its customers trigger workflows when something happens in Grain.

An OAuth app is probably more than you need if:

  • You only want to automate your own work.

  • You're an admin connecting your own workspace to an internal tool.

  • You want to use Grain inside Claude, ChatGPT, or another AI tool that already supports Grain.

If one of these describes you, use one of the alternatives below instead.


Alternatives to an OAuth app

Each of these gives you access to Grain data without building a sign-in flow:

  • Personal Access Token: for your own scripts and tools. It gives the same access as your account and doesn't expire until you revoke it. See Grain API for how to create one.

  • Workspace Access Token: for admins connecting their own workspace to an internal tool, such as a data warehouse or reporting dashboard. It can access every recording in the workspace. See Grain API for how to create one and which plans include it.

  • Grain MCP: for using your meetings inside Claude, ChatGPT, and other AI tools without writing any code. See Grain MCP.

  • Zapier: for no-code automations between Grain and other apps. See Zapier.

Note: Tokens are tied to the person or workspace that created them. If other people will use your tool with their own Grain accounts, build an OAuth app instead of asking them to share tokens.


What your app can access

When your app sends someone to Grain to connect, it asks for one of two levels of access:

  • Personal access: the same access as the person who approves your app. They can only share data they can already see in Grain. Any Grain user can approve it, and it's the default.

  • Workspace access: full access to the person's workspace. Your app can read every recording, edit recordings, clips, and playlists, change who they're shared with, upload recordings, and set up webhooks for the whole workspace.

Because workspace access is so broad, it has extra requirements:

  • Your app must be verified by Grain.

  • The person approving must be a workspace admin.

  • The workspace's plan must include Workspace API. See grain.com/pricing for which plans include it.

Note: To request verification for your app, contact Grain Support.


Connect AI agents through Grain MCP

If you're building an AI agent or MCP client, the same OAuth setup also connects it to the Grain MCP server, so your agent can search and work with a user's meetings. Many AI tools, including Claude and ChatGPT Codex, already connect to Grain this way.

Note: The Grain MCP server only works with personal access. Workspace access can't be used for MCP connections.


How users and admins stay in control

Nobody's data is shared until they approve your app on Grain's approval screen, which shows your app's name and what it's asking for.

Workspace admins can see every app their members have connected and disconnect any of them. Go to the Grain API settings and find the 'Member API access' section.

Disconnecting an app also removes any webhooks it set up for that member. To reconnect, the member has to approve the app again.

Members can disconnect apps they connected themselves:

  1. Go to 'Account settings' > 'Integrations'.

  2. Open the type of connection: OAuth, MCP, or API.

  3. Find the app and click 'Revoke' or the trash can icon.


Get started

When you're ready to build, the developer docs cover each step in detail:

  1. Host a metadata document that describes your app. See the Client ID Metadata Document reference.

  2. Add a connect button that sends users to Grain's approval screen, then exchange their approval for access. See the OAuth2 Flow reference.

  3. Call the API with the access you receive, and refresh it when it expires. See Endpoints.


FAQ

Do I need to contact Grain to get a client ID or secret? No. Your app identifies itself with the metadata document you host. Grain registers it automatically the first time someone connects.

I already have a client ID and secret from Grain. Do I need to switch? No. Client IDs and secrets will continue to work.

Does my workspace need a paid plan to build an OAuth app? No. Any Grain user can approve personal access to your app. Workspace access depends on the plan of the workspace being connected, not yours.

Does my app need to be verified by Grain? Only if it asks for workspace access. Apps that use personal access work without verification.

Why does the approval screen show my domain instead of my app's name? Your metadata document doesn't include a name for your app. Add one, and Grain shows it the next time it reads the file. See the Client ID Metadata Document reference.

Can users see what my app has access to? Yes. The approval screen lists what your app is asking for before anyone approves it, and workspace admins can review and disconnect connected apps at any time.

Did this answer your question?