Skip to content

Commit 936cb7d

Browse files
committed
Sync open source content 🐝 (from f58726cbcef363def3a18443a16a24dfe32e5636)
1 parent fb55a28 commit 936cb7d

File tree

2 files changed

+42
-60
lines changed

2 files changed

+42
-60
lines changed

docs/gram/introduction.md

Lines changed: 42 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,95 +1,77 @@
11
---
22
title: Introducing Gram 👋
3-
description: Gram effortlessly turns API specifications and code into LLM-ready tools, generating optimized tool definitions from OpenAPI documents and Gram Functions for powerful agentic workflows.
3+
description: Gram is the complete MCP cloud. Create and curate high quality agentic tools. Start with your APIs or from scratch with easy to define TypeScript functions. Deploy and host your MCP servers in minutes - secure, authenticated and ready to scale usage.
44
sidebar:
55
order: 0
66
---
77

8-
**[Gram](/product/gram)** is the fastest way to build a production-ready MCP server.
8+
![Gram banner](/assets/docs/gram/img/gram.gif)
99

10-
It is a platform that enables any company to **create, curate and host** agentic tools for your APIs.
10+
**[Gram](/product/gram)** is the complete MCP cloud. Create and curate high quality agentic tools. Deploy and host your MCP servers in minutes. Secure, complete with OAuth and ready to scale in for production usage.
1111

