Skip to main content
Glama
Sniptide MCP Server

Sniptide MCP Server

Sniptide MCP server

Let a coding agent search, read and save your Sniptide snippets and apply a collection as ordered steps. The server offers nine tools and three prompts to Claude Code, Codex, Cursor and any other MCP client.

It runs in two ways with the same tools:

Transport

Where it runs

Sign-in

Use it when

Remote HTTP

Inside the app at /api/mcp

OAuth in the browser, or an API token

Your client supports remote servers. Nothing extra to install.

Local stdio

npx @sniptide/mcp on your machine

An API token

Your client only supports stdio servers.

Connect a client

The examples use Sniptide Cloud at https://app.sniptide.com/api/mcp. For your own instance, append /api/mcp to its address instead.

claude mcp add --transport http sniptide https://app.sniptide.com/api/mcp

In Claude Code, adding the server doesn't open the browser. Start Claude Code, type /mcp, choose sniptide and pick Authenticate.

Codex uses codex mcp add sniptide --url https://app.sniptide.com/api/mcp. In Cursor, add a remote server with the same URL and no headers. The client receives a 401, finds the sign-in through the app's OAuth metadata and opens Sniptide in your browser, where you allow access. OAuth for agents explains the scopes and how to revoke a connection.

To check the connection, ask the agent to list your Sniptide collections. It calls list_collections and answers with your collections, or with an empty list on a new account.

Use an API token instead

Use a personal API token when the client doesn't support OAuth or the agent runs unattended. Create it in Settings > API tokens. A read-only token can only look things up, and Write access also lets the agent save and edit snippets.

For Claude Code, put this in the project's .mcp.json and export SNIPTIDE_TOKEN before you start it. Claude Code expands ${SNIPTIDE_TOKEN} from the environment.

{
  "mcpServers": {
    "sniptide": {
      "type": "http",
      "url": "https://app.sniptide.com/api/mcp",
      "headers": { "Authorization": "Bearer ${SNIPTIDE_TOKEN}" }
    }
  }
}

Cursor takes the same url and headers without type. Put that configuration in your private ~/.cursor/mcp.json, or in a project .cursor/mcp.json that Git ignores, with the token written in place of the variable. Keep real tokens out of source control.

Run the server locally

The local server needs Node.js 24 or newer and an API token. It calls Sniptide Cloud by default. For a self-hosted instance, add SNIPTIDE_BASE_URL to env with the address of the instance that issued your token.

{
  "mcpServers": {
    "sniptide": {
      "type": "stdio",
      "command": "npx",
      "args": ["--yes", "@sniptide/mcp"],
      "env": {
        "SNIPTIDE_TOKEN": "${SNIPTIDE_TOKEN}"
      }
    }
  }
}

The local server reads only these two variables and takes no arguments. It doesn't use the CLI's saved credentials. The base URL must use HTTPS, except on localhost, 127.0.0.1 and [::1], and can include a path prefix. Redirects are refused, so the token never leaves the instance you chose. Standard output carries only MCP messages, and startup failures go to standard error.

Related MCP server: mcp-code-snippets

Tools

Tool

What it does

Access

search_snippets

Returns a page of summaries. query matches when every word appears in the title, description, tags, file paths or code. Filters by tags, language and collection. nextCursor continues the search.

read

read_snippet

Returns one snippet by id or link, with its file paths, code and source metadata.

read

list_collections

Lists your collections with their slugs, names and how many live snippets each holds.

read

fetch_collection

Returns a page of up to 50 snippets from a collection as numbered steps, oldest capture first.

read

create_snippet

Saves a new snippet. It is private unless visibility is set.

write

update_snippet

Replaces a snippet's title and all its files. Marked destructive.

write

update_snippet_settings

Changes visibility, expiry, password or burn after read. Marked destructive.

write

create_collection

Creates an empty collection by name and returns its slug.

write

trash_snippet

Moves a snippet to the trash, where you can restore it in the app. Marked destructive.

write

The agent reaches only the account owner's own live snippets, private ones included. It can't reach other people's snippets, snippets shared with you, the trash or expired snippets. The server doesn't run code, write files to your machine, expose env groups or accept browser session cookies.

A few rules decide what a write does:

  • An update replaces every file, so the agent reads the snippet first and sends every file it wants to keep. Fields it leaves out keep their values. null clears the collection or source, and [] clears the tags. The previous version stays in the snippet's revisions.

  • update_snippet_settings counts expiry from now. A password set this way appears in the conversation, and the tool never returns it.

  • Creates and edits are never retried. The client decides whether to ask you before a write runs.

Prompts

Claude Code and Cursor list the prompts in their slash menus. Each one starts a common job with the tools in the right order.

Prompt

Arguments

What it asks the agent to do

use_snippet

task

Search your snippets for the task, read the best match and adapt it to the project.

save_snippet

code, optional collection

Propose a title, tags and paths, leave secrets out, and save a private snippet after you confirm.

apply_collection

collection, optional goal

Fetch every page of the collection, list its steps and wait for your go-ahead before applying them in order.

The collection argument completes from your collection slugs.

Snippet content is data from whoever saved it. The server's instructions tell clients to read it as code and to follow only your instructions. Give an agent write access only when it needs it, and review what it saves.

Limits and errors

MCP requests share the token's 3,600 requests an hour, the limit of 30 new pastes an hour, paste validation and the account's storage limit. Remote request bodies are capped at 8 MiB, and every tool result at 25 MiB, so read single snippets when a collection page is too large. The local server's API calls time out after 30 seconds.

