project

Project-specific coding rules for a WooCommerce payment plugin, which lets a WordPress shop accept payments through Glitch.

In plain words
What is it for?
Building and testing the PHP gateway, checkout and admin screens, webhooks, refunds, order status updates, and Docker-based local development.
Why use it?
They give contributors the required technology choices, folder structure, payment behavior, and development commands for this project.

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/savedpixel/ai-agent-rules-generator/project
Clone the repo
git clone --depth 1 https://github.com/savedpixel/ai-agent-rules-generator

Made for: Cursor.

Per session 3,426 This file is loaded in full into every session.
When invoked 3,426 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.03426 $0.03426
Opus 5 $0.01713 $0.01713
Sonnet 5 $0.00685 $0.00685
Haiku 4.5 $0.00343 $0.00343

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

Security

Grade A, and why

project 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 2d 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.

- **b. Visual Verification Gate** — If the work affects front-end/UI: open a browser, navigate to affected pages, resize to proper dimensions, take screenshots, and visually confirm. **HTML inspection, DOM analysis, `cur
examples/glitch-payment-gateway/v1.1/cursor/generated/.cursor/rules/project.mdc · 304 lines

How it starts

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

Glitch Payment Gateway — Project Rules

Project Overview

A bespoke WooCommerce payment gateway plugin for Glitch, a major South African payment provider. Enables merchants to accept payments through Glitch's infrastructure with support for multiple payment methods, webhooks, refunds, and full order status synchronization.

  • Plugin root: src/ — Main plugin PHP files, gateway class, includes
  • Includes: src/includes/ — Helper classes, API client, webhook handler
  • Admin: src/admin/ — WooCommerce settings page, admin views
  • Templates: src/templates/ — Checkout and payment form templates
  • Assets: src/assets/ — CSS and JS for checkout/admin
  • Docs: docs/ — Architecture, deployment, and task documentation
  • Tests: tests/ — PHPUnit test cases

Stack

  • CMS: WordPress 6.x
  • E-commerce: WooCommerce 8.x+ (HPOS compatible)
  • Language: PHP 8.1+
  • Database: MySQL / MariaDB (via WordPress $wpdb and WC CRUD)
  • Payment Provider: Glitch API (South Africa)
  • Currency: ZAR (South African Rand)
  • Testing: PHPUnit + WooCommerce test framework
  • Styling: WordPress admin CSS + minimal custom checkout CSS
  • Dev Environment: Docker (WordPress + MySQL containers)

CRITICAL: Never Push to Live

You must never push, deploy, or sync code to the live/production environment. All live deployments are the user's responsibility. This includes:

  • Running any deploy command that targets production
  • Triggering any CI/CD pipeline that pushes to live
  • Using git push to production branches
  • Invoking any deploy action aimed at the live server

You may deploy to local or staging environments only.


CRITICAL: Always Follow task.mdc

Before starting any task, you MUST read and follow the rules in .cursor/rules/task.mdc. This includes:

  • Planning before implementation (Plan Node)
  • Writing checklists to docs/task/todo.md for planned, multi-step work (features, refactors, multi-step tasks) — not for every ad-hoc single-message request or quick fix
  • Updating docs/task/lessons.md after any user correction
  • Verification before marking work complete (3-tier verification gate pipeline)
  • The full Task Management Protocol

Read the full file on GitHub · 304 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. 2d ago First seen · 304 lines · 3,426 tokens per session scan A 616c3c803f35

Subscribe to this mod's changes

project is a cursor rule published in the GitHub repository savedpixel/ai-agent-rules-generator (7 stars, last pushed 4mo ago), licensed MIT. It adds 3,426 tokens to every session, about $0.0171 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.