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

Design API backend schema #1091

Closed
3 tasks
bajiat opened this issue Jun 8, 2016 · 4 comments · Fixed by #1397
Closed
3 tasks

Design API backend schema #1091

bajiat opened this issue Jun 8, 2016 · 4 comments · Fixed by #1397
Assignees
Milestone

Comments

@bajiat
Copy link
Contributor

bajiat commented Jun 8, 2016

In order to decouple API backends from Api Umbrella, we will need a collection for API backend that is separate from the proxy settings. In other words, the schema needs to be changed and separated from proxies and their settings.

Idea: Align with Swagger specification or Open API specification (depending on the schedule of the latter). This might enable importing API backend configuration by importing Swagger (or Open API) file. Only after adding the API backend, the owner would assign a proxy to it.

Potential user story related to the Swagger idea:

As an API owner
I want to add my API by importing a Swagger file
so that I can reuse my Swagger file and do not need to type in the API details

As a minimum requirement, all fields that exist both in our collection and in Swagger spec should match.

Definition of done

  • Api Backend schema exists
  • Api Backend does not contain API Umbrella related settings
  • When applicable, schema field(s) confirm to Swagger / Open API specification
@brylie
Copy link
Contributor

brylie commented Aug 15, 2016

After initial discussion, we agreed to rename the ApiBackends collection to Apis, and set up the following schema:

# Apis
- name
- Description
- isPublic
- backendUrl
- version
- managerIds
- averageRating
- bookmarkCount
- created_at
- created_by
- updated_at
- updated_by
- proxyId

@jykae
Copy link
Contributor

jykae commented Aug 17, 2016

I think we need also these:

documentationFileId: {
    type: String,
    optional: true
  },
  apiLogoFileId: {
    type: String,
    optional: true
  },
  documentation_link: {
    type: String,
    optional: true,
    regEx: SimpleSchema.RegEx.Url
  }

@brylie
Copy link
Contributor

brylie commented Aug 17, 2016

@brylie
Copy link
Contributor

brylie commented Aug 17, 2016

As part of this task, I have been removing a bit of code related to the following components:

  • API Umbrella
  • Add API wizard
  • Initial setup wizard

We can re-introduce API Umbrella code at a later point, but both of the wizards were deemed unnecessary for the time being (after discussions at standup and with @bajiat). As such, I am designing a modal dialogue to inform admin users when either the Branding or Settings collection are empty, so they know to visit those pages (ping @Nazarah):

screenshot from 2016-08-17 14-57-45

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