cursorrules

cursorrules is a cursor rule for Cursor from bkotos/todoist-mcp. It costs 1,974 tokens per session, scanned A, original, MIT.

A set of coding rules for developing a Todoist MCP server, including test-driven development, architecture, code style, and testing practices. Test-driven development, or TDD, means writing a failing test before writing the code that should pass it.

In plain words
What is it for?
Use it when building or reviewing the Todoist MCP server, especially when separating client and business logic, writing Vitest tests first, and following the stated TypeScript style.
Why use it?
It gives contributors a shared way to structure code and tests. This reduces ambiguity around design choices, formatting, mocking, and the order of implementation work.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/bkotos/todoist-mcp/cursorrules
Clone the repo
git clone --depth 1 https://github.com/bkotos/todoist-mcp

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cursorrules

README.md
[![agentmods](https://agentmods.dev/badge/rules/bkotos/todoist-mcp/cursorrules.svg)](https://agentmods.dev/rules/bkotos/todoist-mcp/cursorrules)
Your own site
<a href="https://agentmods.dev/rules/bkotos/todoist-mcp/cursorrules"><img src="https://agentmods.dev/badge/rules/bkotos/todoist-mcp/cursorrules.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,974 This file is loaded in full into every session.
When invoked 1,974 The same file — it is already loaded in full.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.01974 $0.01974
Opus 5 $0.00987 $0.00987
Sonnet 5 $0.00395 $0.00395
Haiku 4.5 $0.00197 $0.00197

Measured 4d ago against content hash 97f3218042fc, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cursorrules scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

if (axios.isAxiosError(error)) {
.cursorrules · 316 lines

How it starts

The opening of the file, as written. The whole thing — 316 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Todoist MCP Server - Development Standards

TDD Approach

ALWAYS write tests first:

  1. Red - Write a failing test
  2. PAUSE - Ask user to pause and read the tests before proceeding to green
  3. Green - Write minimal code to make it pass
  4. Refactor - Improve code while keeping tests green

Architecture

  • Use functional programming approach with pure functions
  • Separate concerns: client logic in client.ts, business logic in todoist.ts
  • Use Vitest module mocking for testing (not dependency injection)
  • Keep functions small and focused on single responsibility

Code Style

  • Use 2 spaces for indentation (configured in .editorconfig)
  • Prefer const over let, avoid var
  • Use arrow functions for consistency
  • Use template literals for string interpolation
  • Use destructuring for cleaner code

Testing

  • Write tests first (TDD approach)

  • Use descriptive test names that explain the behavior

  • Mock modules at the top of test files with vi.mock('./module')

  • Import Vitest types only, not runtime functions:

    // ✅ Good - import types only
    import type { MockedFunction, Mocked } from 'vitest';
    
    // ❌ Bad - import runtime functions
    import { vi, describe, it, expect } from 'vitest';
    
  • Test both success and error cases

  • Keep tests focused and isolated

  • Tests are sufficient validation - do NOT start/run the project manually

  • Running npm test is the only validation needed for new features

  • Do NOT use npm run dev, npx tsx src/index.ts, or any server startup commands

  • Do NOT check server logs or verify server is running

  • Focus on test coverage and test results only

AAA Test Pattern

ALWAYS follow this exact structure:

it('should do something', async () => {
  // arrange
  const mockClient = {
    get: vi.fn().mockResolvedValue({ data: mockData }),
  };
  mockGetTodoistClient.mockReturnValue(mockClient);

  // act
  const result = await functionName();

  // assert
  expect(result).toContain('expected output');
  expect(mockClient.get).toHaveBeenCalledWith('/endpoint');
});

Read the full file on GitHub · 316 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 316 lines · 1,974 tokens per session scan A 97f3218042fc

Subscribe to this mod's changes

cursorrules is a cursor rule published in the GitHub repository bkotos/todoist-mcp (0 stars, last pushed 8mo ago), licensed MIT. It adds 1,974 tokens to every session, about $0.0099 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.