Create a TCP check
Create a new TCP check to monitor TCP connectivity
Requires UPTIME_CHECKS:EDIT; EDIT also grants READ. Session cookies are accepted only when no bearer credential is supplied.
Security: Bearer Auth
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Header parameters
Body parameters
Responses
| Status | Meaning | Description |
|---|---|---|
| 201 | Created | Create a new OnlineOrNot TCP Check |
| 400 | Bad Request | Validation error |
| 401 | Unauthorized | Unauthenticated |
| 403 | Forbidden | Forbidden |
| 500 | Internal Server Error | Internal Server Error |
Response Schema
Request
curl --request POST \
--url https://api.onlineornot.com/v1/checks/tcp \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'Content-Type: application/json' \
--header 'X-OnlineOrNot-Organisation: string' \
--data '{"name":"TCP for example.com:443","tcp_hostname":"example.com","tcp_port":443,"test_interval":60}'
Response
{
"result": {
"id": "a1b2c3d4",
"name": "My landing page",
"last_queued": "2021-01-01T00:00:00.000Z",
"status": "UP",
"reminder_alert_interval_minutes": 1440,
"confirmation_period_seconds": 60,
"recovery_period_seconds": 180,
"test_interval": 60,
"timeout": 0,
"alert_priority": "HIGH",
"test_regions": [
"aws:us-east-1",
"aws:eu-central-1"
],
"user_alerts": [
"string"
],
"slack_alerts": [
"string"
],
"discord_alerts": [
"string"
],
"incident_io_alerts": [
"string"
],
"microsoft_teams_alerts": [
"string"
],
"telegram_alerts": [
"string"
],
"pushover_alerts": [
"string"
],
"oncall_alerts": [
"string"
],
"webhook_alerts": [
"string"
],
"check_type": "TCP",
"url": null,
"version": "NODE24_TCP",
"tcp_hostname": "tcpbin.com",
"tcp_port": 4242,
"tcp_ip_family": "IPv4",
"tcp_data": "string",
"tcp_should_fail": false,
"assertions": [
{
"type": "TCP_RESPONSE_DATA",
"property": "",
"comparison": "EQUALS",
"expected": "OK"
}
]
},
"success": true,
"errors": [],
"messages": []
}
Retrieve a TCP check
Look up detailed information about a specific TCP check
Requires UPTIME_CHECKS:READ; EDIT also grants READ. Session cookies are accepted only when no bearer credential is supplied.
Security: Bearer Auth
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Header parameters
Path parameters
Responses
| Status | Meaning | Description |
|---|---|---|
| 200 | OK | Retrieve the specified OnlineOrNot TCP Check. May also return a canonical failure envelope with success: false at HTTP200. |
| 400 | Bad Request | Invalid request |
| 401 | Unauthorized | Unauthenticated |
| 403 | Forbidden | Forbidden |
| 404 | Not Found | TCP check not found |
| 500 | Internal Server Error | Internal Server Error |
Response Schema
Request
curl --request GET \
--url https://api.onlineornot.com/v1/checks/tcp/a1b2c3d4 \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'X-OnlineOrNot-Organisation: string'
Response
{
"result": {
"id": "a1b2c3d4",
"name": "My landing page",
"last_queued": "2021-01-01T00:00:00.000Z",
"status": "UP",
"reminder_alert_interval_minutes": 1440,
"confirmation_period_seconds": 60,
"recovery_period_seconds": 180,
"test_interval": 60,
"timeout": 0,
"alert_priority": "HIGH",
"test_regions": [
"aws:us-east-1",
"aws:eu-central-1"
],
"user_alerts": [
"string"
],
"slack_alerts": [
"string"
],
"discord_alerts": [
"string"
],
"incident_io_alerts": [
"string"
],
"microsoft_teams_alerts": [
"string"
],
"telegram_alerts": [
"string"
],
"pushover_alerts": [
"string"
],
"oncall_alerts": [
"string"
],
"webhook_alerts": [
"string"
],
"check_type": "TCP",
"url": null,
"version": "NODE24_TCP",
"tcp_hostname": "tcpbin.com",
"tcp_port": 4242,
"tcp_ip_family": "IPv4",
"tcp_data": "string",
"tcp_should_fail": false,
"assertions": [
{
"type": "TCP_RESPONSE_DATA",
"property": "",
"comparison": "EQUALS",
"expected": "OK"
}
]
},
"success": true,
"errors": [],
"messages": []
}
Modify a TCP check
Modify the configuration of an existing TCP check
Requires UPTIME_CHECKS:EDIT; EDIT also grants READ. Session cookies are accepted only when no bearer credential is supplied.
Security: Bearer Auth
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Header parameters
Path parameters
Body parameters
Responses
| Status | Meaning | Description |
|---|---|---|
| 200 | OK | Modify an OnlineOrNot TCP Check |
| 400 | Bad Request | Validation error |
| 401 | Unauthorized | Unauthenticated |
| 403 | Forbidden | Forbidden |
| 404 | Not Found | TCP check not found |
| 500 | Internal Server Error | Internal Server Error |
Response Schema
Request
curl --request PATCH \
--url https://api.onlineornot.com/v1/checks/tcp/a1b2c3d4 \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'Content-Type: application/json' \
--header 'X-OnlineOrNot-Organisation: string' \
--data '{"tcp_hostname":"example.org","tcp_port":8443,"tcp_ip_family":"IPv4"}'
Response
{
"result": {
"id": "a1b2c3d4",
"name": "My landing page",
"last_queued": "2021-01-01T00:00:00.000Z",
"status": "UP",
"reminder_alert_interval_minutes": 1440,
"confirmation_period_seconds": 60,
"recovery_period_seconds": 180,
"test_interval": 60,
"timeout": 0,
"alert_priority": "HIGH",
"test_regions": [
"aws:us-east-1",
"aws:eu-central-1"
],
"user_alerts": [
"string"
],
"slack_alerts": [
"string"
],
"discord_alerts": [
"string"
],
"incident_io_alerts": [
"string"
],
"microsoft_teams_alerts": [
"string"
],
"telegram_alerts": [
"string"
],
"pushover_alerts": [
"string"
],
"oncall_alerts": [
"string"
],
"webhook_alerts": [
"string"
],
"check_type": "TCP",
"url": null,
"version": "NODE24_TCP",
"tcp_hostname": "tcpbin.com",
"tcp_port": 4242,
"tcp_ip_family": "IPv4",
"tcp_data": "string",
"tcp_should_fail": false,
"assertions": [
{
"type": "TCP_RESPONSE_DATA",
"property": "",
"comparison": "EQUALS",
"expected": "OK"
}
]
},
"success": true,
"errors": [],
"messages": []
}
Delete a TCP check
Permanently delete a TCP check
Requires UPTIME_CHECKS:EDIT; EDIT also grants READ. Session cookies are accepted only when no bearer credential is supplied.
Security: Bearer Auth
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Header parameters
Path parameters
Responses
| Status | Meaning | Description |
|---|---|---|
| 200 | OK | Returns the deleted OnlineOrNot TCP Check's ID |
| 400 | Bad Request | Validation error |
| 401 | Unauthorized | Unauthenticated |
| 403 | Forbidden | Forbidden |
| 404 | Not Found | TCP check not found |
| 500 | Internal Server Error | Internal Server Error |
Response Schema
Request
curl --request DELETE \
--url https://api.onlineornot.com/v1/checks/tcp/a1b2c3d4 \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'X-OnlineOrNot-Organisation: string'
Response
{
"result": {
"id": "a1b2c3d4"
},
"success": true,
"errors": [],
"messages": []
}
Review recent failures and recoveries for a specific TCP check
List incidents for a TCP check. Optional from/to select overlapping incidents, not only incidents starting within the interval. Results are ordered by started time descending, then ID descending. Bounds accept at most millisecond precision; page/per_page and the computed offset must be safe integers, with per_page <= 100.
Requires UPTIME_CHECKS:READ; EDIT also grants READ. Session cookies are accepted only when no bearer credential is supplied.
Security: Bearer Auth
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Header parameters
Path parameters
Query parameters
Responses
| Status | Meaning | Description |
|---|---|---|
| 200 | OK | A page of incidents for the check |
| 400 | Bad Request | Invalid query parameters |
| 401 | Unauthorized | Unauthenticated |
| 403 | Forbidden | Forbidden |
| 404 | Not Found | Check not found |
| 500 | Internal Server Error | Internal server error |
Response Schema
Request
curl --request GET \
--url https://api.onlineornot.com/v1/checks/tcp/a1b2c3d4/incidents \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'X-OnlineOrNot-Organisation: string'
Response
{
"success": true,
"result": [
{
"id": "string",
"check_id": "string",
"started_at": "2019-08-24T14:15:22Z",
"ended_at": "2019-08-24T14:15:22Z"
}
],
"result_info": {
"page": 0,
"per_page": 1,
"count": 0,
"total_count": 0
},
"errors": [
null
],
"messages": [
null
]
}
Review raw TCP check results over a bounded time range
List results for a TCP check. Requires from < to, at most seven days, and at most three fractional timestamp digits. Pagination uses positive safe integers with per_page <= 100 and a safe integer offset.
Requires UPTIME_CHECKS:READ; EDIT also grants READ. Session cookies are accepted only when no bearer credential is supplied.
Security: Bearer Auth
Provide your bearer token in the Authorization header when making requests to protected resources.
Example: Authorization: Bearer 123
Header parameters
Path parameters
Query parameters
Responses
| Status | Meaning | Description |
|---|---|---|
| 200 | OK | A chronological page of raw check results |
| 400 | Bad Request | Invalid query parameters |
| 401 | Unauthorized | Unauthenticated |
| 403 | Forbidden | Forbidden |
| 404 | Not Found | Check not found |
| 500 | Internal Server Error | Internal server error |
| 503 | Service Unavailable | Required result storage unavailable |
Response Schema
Request
curl --request GET \
--url 'https://api.onlineornot.com/v1/checks/tcp/a1b2c3d4/results?from=2026-08-25T10%3A00%3A00Z&to=2026-08-25T11%3A00%3A00Z' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'X-OnlineOrNot-Organisation: string'
Response
{
"success": true,
"result": {
"check_id": "string",
"check_type": "TCP",
"window": {
"from": "2019-08-24T14:15:22Z",
"to": "2019-08-24T14:15:22Z"
},
"results": [
{
"id": "string",
"checked_at": "2019-08-24T14:15:22Z",
"checked_from": "aws:us-east-1",
"passing": true,
"response_time_ms": 0,
"attempt_number": 0,
"is_final_attempt": true,
"dispatched_at_ms": 0,
"response_body": "string",
"body_availability": "AVAILABLE",
"tcp_status": "string",
"failure_source": "TRANSPORT",
"failure_type": "string",
"dns_time_ms": 0,
"connect_time_ms": 0,
"data_time_ms": 0
}
],
"result_info": {
"page": 0,
"per_page": 1,
"count": 0,
"total_count": 0
}
},
"errors": [
null
],
"messages": [
null
]
}