How to integrate Mem0 MCP with Kimi Code

Connect Kimi Code to Mem0 MCP. Store meeting notes from today's call, export all project memories as csv, and more using natural language, with authentication handled for you.

Mem0 logoMem0
Api Key

Mem0 is an AI-powered note-taking and knowledge management platform. It helps you organize, search, and generate content from your personal knowledge base.

47 Tools

How to integrate Mem0 MCP with Kimi Code

Kimi Code is Moonshot AI's open-source coding agent, powered by Kimi K2.6. It runs in your terminal, reads and edits code, executes shell commands, and plans multi-step tasks, with native MCP support for extending it to outside tools.

In this guide, I will explain the easiest and most secure way to connect your Mem0 account to Kimi Code via Composio Connect, so it can store meeting notes from today's call, export all project memories as CSV, add new user to our team space, and more without ever putting your account credentials at risk.

For exact tool slugs and parameter tables, see the tool catalog in the Composio docs.

Also integrate Mem0 with

Why use Composio?

Composio provides:

  • Access to 1,700+ managed apps from a single MCP endpoint. This makes it convenient for agents to run cross-app workflows.
  • Managed OAuth. You do not have to worry about authentication and authorization flows for every app.
  • Programmatic tool calling. Allows LLMs to write code in a remote workbench to handle complex tool chaining. This reduces back-and-forth for frequent tool calls.
  • Large tool response handling outside the LLM context. This minimizes context bloat from large tool responses.
  • Dynamic just-in-time access to thousands of tools across hundreds of apps. Composio loads the tools your agent needs, so LLMs are not overwhelmed by tools they do not need.

Connect Mem0 to Kimi Code

Kimi Code is a TypeScript agent distributed through npm. It acts as an MCP client and reads server definitions from an mcp.json file, and it can also add and authenticate servers conversationally through /mcp-config. Composio is a remote HTTP server that authenticates with OAuth, so no API key is stored anywhere.

1. Install Kimi Code

The quickest way is the official install script, which requires no pre-installed Node.js and places the kimi executable on your PATH.

bash
# macOS or Linux
curl -fsSL https://code.kimi.com/kimi-code/install.sh | bash

# Windows PowerShell
irm https://code.kimi.com/kimi-code/install.ps1 | iex

# Confirm the installation
kimi --version

2. Log in

Start Kimi Code in your project directory, then sign in from the interactive UI:

bash
kimi

Run /login and choose Kimi Code OAuth using the device-code flow, or use a Moonshot API key.

3. Add Composio with /mcp-config

In current versions of Kimi Code, MCP servers are managed inside the app, not with a shell subcommand. From the interactive UI, run:

bash
/mcp-config
Kimi Code MCP config flow for adding the Composio MCP server

Tell it the server name and URL in plain language. For example:

Server name is Composio, and here is the server URL: https://connect.composio.dev/mcp

Kimi Code asks whether to add it globally, at ~/.kimi-code/mcp.json, or project-local for the current checkout, then writes the entry for you:

bash
{
  "mcpServers": {
    "Composio": {
      "url": "https://connect.composio.dev/mcp"
    }
  }
}

There is no transport field to set. Kimi Code infers HTTP from the url.

4. Restart the session

The new server is picked up on a fresh session, not the current one. Start a new session:

bash
/new

On the new session, Kimi Code detects that the server needs authorization and prompts you to run:

bash
/mcp-config login Composio

5. Authorize with OAuth

Run the command Kimi suggests:

bash
/mcp-config login composio

Kimi Code opens Composio's authorization page or surfaces a URL. Approve access, then return to the session. You should see confirmation that the Composio MCP server is connected.

Composio authorization page for Kimi Code MCP setup

Check the connection status any time with /mcp. Composio should appear as connected with its tools listed.

Kimi Code showing Composio connected after OAuth authorization

Connect your Mem0 account

Back in a Kimi Code session, ask the agent to connect to Mem0 or give it any Mem0-related task.

For example, ask it to:

  • "Store meeting notes from today's call"
  • "Export all project memories as CSV"
  • "Add new user to our team space"

It will prompt you to authenticate and authorize access to Mem0.

That is it. Composio tools are now available in Kimi Code, and your Mem0 account is ready to use.

Conclusion

You have successfully connected Mem0 to Kimi Code using Composio Connect. Your agent can now manage Mem0 from the terminal with natural language, without exposing credentials in prompts or local scripts.

Since the same Composio endpoint exposes 1,700+ apps, you can add Slack, Calendar, Linear, and more to the same server and chain them into cross-app workflows.

TOOLS

Supported Tools

Every Mem0 action and event your agent gets out of the box.

Add member to project

