al-agent-task
Skill115 starsChanged 14 days agoMITView on GitHub
Generate AL code for Business Central Agent SDK task integration. Applies the patterns from skill-agent-task-patterns to produce production-ready codeunits, page extensions, and event subscribers — verified against the runtime API availability matrix.
In this repository64 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- claude-plugin/CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- instructions/copilot-instructions.mdCopilot instructions
- agent-builderSkill
- al-agent-createSkill
- al-agent-instructionsSkill
- al-agent-taskSkill
- al-agent-testSkill
- al-buildSkill
- al-context-createSkill
- al-initializeSkill
- al-memory-createSkill
- al-pr-prepareSkill
- al-spec-createSkill
- architectSkill
- auditSkill
- conductSkill
- developSkill
- presalesSkill
- reviewSkill
- skill-agent-instructionsSkill
- skill-agent-task-patternsSkill
- skill-agent-toolkitSkill
- skill-al-review-pipelineSkill
- skill-apiSkill
- skill-contribution-assistantSkill
- skill-copilotSkill
- skill-debugSkill
- skill-estimationSkill
- skill-eventsSkill
- skill-migrateSkill
- skill-pagesSkill
- skill-performanceSkill
- skill-permissionsSkill
- skill-testingSkill
- skill-translateSkill
- specSkill
- triageSkill
- al-agent-createSkill
- al-agent-instructionsSkill
- al-agent-testSkill
- al-buildSkill
- al-context-createSkill
- al-initializeSkill
- al-memory-createSkill
- al-pr-prepareSkill
- al-spec-createSkill
- skill-agent-instructionsSkill
- skill-agent-task-patternsSkill
- skill-agent-toolkitSkill
- skill-al-review-pipelineSkill
- skill-apiSkill
- skill-contribution-assistantSkill
- skill-copilotSkill
- skill-debugSkill
- skill-estimationSkill
- skill-eventsSkill
- skill-migrateSkill
- skill-pagesSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 16
Before generating code, determine:
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Workflow: Generate Agent Task Integration Code
Generates production-ready AL code for agent task integration. This prompt does not contain pattern knowledge — it applies the patterns from skill-agent-task-patterns.
Load skill first: skill-agent-task-patterns (8 patterns A–H, SDK codeunits, API availability matrix, OnPrem-only restrictions, workarounds).
Step 1 — Gather context
Before generating code, determine:
- Agent name and prefix — read from
app.jsonor ask the developer - Object ID range — check existing objects in
app/for the next available IDs - Which pattern(s) — ask or infer from the request:
- "I need a Public API" → Pattern A
- "Add a button to send work to the agent" → Pattern B (calls A)
- "Trigger agent on posting/releasing" → Pattern C (calls A)
- "Agent needs to process files" → Pattern D (combine with A/B/C)
- "Continue an existing task" → Pattern E (verify
AddToTaskavailability against the matrix) - "Run code only in agent context" → Pattern G/H
- "Force human review" → Warning annotation workaround (matrix:
SetRequiresReviewOnPrem-only)
- ExternalId format — convention
{PREFIX}-{No.}(e.g.LEAD-001,SO-1001) - Target page/table — which page extension or event subscriber is needed?
Step 2 — Verify availability
Before writing any code, check each method against the API Availability Matrix in skill-agent-task-patterns. Any method marked OnPrem-only or "Not in 17.0" requires the documented workaround.
Step 3 — Generate code
For each requested pattern:
- Search the codebase for existing agent objects (Setup table, Public API, enums) to reuse
- Generate AL objects following the pattern from the skill, substituting:
{Agent}→ actual agent name/prefix{id}→ actual object IDs- Record names, field names, enum values → actual project values
- Place files in the correct folder of the project structure:
- Public API + Impl →
app/Example/ - Page extensions →
app/Example/ - Session events →
app/Setup/TaskExecution/
- Public API + Impl →
- Verify generated code references correct enum values and codeunit names
Step 4 — Validate
- All generated codeunits compile (correct parameter types, return types)
- Public API has
Access = Public, Implementation hasAccess = Internal - Event-driven task creation uses
[TryFunction] - Business conditions checked BEFORE task creation (outside TryFunction)
- Failures logged via
Session.LogMessage - ExternalId follows the agreed format convention
- Page extensions use
AgentSetup.OpenAgentLookup()for agent selection - No OnPrem-only methods invoked from Extension scope
- If
AddToTaskwas needed, follow-up task workaround is in place
🛑 STOP — Review generated code with the developer.
Skills Evidencing
End with:
**Skills loaded**: skill-agent-task-patterns
**Patterns applied**:
- Pattern {X} — {file where applied}
- API matrix verified: {list any OnPrem/future methods that triggered workarounds}Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

