All Projects → theSage21 → redbull

theSage21 / redbull

Licence: MIT License
Develop JSON endpoints fast!

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to redbull

express-mquery
Expose mongoose query API through HTTP request.
Stars: ✭ 37 (+236.36%)
Mutual labels:  json-api
Swiftfall
Wrapper for Scryfall API written in Swift
Stars: ✭ 21 (+90.91%)
Mutual labels:  json-api
RESTEasy
REST API calls made easier
Stars: ✭ 12 (+9.09%)
Mutual labels:  json-api
wp-json-api-flutter
WordPress and WooCommerce JSON API for Flutter Mobile. Register Users, Login (with email or username), Get Users Info, Update Users Info, Update Users Password + more.
Stars: ✭ 24 (+118.18%)
Mutual labels:  json-api
instagramBot
A NodeJS wrapper for the Instagram Bot It works with instagram private api ,It has almost all the features the Instagram app.
Stars: ✭ 40 (+263.64%)
Mutual labels:  json-api
girias.json
JSON com gírias da rua e seus significados.
Stars: ✭ 40 (+263.64%)
Mutual labels:  json-api
json-caching-proxy
Node caching HTTP proxy built on top of express-http-proxy. Persists requests and responses to an in-memory HAR-like data structure based on HAR1.2 . Caches JSON content-type responses by default with the ability to cache an entire site; including content-types describing images. Useful for testing front end code, mocking api, and saving the cac…
Stars: ✭ 31 (+181.82%)
Mutual labels:  json-api
jsonapi
Set of tools to build a JSON:API compliant service.
Stars: ✭ 19 (+72.73%)
Mutual labels:  json-api
playsonify
An opinionated micro-framework to help you build practical JSON APIs with Play Framework (or akka-http)
Stars: ✭ 42 (+281.82%)
Mutual labels:  json-api
JSONinSV
JSON lib in Systemverilog
Stars: ✭ 25 (+127.27%)
Mutual labels:  json-api
dr scaffold
scaffold django rest apis like a champion 🚀
Stars: ✭ 116 (+954.55%)
Mutual labels:  json-api
laravel5-api
A modular controller for exposing Laravel 5 Eloquent models as a REST API
Stars: ✭ 13 (+18.18%)
Mutual labels:  json-api
json-api-serializer
Node.js/browser framework agnostic JSON API (http://jsonapi.org/) serializer.
Stars: ✭ 141 (+1181.82%)
Mutual labels:  json-api
laravel-json-api
Integrate JSON:API resources on Laravel
Stars: ✭ 17 (+54.55%)
Mutual labels:  json-api
hanami-serializer
Serializer library for hanami applications
Stars: ✭ 22 (+100%)
Mutual labels:  json-api
prisma-client-py
Prisma Client Python is an auto-generated and fully type-safe database client designed for ease of use
Stars: ✭ 739 (+6618.18%)
Mutual labels:  python-types
jsonapi-mapper
JSON API-Compliant Serialization for your Node ORM
Stars: ✭ 41 (+272.73%)
Mutual labels:  json-api
ck-web
Collective Knowledge web extension to browse CK repositories, visualize interactive graphs and articles, render CK-based websites, implement simple web services with JSON API (for example to crowdsource experiments or unify access to DNN). Demos of interactive articles, graphs and crowdsourced experiments:
Stars: ✭ 31 (+181.82%)
Mutual labels:  json-api
ctuning-programs
Collective Knowledge extension with unified and customizable benchmarks (with extensible JSON meta information) to be easily integrated with customizable and portable Collective Knowledge workflows. You can easily compile and run these benchmarks using different compilers, environments, hardware and OS (Linux, MacOS, Windows, Android). More info:
Stars: ✭ 41 (+272.73%)
Mutual labels:  json-api
MQL5-JSON-API
Metaquotes MQL5 - JSON - API
Stars: ✭ 183 (+1563.64%)
Mutual labels:  json-api

RedBull

Quickly develop JSON apis using Python type hints. Do not use in production

Minimal Example

from redbull import Manager

mg = Manager()

@mg.api()
def say_Hello(name: str='World'):
    "Says hello if you provide a name"
    return f'Hello {name}.'

mg.run()
  • APIs are live auto-documented at /<version>/docs
  • You can still code the way your framework of choice expects you to (Bottle, Flask, Django, Aiohttp ...)
  • Use python type hints to define json input keys.

The live page is minimal and looks like:

docs screenshot

A bigger example

from aiohttp import web
from redbull import Manager

mg = Manager(web.Application())  # You can use another framework if you want

# The function name say_hi becomes the api say/hi
# the args are treated as JSON keys. All args must by type annotated
# optional args are supported
# Simply return dict/string. Redbull wraps it for you in the appropriate object
@mg.api(pass_args=True)
async def say_hi(name: str,
                 please: bool,
                 lastname: str='Snow',  # A default is provided
                 __args__,  #     The original args passed to the function by Aiohttp
                 __kwargs__):  #  are added if pass_args is True in the decorator.
    "Says hi if you say please"
    if please:
        return 'hi ' + name
    return 'um hmm'

# ADD a generous CORS for all defined routes using the OPTIONS method
# The OPTIONS of the page also provides a documentation of the API
# Add a `/<version>/docs` GET Page
mg.run()

Notes

  • See if this is still possible with Flask / Django
  • DO NOT USE IN Production This is just a neat way of making life easier for the person who works on the UI and yourself. Security and other implications are not studies in any significant way.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].