problem

Pack: leetcode · Endpoint: https://gateway.pipeworx.io/leetcode/mcp

Problem detail by slug.

Parameters

NameTypeRequiredDescription
title_slugstringyes

Example call

Arguments

{
  "title_slug": "two-sum"
}

curl

curl -X POST https://gateway.pipeworx.io/leetcode/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"problem","arguments":{"title_slug":"two-sum"}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('problem', {
  "title_slug": "two-sum"
});

More examples

{
  "title_slug": "longest-substring-without-repeating-characters"
}

Response shape

FieldTypeDescription
questionobject
Full JSON Schema
{
  "type": "object",
  "properties": {
    "question": {
      "type": "object",
      "properties": {
        "questionId": {
          "type": "string",
          "description": "Problem ID"
        },
        "title": {
          "type": "string",
          "description": "Problem title"
        },
        "titleSlug": {
          "type": "string",
          "description": "Problem title slug"
        },
        "content": {
          "type": "string",
          "description": "Problem description"
        },
        "difficulty": {
          "type": "string",
          "description": "Difficulty level"
        },
        "likes": {
          "type": "number",
          "description": "Number of likes"
        },
        "dislikes": {
          "type": "number",
          "description": "Number of dislikes"
        },
        "isPaidOnly": {
          "type": "boolean",
          "description": "Whether problem is premium"
        },
        "stats": {
          "type": "string",
          "description": "Problem statistics"
        },
        "topicTags": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "description": "Tag name"
              },
              "slug": {
                "type": "string",
                "description": "Tag slug"
              }
            }
          },
          "description": "Topic tags"
        }
      }
    }
  }
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "leetcode": {
      "url": "https://gateway.pipeworx.io/leetcode/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build July 6, 2026