Query SMTP configuration for email delivery.
GraphQL
query GetSmtp($id: ID) {
Smtp(id: $id) {
id
email
host
port
active
created_at
user_profile_id
}
}
GraphQL
query Smtps(
$where: QuerySmtpsWhereWhereConditions,
$orderBy: [QuerySmtpsOrderByOrderByClause!],
$search: String
) {
Smtps(
where: $where
orderBy: $orderBy
search: $search
) {
id
email
host
port
active
created_at
user_profile_id
}
}
Variables (JSON)
{
"where": {
"AND": [
{ "column": "ACTIVE", "operator": "EQ", "value": true }
]
},
"orderBy": [
{ "column": "EMAIL", "order": "ASC" }
],
"search": "smtp.example.com"
}
Field Type Description idInt Unique identifier of the SMTP configuration. user_profile_idInt Identifier of the user profile owning the configuration. emailString SMTP account email address used for sending. hostString SMTP server hostname. portInt SMTP server port. activeBoolean If true, the SMTP configuration is active. created_atDateTime Creation date of the configuration.
You can create filters based on following fields
id - Int Example: { "column": "ID", "operator": "EQ", "value": 100012 }
host - String Example: { "column": "HOST", "operator": "EQ", "value": "smtp.example.com" }
port - Int Example: { "column": "PORT", "operator": "EQ", "value": 587 }
user_profile_id - Int Example: { "column": "USER_PROFILE_ID", "operator": "EQ", "value": 42 }
active - Boolean Example: { "column": "ACTIVE", "operator": "EQ", "value": true }
You can sort data based on following fields: email, host, port
GraphQL
query SortSmtps(
$where: QuerySmtpsWhereWhereConditions
) {
Smtps(
where: $where
orderBy: [{ column: EMAIL, order: ASC }]
) {
id
email
host
port
active
}
}
JSON
{
"data": {
"Smtps": [
{
"id": 100001,
"email": "[email protected] ",
"host": "smtp.example.com",
"port": 587,
"active": true,
"created_at": "2025-01-01T00:00:00Z",
"user_profile_id": 42
},
{
"id": 100002,
"email": "[email protected] ",
"host": "smtp.example.com",
"port": 465,
"active": false,
"created_at": "2025-01-02T00:00:00Z",
"user_profile_id": 43
}
]
}
}