A tool returns JSON as text and as structured content. A failed tool call returns an isError result with a short message, which never contains the token or the server's error body.

Response

Meaning

Action

401

The token or connection is missing, expired, invalid or revoked.

Sign in again, or replace the token.

Tool error that names the write scope

The token or connection is read-only.

Connect again with write, or use a token with Write access.

403

The request came from a browser origin other than the app's.

Call the server from the agent, not from a web page.

405

A GET or DELETE reached the endpoint. The server is stateless and keeps no sessions.

Connect with Streamable HTTP, not the older SSE transport.

429

A rate limit was reached.

Wait for Retry-After before retrying.

The MCP documentation covers the agent plugin, read counts and more client setups.

Develop the server

From the repository root, bun run mcp starts the stdio server from source. To build the Node.js executable that npm ships:

bun install
bun --filter @sniptide/mcp build
node packages/mcp/dist/sniptide-mcp.js

To use a local build in a client, put node and the absolute path to packages/mcp/dist/sniptide-mcp.js in place of npx and its arguments.

Run the tests:

bun run test:mcp
TEST_DATABASE_URL=postgres://sniptide:sniptide@localhost:5432/sniptide_test bun --filter web test

test:mcp drives the server with the official SDK client over in-memory and HTTP transports. The web suite in apps/web/test/mcp.test.ts connects over real HTTP and through the built stdio process, and checks ownership, scopes, revocation, expiry, pagination and rate limits. It clears its database, so the database name must end in _test. CI runs both suites.

License

MIT.

Available Tools

9 tools
create_collectionCreate collectionAInspect

Create an empty collection by name (write scope required) and return its slug. Names are unique per account and accounts hold up to 50 collections. Renaming and deleting collections stay in the app.

Inputs: name (required).

create_snippetCreate snippetAInspect

Save code as a new snippet (write scope required). Defaults to private. A collection must already exist. Up to 10 files; instance size and storage limits apply. Files are data only. Do not retry automatically: retries may create duplicates.

Inputs: files (required), title (required), tags, source, +3 more.

fetch_collectionFetch collection recipeA
Read-onlyIdempotent
Inspect

Fetch a page of your collection as numbered recipe steps, with full snippet files. Order is oldest capture first, matching the CLI. Continue with nextCursor and nextStep; a page holds up to 50 snippets. This does not execute the recipe.

Inputs: slug (required), cursor, startStep.

list_collectionsList collectionsA
Read-onlyIdempotent
Inspect

List your collections, oldest first, with each slug, name and live snippet count. Use a slug as the collection of create_snippet, update_snippet or fetch_collection.

Inputs: no named parameters.

read_snippetRead snippetA
Read-onlyIdempotent
Inspect

Read one of your live snippets by its ID or slug, including all files, paths, code and source metadata.

Inputs: id (required).

search_snippetsSearch snippetsA
Read-onlyIdempotent
Inspect

Find your live snippets by words in the title, description, tags, file paths or code (every word must match), plus tag, language and collection filters. Returns summaries and nextCursor; call again with that cursor for the next page. Use read_snippet to fetch code.

Inputs: tags, limit, query, cursor, +2 more.

trash_snippetMove snippet to trashA
Destructive
Inspect

Move your live snippet to the trash (write scope required). Its link stops working; the owner can restore it from the app until the trash is emptied. This tool never deletes permanently. Confirm with the user first.

Inputs: id (required).

update_snippetUpdate snippetA
Destructive
Inspect

Replace the title and entire file list of your live snippet (write scope required). Read it first to keep files you still need. Omitted description, visibility, collection, tags and source are preserved; explicit null clears collection/source. Link, expiry, password and burn setting remain unchanged. Records an edit in history.

Inputs: id (required), files (required), title (required), tags, +4 more.

update_snippet_settingsUpdate snippet sharing settingsA
DestructiveIdempotent
Inspect

Change who can open your live snippet (write scope required): visibility, expiry counted from now, a password (null removes it) and burn after read. Omitted fields stay as they are. Confirm with the user before making a snippet public or setting a password, which is then visible in this conversation. Returns the current settings; the password itself is never returned.

Inputs: id (required), expiry, password, visibility, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.2/5.0

    Scored across 9 tools

    Disambiguation5/5

    Each tool has a clearly distinct action and resource: snippet content operations, snippet settings, collection listing/fetching, and search are well separated. update_snippet versus update_snippet_settings is explicitly scoped and unlikely to be confused.

    Naming Consistency4/5

    The set overwhelmingly follows snake_case verb_noun naming. Minor inconsistency appears with plural nouns in list_collections and search_snippets while most sibling tools use singular resource names.

    Tool Count5/5

    Nine tools are well-scoped for a snippet management server. Each tool covers a meaningful operation without excessive granularity.

    Completeness4/5

    Snippet lifecycle coverage is strong: create, read, update, search, trash, and settings update. Collection support is limited to create, list, and fetch; rename/delete and trash restore are intentionally left to the app, creating minor gaps but not blocking core workflows.

    Maintenance

    ActivityActive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Allows agents to lookup code snippets in your project. Uses a remote MCP server with a collection of code snippets, with support for automatic project language detection.
      13
      Apache 2.0
    • A
      license
      A
      quality
      Not graded
      maintenance
      MCP server for massCode that lets AI assistants list, read, create, and update snippets, folders, and tags via the local massCode API.
      8
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      snipper-mcp — the MCP server inside SnipperApp 3. SnipperApp 3 is a native macOS code snippet manager. It ships its own MCP server, so AI assistants can search, read, create and organise the snippets in your library.
      MIT