// |
| name | sap-api-style |
| description | This skill provides comprehensive guidance for documenting SAP APIs following official SAP API Style Guide standards. It should be used when creating or reviewing API documentation for REST, OData, Java, JavaScript, .NET, or C/C++ APIs. The skill covers naming conventions, documentation comments, OpenAPI specifications, quality checklists, deprecation policies, and manual documentation templates. It ensures consistency with SAP API Business Hub standards and industry best practices. Keywords: SAP API, REST, OData, OpenAPI, Swagger, Javadoc, JSDoc, XML documentation, API Business Hub, API naming, API deprecation, x-sap-stateInfo, Entity Data Model, EDM, documentation tags, API quality, API templates |
| license | GPL-3.0 |
| metadata | {"version":"1.1.0","last_verified":"2025-11-27","source_version":"2025.01","source_commit":"902247f3afb6a0cb3fa110b284bb5d93a65c1268","source_license":"CC-BY-4.0"} |
This skill provides comprehensive guidance for documenting SAP APIs according to official SAP API Style Guide standards. It covers all major API types and documentation approaches used across the SAP ecosystem.
Documentation Source: https://github.com/SAP-docs/api-style-guide (76 files extracted)
Last Verified: 2025-11-21
Use this skill when:
REST/OData API
โโ Auto-generated (OpenAPI/Swagger)?
โ โโ references/rest-odata-openapi-guide.md
โ โข OpenAPI specification standards
โ โข Package, API, operation descriptions
โ โข Parameters, responses, components
โ โข SAP API Business Hub requirements
โ
โโ Manually written?
โโ references/manual-templates-guide.md
โข REST templates (2-level: overview โ method)
โข OData templates (3-level: service โ resource โ operation)
โข Complete field requirements
โข templates/ directory for ready-to-use files
Native Library API
โโ Java โ references/java-javascript-dotnet-guide.md
โโ JavaScript โ references/java-javascript-dotnet-guide.md
โโ .NET (C#) โ references/java-javascript-dotnet-guide.md
โโ C/C++ โ references/java-javascript-dotnet-guide.md
โข Documentation comments structure
โข Language-specific tags
โข Templates for classes, methods, enums
โข Complete code examples
Naming
โโ references/naming-conventions.md
โข REST/OData naming (resources, parameters, URIs)
โข Native library naming (classes, methods, constants)
โข Common mistakes to avoid
Writing Descriptions
โโ references/rest-odata-openapi-guide.md
โข Package descriptions
โข API details (info object)
โข Operations, parameters, responses
Quality Assurance
โโ references/quality-processes.md
โข Complete API Quality Checklist
โข Review workflows
โข Development team guidelines
Deprecating APIs
โโ references/deprecation-policy.md
โข Lifecycle states (beta, active, deprecated, decommissioned)
โข Timeline requirements (12+ months support)
โข Required metadata (x-sap-stateInfo)
Developer Guides
โโ references/developer-guides.md
โข Structure guidelines
โข Content selection
โข Code sample standards
All SAP API documentation follows consistent conventions:
| API Type | Standard | Tool | Documentation |
|---|---|---|---|
| REST | OpenAPI 3.0.3 | Swagger | Spec |
| OData | v4.01, v3.0, v2.0 | Various | OData.org |
| Java | Javadoc | javadoc | Oracle |
| JavaScript | JSDoc 3 | jsdoc | JSDoc.app |
| .NET | XML Comments | DocFX | Microsoft |
| C/C++ | Doxygen | doxygen | Doxygen.nl |
Documentation organized hierarchically:
All documentation must:
| Element | Limit | Use Case |
|---|---|---|
| API Title | 80 | info.title in OpenAPI |
| API Short Text | 180 | x-sap-shortText |
| Package Short Desc | 250 | Package tile description |
| Operation Summary | 255 | Operation summary line |
| Description | 1024 | General descriptions |
General Rules (all API types):
See references/naming-conventions.md for complete language-specific rules.
Java/JavaScript:
@param <name> <description> - Parameter documentation@return <description> - Return value@throws <class> <description> - Exception@deprecated <description> - Deprecation notice.NET:
<summary> - Brief description<param name=""> - Parameter<returns> - Return value<exception cref=""> - ExceptionSee references/java-javascript-dotnet-guide.md for complete tag reference.
| State | Definition | Support | Metadata Required |
|---|---|---|---|
| Beta | Pre-production testing | No guarantees | state: beta |
| Active | Production-ready (default) | Full support | Optional |
| Deprecated | Replaced by successor | 12+ months | state, deprecationDate, successorApi |
| Decommissioned | Fully retired | None | Document removal |
See references/deprecation-policy.md for complete timeline and process requirements.
Ready-to-use templates in templates/ directory:
All templates include:
rest-odata-openapi-guide.md (2,800 lines)
manual-templates-guide.md (2,765 lines)
naming-conventions.md (2,059 lines)
quality-processes.md (1,774 lines)
java-javascript-dotnet-guide.md (1,517 lines)
developer-guides.md (704 lines)
deprecation-policy.md (664 lines)
glossary-resources.md (472 lines)
PROGRESS_TRACKING.md (333 lines)
This skill includes comprehensive documentation and templates organized for optimal use:
references/)templates/)Total: 2,343 lines of ready-to-use templates
Determine if you're documenting REST, OData, Java, JavaScript, .NET, or C/C++ API.
Auto-Generated: Write documentation comments in source code โ Use appropriate tags โ Submit for review
Manual: Select template from templates/ โ Customize [placeholders] โ Follow hierarchy โ Validate with checklist
Consult appropriate reference file:
naming-conventions.mdrest-odata-openapi-guide.md or java-javascript-dotnet-guide.mdquality-processes.mddeprecation-policy.mdBefore publishing:
quality-processes.md)naming-conventions.md)Naming:
Descriptions:
Documentation:
See individual reference files for complete anti-patterns and fixes.
Source Version: SAP API Style Guide 2025.01 (verified against commit 902247f)
Recent Changes:
To Update This Skill:
Quarterly Review Recommended: Check for updates every 3 months
Next Review: 2026-02-27
Skill Version: 1.1.0 Last Updated: 2025-11-27 License: GPL-3.0 Maintainer: SAP Skills Team | https://github.com/secondsky/sap-skills