Logs
GET /api/v1/accounts/{username}/logs
List Logs
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
username |
string | yes | — |
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
AvailableLogsResponse |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
JSON
{
"data": [
{
"domain": "example.com",
"filename": "string",
"type": "access"
}
],
"status": "string"
}
cURL example:
shell
curl -X GET \
-H "X-WHost-Key: $WHOST_API_KEY" \
-H "X-WHost-Timestamp: $(date +%s)" \
-H "X-WHost-Nonce: $(openssl rand -hex 16)" \
-H "X-WHost-Signature: $(compute_hmac)" \
https://your-server:2000/api/v1/accounts/{username}/logs
GET /api/v1/accounts/{username}/logs/access
Read Access Log
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
username |
string | yes | — |
Query parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
domain |
string | yes | — |
lines |
integer | no | minimum=1; maximum=5000 |
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
LogContentResponse |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
JSON
{
"data": {
"content": [
"string"
],
"domain": "example.com",
"lines": 0,
"log_type": "access"
},
"status": "string"
}
cURL example:
shell
curl -X GET \
-H "X-WHost-Key: $WHOST_API_KEY" \
-H "X-WHost-Timestamp: $(date +%s)" \
-H "X-WHost-Nonce: $(openssl rand -hex 16)" \
-H "X-WHost-Signature: $(compute_hmac)" \
https://your-server:2000/api/v1/accounts/{username}/logs/access
GET /api/v1/accounts/{username}/logs/error
Read Error Log
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
username |
string | yes | — |
Query parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
domain |
string | yes | — |
lines |
integer | no | minimum=1; maximum=5000 |
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
LogContentResponse |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
JSON
{
"data": {
"content": [
"string"
],
"domain": "example.com",
"lines": 0,
"log_type": "access"
},
"status": "string"
}
cURL example:
shell
curl -X GET \
-H "X-WHost-Key: $WHOST_API_KEY" \
-H "X-WHost-Timestamp: $(date +%s)" \
-H "X-WHost-Nonce: $(openssl rand -hex 16)" \
-H "X-WHost-Signature: $(compute_hmac)" \
https://your-server:2000/api/v1/accounts/{username}/logs/error
GET /api/v1/accounts/{username}/logs/php
Read Php Error Log
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
username |
string | yes | — |
Query parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
lines |
integer | no | minimum=1; maximum=5000 |
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
LogContentResponse |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
JSON
{
"data": {
"content": [
"string"
],
"domain": "example.com",
"lines": 0,
"log_type": "access"
},
"status": "string"
}
cURL example:
shell
curl -X GET \
-H "X-WHost-Key: $WHOST_API_KEY" \
-H "X-WHost-Timestamp: $(date +%s)" \
-H "X-WHost-Nonce: $(openssl rand -hex 16)" \
-H "X-WHost-Signature: $(compute_hmac)" \
https://your-server:2000/api/v1/accounts/{username}/logs/php
Still Need Help?
Our support team is here around the clock for anything you can't find above.