All API requests must include your API key in the header:
X-API-Key: your_api_key_here
API requests are limited to 100 requests per minute. If you exceed this limit, you'll receive a 429 Too Many Requests response.
Returns a list of all websites monitored by your account.
curl -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/websites
{
"success": true,
"websites": [
{
"id": 1,
"name": "Example Website",
"url": "https://www.example.com",
"status": "up",
"last_checked": "2025-04-18T08:30:00Z",
"ssl_status": "valid",
"ssl_expiry": "2026-04-18T00:00:00Z",
"keyword_status": "found",
"monitor_type": "http"
},
{
"id": 2,
"name": "SIP Server",
"url": "sip:sipserver.example.com:5060",
"status": "up",
"last_checked": "2025-04-18T08:35:00Z",
"monitor_type": "sip"
}
]
}
Returns detailed information about a specific website.
id
(path parameter): The ID of the websitecurl -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/website/1
{
"success": true,
"website": {
"id": 1,
"name": "Example Website",
"url": "https://www.example.com",
"status": "up",
"last_checked": "2025-04-18T08:30:00Z",
"ssl_status": "valid",
"ssl_expiry": "2026-04-18T00:00:00Z",
"keyword_status": "found",
"keywords": ["example", "test", "monitoring"],
"check_interval": 5,
"monitor_type": "http",
"uptime_30d": 99.98,
"response_time_avg": 320
}
}
Returns a list of alert configurations for a specific website.
id
(path parameter): The ID of the websitecurl -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/website/1/alerts
{
"success": true,
"alerts": [
{
"id": 1,
"website_id": 1,
"type": "downtime",
"threshold": 5,
"notification_method": "email",
"email": "admin@example.com",
"is_active": true
},
{
"id": 2,
"website_id": 1,
"type": "ssl_expiry",
"threshold": 30,
"notification_method": "both",
"email": "admin@example.com",
"phone": "+1234567890",
"is_active": true
}
]
}
Returns recent notifications sent for a specific website.
id
(path parameter): The ID of the websitelimit
(query parameter, optional): Maximum number of notifications to return (default: 10)curl -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/website/1/notifications?limit=5
{
"success": true,
"notifications": [
{
"id": 1,
"website_id": 1,
"alert_id": 1,
"message": "Website Example Website is down (HTTP 500)",
"sent_at": "2025-04-17T14:30:00Z",
"notification_method": "email"
},
{
"id": 2,
"website_id": 1,
"alert_id": 1,
"message": "Website Example Website is back up",
"sent_at": "2025-04-17T14:45:00Z",
"notification_method": "email"
}
]
}
Returns information about your tenant account.
curl -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/tenant
{
"success": true,
"tenant": {
"id": 1,
"name": "Example Company",
"subdomain": "example",
"logo_url": "/static/uploads/logos/tenant_1_logo.png",
"created_at": "2025-01-15T10:00:00Z",
"website_count": 5,
"user_count": 3
}
}
Returns information about the authenticated user.
curl -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/user
{
"success": true,
"user": {
"id": 1,
"username": "admin",
"email": "admin@example.com",
"role": "admin",
"tenant_id": 1,
"created_at": "2025-01-15T10:00:00Z",
"last_login": "2025-04-18T08:00:00Z"
}
}
Triggers an immediate check of a website and returns the results.
id
(path parameter): The ID of the website to checkcurl -X POST -H "X-API-Key: your_api_key_here" https://mysitesalive.com/api/website/1/check
{
"success": true,
"check_result": {
"website_id": 1,
"status": "up",
"response_time": 215,
"response_code": 200,
"ssl_status": "valid",
"ssl_expiry": "2026-04-18T00:00:00Z",
"keyword_status": "found",
"checked_at": "2025-04-18T10:30:00Z"
}
}
The API uses standard HTTP status codes to indicate the success or failure of a request. Additional information may be provided in the response body.
Status Code | Description |
---|---|
200 OK | The request was successful. |
400 Bad Request | The request was invalid or cannot be served. The exact error is explained in the response body. |
401 Unauthorized | Authentication failed or user doesn't have permissions for the requested operation. |
404 Not Found | The requested resource could not be found. |
429 Too Many Requests | You have sent too many requests in a given amount of time. |
500 Internal Server Error | An error occurred on the server while processing the request. |
Sign in to your account to generate your API key and start building with our monitoring platform.