odata-vocabularies-sync
Sync odata-vocabularies package — update all vocabulary resource files to their latest published versions, and optionally add a new vocabulary given its JSON…
от SAP★ 162 звезды на GitHub
Установить odata-vocabularies-sync в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
odata-vocabularies-sync
Keeps the packages/odata-vocabularies package in sync with the upstream OData vocabulary sources.
- No argument — update all existing vocabulary resource files to their latest published versions.
- With a URL argument — register and add the new vocabulary first, then update everything.
All file edits are relative to packages/odata-vocabularies/.
Note:
com.sap.cds.vocabularies.*files (ObjectModel, AnalyticsDetails) are hand-crafted and not managed by this skill. Do not attempt to add them via a URL.
Step 1 — Add a new vocabulary (only when a URL argument is provided)
1a. Fetch and inspect the vocabulary JSON
Fetch the JSON at the provided URL (must end in .json — XML URLs are not supported by the update tool). Extract:
namespace— the key of the top-level schema object (e.g.Org.OData.NewThing.V1orcom.sap.vocabularies.NewThing.v1)alias— the value of$Aliasinside that schema object (e.g.NewThing)
Determine the vocabulary family from the namespace:
- Starts with
Org.OData.→ OASIS vocabulary - Starts with
com.sap.vocabularies.→ SAP vocabulary - Starts with
com.sap.cds.→ CDS vocabulary — stop. These files are hand-crafted and cannot be added via this skill. Explain this to the user. - Anything else → stop and ask the user to confirm the family before proceeding.
1b. Edit tools/update.ts
Add an entry to SUPPORTED_VOCABULARIES in alphabetical order within the existing entries:
'<namespace>': {
uri: '<the provided URL>'
},
Note: The entry can include
update: falseto pin the vocabulary and exclude it from future automatic updates (e.g.com.sap.vocabularies.CDS.v1uses this because it is hand-maintained). Omit the field for normal auto-updating behaviour.
1c. Edit src/resources/index.ts
Make all six additions. All six are mandatory — missing any one will cause a runtime error.
Import — insert alphabetically by alias in the single import block (OASIS and SAP imports are interleaved by alias, not grouped by family):
import <Alias> from './<namespace>.js';Use the
$Aliasvalue from the JSON as the import identifier. Exception: if the alias is a reserved JS keyword or built-in (e.g.JSON,Map,Error), prefix it to form a valid identifier (e.g.JSON→ODataJSON). Also check existing imports for precedent — some aliases are shortened for brevity (e.g.Authorization→Auth).Namespace union type — add to the matching family type:
- OASIS →
OasisVocabularyNamespace - SAP →
SapVocabularyNamespace
| '<namespace>'- OASIS →
Alias union type — add to the matching family type:
- OASIS →
OasisVocabularyAlias - SAP →
SapVocabularyAlias
| '<Alias>'- OASIS →
NAMESPACE_TO_ALIASMap:['<namespace>', '<Alias>'],ALIAS_TO_NAMESPACEMap:['<Alias>', '<namespace>'],vocabulariesRecord:'<namespace>': <Alias>,
1d. Edit src/loader.ts
Add the namespace to SUPPORTED_VOCABULARY_NAMESPACES in alphabetical order within its family block:
'<namespace>',
1e. Edit README.md
Add the alias to the correct bullet list in the "Supported Vocabularies" section, in alphabetical order:
- OASIS namespace → OASIS Vocabularies list
- SAP namespace → SAP Vocabularies list
* <Alias>
Step 2 — Run the update tool
This fetches the latest JSON for every registered vocabulary (including any newly added one) and regenerates all src/resources/*.ts resource files.
Run from the repo root:
pnpm --filter @sap-ux/odata-vocabularies update:vocabularies
If the tool fails, stop and report the full error output before proceeding.
Step 3 — Audit and fix README
Cross-check the README against the registered vocabularies and add any missing entries.
Read
src/resources/index.tsand collect all namespaces fromNAMESPACE_TO_ALIAS, split by family:- OASIS: namespaces starting with
Org.OData. - SAP: namespaces starting with
com.sap.vocabularies.excludingcom.sap.vocabularies.CDS.v1 - Skip all
com.sap.cds.namespaces (hand-crafted, not listed in README)
- OASIS: namespaces starting with
For each collected namespace, read the corresponding generated resource file
src/resources/<namespace>.tsand extract the$Aliasvalue — this is the authoritative published alias used as the display name in README.Read
README.mdand find the two bullet lists under "Supported Vocabularies":- The OASIS Vocabularies list
- The SAP Vocabularies list
For each alias not yet present in the correct list, insert it in alphabetical order.
If the README is already complete, do nothing.
Step 4 — Run tests and update snapshots
pnpm --filter @sap-ux/odata-vocabularies test -- -u
Report a
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл odata-vocabularies-sync?
Sync odata-vocabularies package — update all vocabulary resource files to their latest published versions, and optionally add a new vocabulary given its JSON URL. Use when asked to update vocabularies, refresh vocabulary resources, or add a new vocabulary to @sap-ux/odata-vocabularies.
Как установить скилл odata-vocabularies-sync?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл odata-vocabularies-sync запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
frontend-design
AnthropicGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making…
webapp-testing
AnthropicToolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing…
brand-guidelines
AnthropicApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand…
web-artifacts-builder
AnthropicSuite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use…