refactor-entry-point-to-action

refactor-entry-point-to-action is a skill for Claude Code, Codex from pekral/cursor-rules. It costs 37 tokens per session (3,641 once invoked), scanned A, original, MIT.

A refactoring workflow that moves business coordination out of a Laravel entry point, such as a controller, job, command, listener, or Livewire component, into a dedicated Action class.

In plain words
What is it for?
Use it to extract orchestration from entry-point methods, create or update the matching Action and validator, run project checks, or review whether an extraction is appropriate without changing code.
Why use it?
It separates request-handling code from the work it coordinates while preserving existing behaviour and response rules.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions subagents.

Good fit Use it to extract orchestration from entry-point methods, create or update the matching Action and validator, run project checks, or review whether an extraction is appropriate without changing code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/pekral/cursor-rules/refactor-entry-point-to-action
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.

Any agent
npx skills add pekral/cursor-rules --skill refactor-entry-point-to-action
Clone the repo
git clone --depth 1 https://github.com/pekral/cursor-rules

Made for: Claude Code, Codex.

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 refactor-entry-point-to-action

README.md
[![agentmods](https://agentmods.dev/badge/skills/pekral/cursor-rules/refactor-entry-point-to-action/github.svg)](https://agentmods.dev/skills/pekral/cursor-rules/refactor-entry-point-to-action)
Your own site
<a href="https://agentmods.dev/skills/pekral/cursor-rules/refactor-entry-point-to-action"><img src="https://agentmods.dev/badge/skills/pekral/cursor-rules/refactor-entry-point-to-action/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for refactor-entry-point-to-action

Your own site · 80×15
<a href="https://agentmods.dev/skills/pekral/cursor-rules/refactor-entry-point-to-action"><img src="https://agentmods.dev/badge/skills/pekral/cursor-rules/refactor-entry-point-to-action.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 37 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,641 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00037 $0.03641
Opus 5.5 $0.00015 $0.01456
Sonnet 5.5 $0.00007 $0.00728
Haiku 4.5 $0.00004 $0.00364

Measured 3mo ago against content hash f350bc706b98, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

refactor-entry-point-to-action scanned grade A with 0 findings 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 3mo 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/refactor-entry-point-to-action/SKILL.md · 111 lines

How it starts

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

Modes

This skill runs in one of two modes, selected by the caller via MODE (default apply):

  • apply (default) — perform the entry-point → Action refactoring: create / update the Action, move orchestration, run fixers / checkers, and chain the After Completion review. The Execution and Done-when steps below behave as written.
  • cr (read-only lens — invoked by @skills/code-review/SKILL.md, code-review-github, code-review-jira) — never modify code, never create files, never stage / commit / push, never run fixers or checkers, and never chain code-review / process-code-review. Scope the analysis to entry points (controller / job / command / listener / Livewire) touched by the PR diff that still hold business orchestration, and return — as markdown only — the proposed Action extraction for each: the entry-point Class::method, the orchestration that should move out, the target app/Actions/<Domain>/<ActionName> and Data Validator, and the rule reference. The CR folds these into its Refactoring (DRY / tech debt) section (in-scope) or Refactoring proposals section (out-of-scope). Execution steps 3–11 below apply to MODE=apply only.

Constraints

  • Apply @rules/refactoring/general.mdc — incremental migration only, never a big-bang rewrite. The Test Coverage Contract in that rule is binding: 100% coverage of the target lines must exist in a dedicated test(scope): cover <area> before refactor commit before the entry-point change lands, and the assertion logic of those tests must remain unchanged through the refactor commit.
  • Apply @rules/php/core-standards.mdc.
  • If the current project uses Laravel, also apply @rules/laravel/laravel.mdc, @rules/laravel/architecture.mdc, @rules/laravel/filament.mdc, and @rules/laravel/livewire.mdc
  • Preserve behavior, signatures, response contracts, and tenant/account scope. Rewrite the entry-point code strictly per the applied rules — anything that would deviate (parameter count, naming, nesting, layer placement, validation home) is rewritten until it complies.
  • Do not report review output to any third-party service.
  • After changes (MODE=apply only), run an internal architecture-first review and fix important findings immediately. In MODE=cr there are no changes — emit the Action-extraction proposal and stop.

Read the full file on GitHub · 111 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. 3mo ago First seen · 111 lines · 37 tokens per session scan A f350bc706b98

Subscribe to this mod's changes

refactor-entry-point-to-action is a skill published in the GitHub repository pekral/cursor-rules (11 stars, last pushed yesterday), licensed MIT. It adds 37 tokens to every session and 3,641 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

refactor-entry-point-to-action compared with skills from other repositories

refactor-entry-point-to-action next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
refactor-entry-point-to-actionpekral/cursor-rulesSkill11yesterdayMITA37Claude Code, Codex
Laravel Mass Assignment and Authorization Reviews977043/river-reviewSkill8yesterdayMITA35Claude Code
Laravel Eloquent N+1 and Query Efficiency Reviews977043/river-reviewSkill8yesterdayMITA48Claude Code
create-powergrid-pluginPower-Components/livewire-powergridSkill1.7k2d agoMITA31Claude Code, Codex
laravelericrisco/rsc-harnessSkill6915d agoMITA75Claude Code, Codex
owl-admin-app-devslowlyo/owl-adminSkill62116d agoMITA114Claude Code, Codex
owl-admin-devtools-generatorslowlyo/owl-adminSkill62116d agoMITA82Claude Code, Codex