Add dedicated OData API support (extract & publish)
- 主要言語
- TypeScript
- スター
- 26
- フォーク
- 9
- 平均マージ
- 1日 3時間
- マージ済み PR(30日)
- 20
説明
## Summary
apiops-cli currently handles OData APIs via the generic OpenAPI fallback path, which does not capture OData-specific artifacts. This issue tracks adding first-class OData support to both the extractor and publisher.
## Background
Azure API Management added OData API support, but tooling across the ecosystem has lagged behind (see [Azure/apiops#419](https://github.com/Azure/apiops/issues/419)). Users report that entity sets and functions are lost when extracting/publishing OData APIs.
## Current behavior
- **Extractor** (`api-extractor.ts`): No special-case handling for `odata` API type — it falls through to the generic `openapi-link` export, which misses OData-specific resources.
- **Publisher** (`api-publisher.ts`): Recognizes `odata` as a valid `apiType` string but has no OData-specific import format or schema handling.
- **APIM Client** (`apim-client.ts`): `getExportFormat()` returns `'openapi-link'` for OData via the `default` case — no dedicated export format.
## What needs to change
1. **Extract**: Add OData-specific handling in `api-extractor.ts` to export CSDL schemas, entity sets, and functions via the appropriate APIM export format.
2. **APIM Client**: Add an `'odata'` case to `getExportFormat()` returning the correct APIM export format for OData APIs (investigate whether APIM supports a dedicated OData/CSDL export link).
3. **Publish**: Add OData-specific import format handling in `getImportFormat()` so that CSDL schemas and entity sets are correctly imported on publish.
4. **Tests**: Add unit/integration tests covering OData extract and publish flows.
## Related
- [Azure/apiops#419](https://github.com/Azure/apiops/issues/419) — original feature request in the apiops toolkit repo
コントリビューションガイド
調査の方向性
api-extractor.ts、api-publisher.ts、apim-client.ts から始め、既存の apiType の処理と getExportFormat()/getImportFormat() のパスを追跡します。OData/CSDL のエクスポート形式とインポート形式を確認するため、APIM API 形式のドキュメントまたは既存のクライアント動作を確認します。OData のエンティティ セットと関数が extract と publish を通過して保持され、両方のフローをカバーする単体テストまたは統合テストがあれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- azure, typescript
- 領域
- api, cli
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 静か
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 48/100