What is A simple Model Context Protocol (MCP) server implementation for Momento Cache.?
Momento MCP Server is a straightforward implementation of the Model Context Protocol (MCP) for managing cache operations with Momento Cache. It provides tools for getting, setting, listing, creating, and deleting cache entries, along with a quickstart guide for setup and usage.
Documentation
Momento MCP Server
A simple Model Context Protocol (MCP) server implementation for Momento Cache.
cacheName string -- the name cache where the key presides (optional)
Returns:
Hit with the found value if the key was found.
Miss if the key was not found.
Error if the request failed.
set
Sets the value in cache with a given Time To Live (TTL) seconds. If a value for this key is already present, it will be replaced by the new value regardless of the previous value's data type.
Inputs:
key: string -- the key to set in the cache
value: string -- the value to set for the given key
ttl: integer -- the number of seconds to keep this value in the cache (optional)
cacheName: string -- the name of the cache to store the key in (optional)
Returns:
Success if the key was successfully written to the cache.
Error if the request failed.
list-caches
Lists the names of all the caches in your Momento account.
Inputs:
(none)
Returns:
Success with a comma separated list of cache names
Error if the request failed
create-cache
Creates a new cache in your Momento account
Inputs:
name: string - the name of the cache to create
Returns:
Success if the cache was successfully created
Error if the request failed
delete-cache
Deletes a cache from your Momento account
Inputs:
name: string - the name of the cache to delete
Returns:
Success if the cache was successfully deleted
Error if the request failed
Quickstart
Get a Momento API key from the Momento Console. Note - to run control plane tools (list-caches, create-cache, delete-cache), you must use a super user API key.
Set environment variables to configure the cache name and Time To Live (TTL) for items in the cache.