12-
## Why MCP Matters
12+
The [Model Context Protocol (MCP)](https://modelcontextprotocol.io/docs/getting-started/intro) provides a standardized way to connect LLMs to tools and data. Gram provides a serverless and production ready platform to build and host tools as MCP servers. Source tools through existing APIs or build from scratch using TypeScript functions. Mix and match tools in toolsets and expose them as MCP servers in minutes.
1313

14-
Agents mainly interact with APIs through the [Model Context Protocol (MCP)](/mcp). Since it was announced by Anthropic in November 2024, MCP has seen an unprecedented rate of adoption, quickly becoming the de facto standard. Companies like Microsoft, Google, OpenAI, and Cloudflare (among many others) have embraced it and offer MCP servers as a new way to interact with their existing APIs.
14+
```typescript filename="gram.ts"
15+
import { Gram } from "@gram-ai/functions";
16+
import * as z from "zod/mini";
1517

16-
But creating, deploying, hosting, and managing MCP servers remains confusing and challenging. Although MCP follows a familiar client-server model, it creates confusion about who should build, own, manage, and maintain the server. With APIs, it's always been clear. The producer (like Stripe) hosts the API, and the consumer (for example, an online shop) uses that API. With MCP, hosting models vary: Developers often "host" MCP servers on their own machines, or companies host them internally for team-wide access to third-party integrations.
18+
const gram = new Gram().tool({
19+
name: "greet",
20+
description: "Greet someone special",
21+
inputSchema: { name: z.string() },
22+
async execute(ctx, input) {
23+
return ctx.text(`Hello, ${input.name}!`);
24+
},
25+
});
1726

18-
We think that companies will naturally gravitate to hosting and managing their own MCP servers, and we built Gram to make that easy.
19-
20-
## Why Gram?
27+
export default gram;
28+
```
2129

22-
To unlock the value of MCP companies need to be able to leverage existing APIs and products capabilities. Gram is aimed to give you a comprehensive experience around MCP without the need to learn a new language or framework. APIs alone are often not enough to build high quality tools but they can be a great starting point to build on.
30+
Use Gram to build out MCP servers for your product, power chat expereinces in your product or surface the right data to AI agents to automate workflows.
2331

24-
To realise this vision Gram is built with the following principles:
25-
26-
🔹 Simplicity: Easy to use, easy to understand, easy to maintain.
27-
28-
🔹 Performant: Fast infrastructure that you can rely on.
29-
30-
🔹 Secure: Built in security and best practices for working with agentic tools.
31-
32-
🔹 Works with your stack: Helps you leverage existing APIs to bootstrap tools.
32+
## Why MCP?
3333

34-
Gram is made with love ❤️ and ⚒️ by our [team](/company).
34+
LLMs and Agents need access to context specific data to perform useful tasks. This data is often found behind an authenticated service, in a database or stored content. [Model Context Protocol (MCP)](https://modelcontextprotocol.io/docs/getting-started/intro) is the standard protocol for defining tools that AI can use to connect to external systems where this data may live.
3535

36-
### Create and curate tools with ease
36+
Since it was announced by Anthropic in November 2024, MCP has seen an unprecedented rate of adoption, quickly becoming the de facto standard. Companies like Microsoft, Google, OpenAI, and Cloudflare (among many others) have embraced it and offer MCP servers as a new way to interact with their products and APIs.
3737

38-
A great MCP server is not a 1:1 mapping to your REST API.
38+
But creating, deploying, hosting, and managing the lifecycle of MCP servers remains confusing and challenging. Although MCP follows a familiar client-server model, it creates confusion about who should build, own, manage, and maintain the server. With APIs, it's always been clear. The producer (like Stripe) hosts the API, and the consumer (for example, an online shop) uses that API. With MCP, hosting models vary: Developers often "host" MCP servers on their own machines, or companies host them internally for team-wide access to internal apis or third-party integrations..
3939

40-
Existing REST APIs are a starting point, but to create a functional MCP server, you need to perform additional steps:
41-
42-
1. **Scope tools** - Presented with the list of all the operations in an API, LLMs struggle to choose the right tool to accomplish a job. This is due to their limited context window. To improve performance, scope the API operations to only include the most relevant ones. Less is more when it comes to MCP. Gram gives you the ability to create toolsets to scope and slice up your API specs.
43-
2. **Add Context** - A user reading an API reference is coming in with some implicit context about the relevant business domain. The same is not true of an LLM examining a list of tools on an MCP server. It is up to the MCP server maintainer to make sure the server provides the LLM with the context it needs. Adding rich tool descriptions, prompts, and examples, greatly improves the performance of the MCP server. Focus on the _when_ and _why_ of the tool. Gram gives you the ability to add additional context to your tools.
44-
3. **Define Custom Tools** - REST APIs are resource-oriented: create a company, update the contact field, etc. MCP servers work best when they're workflow-based: "summarize recent channel activity". Gram gives you the ability to distribute custom tools that wrap multiple API endpoints and additional steps as a single tool.
45-
46-
Gram makes tool creation & curation easy. [Tools](/docs/gram/concepts/tool-definitions) are bootstrapped from [sources](/docs/gram/concepts/tool-sources) like OpenAPI documents (which provide API paths, input schemas, security schemes, and descriptions) or Gram Functions (custom Node.js code). Once a source is uploaded to the Gram platform the day 0 workflow looks like this:
47-
48-
* Remove unnecessary tools from your toolset
49-
* Combine tools into use case specific toolsets.
50-
* Fine-tune individual tools with better descriptions and custom prompts
51-
* Create custom toolsets to map a workflow
52-
* Test and iterate on tools in the LLM playground
53-
54-
All the changes made to a toolset are reflected in a MCP server instantly.
40+
We think that companies will naturally gravitate to hosting and managing their own MCP servers, and we built Gram to make that easy.
5541

56-
### Going live: Distributing MCP servers
42+
## Why Gram?
5743

58-
![MCP server models](/assets/docs/gram/img/blog/the-easiest-way-to-host-mcp-servers/managed-mcp.png)
44+
Gram is aimed to give you a comprehensive experience and unlock the value of MCP without the need to build complete servers.
5945

60-
People use MCP in various ways, broadly categorized as follows:
46+
To realise this vision Gram is built with the following principles:
6147

62-
* **Local:** A developer downloads an MCP server to their developer machine, and configures an MCP client, like Claude or Cursor, to use the tools provided in that server.
63-
* **Remote:** A system administrator downloads an MCP server to a company-accessible server. Anyone at the company can configure their MCP client to interact with a company-accessible tool via this server.
64-
* **Managed:** The API **producer** hosts and manages the MCP server, allowing any of its customers to configure their MCP clients to connect to the server and use the API.
48+
🔹 Simplicity: Easy to use, easy to understand, easy to maintain.
6549

66-
Currently, MCP servers are mostly **local** (hosted by API consumers), which creates friction through replicated setup work and lack of centralized control. We believe the industry will evolve toward **Managed** MCP servers, where API producers handle hosting, security, and enterprise features.
50+
🔹 Performant and Managed: Fast and serverless infrastructure that you can rely on.
6751

68-
### Gram's managed hosting approach
52+
🔹 Secure: Built in security and best practices for working with agentic tools.
6953

70-
Once tools have been curated, the MCP server is ready to deploy. Every toolset automatically comes with an MCP server hosted at a Gram managed URL. Custom domains can be linked to create a branded, 1st party MCP server at `mcp.{{your-domain}}.com/{{server-name}}`
54+
🔹 Works with your stack: Helps you leverage existing APIs to bootstrap tools.
7155

72-
Gram provides completely [managed hosting of MCP servers](/docs/gram/getting-started) or self-hosted.
56+
Gram is made with love ❤️ and ⚒️ by the team at [Speakeasy](/company).
7357

74-
<!-- ## LLM-Friendly Docs
58+
## LLM-Friendly Docs
7559

7660
This documentation site is also available in [llms.txt](https://llmstxt.org/) format, which is a simple markdown standard that LLMs can consume easily.
7761

7862
The `llms.txt` references two ways to access the LLM-friendly documentation:
79-
* `llms-small.txt` is an abridged developer documentation for the site.
80-
* `llms-full.txt` contains the entire documentation. Note this may exceed the context window of your LLM.
8163

82-
In addition, any page can be accessed as markdown by appending .md to the URL. For example, this page would become `https://docs.getgram.ai/introduction.md` , which you can view [here](https://docs.getgram.ai/introduction.md).
64+
- `llms-small.txt` is an abridged developer documentation for the site.
65+
- `llms-full.txt` contains the entire documentation. Note this may exceed the context window of your LLM.
8366

84-
Finally, you can copy the contents of any page as markdown by pressing “Cmd+C” (or “Ctrl+C” on Windows) on your keyboard. -->
67+
In addition, any page can be copied into markdown or opened into popular LLM chat clients like ChatGPT or Claude by using the drop down at the top of the right hand nav bar.
8568

8669
## Further Reading
8770

88-
* [Quickstart](/docs/gram/getting-started)
89-
* [Creating your first toolset](/docs/gram/build-mcp/create-default-toolset)
90-
* [Curating custom toolsets](/docs/gram/build-mcp/custom-toolsets)
91-
* [Deploying an MCP server](/docs/gram/host-mcp/deploy-mcp-server)
92-
* [OpenAPI concepts](/docs/gram/concepts/tool-sources)
93-
* [Tool definitions](/docs/gram/concepts/tool-definitions)
94-
* [Toolsets](/docs/gram/concepts/toolsets)
95-
* [Environment variables](/docs/gram/concepts/environments)
71+
- [Building tools in TypeScript using Gram Functions](/docs/gram/typescript)
72+
- [Getting started with Gram using an API spec](/docs/gram/openapi)
73+
- [Bring an existing MCP server to Gram](/docs/gram/gram-functions/mcp-sdk)
74+
- [Advanced tool curation](/docs/advanced/art-of-tool-curation)
75+
- [For resources on MCP see our MCP hub](/mcp)
76+
- [Adding OAuth to your MCP server](/docs/gram/host-mcp/adding-oauth)
77+
- [CLI reference](/docs/gram/command-line/installation)
4 MB
Loading

0 commit comments

Comments
 (0)