require-custom-agent-fields
Require standalone Codex custom agents to declare non-empty name, description, and developer_instructions strings.
Rule catalog ID: R016
Targeted pattern scope
**/.codex/agents/*.toml
What this rule reports
- Codex custom agents must declare a non-empty string
{{field}}field.
Why this rule exists
Require standalone Codex custom agents to declare non-empty name, description, and developer_instructions strings.
❌ Incorrect
A file in the targeted scope that produces any diagnostic listed above is incorrect for this rule.
✅ Correct
A file is correct when it uses the documented Codex structure and produces no diagnostic from this rule.
Behavior and migration notes
Included in:
codex.configs.minimalcodex.configs.recommendedcodex.configs.strictcodex.configs.all
ESLint flat config example
The preset layers supply the correct Markdown, TOML, or JSON language configuration. Override the rule only in a later matching flat-config entry:
import codex from "@typpi/eslint-plugin-codex";
export default [
...codex.configs.recommended,
{
rules: { "codex/require-custom-agent-fields": "error" },
},
];