Giter Club home page Giter Club logo

api-guidelines's Introduction

description
Guidelines for the API design and development at adidas

adidas API Guidelines

adidas logo

License: MIT

Read online at GitBook

Motivation

The goal of this document is to facilitate the work and minimize the effort of all API users at adidas while protecting their investment and encouraging API adoption.

These guidelines lay down the foundation for collaboration, stability, and extensibility.

Guidelines

The API Guidelines are split into two main parts:

The general guidelines section discusses the core principles relevant to any kind of API. The API type-specific section further defines the guidelines specific to a given architectural style or API technique (such as REST, Kafka or GraphQL APIs).

How to read the Guidelines

These Guidelines are available for online reading at GitBook its source can be found on GitHub.

The CAPITALIZED words throughout these guidelines have a special meaning:

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED",  "MAY", and "OPTIONAL" in 
this document are to be interpreted as described in RFC2119.

Refer to RFC2119 for details.

Validating your API Guidelines against OpenAPI Specification

In the ruleset.md file you can find a digest of API Guidelines rules which you can validating your API description documents with. If you are using OpenAPI Specification as the API description format you can also leverage the .spectral.yaml ruleset to automatically verify your specification compliance using Spectral.

To install Spectral you will need Node.js and a package manager (npm or yarn).

Note: The version used with the spectal specifictions was 5.3.0

npm install -g @stoplight/[email protected]

# OR

yarn global add @stoplight/[email protected]

Once installed, to verify your OAS file with spectral execute spectral lint <oas-file> -r <adidas-api-guidelines-folder>/.spectral.yaml where <adidas-api-guidelines-folder>/.spectral.yaml indicated the location .spectral.yaml file.

For further documentation on Spectral refer to their documentation.

Questions & Comments

Please contact [email protected] in case of questions.

Intended Use Cases

This project is intended to provide the guidelines for design & development of APIs at adidas.

adidas is not responsible for the usage of this software for different purposes that the ones described in the use cases.

Last Review

February 2021

License and Software Information

© adidas AG

adidas AG publishes this software and accompanied documentation (if any) subject to the terms of the MIT license with the aim of helping the community with our tools and libraries which we think can be also useful for other people. You will find a copy of the MIT license in the root folder of this package. All rights not explicitly granted to you under the MIT license remain the sole and exclusive property of adidas AG.

NOTICE: The software has been designed solely for the purpose of providing API design and development guidelines. The software is NOT designed, tested or verified for productive use whatsoever, nor or for any use related to high risk environments, such as health care, highly or fully autonomous driving, power plants, or other critical infrastructures or services.

If you want to contact adidas regarding the software, you can mail us at [email protected].

For further information open the adidas terms and conditions page.

License

MIT

api-guidelines's People

Contributors

albertosh avatar alikhalili avatar amzani avatar apidesigner avatar azetilov avatar cesareomacias avatar danicatalan avatar dependabot[bot] avatar felipesolanaadidas avatar filfreire avatar fmvilas avatar gitbook-bot avatar jerzyn avatar jesusjavierdediego avatar jesusjavierdediegoadidas avatar jmsampayo avatar oonovak avatar zdne avatar zinch avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

api-guidelines's Issues

Could not parse https://unpkg.com/spectral:oas2: Forbidden

  • I'm submitting a ...

    • bug report
    • feature request
    • support request
  • What is the current behavior?

spectral lint ./demo-orderapi-v3.oas2.yaml -r ./api-guidelines/.spectral.yml
Could not parse https://unpkg.com/spectral:oas2: Forbidden
  • What is the expected behavior?

Showing the potentials warnings / errors to validate the API Spec against the guidelines

  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)

node version: v12.16.1
spectral version: 5.2.0

Guidelines for muti-value search filters

  • I'm submitting a ...

    • feature request
  • What is the current behavior?
    While we have guidelines on how to request multiple fields or embedded resources, search request section does not consider multi-value filters. OpenAPI defines different serialization options so we could mention all of them or choose one format as preferred option: https://swagger.io/docs/specification/serialization/

  • What is the expected behavior?
    Search filter structures for multi-value attributes are mentioned in the search request section.

  • What is the motivation / use case for changing the behavior?
    I think it is always advisable to provide guidelines for complex search filters as it is a common user case for many APIs.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.