add middleware
add json_response
bad request
json for time