-
Notifications
You must be signed in to change notification settings - Fork 6
Add x-sap-ai-hint extension #41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
201be0b
Add x-sap-ai-hint extension + CHANGELOG.md
Fannon 171fc87
Also applicable on info object and params
Fannon e855e11
Gitignore .claude
Fannon 7651813
Not in scope for tags
Fannon 4ddff55
Add more explanations and guidance how to use the ai-hint
Fannon 536dde2
Recommend markdown
Fannon fb1f43e
Update sap-schemas/v2.0/README.md
Fannon 98b690c
More consistent best practices block
Fannon d92aac6
Merge branch 'main' into add-ai-hint-extension
pavelkornev 29db04a
Address PR review comments on x-sap-ai-hint extension
vyshnavigadamsetti f1a1dc1
Update sap-schemas/v2.0/README.md
vyshnavigadamsetti 13534a1
Update sap-schemas/v3.0/README.md
vyshnavigadamsetti d5ba7bf
Remove SAP-internal link from x-sap-ai-hint best practices section
vyshnavigadamsetti b3f0cd2
Commit generated files
pavelkornev ea11c72
Merge branch 'main' into add-ai-hint-extension
pavelkornev File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,4 @@ | ||
| node_modules | ||
| dist | ||
| dist | ||
| .claude/ | ||
| .DS_Store |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,142 @@ | ||
| # Changelog | ||
|
|
||
| All notable changes to this project will be documented in this file. | ||
|
|
||
| The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). | ||
|
|
||
| ## [Unreleased] | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-ai-hint` extension for Info Object, Operation Object, Parameter Object, and Schema Object. | ||
| - Provides a hint for AI consumers (e.g., LLMs) on how to use or interpret the annotated element, intentionally kept separate from human-readable `description` fields so that end-user-facing documentation and AI-targeted guidance can evolve independently. | ||
|
|
||
| --- | ||
|
|
||
| ## 2024-11-18 (#31) | ||
|
|
||
| ### Changed | ||
|
|
||
| - Updated description of `x-sap-dpp-field-semantics` to clarify meaning and usage. | ||
|
|
||
| ## 2024-10-24 (#32) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-odm-semantic-key` on Schema Object. A human-readable identifier used to identify business objects by the end-user. Carries an array of key name/values pairs. | ||
|
|
||
| ## 2024-09-30 (#30) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-dpp-entity-semantics` on Schema Object. Primary meaning of the personal data in the annotated entity set (`sap:DataSubject`, `sap:DataSubjectDetails`, `sap:Other`). | ||
| - `x-sap-dpp-data-subject-role` on Schema Object. Role of the data subjects in the set (e.g. employee, customer). | ||
| - `x-sap-dpp-data-subject-role-description` on Schema Object. Language-dependent description of the data subject role. | ||
| - `x-sap-dpp-field-semantics` on Schema Object. Primary meaning of personal data in a property; drives audit log tracking. | ||
| - `x-sap-dpp-is-potentially-personal` on Schema Object. Flags a property as containing potentially personal data. | ||
| - `x-sap-dpp-is-potentially-sensitive` on Schema Object. Flags a property as containing potentially sensitive personal data. | ||
|
|
||
| ## 2024-06-17 (#23, #25, #26, #27, #28) | ||
|
|
||
| ### Added | ||
|
|
||
| - GitHub Actions CI workflow (build on push/PR) and release workflow (publish to npmjs.com). | ||
|
|
||
| ### Changed | ||
|
|
||
| - Cleaned up npm package metadata and repository URL. | ||
|
|
||
| ## 2024-06-10 (#24) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-deprecated-operation` on Operation Object. Carries structured deprecation metadata: `deprecationDate` (RFC 3339 date), and either `successorOperationRef` (URI reference) or `successorOperationId` (operationId string) — exactly one successor field is required. | ||
|
|
||
| ## 2024-03-26 (#20) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-operation-intent` on Operation Object. Communicates the semantic intent of an operation (`create-single`, `read-collection`, `update-single`, `upsert-collection`, `action`, etc.). | ||
|
|
||
| ## 2024-03-01 (#22) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-ord-id` at OpenAPI Object (root) level. Links the API resource to its corresponding ORD ID using the pattern `<namespace>:apiResource:<name>:<version>`. | ||
|
|
||
| ## 2024-02-29 (#16) | ||
|
|
||
| ### Changed | ||
|
|
||
| - `x-sap-ext-overview` value items now have a proper JSON Schema: each item can be a plain string or an object with `text` (string) and `format` (`plain` | `markdown`). | ||
|
|
||
| ## 2024-01-26 (#19) | ||
|
|
||
| ### Fixed | ||
|
|
||
| - Aligned naming of deprecation-related attributes in documentation for consistency across extensions. | ||
|
|
||
| ## 2024-01-17 (#18) | ||
|
|
||
| ### Changed | ||
|
|
||
| - Improved the primitive type mapping table in README with corrected JSON examples. | ||
|
|
||
| ## 2023-11-16 (#17) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-odm-oid-reference-entity-name` on Schema Object. Specifies the ODM entity name of a referenced entity on a property that holds a foreign OID reference. | ||
|
|
||
| ## 2023-04-21 (#13) | ||
|
|
||
| ### Added | ||
|
|
||
| - Primitive type mapping table in README covering ABAP, CAP, Java, OData, SQL, and OpenAPI type/format correspondences. | ||
|
|
||
| ## 2023-04-04 (#9, #10, #11, #12) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-root-entity` on Schema Object. Boolean flag indicating that the annotated schema is a root entity (a globally addressable business object root). | ||
|
|
||
| ### Fixed | ||
|
|
||
| - Corrected examples in the OpenAPI v2.0 schema documentation. | ||
| - Removed incorrect DECFLOAT34 example from the type mapping. | ||
|
|
||
| ## 2023-02-28 (#4) | ||
|
|
||
| ### Changed | ||
|
|
||
| - **Breaking**: removed lowercase enum values (`rest`, `soap`, `odata`, `odatav4`) from `x-sap-api-type`. Only uppercase values (`REST`, `SOAP`, `ODATA`, `ODATAV4`) are now valid. | ||
|
|
||
| ## 2023-02-24 (#3) | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-precision` on Schema Object. Maximum number of significant decimal digits (integer ≥ 1). | ||
| - `x-sap-scale` on Schema Object. Maximum number of decimal digits to the right of the decimal point (integer ≥ 0). | ||
|
|
||
| ## 2023-02-10 | ||
|
|
||
| ### Added | ||
|
|
||
| - `x-sap-odm-entity-name` on Schema Object. Name of the ODM entity concept the schema represents, used by consumers to find APIs exposing the same entity. | ||
| - `x-sap-odm-oid` on Schema Object. Marks the annotated field as the ODM Object Identifier (OID) that uniquely identifies an ODM root entity across a customer landscape. | ||
|
|
||
| ## 2022-11-29 — Initial release | ||
|
|
||
| ### Added | ||
|
|
||
| - OpenAPI v2.0 and v3.0 SAP extension schemas with generator toolchain (`src/generate-specs.ts`). | ||
| - Root-level extensions (OpenAPI Object): | ||
| - `x-sap-compliance-level` — expected compliance level (`sap:base:v1`, `sap:core:v1`, `sap:core:v2`). | ||
| - `x-sap-shortText` — short display description of the API. | ||
| - `x-sap-software-min-version` — minimum required software version. | ||
| - `x-sap-api-type` — API protocol type (`REST`, `SOAP`, `ODATA`, `ODATAV4`). | ||
| - `x-sap-ext-overview` — stakeholder-specific metadata as name/values pairs. | ||
| - `x-sap-stateInfo` — API lifecycle state (`Beta`, `Active`, `Deprecated`, `Decommissioned`) with optional deprecation and decommission dates and a successor URL. | ||
| - `x-sap-direction` — API traffic direction (`inbound`, `outbound`, `mixed`). | ||
| - `x-sap-extensible` — extensibility metadata with `supported` (`no`, `manual`, `automatic`) and optional `description`. | ||
| - OAuth flow URL relaxation: `authorizationUrl`, `tokenUrl`, and `refreshUrl` made non-required to accommodate SAP-specific flows. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.