Create an SMTP configuration
| input - SmtpInput |
|---|
| Data of the SMTP configuration |
mutation CreateSmtp($input: SmtpInput!) {
CreateSmtp(input: $input) {
id
email
host
port
active
created_at
user_profile_id
}
}
{
"input": {
"email": "[email protected]",
"password": "******",
"host": "smtp.example.com",
"port": 587,
"active": true
}
}
{
"data": {
"CreateSmtp": {
"id": 100045,
"email": "[email protected]",
"host": "smtp.example.com",
"port": 587,
"active": true,
"created_at": "2025-01-01T00:00:00Z",
"user_profile_id": 42
}
}
}
Update an SMTP configuration
| id - ID |
|---|
| Id of the SMTP configuration |
| input - SmtpInput |
|---|
| Data of the SMTP configuration |
mutation UpdateSmtp($id: ID!, $input: SmtpInput!) {
UpdateSmtp(id: $id, input: $input) {
id
email
host
port
active
created_at
user_profile_id
}
}
{
"id": 100045,
"input": {
"email": "[email protected]",
"password": "******",
"host": "smtp.example.com",
"port": 465,
"active": false
}
}
{
"data": {
"UpdateSmtp": {
"id": 100045,
"email": "[email protected]",
"host": "smtp.example.com",
"port": 465,
"active": false,
"created_at": "2025-01-03T00:00:00Z",
"user_profile_id": 42
}
}
}
Disable an SMTP configuration
| id - ID |
|---|
| Id of the SMTP configuration |
mutation DisableSmtp($id: ID!) {
DisableSmtp(id: $id) {
id
email
active
}
}
{
"data": {
"DisableSmtp": {
"id": 100045,
"email": "[email protected]",
"active": false
}
}
}
Enable an SMTP configuration
| id - ID |
|---|
| Id of the SMTP configuration |
mutation EnableSmtp($id: ID!) {
EnableSmtp(id: $id) {
id
email
active
}
}
{
"data": {
"EnableSmtp": {
"id": 100045,
"email": "[email protected]",
"active": true
}
}
}
Send an email for a document
mutation SendEmail($email: EmailInput!) {
SendEmail(email: $email)
}
{
"data": {
"SendEmail": true
}
}
Send a test email to verify SMTP configuration
| to - String |
|---|
| Recipient email address |
mutation SendTestEmail($to: String!) {
SendTestEmail(to: $to)
}
{
"data": {
"SendTestEmail": true
}
}
| email - String |
|---|
| SMTP account email address |
| password - String |
|---|
| SMTP account password |
| host - String |
|---|
| SMTP server hostname |
| port - Int |
|---|
| SMTP server port |
| active - Boolean |
|---|
| If true, the SMTP configuration is active |
| document_id - ID |
|---|
| Document identifier |
| document_type - String |
|---|
| Document type (e.g., INVOICE) |
| bcc - [String] |
|---|
| Blind carbon copy recipients |