openapi: 3.0.0
info:
  version: v1
  title: Fuseki Proxy API
  contact:
    name: xyzw
    url: https://www.cdq.ch/team
    email: xyz@cdq.ch
tags:
  - name: Fuseki
    description: Nginx proxy for Fuseki service
servers:
  - url: http://fuseki-meta-cdq.internal.wiki.cdq/
    description: |
      meta -> Meta CDQ (meta.cdq.com)
  - url: http://fuseki-cdlplus-bayer.internal.wiki.cdq/
    description: |
      meta -> CDL+ Bayer (cdlplus-bayer.cdq.ch)
  - url: http://fuseki-meta-ferring.internal.wiki.cdq/
    description: |
      meta -> Meta Ferring (meta-ferring.cdq.ch)
  - url: http://fuseki-meta-novartis.internal.wiki.cdq/
    description: |
      meta -> Meta Novartis (meta-novartis.cdq.ch)
  - url: http://fuseki-odas.internal.wiki.cdq/
    description: |
      meta -> ODAS (odas.cdq.ch)
  - url: http://fuseki-sim-novartis.internal.wiki.cdq/
    description: |
      meta -> Sim Novartis (sim-novartis.cdq.ch)
  - url: http://fuseki-demo.internal.wiki.cdq/
    description: |
      meta -> Demo (demo.cdq.ch)
  - url: http://fuseki-testing.internal.wiki.cdq/
    description: |
      meta -> Testing (testing.wiki.cdq.ch)
paths:
  /backup:
    get:
      summary: Starts backup process with Supervisor
      description: >
        Multiple calls will not start multiple backups at the same time until
        the running one is done.


        1. Connect to CDQ VPN

        2. Hit this endpoint to trigger the backup process

        3. The data dump archive should be stored on S3
      tags:
        - Backup
      responses:
        '200':
          description: OK
          content:
            text/xml:
              schema:
                type: string
  /ping:
    get:
      summary: Redirects ping requests to Fuseki
      tags:
        - Ping
      responses:
        '200':
          description: OK
          content:
            text/plain:
              schema:
                type: string
  /refresh:
    get:
      summary: Restarts Fuseki and Nginx, removes Nginx cache
      description: >
        Does not require an additional use of /fuseki/start or /fuseki/stop
        endpoints
      tags:
        - Refresh
      responses:
        '200':
          description: OK
          content:
            text/xml:
              schema:
                type: string
  /fuseki/start:
    get:
      summary: Starts fuseki process with Supervisor
      description: |
        Will not stop already running process.
        Could be used immediately after /fuseki/stop
      tags:
        - Start
      responses:
        '200':
          description: OK
          content:
            text/xml:
              schema:
                type: string
  /fuseki/stop:
    get:
      summary: Stops fuseki process with Supervisor
      description: |
        Can kill the container if there is a health-check probing Fuseki.
      tags:
        - Stop
      responses:
        '200':
          description: OK
          content:
            text/xml:
              schema:
                type: string
  /sparql:
    get:
      summary: Redirects requests to Fuseki
      description: |
        This is a publicly available path!
      tags:
        - Sparql
      responses:
        '200':
          description: OK
          content:
            application/sparql-results+json:
              schema:
                type: string
components: {}
