MCP
MCP Workflows
Common end-to-end agent workflows for generation and mocking.
MCP Workflows
These workflows show practical, repeatable agent-driven operations.
Workflow 1: New Codebase Generation
- Derive codebase identifier from git remote.
- Call generate-fake-data with full schema.
- Poll until completion.
- Retrieve generated result references.
Workflow 2: Evolving Existing Schema
- Call get-codebase-schema with codebase identifier.
- Add newly introduced tables.
- Add/remove changed columns.
- Regenerate fake data.
Workflow 3: Shape Realistic Data
- Call get-schema-overview to see tables, profiles and relationships.
- Call get-column-profiles for the table you want to improve.
- Call update-column-profile for precise changes, or reprofile-tables for broad ones.
- Call preview-rows and show the user the sample.
- Call generate-fake-data to apply the changes, then export-generated-data.
Workflow 4: Fix Relationships
- Call get-schema-overview and look for
*_idcolumns without a relationship. - Call read-schema-source for those tables to confirm the intended foreign key.
- Call manage-relationship with
action: add. - For a wrong relationship, describe the change, wait for the user to confirm, then call manage-relationship with
confirmed: true. - Use set-parent-tables and set-row-counts to shape ratios, then regenerate.
Workflow 5: Mock API Bootstrap
- Call create-api-mock with domain prompt.
- Review generated endpoints.
- Call get-api-mock for exact endpoint/scenario details.
- Iterate prompt for additional coverage.
Workflow 6: Extend Existing Mock
- Call list-mocks.
- Pick mock by ID.
- Call create-api-mock with mock_id and prompt for only new endpoints.
- Validate responses in client tests.
Workflow 7: Safety-First Operation Pattern
- Start with read-only tools (list/get).
- Validate context and identifiers.
- Use mutation tools intentionally.
- Re-read state and confirm expected changes.
Team Conventions
- Store shared codebase identifiers in project docs.
- Keep MCP prompts deterministic and explicit.
- Prefer incremental mutations over large one-shot changes.