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

Bundle Admin API Swagger file with API Umbrella? #211

Open
brylie opened this issue Jan 25, 2016 · 9 comments
Open

Bundle Admin API Swagger file with API Umbrella? #211

brylie opened this issue Jan 25, 2016 · 9 comments

Comments

@brylie
Copy link
Contributor

brylie commented Jan 25, 2016

User story

As a developer
I need an API Umbrella instance to provide a self-referencing Swagger file
so that I can easily create a JavaScript wrapper around the Admin API

As a system administrator
I would like for an API Umbrella instance to provide a self-referencing Swagger file
so that I can make test calls to our API Umbrella instance from the Swagger UI

Goal

The goal of this feature request is to have API Umbrella provide a self-referencing Swagger documentation file, for any given API Umbrella instance.

Feature

We are interested in using swagger.js to integrate with one or more API Umbrella instances:

var Swagger = require('swagger-client');

var client = new Swagger({
  url: 'http://umbrella.example.com/api/v1/swagger.json',
  success: function() {
    client.api.get(...);
  }
});

The only swagger descriptor file I can find is located at api-umbrella.readthedocs.org.

Background

We have been maintaining an API Umbrella integration package for Meteor.js. The package uses the API Umbrella Admin API to manage a given API Umbrella instance. Maintaining this package seems unnecessary, when the swagger.js would serve the same purpose.

Considerations

Rails

Currently, API Umbrella Admin API is provided by the Ruby on Rails based API Umbrella Web. Initially, the self-documented Swagger file might be provided by the Rails frontend.

Lua

In the future, it may prove beneficial to consolidate the platform by moving the Admin API into the Lua port, which currently contains a minimal HTTP API.

@diegojonio
Copy link

I couldn't find one on a running instance either.
The Admin Api documentation is on this web-site: https://api-umbrella.readthedocs.org/en/latest/admin/api.html

But I found a Meteor wrapper for the Admin Api, check it out: https://github.com/apinf/meteor-api-umbrella

@brylie
Copy link
Contributor Author

brylie commented Apr 4, 2016

Jep, we are hoping to deprecate that module if API Umbrella can include a self referencing swagger.json. E.g. the API document would refer to the base URL of the API Umbrella instance.

@diegojonio
Copy link

Would it be embedded on the api-umbrella-static-website?

@brylie
Copy link
Contributor Author

brylie commented Apr 4, 2016

Basically, yes. Although the baseUrl would need to be dynamically set by the server, so that the API is self documenting.

@brylie brylie changed the title Bundle Admin API swagger.json with API Umbrella? Bundle Admin API Swagger file with API Umbrella? Apr 11, 2016
@brylie
Copy link
Contributor Author

brylie commented Apr 11, 2016

@GUI, we are still waiting on your input here. We can provide some development time towards this feature request.

@shaliko
Copy link
Contributor

shaliko commented Apr 11, 2016

The task can be managed by adding "swagger-blocks" or "ruby-swagger".

@brylie
Copy link
Contributor Author

brylie commented Apr 11, 2016

@shaliko would either, or both, of those modules work well with the current API Umbrella Web structure?

@shaliko
Copy link
Contributor

shaliko commented Apr 11, 2016

@brylie Based on Readme of these GEM's, both can manage the goal of this issue. I don't see any difference related to API Umbrella Web structure.

@brylie
Copy link
Contributor Author

brylie commented Apr 11, 2016

OK, I have created an issue in our project repository, so that we can track the progress towards this goal. We will try to work with @GUI, so that our efforts are compatible with the goals of API Umbrella.

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

No branches or pull requests

3 participants