Breaking Change with Scope and Body
A complete example of a breaking change commit with scope, multi-line body, and BREAKING CHANGE footer. The full Conventional Commits pattern.
Breaking Changes
Detailed Explanation
The Complete Breaking Change Commit
This example demonstrates every element of a Conventional Commit working together: type, scope, breaking change marker, description, body, and footer.
Full Example
feat(api)!: replace REST endpoints with GraphQL
The entire REST API has been replaced with a GraphQL API.
All existing client integrations must be updated to use
GraphQL queries and mutations instead of HTTP method-based
REST calls.
The new API provides:
- A single /graphql endpoint
- Type-safe queries with auto-generated TypeScript types
- Real-time subscriptions via WebSocket
- Batched queries for reduced network overhead
Migration guide: https://docs.example.com/migration/v3
BREAKING CHANGE: all /api/v2/* REST endpoints have been
removed. Use the /graphql endpoint with the appropriate
queries and mutations. See the migration guide for
endpoint-to-query mapping.
Refs: #892, #915
Reviewed-by: Alice
Element Analysis
| Element | Value | Notes |
|---|---|---|
| Type | feat |
New feature (GraphQL API) |
| Scope | (api) |
Affects the API module |
| Bang | ! |
Breaking change indicator |
| Description | replace REST endpoints with GraphQL |
Imperative, concise |
| Body | 8 lines | Detailed explanation with bullet points |
| BREAKING CHANGE footer | 4 lines | Migration instructions |
| Refs footer | #892, #915 |
Related issue references |
| Reviewed-by footer | Alice |
Reviewer attribution |
Version Impact
This commit triggers a major version bump (e.g., 2.x.x to 3.0.0) because of the breaking change. The feat type alone would trigger a minor bump, but the breaking change overrides it.
Best Practices Demonstrated
- The subject line is under 72 characters.
- The body wraps at 100 characters per line.
- The body explains what changed and why.
- The footer provides migration instructions.
- Multiple footer tokens are used correctly.
Use Case
Use this complete pattern for major releases or significant architectural changes. The combination of scope, bang marker, detailed body, and BREAKING CHANGE footer provides maximum clarity for both human reviewers and automated tools.