Skip to content
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

Create Camara-OAS-Sections-Guidelines.md #317

Draft
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

shilpa-padgaonkar
Copy link
Collaborator

@shilpa-padgaonkar shilpa-padgaonkar commented Oct 15, 2024

What type of PR is this?

Add one of the following kinds:

  • cleanup
  • documentation

What this PR does / why we need it:

Creates a new document with guidelines for OAS sections. Will add all the content related to OAS sections which was originally part of API design guidelines doc,

Which issue(s) this PR fixes:

Fixes #306

Does this PR introduce a breaking change?

  • Yes
  • No

Special notes for reviewers:

Changelog input

 release-note

Additional documentation

This section can be blank.

docs

@PedroDiez
Copy link
Collaborator

18/OCT: Fine to me so far

+ [External Documentation](#ext-doc)

## Introduction
Camara uses OpenAPI Specification (OAS) to describe its APIs. The below guidelines specify the restrictions or conventions to be followed within the OAS yaml by all Camara APIs (referred below simply as APIs).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Camara -> CAMARA (multiple occurences)


## Conventions
The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest to add a section on the OAS file name which should be the api name in kebab-case.yaml e.g. simple-edge-discovery.yaml

Title describes the API shortly. The title shall not include the term "API" in it.

#### Description
No special restrictions specified in Camara.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the description shall include the user documentation for the API.
as well as a copy from the section from the ICM guidelines on the auth flows applicable to the API.

default: http://localhost:9091
description: API root, defined by the service provider, e.g. `api.example.com` or `api.example.com/somepath`
```
<b>API-Name</b>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use as in the example above ?


</br>

<b>API-Version </b> </br>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use as in the example above ?


For the below example, the API-name would be location-verification.
```
/location-verification/v0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make this example use v1 instead of v0 (see next comment)


<b>API-Version </b> </br>

API-Version shall be same as the [Version](#version) in the info object.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shall be a "v" concatenated with the MAJOR version number of the version field in the info object.
A CAMARA specific exception is that for APIs with version 0.y.z, the both the MAJOR and the MINOR version number are included in the , e.g. simple-edge-discovery/v0.3

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should probably reference the section on API versioning in the API design guidelines


### Paths
No special restrictions or changes specified in Camara.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this be added to the end of the API Guidelines where there is a section on the OAS specification ? else this risks to create duplication / divergence

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cleanup and slim down design guidelines document
3 participants