Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
LEETCODE_COOKIENoComplete cookie string containing csrftoken and LEETCODE_SESSION, used as a fallback when no system keychain is available.
LEETCODE_SESSIONNoLeetCode session token, alternative to LEETCODE_COOKIE.
LEETCODE_CSRFTOKENNoCSRF token, alternative to LEETCODE_COOKIE.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
auth_statusA

检查 LeetCode 中国站登录状态,不返回或显示任何 Cookie。

loginB

通过本机安全页面登录 LeetCode 中国站并将 Cookie 保存到系统钥匙串。Cookie 不作为工具参数,也不会进入模型上下文。

logoutA

删除系统钥匙串中保存的 LeetCode 中国站凭证。

get_problemA

根据中国站题号、中文/英文标题、titleSlug 或题目 URL 获取题目信息。题目查询不需要登录。language 可指定 python3、cpp、java、typescript 等代码模板。

get_submissions_by_dateA

获取当前登录用户某个自然日的全部 LeetCode 中国站提交。date 默认为 Asia/Shanghai 时区的今天,格式 YYYY-MM-DD;包含 AC 和失败提交。

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/lkastar/leetcode-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server