guillotinaweb / guillotina_swagger

1 stars 1 forks source link

Introduction

A guillotina application to automatically generate swagger interfaces for APIs defined with guillotina.

Configuration

Available config.json options::

{
    "swagger": {
        "authentication_allowed": false,
        "base_configuration": {
            "swagger": "2.0",
            "info": {
                "version": "",
                "title": "Guillotina",
                "description": "The REST Resource API"
            },
            "host": "",
            "basePath": "",
            "schemes": [],
            "produces": [
                "application/json"
            ],
            "consumes": [
                "application/json"
            ],
            "paths": {},
            "definitions": {}
        },
        "index_html": null
    }
}

Viewing swagger for resource

Append @docs onto any url: http://localhost:8080/@docs.

Generating swagger docs

guillotina_swagger reads service configuration.

You can provide additional swagger configuration hints by providing a swagger configuration with any of the following options: