# Client — Logs

<a id="get-api-v1-client-logs"></a>
#### `GET /api/v1/client/logs`

*List available logs (client)*

Return the list of log files (access, error, php) available for the authenticated client account.

**Responses:**

| Status | Schema | Description |
|--------|--------|-------------|
| `200` | `ApiSuccess_list_dict_str__Any___` | Successful Response |

**Response example (200):**

```json
{
  "data": [
    {}
  ],
  "message": "",
  "status": "success",
  "warnings": [
    "string"
  ]
}
```

**cURL example:**

```bash
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/client/logs
```

---

<a id="get-api-v1-client-logs-access"></a>
#### `GET /api/v1/client/logs/access`

*Read access log (client)*

Return the last N lines of the access log for a domain owned by the authenticated client account.

**Query parameters:**

| Name | Type | Required | Notes |
|------|------|----------|-------|
| `domain` | string | yes | — |
| `lines` | integer | no | minimum=1; maximum=5000 |

**Responses:**

| Status | Schema | Description |
|--------|--------|-------------|
| `200` | `ApiSuccess_dict_str__Any__` | Successful Response |
| `422` | `HTTPValidationError` | Validation Error |

**Response example (200):**

```json
{
  "data": {},
  "message": "",
  "status": "success",
  "warnings": [
    "string"
  ]
}
```

**cURL example:**

```bash
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/client/logs/access
```

---

<a id="get-api-v1-client-logs-error"></a>
#### `GET /api/v1/client/logs/error`

*Read error log (client)*

Return the last N lines of the error log for a domain owned by the authenticated client account.

**Query parameters:**

| Name | Type | Required | Notes |
|------|------|----------|-------|
| `domain` | string | yes | — |
| `lines` | integer | no | minimum=1; maximum=5000 |

**Responses:**

| Status | Schema | Description |
|--------|--------|-------------|
| `200` | `ApiSuccess_dict_str__Any__` | Successful Response |
| `422` | `HTTPValidationError` | Validation Error |

**Response example (200):**

```json
{
  "data": {},
  "message": "",
  "status": "success",
  "warnings": [
    "string"
  ]
}
```

**cURL example:**

```bash
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/client/logs/error
```

---

<a id="get-api-v1-client-logs-php"></a>
#### `GET /api/v1/client/logs/php`

*Read PHP log (client)*

Return the last N lines of the PHP error log for the authenticated client account.

**Query parameters:**

| Name | Type | Required | Notes |
|------|------|----------|-------|
| `lines` | integer | no | minimum=1; maximum=5000 |

**Responses:**

| Status | Schema | Description |
|--------|--------|-------------|
| `200` | `ApiSuccess_dict_str__Any__` | Successful Response |
| `422` | `HTTPValidationError` | Validation Error |

**Response example (200):**

```json
{
  "data": {},
  "message": "",
  "status": "success",
  "warnings": [
    "string"
  ]
}
```

**cURL example:**

```bash
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/client/logs/php
```

---
