Client — Spam
Bu sayfa henüz Türkçeye çevrilmedi. İngilizce sürüm gösteriliyor.
GET /api/v1/client/spam/emails
List spam-enabled emails (client)
Return all email accounts owned by the authenticated client with their per-address spam summary.
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
ApiSuccess_list_dict_str__Any___ |
Successful Response |
Response example (200):
{
"data": [
{}
],
"message": "",
"status": "success",
"warnings": [
"string"
]
}
cURL example:
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/spam/emails
DELETE /api/v1/client/spam/settings/{email}
Reset spam settings (client)
Reset spam settings to defaults for a specific email address owned by the authenticated client.
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
email |
string | yes | — |
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
ApiSuccess_dict_str__Any__ |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
{
"data": {},
"message": "",
"status": "success",
"warnings": [
"string"
]
}
cURL example:
curl -X DELETE \
-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/spam/settings/{email}
GET /api/v1/client/spam/settings/{email}
Get spam settings (client)
Return spam settings (whitelist, blacklist, enabled flag) for a specific email address.
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
email |
string | yes | — |
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
ApiSuccess_dict_str__Any__ |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
{
"data": {},
"message": "",
"status": "success",
"warnings": [
"string"
]
}
cURL example:
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/spam/settings/{email}
PUT /api/v1/client/spam/settings/{email}
Update spam settings (client)
Update spam settings (whitelist, blacklist, enabled flag) for a specific email address owned by the authenticated client. Entries are sender addresses or domains, at most 100 per list (422 VALIDATION_ERROR otherwise); the lists are applied by the mail filter when the message's recipients agree.
Path parameters:
| Name | Type | Required | Notes |
|---|---|---|---|
email |
string | yes | — |
Body fields:
| Field | Type | Required | Notes |
|---|---|---|---|
blacklist |
array |
no | — |
spam_enabled |
boolean | no | default True |
whitelist |
array |
no | — |
Request body example:
{
"blacklist": [
"string"
],
"spam_enabled": true,
"whitelist": [
"string"
]
}
Responses:
| Status | Schema | Description |
|---|---|---|
200 |
ApiSuccess_dict_str__Any__ |
Successful Response |
422 |
HTTPValidationError |
Validation Error |
Response example (200):
{
"data": {},
"message": "",
"status": "success",
"warnings": [
"string"
]
}
cURL example:
curl -X PUT \
-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)" \
-H "Content-Type: application/json" \
-d @body.json \
https://your-server:2000/api/v1/client/spam/settings/{email}
Yukarıda bulamadığınız her şey için destek ekibimiz her zaman yanınızda.