2024-08-11 16:15:30 +03:00
{
"openapi" : "3.1.0" ,
"info" : {
2024-08-12 21:40:15 +03:00
"title" : "BlueWave Uptime" ,
2024-08-11 16:15:30 +03:00
"summary" : "BlueWave Uptime OpenAPI Specifications" ,
"description" : "BlueWave Uptime is an open source server monitoring application used to track the operational status and performance of servers and websites. It regularly checks whether a server/website is accessible and performs optimally, providing real-time alerts and reports on the monitored services' availability, downtime, and response time." ,
"contact" : {
"name" : "API Support" ,
2024-08-11 18:52:19 +03:00
"url" : "mailto:support@bluewavelabs.ca" ,
"email" : "support@bluewavelabs.ca"
2024-08-11 16:15:30 +03:00
},
"license" : {
"name" : "AGPLv3" ,
"url" : "https://github.com/bluewave-labs/bluewave-uptime/tree/HEAD/LICENSE"
},
"version" : "1.0"
},
"servers" : [
{
2024-08-11 19:03:02 +03:00
"url" : "https://bluewavelabs.ca/{API_PATH}" ,
"description" : "Remote Development Server" ,
"variables" : {
"API_PATH" : {
"description" : "API Base Path" ,
"enum" : [ "api/v1" , "api/v1.1" , "api/v2" ],
"default" : "api/v1"
}
}
2024-08-11 16:15:30 +03:00
},
{
2024-08-11 19:03:02 +03:00
"url" : "http://localhost:{PORT}/{API_PATH}" ,
2024-08-11 16:15:30 +03:00
"description" : "Local Development Server" ,
"variables" : {
"PORT" : {
2024-08-11 19:03:02 +03:00
"description" : "API Port" ,
2024-08-11 16:15:30 +03:00
"enum" : [ "5000" , "3000" , "8080" ],
"default" : "5000"
2024-08-11 19:03:02 +03:00
},
"API_PATH" : {
"description" : "API Base Path" ,
"enum" : [ "api/v1" , "api/v1.1" , "api/v2" ],
"default" : "api/v1"
2024-08-11 16:15:30 +03:00
}
}
}
2024-08-12 21:39:10 +03:00
],
"tags" : [
{
"name" : "auth" ,
"description" : "Authentication"
}
],
"paths" : {
"/auth/register" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Register a new user" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/login" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Login with credentials" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/logout" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Logout" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/user/:userId" : {
"put" : {
"tags" : [ "auth" ],
"description" : "Change user informations" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
},
"delete" : {
"tags" : [ "auth" ],
"description" : "Delete user" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/users/admin" : {
"get" : {
"tags" : [ "auth" ],
"description" : "Checks to see if an admin account exists" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/users" : {
"get" : {
"tags" : [ "auth" ],
"description" : "Get all users" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/invite" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Invite people to application" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/invite/verify" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Verify the invite" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/recovery/request" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Request a recovery token" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/recovery/validate" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Validate recovery token" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
},
"/auth/recovery/reset" : {
"post" : {
"tags" : [ "auth" ],
"description" : "Password reset" ,
"responses" : {
"200" : {
"description" : "OK" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/SuccessResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"422" : {
"description" : "Unprocessable Content" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
},
"500" : {
"description" : "Internal Server Error" ,
"content" : {
2024-08-13 00:14:29 +03:00
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ErrorResponse"
}
}
2024-08-12 21:39:10 +03:00
}
}
}
}
}
2024-08-13 00:14:29 +03:00
},
"components" : {
"schemas" : {
"ErrorResponse" : {
"type" : "object" ,
"properties" : {
"success" : {
"type" : "boolean"
},
"msg" : {
"type" : "string"
}
}
},
"SuccessResponse" : {
"type" : "object" ,
"properties" : {
"success" : {
"type" : "boolean"
},
"msg" : {
"type" : "string"
},
"data" : {
"type" : "object"
}
}
}
}
2024-08-12 21:39:10 +03:00
}
2024-08-11 16:15:30 +03:00
}