Giter Site home page Giter Site logo

openapivalidator's Introduction

openAPIValidator - Validate your openapi spec like a boss

Microservice that runs set of tests on an exposed openapispecs of a microservice (as part of OpenAPI Specification).

Prerequisites:

  • Node ^v8
  • Firebase service account

Before running

As we have 2 separate environments in this setup, edit /config/production.json and development.json based on your project configurations:

  • Go to the main project overview tab https://console.firebase.google.com/u/0/project/<your-firebase-project-id>/overview, click on "Add app" and then chose "Web" (html-head icon), copy the content of the var config after the key FirebaseConf in the selected configuration file.
  • Generate a private key from: https://console.firebase.google.com/u/0/project/<your-firebase-project-id>/settings/serviceaccounts/adminsdk and paste it under the key "FirebaseAdminSDK". When executing from dev env use the env_param NODE_ENV=DEV.

Time to test your microservice (by method)

How to deploy

  • First install all node dependencies: npm i
  • Make sure you have firebase tools installed in your global: npm i -g firebase-tools
  • And deploy via: firebase deploy --only functions

How to extend

How you ask? Easy! Add to the following following func module.exports.syntaxValidator.validators (in src/utils.js) your desired new validator and link it to an external function

Example:
exampleForAValidator : ()=>yourFunctionallityGoesHere),

openapivalidator's People

Contributors

dependabot[bot] avatar evilurge 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.