Adding Use Cases
This guide explains how to add new domain-specific use cases to the AXAG documentation.
Why Add Use Cases?
Use cases demonstrate AXAG's applicability across industries. Each new domain:
- Validates the standard's expressiveness
- Provides ready-to-use templates for adopters in that industry
- Highlights domain-specific patterns and edge cases
Structure of a Use-Case Page
Every use-case page follows this template:
---
id: domain-action
title: "Domain — Action Name"
sidebar_label: Action Name
slug: /use-cases/domain/action-name
---
# Domain — Action Name
## Problem Statement
Describe the user action and its business context. What does the UI look like?
What does the user click, fill in, or interact with?
## Why Human-Only Semantics Fail Agents
Explain why a scraping-based agent would struggle. Mention:
- Ambiguous button labels
- Missing parameter metadata
- Unclear preconditions or risk
- Dynamic rendering challenges
## AXAG-Annotated UI
\`\`\`html
<button
axag-intent="entity.action"
axag-entity="entity"
axag-action-type="write"
axag-required-parameters='["param1","param2"]'
...
>Label</button>
\`\`\`
## Semantic Manifest Excerpt
\`\`\`json
{
"intent": "entity.action",
...
}
\`\`\`
## Generated MCP Tool
\`\`\`json
{
"name": "entity_action",
"description": "...",
"inputSchema": { ... }
}
\`\`\`
## Constraints and Safety
- Risk level and why
- Preconditions and postconditions
- Confirmation/approval requirements
- Side effects
## Why Scraping Fails Here
Specific examples of how a scraping agent would misinterpret
or miss critical metadata for this action.
Step-by-Step Process
1. Choose a Domain
Check existing domains in docs/use-cases/:
- E-Commerce, Marketing, CRM, Travel, Jobs, Analytics, Support, Enterprise
If your domain isn't listed, create a new subdirectory.
2. Identify Intents
List the key user actions in the domain. Aim for 2-4 intents per domain:
- At least one read operation (search, list, get)
- At least one write operation (create, update)
- Optionally a delete or approval operation
3. Create the Directory
mkdir -p docs/use-cases/your-domain
4. Write the Pages
Create one .md file per intent following the template above.
5. Update the Sidebar
Add your domain to sidebars.ts under the use-cases category:
{
type: 'category',
label: 'Your Domain',
items: [
'use-cases/your-domain/intent-one',
'use-cases/your-domain/intent-two',
],
},
6. Update the Overview
Add your domain to docs/use-cases/overview.md:
- Add a row to the domain comparison table
- Add a brief description
7. Validate
npm run build
npm run validate