hv-service/swagger.yaml

281 lines
6.3 KiB
YAML
Raw Normal View History

2021-01-16 19:47:34 +01:00
swagger: '2.0'
info:
title: Hausverwaltung
version: "0.1"
paths:
/hv/objekte:
get:
tags: [ "Objekte" ]
operationId: Objekte.get_objekte
summary: Returns all Objekte
responses:
200:
description: Successful response.
schema:
type: array
items:
$ref: '#/definitions/Objekt'
404:
description: No Objekte available
500:
description: Some server error
/hv/objekt/{id}:
get:
tags: [ "Objekte" ]
operationId: Objekte.get_objekt
summary: Returns Objekt by id
parameters:
- name: id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
$ref: '#/definitions/Objekt'
404:
description: Objekt not found
500:
description: Some server error
/hv/wohnungen:
get:
tags: [ "Wohnungen" ]
operationId: Wohnungen.get_wohnungen
summary: Returns all Wohnungen
responses:
200:
description: Successful response.
schema:
type: array
items:
$ref: '#/definitions/Wohnung'
404:
description: No Wohnung available
500:
description: Some server error
/hv/wohnung/{id}:
get:
tags: [ "Wohnungen" ]
operationId: Wohnungen.get_wohnung
summary: Returns Wohnung by id
parameters:
- name: id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
$ref: '#/definitions/Wohnung'
404:
description: Wohnung not found
500:
description: Some server error
/hv/mieters:
get:
tags: [ "Mieter" ]
operationId: Mieter.get_mieters
summary: Returns all Mieter
responses:
200:
description: Successful response.
schema:
type: array
items:
$ref: '#/definitions/Mieter'
404:
description: No Mieter available
500:
description: Some server error
/hv/mieter/{id}:
get:
tags: [ "Mieter" ]
operationId: Mieter.get_mieter
summary: Returns Mieter by id
parameters:
- name: id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
$ref: '#/definitions/Mieter'
404:
description: Mieter not found
500:
description: Some server error
2021-01-17 15:42:34 +01:00
/hv/forderung/{id}:
get:
tags: [ "Forderung" ]
operationId: Forderungen.get_forderung
summary: Returns Forderung by id
parameters:
- name: id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
$ref: '#/definitions/Forderung'
404:
description: Forderung not found
500:
description: Some server error
/hv/mieter/{mieter_id}/forderungen:
get:
tags: [ "Mieter", "Forderung" ]
operationId: Forderungen.get_forderungen_by_mieter
summary: Returns all Forderungen for a given Mieter
parameters:
- name: mieter_id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
type: array
items:
$ref: '#/definitions/Forderung'
404:
description: No Forderung available
500:
description: Some server error
/hv/zahlung/{id}:
get:
tags: [ "Zahlung" ]
operationId: Zahlungen.get_zahlung
summary: Returns Zahlung by id
parameters:
- name: id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
$ref: '#/definitions/Zahlung'
404:
description: Zahlung not found
500:
description: Some server error
/hv/mieter/{mieter_id}/zahlungen:
get:
tags: [ "Mieter", "Zahlung" ]
operationId: Zahlungen.get_zahlungen_by_mieter
summary: Returns all Zahlungen for a given Mieter
parameters:
- name: mieter_id
in: path
type: integer
required: true
responses:
200:
description: Successful response.
schema:
type: array
items:
$ref: '#/definitions/Zahlung'
404:
description: No Zahlung available
500:
description: Some server error
2021-01-16 19:47:34 +01:00
definitions:
Objekt:
description: Objekt type
type: object
properties:
id:
type: integer
shortname:
type: string
flaeche:
type: number
Wohnung:
description: Wohnung type
type: object
properties:
id:
type: integer
objekt_id:
type: integer
wohnung:
type: string
flaeche:
type: number
objekt:
type: string
Mieter:
description: Mieter type
type: object
properties:
id:
type: integer
objekt_id:
type: integer
wohnung_id:
type: integer
wohnung:
type: string
objekt:
type: string
anrede:
type: string
vorname:
type: string
nachname:
type: string
strasse:
type: string
plz:
type: string
ort:
type: string
telefon:
type: string
einzug:
type: string
auszug:
type: string
2021-01-17 15:42:34 +01:00
Forderung:
description: Forderung type
type: object
properties:
id:
type: integer
mieter_id:
type: integer
datum:
type: string
betrag:
type: number
kommentar:
type: string
Zahlung:
description: Zahlung type
type: object
properties:
id:
type: integer
mieter_id:
type: integer
datum_ist:
type: string
datum_soll:
type: string
betrag:
type: number
kommentar:
type: string