Add dedicated OData API support (extract & publish)

Open
#124 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
azure, typescript
Domain
api, cli

Research direction

Start in api-extractor.ts, api-publisher.ts, and apim-client.ts, tracing the existing apiType handling and getExportFormat()/getImportFormat() paths. Check the APIM API format documentation or existing client behavior to confirm the OData/CSDL export and import formats. Done means OData entity sets and functions survive extract and publish, with unit or integration tests covering both flows.

Written by the indexing model from the issue text.

Description

Enhancement P2

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). 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

Dominant language
TypeScript
Stars
29
Forks
10
Avg merge
1d 14h
Merged PRs (30d)
22

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Azure/apiops-cli

All issues in Azure/apiops-cli

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.