Code Monkey home page Code Monkey logo

apicentre's Introduction

apicentre

apicentre (read: epicentre) is a place to host api documentation for different apis.

Motivation

When apis are designed by multiple teams, they would have their own pages documenting their own apis.

It will be really nice to have a single api documentation app where different teams could submit their api documentation or have the api documentation app pull openapi descriptions for rendering, but we could save engineering time by adopting the technique of micro-frontends.

apicentre implements micro-frontends using iframes.

This trades off coherence in the visual design of apicentre, but allows different teams the flexibility of using different styles of api documentation, as long as they can serve a webpage.

Preview

screenshot

Getting Started

Install dependencies

pip install -r requirements.txt

Write your links to a yaml file. (Each team should update this file once when they release an api)

$ cat sample-links.yml
- path: jsonbin
  label: jsonbin.io
  addr: https://jsonbin.io/api-reference
- path: xgboost
  label: Xgboost
  addr: https://xgboost.readthedocs.io/en/latest/python/python_api.html
$

Render the yaml file into App.js

./apicentre.py sample-links.yml

Preview!

yarn start

Todo

To try: implement a backend for apicentre to proxy requests, so that the individual teams won't even have to specifically unset the following on their pages

  • X-Frame-Options: sameorigin
  • X-Frame-Options: deny

apicentre's People

Contributors

ackerleytng avatar

Watchers

 avatar  avatar

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.