Webmail
Mailbox
The Mailbox object represents an individual mailbox in the EstatePrime system. Below are the fields included in a Mailbox object:
Example
json
{
"id": 1489,
"email": "[email protected]",
"name": "Joe Doe",
}- id (int): The system id of the mailbox.
- email (string): The email of the mailbox.
- name (string): The name of the mailbox.
Get mailboxes
/api/webmail (GET)
Fetch a list of mailboxes.
Request
- Method:
GET - Headers: Include authentication headers as described in the Authentication section.
- Body: JSON object with the following parameters:
page(int): The page number to fetch. Defaults to1.
Example Body
json
{
"page": 1
}Response
- 200 OK: Returns a JSON array of mailbox objects.
Example Response
json
{
"status": 200,
"page": 1,
"total_pages": 1,
"results_per_page": 50,
"total_results": 2,
"data": [
{
"id": 1,
"email": "[email protected]",
"name": "Joe Due"
},
{
"id": 2,
"email": "[email protected]",
"name": "John Smith"
},
//Rest of the data...
]
}Get single mailbox
/api/webmail/{id} (GET)
Get a single mailbox by its id.
Request
- Method:
GET - Headers: Include authentication headers.
- Path Params: The mailbox id to be fetched.
Example Response
json
{
"status": 200,
"data": {
"id": 1,
"email": "[email protected]",
"name": "Joe Doe"
}
}Response
- 200 OK: Returns the JSON object of the mailbox.
Email
The Email object represents an individual email in the EstatePrime system. Below are the fields included in a Email object:
Example
json
{
"id": 26158,
"uid": null,
"mailbox_id": 1,
"mailbox_address": "[email protected]",
"subject": "EstatePrime Notification",
"from": {
"name": "EstatePrime",
"email": "[email protected]"
},
"to": [
"[email protected]",
"[email protected]"
],
"cc": [],
"bcc": [],
"date": "2025-04-08 16:02:02",
"has_attachments": false,
"is_read": true,
"is_draft": true,
"is_deleted": false,
"size": 433,
"content": {
"html": "<p>You have a new notification.</p>",
"text": "You have a new notification."
}
}- id (int): The system id of the email.
- uid (string|null): The messages uid if provided by the email service.
- mailbox_id (int): The mailbox's id of the email.
- mailbox_address (string): The mailbox's address of the email.
- subject (string|null): The subject of the email.
- from (object): Information about the sender:
- name (string|null): Sender's name.
- email (string): Sender's email address.
- to (array of strings): The list of recipients.
- cc (array of strings|null): The list of cc.
- bcc (array of strings|null): The list of bcc.
- date (string): The date and time of the email in the format
YYYY-MM-DD HH:MM:SS. - has_attachments (boolean): Whether the email has attachments.
- is_read (boolean): Whether the email is read.
- is_draft (boolean): Whether the email is draft.
- is_deleted (boolean): Whether the email is deleted.
- size (int): The email's size in bytes.
- content (object): Information about the content:
- html (string|null): The html content of the email.
- text (string|null): The text content of the email.
Get emails
/api/webmail/{mailbox_id}/emails (GET)
Fetch a list of emails for a single mailbox.
Request
- Method:
GET - Headers: Include authentication headers as described in the Authentication section.
- Body: JSON object with the following optional search parameters:
page(int): The page number to fetch. Defaults to1.date(object): Filter by date range. Must include:min(string): The minimum date inYYYY-MM-DD HH:MM:SSformat, ornullfor no lower limit.max(string): The maximum date inYYYY-MM-DD HH:MM:SSformat, ornullfor no upper limit.
from_address(string): The sender's email address.subject_contains(string): Text included in the subject.subject_equals(string): Specific subject.to_address(string): Specific recipient's email address.
- Path Params: The mailbox id.
Example Body
json
{
"page": 1,
"from_address": "[email protected]"
}Response
- 200 OK: Returns a JSON array of email objects.
Example Response
json
{
"status": 200,
"page": 1,
"total_pages": 1,
"results_per_page": 50,
"total_results": 2,
"data": [
{
"id": 26158,
"uid": null,
"mailbox_id": 2,
"mailbox_address": "[email protected]",
"subject": "Welcome to Example",
"from": {
"name": "John Smith",
"email": "[email protected]"
},
//Rest of the data...
},
//Rest of the data...
]
}Get single email
/api/webmail/{mailbox_id}/emails/{id} (GET)
Get a single email by its id.
Request
- Method:
GET - Headers: Include authentication headers.
- Path Params: The mailbox id and the email id to be fetched.
Example Response
json
{
"status": 200,
"data": {
"id": 26158,
"uid": null,
"mailbox_id": 2,
"mailbox_address": "[email protected]",
"subject": "Welcome to Example",
"from": {
"name": "John Smith",
"email": "[email protected]"
},
//Rest of the data...
}
}Response
- 200 OK: Returns the JSON object of the email.

