OData / OData/RESTier

[2.0] OpenAPI Annotation Attributes

Open
#660 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature
Dominant language
C#
Stars
481
Forks
136
PR merge metrics
No merged PRs in 30d

Description

Feature
As a developer making a RESTier API I would like automated OData annotations so that my API consumers can more easily use the API

Scenario:
Given the Id property of an entity is designated with the [Key] attribute
When the $metadata is called
Then the property should have the computed=true attribute

For a nice list of properties that are pretty common / standard check out the annotations that the odata to openapi conversion tool supports:
https://github.com/oasis-tcs/odata-openapi/blob/master/doc/Annotations.md

Starting with adding support for the computed and the description attribute would be sufficient for most scenarios

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.

Research direction

Start by locating RESTier's $metadata generation and the handling of the [Key] attribute. Read the linked OData OpenAPI Annotations.md for the computed and description conventions. Done means metadata exposes computed=true for keyed entity properties and supports the requested description annotation.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, openapi
Domain
api, backend-api-design
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.