Skip to content

API's (Swagger)

Simplifying API Development and Documentation

api diagram

Swagger is an open-source framework designed to aid in the development, design, documentation, and consumption of RESTful web services. By providing a suite of tools and an established specification, Swagger streamlines the creation and management of APIs, making it easier for developers to build and maintain robust and well-documented APIs.

Key Features

  • OpenAPI Specification: Swagger leverages the OpenAPI Specification (OAS), a standard format for describing REST APIs, ensuring consistency and compatibility across different tools and platforms.
  • Interactive API Documentation: With Swagger UI, developers can generate interactive, web-based documentation for their APIs, allowing for easy exploration and testing of API endpoints.
  • API Design and Development: Tools like Swagger Editor and SwaggerHub facilitate the design and development process, enabling collaboration and seamless integration with development workflows.
  • Code Generation: Swagger Codegen allows for the automatic generation of client libraries, server stubs, and API documentation in various programming languages, speeding up development and ensuring consistency.
  • Community and Ecosystem: Swagger boasts a vibrant community and a rich ecosystem of tools and integrations, enhancing its capabilities and ensuring continuous improvement.

Getting Started

To get started with Swagger, visit the official Swagger website and explore the comprehensive documentation, tutorials, and resources available. The Swagger Editor and SwaggerHub provide intuitive platforms for designing and documenting your APIs.

Community and Support

Join the Swagger community through the Swagger GitHub repository to engage with other users, contribute to the project, and stay informed about the latest updates and features. The active community ensures robust support and continuous innovation.

Experience the efficiency and clarity of API development with Swagger—a framework designed to simplify and enhance the entire lifecycle of your APIs.

Volumes

/nfs-nas-swarm/config/
/nfs-nas-swarm/data/

Deployment

No Special requirments

Docker swarm file

version: '3.3'
services:
  api:
    image: swaggerapi/swagger-editor
    environment:
      PGID: '911'
      PUID: '911'
      TZ: Europe/Amsterdam
      SWAGGER_JSON_URL: '/api/swagger.yml'
    networks:
     - traefik-public
    logging:
      driver: json-file
    deploy:
      labels:
        traefik.http.routers.api-http.middlewares: https-redirect
        traefik.http.routers.api-http.rule: Host(`api.vnerd.nl`)
        traefik.http.services.api.loadbalancer.server.port: '8080'
        traefik.http.routers.api-https.tls: 'true'
        traefik.http.routers.api-https.tls.certresolver: le
        traefik.constraint-label: traefik-public
        traefik.http.routers.api-https.rule: Host(`api.vnerd.nl`)
        traefik.docker.network: traefik-public
        traefik.enable: 'true'
        traefik.http.routers.api-https.entrypoints: https
        traefik.http.routers.api-http.entrypoints: http
      placement:
        constraints:
         - node.labels.Arch!=i686
         - node.labels.worker==enabled
  vc:
    image: swaggerapi/swagger-ui
    environment:
      PGID: '911'
      PUID: '911'
      TZ: Europe/Amsterdam
      SWAGGER_FILE: '/usr/share/nginx/html/api/swagger.yml'
      SWAGGER_JSON_URL: '/api/swagger.yml'
    volumes:
     - /swarm/config/api/vc:/usr/share/nginx/html/api
    networks:
     - traefik-public
    logging:
      driver: json-file
    deploy:
      labels:
        traefik.http.routers.vc-http.middlewares: https-redirect
        traefik.http.routers.vc-http.rule: Host(`vc.api.vnerd.nl`)
        traefik.http.services.vc.loadbalancer.server.port: '8080'
        traefik.http.routers.vc-https.tls: 'true'
        traefik.http.routers.vc-https.tls.certresolver: le
        traefik.constraint-label: traefik-public
        traefik.http.routers.vc-https.rule: Host(`vc.api.vnerd.nl`)
        traefik.docker.network: traefik-public
        traefik.enable: 'true'
        traefik.http.routers.vc-https.entrypoints: https
        traefik.http.routers.vc-http.entrypoints: http
      placement:
        constraints:
         - node.labels.Arch!=i686
         - node.labels.worker==enabled
  aria:
    image: swaggerapi/swagger-ui
    environment:
      PGID: '911'
      PUID: '911'
      TZ: Europe/Amsterdam
      SWAGGER_FILE: '/usr/share/nginx/html/api/swagger.yml'
      SWAGGER_JSON_URL: '/api/swagger.yml'
    volumes:
     - /swarm/config/api/aria:/usr/share/nginx/html/api
    networks:
     - traefik-public
    logging:
      driver: json-file
    deploy:
      labels:
        traefik.http.routers.aria-http.middlewares: https-redirect
        traefik.http.routers.aria-http.rule: Host(`aria.api.vnerd.nl`)
        traefik.http.services.aria.loadbalancer.server.port: '8080'
        traefik.http.routers.aria-https.tls: 'true'
        traefik.http.routers.aria-https.tls.certresolver: le
        traefik.constraint-label: traefik-public
        traefik.http.routers.aria-https.rule: Host(`aria.api.vnerd.nl`)
        traefik.docker.network: traefik-public
        traefik.enable: 'true'
        traefik.http.routers.aria-https.entrypoints: https
        traefik.http.routers.aria-http.entrypoints: http
      placement:
        constraints:
         - node.labels.Arch!=i686
         - node.labels.worker==enabled
  lcm:
    image: swaggerapi/swagger-ui
    environment:
      PGID: '911'
      PUID: '911'
      TZ: Europe/Amsterdam
      SWAGGER_FILE: '/usr/share/nginx/html/api/swagger.yml'
      SWAGGER_JSON_URL: '/api/swagger.yml'
    volumes:
     - /swarm/config/api/lcm:/usr/share/nginx/html/api
    networks:
     - traefik-public
    logging:
      driver: json-file
    deploy:
      labels:
        traefik.http.routers.lcm-http.middlewares: https-redirect
        traefik.http.routers.lcm-http.rule: Host(`lcm.api.vnerd.nl`)
        traefik.http.services.lcm.loadbalancer.server.port: '8080'
        traefik.http.routers.lcm-https.tls: 'true'
        traefik.http.routers.lcm-https.tls.certresolver: le
        traefik.constraint-label: traefik-public
        traefik.http.routers.lcm-https.rule: Host(`lcm.api.vnerd.nl`)
        traefik.docker.network: traefik-public
        traefik.enable: 'true'
        traefik.http.routers.lcm-https.entrypoints: https
        traefik.http.routers.lcm-http.entrypoints: http
      placement:
        constraints:
         - node.labels.Arch!=i686
         - node.labels.worker==enabled
networks:
  traefik-public:
    external: true

Notes

Comments