Coder Social home page Coder Social logo

api-openapi-samples's People

Contributors

bfabio avatar giux78 avatar ioggstream avatar libremente avatar mauriamb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

api-openapi-samples's Issues

API Starter Kit

I wish

  • to have an API Starter Kit

  • the yaml

  • has a description divided in predefined section

  • all required fields populated

  • more fields with healthCheck endpoint (see docker/kubernetes)

  • a style guide for texts

  • a x-logo

  • references to docsitalia

Metadatazione API caso specifico PA2PA

Potrebbe essere utile recuperare qualcosa dalla BustaEgov come metadatazione specifica per le API rivolte allo scambio tra PA. Ad esempio il Codice IPA, ecc

Muoversi lombardia: glossario

@stefkohub.

Le info di glossario non le metterei direttamente qui ma in components.schemas.

Guarda in questo draft come le informazioni di glossario siano indicate sia sulla classe
che per campo.

https://github.com/teamdigitale/api-openapi-samples/blob/master/external-apis/spid-aa.yaml#L109

Un parser può semplicemente ricostruire tutto il gioco leggendo lo yaml e ricavare l'informazione completa e aggiornata.

eg.

    Point:
      externalDocs:
         url: URL VERSO IL GLOSSARIO
         x-glossary: true
      description: Un punto sulla mappa. Questo e' definito in un glossario e linkato tramite externalDocs
         oppure potremmo definire un x-glossary a questo livello.
      type: object
      properties:
        label:
          type: string
        type:
          type: string
        x:
          '$ref': '#/components/schemas/Longitudine'
        y:
          '$ref': '#/components/schemas/Latitudine'
      example:
        label: Rogoredo M3
        type: areadifermata
        x: 9.237421
        y: 45.433681

ERROR: json-schema-generator 0.3 has requirement jsonschema==0.8.0, but you'll have jsonschema 3.0.1 which is incompatible.

Running:

# pip install --user -r api-openapi-samples/requirements.txt

The output contains this error:

ERROR: json-schema-generator 0.3 has requirement jsonschema==0.8.0, but you'll have jsonschema 3.0.1 which is incompatible.

This is the complete output:

/opt # pip install --user -r api-openapi-samples/requirements.txt
Collecting openapi-spec-validator (from -r api-openapi-samples/requirements.txt (line 1))
  Downloading https://files.pythonhosted.org/packages/34/98/6bf2cbbc6633768f0a23baefa8e1c7be4bf4aeb800d3ee82fd0ccbb2dc7d/openapi_spec_validator-0.2.7-py3-none-any.whl
Collecting ansicolors (from -r api-openapi-samples/requirements.txt (line 2))
  Downloading https://files.pythonhosted.org/packages/53/18/a56e2fe47b259bb52201093a3a9d4a32014f9d85071ad07e9d60600890ca/ansicolors-1.1.8-py2.py3-none-any.whl
Collecting jsonschema (from -r api-openapi-samples/requirements.txt (line 3))
  Downloading https://files.pythonhosted.org/packages/aa/69/df679dfbdd051568b53c38ec8152a3ab6bc533434fc7ed11ab034bf5e82f/jsonschema-3.0.1-py2.py3-none-any.whl (54kB)
     |████████████████████████████████| 61kB 1.5MB/s
Collecting json_schema_generator (from -r api-openapi-samples/requirements.txt (line 4))
  Downloading https://files.pythonhosted.org/packages/63/3e/31b0bb289e02c3cf023ddd4214f4243e5d0af7ade85d9661ae67a546e868/json_schema_generator-0.3.tar.gz
Collecting yamllint (from -r api-openapi-samples/requirements.txt (line 5))
  Downloading https://files.pythonhosted.org/packages/a7/9b/f43134908f31b420f983726e348ac30f884c300e006f244ab095c29b942a/yamllint-1.16.0-py2.py3-none-any.whl (57kB)
     |████████████████████████████████| 61kB 1.8MB/s
Collecting openapi-resolver==0.0.6 (from -r api-openapi-samples/requirements.txt (line 6))
  Downloading https://files.pythonhosted.org/packages/c5/71/cf5da892021588d00082878c3d1eef5da70fd060c0241a9ef0800c7fd58f/openapi_resolver-0.0.6.tar.gz
Requirement already satisfied: PyYAML>=5.1 in /root/.local/lib/python3.7/site-packages (from openapi-spec-validator->-r api-openapi-samples/requirements.txt (line 1)) (5.1.1)
Requirement already satisfied: six in /root/.local/lib/python3.7/site-packages (from openapi-spec-validator->-r api-openapi-samples/requirements.txt (line 1)) (1.12.0)
Collecting pyrsistent>=0.14.0 (from jsonschema->-r api-openapi-samples/requirements.txt (line 3))
  Downloading https://files.pythonhosted.org/packages/68/0b/f514e76b4e074386b60cfc6c8c2d75ca615b81e415417ccf3fac80ae0bf6/pyrsistent-0.15.2.tar.gz (106kB)
     |████████████████████████████████| 112kB 2.9MB/s