Adds an existing user to a project (identified by `project_id` within organization `org_id`), assigning a valid system role.

Add new memory records

Adds memory records from messages, optionally inferring structured content.

Add organization member

Adds a new member, who must be a registered user, to an organization, assigning them a specific role.

Create a new agent

Creates a new agent with a unique agent ID and a required name; additional metadata may be assigned by the system.

Create a new agent run

Creates a new agent run in the mem0.ai system.

Create a new application

Creates a new application with an application ID and name; ensure the app ID is unique to avoid potential errors or unintended updates.

Create a new organization entry

Creates a new organization entry using the provided name and returns its details.

Create a new user

Creates a new user with the specified unique user ID and optional metadata.

Create memory entry

Lists or searches existing memory entries using required nonempty filters and optional pagination.

Create project

Creates a new project with a given name within an organization that must already exist.

Create webhook

Creates a new webhook for a specific project to receive real-time notifications.

Delete an organization

Permanently deletes an existing organization identified by its unique ID.

Delete memory by id

Permanently deletes a specific memory by its unique ID; ensure the `memory_id` exists as this operation is irreversible.

Delete entity by type and id

Call to permanently and irreversibly hard-delete an existing entity (user, agent, app, or run) and all its associated data, using its type and ID.

Delete memories

Deletes all memories matching specified filter criteria.

Delete memory batch with uuids

Deletes a batch of up to 1000 existing memories, identified by their UUIDs, in a single API call.

Delete project

Permanently deletes a specific project and all its associated data from an organization; this action cannot be undone and requires the project to exist within the specified organization.

Delete project member

Removes an existing member, specified by email address, from a project, immediately revoking their project-specific access; the user is not removed from the organization.

Delete webhook

Deletes a webhook and stops receiving notifications for the specified webhook ID.

Export data based on filters

Creates a memory export job requiring organization and project IDs and at least one user, agent, app or run filter.

List organizations

Retrieves a list of organizations with their details, including IDs, names, ownership, members and plan information.

Fetch details of a specific organization

Fetches comprehensive details for an organization using its `org_id`; the `org_id` must be valid and for an existing organization.

Get list of entity filters

Retrieves entity filters from the entity filters endpoint, with a response modeled as a list of entities.

Get entity by id

Fetches detailed information for an existing entity (user, agent, app, or run) identified by its type and unique ID.

Get event status by event ID

Retrieves a single async event by ID to check its current status and results.

Get memories by entity

Retrieves memories associated with a specified user, agent, app, or run by entity type and ID, with optional pagination.

Get memory export

Retrieves the status and results of a memory export job by its ID.

Get organization members

Fetches a list of members for a specified, existing organization.

Get project details

Fetches comprehensive details for a specified project within an organization.

Get project members

Retrieves all members for a specified project within an organization.

Get projects

Retrieves all projects for a given organization `org_id` to which the caller has access.

Get project webhooks

Retrieves all webhooks configured for a specific project.

Get user memory stats

Retrieves a summary of the authenticated user's memory activity, including total memories created, search events, and add events.

List entities

Retrieves entities with optional organization and project filters; results may be summaries and subject to limits.

Perform semantic search on memories

Searches memories using a natural language query and optional filters, or requests metadata-only search.

Remove a member from the organization

Removes a member from an organization using the organization ID and member's email address.

Retrieve all events for the currently logged in user

Retrieves a paginated list of events for the authenticated user in a read-only operation.

Retrieve list of memory events

Retrieves memory events from the Mem0 platform, providing interaction history and context for AI assistants.

Retrieve memory by id

Retrieves a complete memory entry by its unique identifier; `memory_id` must be valid and for an existing memory.

Retrieve memory history by id

Retrieves the version history of a Mem0 memory by its ID, allowing you to inspect its evolution and audit changes.

Retrieve memory list

Retrieves a paginated list of memories filtered by IDs, metadata, keywords, dates, and other criteria.

Search memories with filters

Searches memories using a required nonempty set of structured filters and an optional natural language query, which defaults to '*'.

Update memory batch with uuid

Updates text for up to 1000 memories in a single batch, using their UUIDs.

Update memory text content

Updates the text and/or metadata of an existing memory identified by its memory ID.

Update organization member role

Updates the role of an existing member to a new valid role within an existing organization.

Update project

Updates a project within an organization using the provided name, description, custom instructions, or custom categories.

Update project member role

Updates the role of a specific member within a designated project, ensuring the new role is valid and recognized by the system.

FAQ

Frequently asked questions

Start with Mem0.It takes 30 seconds.

Managed auth, hosted MCP servers, and every Mem0 tool your agent needs.Free to start.

Start building