Tulip Logo IconTulip
Google Provider

Setup

Set up the Google provider by preparing credentials, scopes, and server procedures.

Required pieces

  • Google API credentials
  • the correct Drive scopes for your product
  • a GoogleDrive server implementation
  • a contract implementation created from googleDriveRouterContract
  • client provider and view components

Most products also need an application-level decision about what namespace means. In the Google provider, namespace is still the canonical root from the app's point of view even though Google has its own drive and parent identifiers.

Main entrypoints

import { googleDriveRouterContract } from "@tulip-systems/drive/google/server";
import { GoogleDriveProvider } from "@tulip-systems/drive/google/client";
import { implement } from "@orpc/server";
import { RPCContext } from "@tulip-systems/core/router/server";
const googleDriveProcedure = implement(googleDriveRouterContract)
  .$context<RPCContext<DatabaseSchema, AuthServerOptions>>()
  .use(sessionMiddleware);

Provider shape

GoogleDriveProvider is intentionally smaller than the local provider. It focuses on:

  • permission gating
  • selection state
  • view mode state
  • drag and drop wrapper
  • namespace and meta context

It does not expose the local upload-zone surface because the upload model is different.

On this page