- Added first draft of yaml file - Added Python stubs generated by postman export tool
64 lines
1.3 KiB
Python
64 lines
1.3 KiB
Python
import json
|
|
|
|
|
|
def GetTimes(options):
|
|
"""
|
|
:param options: A dictionary containing all the paramters for the Operations
|
|
options["shipcall_id"]: **Id**. *Example: 42*. Id of referenced ship call.
|
|
|
|
"""
|
|
|
|
# Implement your business logic here
|
|
# All the parameters are present in the options argument
|
|
|
|
return json.dumps([{
|
|
"duration_planned": "<integer>",
|
|
"end_actual": "<date-time>",
|
|
"end_planned": "<date-time>",
|
|
"id": "<integer>",
|
|
"participant_id": "<integer>",
|
|
"shipcall_id": "<integer>",
|
|
"start_actual": "<date-time>",
|
|
"start_planned": "<date-time>",
|
|
}]), 200
|
|
|
|
|
|
def PostTimes(body):
|
|
"""
|
|
|
|
:param body: The parsed body of the request
|
|
"""
|
|
|
|
# Implement your business logic here
|
|
# All the parameters are present in the options argument
|
|
|
|
return 400
|
|
|
|
|
|
def PutTimes(body):
|
|
"""
|
|
|
|
:param body: The parsed body of the request
|
|
"""
|
|
|
|
# Implement your business logic here
|
|
# All the parameters are present in the options argument
|
|
|
|
return 400
|
|
|
|
|
|
def DeleteTimes(options):
|
|
"""
|
|
:param options: A dictionary containing all the paramters for the Operations
|
|
options["id"]
|
|
|
|
"""
|
|
|
|
# Implement your business logic here
|
|
# All the parameters are present in the options argument
|
|
|
|
return 400
|
|
|
|
|
|
|