Requirement already satisfied: setuptools in /usr/local/lib/python3.7/site-packages (from jsonschema->-r api-openapi-samples/requirements.txt (line 3)) (41.0.1)
Collecting attrs>=17.4.0 (from jsonschema->-r api-openapi-samples/requirements.txt (line 3))
  Downloading https://files.pythonhosted.org/packages/23/96/d828354fa2dbdf216eaa7b7de0db692f12c234f7ef888cc14980ef40d1d2/attrs-19.1.0-py2.py3-none-any.whl
Collecting pathspec>=0.5.3 (from yamllint->-r api-openapi-samples/requirements.txt (line 5))
  Downloading https://files.pythonhosted.org/packages/84/2a/bfee636b1e2f7d6e30dd74f49201ccfa5c3cf322d44929ecc6c137c486c5/pathspec-0.5.9.tar.gz
Requirement already satisfied: pathlib in /root/.local/lib/python3.7/site-packages (from openapi-resolver==0.0.6->-r api-openapi-samples/requirements.txt (line 6)) (1.0.1)
Building wheels for collected packages: json-schema-generator, openapi-resolver, pyrsistent, pathspec
  Building wheel for json-schema-generator (setup.py) ... done
  Stored in directory: /root/.cache/pip/wheels/30/1a/6d/85a2d8cf580546e8356f8921b3622b3dc0833a1df8ce4d9787
  Building wheel for openapi-resolver (setup.py) ... done
  Stored in directory: /root/.cache/pip/wheels/d0/10/0f/91d302475b7fc63b16aa945c51d2038fd28a63a76075ddc2b0
  Building wheel for pyrsistent (setup.py) ... done
  Stored in directory: /root/.cache/pip/wheels/6b/b9/15/c8c6a1e095a370e8c3273e65a5c982e5cf355dde16d77502f5
  Building wheel for pathspec (setup.py) ... done
  Stored in directory: /root/.cache/pip/wheels/45/cb/7e/ce6e6062c69446e39e328170524ca8213498bc66a74c6a210b
Successfully built json-schema-generator openapi-resolver pyrsistent pathspec
ERROR: json-schema-generator 0.3 has requirement jsonschema==0.8.0, but you'll have jsonschema 3.0.1 which is incompatible.
Installing collected packages: pyrsistent, attrs, jsonschema, openapi-spec-validator, ansicolors, json-schema-generator, pathspec, yamllint, openapi-resolver
  WARNING: The script jsonschema is installed in '/root/.local/bin' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
  WARNING: The script openapi-spec-validator is installed in '/root/.local/bin' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
  WARNING: The script yamllint is installed in '/root/.local/bin' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
  Found existing installation: openapi-resolver 0.0.5
    Uninstalling openapi-resolver-0.0.5:
      Successfully uninstalled openapi-resolver-0.0.5
Successfully installed ansicolors-1.1.8 attrs-19.1.0 json-schema-generator-0.3 jsonschema-3.0.1 openapi-resolver-0.0.6 openapi-spec-validator-0.2.7 pathspec-0.5.9 pyrsistent-0.15.2 yamllint-1.16.0
/opt #

Python used:

# python -V
Python 3.7.3
#

Remove swagger / openapi v2 files

I expect

This repo should only reference OpenAPI 3.0 files.
Swagger 2.0 files should only be the outcome of conversion.

Now many projects are openapi v3 ready and
the converters works nicely enough to support most of the 3-to-2 features.

.env.example PORTAL_ suffix for variables??

externally reachable port of the mssql service-db

PORTAL_SERVICE_DB_PORT=1434

username for the keycloak admin user

PORTAL_KEYCLOAK_ADMIN=admin

port on which nginx is reachable on the host

PORTAL_REVERSEPROXY_PORT=80

should be this?

externally reachable port of the mssql service-db

SERVICE_DB_PORT=1434

username for the keycloak admin user

KEYCLOAK_ADMIN=admin

port on which nginx is reachable on the host

REVERSEPROXY_PORT=80

Cleanup old files

I wish

To cleanup old files

  • remove legacy openapi-v2 files
  • source python scripts from pypi

Metadata on Muoversi Lombardia

I expect

The OAS3 specs under this branch https://github.com/teamdigitale/api-openapi-samples/tree/14-metadata-muoversi-lombardia conforms to:

  • Muoversi Lombardia contains metadata under info

  • Muoversi Lombardia contains all required documentation

  • Schemes in "glossaries" should be exposed via a "glossary" url

Files are:

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.