MailSlurp is an API for sending and receiving emails from dynamically allocated email addresses. It's designed for developers and QA teams to test applications, process inbound emails, send templated notifications, attachments, and more.
This API client was generated by the OpenAPI Generator project. By using the openapi-spec from a remote server, you can easily generate an API client.
Put the package under your project folder and add the following to Cargo.toml
under [dependencies]
:
openapi = { path = "./generated" }
All URIs are relative to https://api.mailslurp.com
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
AliasControllerApi | createalias | Post /aliases | Create an email alias. Must be verified by clicking link inside verification email that will be sent to the address. Once verified the alias will be active.
*AliasControllerApi* | deletealias | Delete /aliases/{aliasId} | Delete an email alias
AliasControllerApi | getalias | Get /aliases/{aliasId} | Get an email alias
*AliasControllerApi* | getaliasemails | Get /aliases/{aliasId}/emails | Get emails for an alias
*AliasControllerApi* | getaliasthreads | Get /aliases/{aliasId}/threads | Get threads created for an alias
*AliasControllerApi* | getaliases | Get /aliases | Get all email aliases you have created
AliasControllerApi | replytoaliasemail | Put /aliases/{aliasId}/emails/{emailId} | Reply to an email
*AliasControllerApi* | sendaliasemail | Post /aliases/{aliasId}/emails | Send an email from an alias inbox
*AliasControllerApi* | updatealias | Put /aliases/{aliasId} | Update an email alias
AttachmentControllerApi | uploadattachment | Post /attachments | Upload an attachment for sending using base64 file encoding. Returns an array whose first element is the ID of the uploaded attachment.
*AttachmentControllerApi* | uploadattachmentbytes | Post /attachments/bytes | Upload an attachment for sending using file byte stream input octet stream. Returns an array whose first element is the ID of the uploaded attachment.
*AttachmentControllerApi* | uploadmultipartform | Post /attachments/multipart | Upload an attachment for sending using a Multipart Form request. Returns an array whose first element is the ID of the uploaded attachment.
*BulkActionsControllerApi* | bulkcreateinboxes | Post /bulk/inboxes | Bulk create Inboxes (email addresses)
*BulkActionsControllerApi* | bulkdeleteinboxes | Delete /bulk/inboxes | Bulk Delete Inboxes
*BulkActionsControllerApi* | bulksendemails | Post /bulk/send | Bulk Send Emails
*CommonActionsControllerApi* | createnewemailaddress | Post /createInbox | Create new random inbox
CommonActionsControllerApi | createnewemailaddress1 | Post /newEmailAddress | Create new random inbox
*CommonActionsControllerApi* | emptyinbox | Delete /emptyInbox | Delete all emails in an inbox
CommonActionsControllerApi | sendemailsimple | Post /sendEmail | Send an email
ContactControllerApi | createcontact | Post /contacts | Create a contact
*ContactControllerApi* | deletecontact | Delete /contacts/{contactId} | Delete contact
ContactControllerApi | getallcontacts | Get /contacts/paginated | Get all contacts
ContactControllerApi | getcontact | Get /contacts/{contactId} | Get contact
*ContactControllerApi* | getcontacts | Get /contacts | Get all contacts
DomainControllerApi | adddomainwildcardcatchall | Post /domains/{id}/wildcard | Add catch all wild card inbox to domain
DomainControllerApi | createdomain | Post /domains | Create Domain
*DomainControllerApi* | deletedomain | Delete /domains/{id} | Delete a domain
DomainControllerApi | getdomain | Get /domains/{id} | Get a domain
*DomainControllerApi* | getdomains | Get /domains | Get domains
DomainControllerApi | updatedomain | Put /domains/{id} | Update a domain
*EmailControllerApi* | deleteallemails | Delete /emails | Delete all emails
*EmailControllerApi* | deleteemail | Delete /emails/{emailId} | Delete an email
EmailControllerApi | downloadattachment | Get /emails/{emailId}/attachments/{attachmentId} | Get email attachment bytes. If you have trouble with byte responses try the downloadAttachmentBase64
response endpoints.
*EmailControllerApi* | downloadattachmentbase64 | Get /emails/{emailId}/attachments/{attachmentId}/base64 | Get email attachment as base64 encoded string (alternative to binary responses)
*EmailControllerApi* | forwardemail | Post /emails/{emailId}/forward | Forward email
EmailControllerApi | getattachmentmetadata | Get /emails/{emailId}/attachments/{attachmentId}/metadata | Get email attachment metadata
*EmailControllerApi* | getattachments | Get /emails/{emailId}/attachments | Get all email attachment metadata
EmailControllerApi | getemail | Get /emails/{emailId} | Get email content
*EmailControllerApi* | getemailcontentmatch | Post /emails/{emailId}/contentMatch | Get email content regex pattern match results. Runs regex against email body and returns match groups.
EmailControllerApi | getemailhtml | Get /emails/{emailId}/html | Get email content as HTML
EmailControllerApi | getemailhtmlquery | Get /emails/{emailId}/htmlQuery | Parse and return text from an email, stripping HTML and decoding encoded characters
*EmailControllerApi* | getemailtextlines | Get /emails/{emailId}/textLines | Parse and return text from an email, stripping HTML and decoding encoded characters
EmailControllerApi | getemailspaginated | Get /emails | Get all emails
EmailControllerApi | getlatestemail | Get /emails/latest | Get latest email
EmailControllerApi | getlatestemailininbox | Get /emails/latestIn | Get latest email
EmailControllerApi | getrawemailcontents | Get /emails/{emailId}/raw | Get raw email string
*EmailControllerApi* | getrawemailjson | Get /emails/{emailId}/raw/json | Get raw email in JSON
EmailControllerApi | getunreademailcount | Get /emails/unreadCount | Get unread email count
*EmailControllerApi* | replytoemail | Put /emails/{emailId} | Reply to an email
*EmailControllerApi* | validateemail | Post /emails/{emailId}/validate | Validate email
ExpiredControllerApi | getexpirationdefaults | Get /expired/defaults | Get default expiration settings
ExpiredControllerApi | getexpiredinboxbyinboxid | Get /expired/inbox/{inboxId} | Get expired inbox record for a previously existing inbox
*ExpiredControllerApi* | getexpiredinboxrecord | Get /expired/{expiredId} | Get an expired inbox record
ExpiredControllerApi | getexpiredinboxes | Get /expired | List records of expired inboxes
FormControllerApi | submitform | Post /forms | Submit a form to be parsed and sent as an email to an address determined by the form fields
*GroupControllerApi* | addcontactstogroup | Put /groups/{groupId}/contacts | Add contacts to a group
GroupControllerApi | creategroup | Post /groups | Create a group
*GroupControllerApi* | deletegroup | Delete /groups/{groupId} | Delete group
GroupControllerApi | getallgroups | Get /groups/paginated | Get all Contact Groups in paginated format
GroupControllerApi | getgroup | Get /groups/{groupId} | Get group
*GroupControllerApi* | getgroupwithcontacts | Get /groups/{groupId}/contacts | Get group and contacts belonging to it
GroupControllerApi | getgroupwithcontactspaginated | Get /groups/{groupId}/contacts-paginated | Get group and paginated contacts belonging to it
GroupControllerApi | getgroups | Get /groups | Get all groups
*GroupControllerApi* | removecontactsfromgroup | Delete /groups/{groupId}/contacts | Remove contacts from a group
InboxControllerApi | createinbox | Post /inboxes | Create an Inbox (email address)
*InboxControllerApi* | createinboxwithoptions | Post /inboxes/withOptions | Create an inbox with additional options
InboxControllerApi | deleteallinboxes | Delete /inboxes | Delete all inboxes
InboxControllerApi | deleteinbox | Delete /inboxes/{inboxId} | Delete inbox
*InboxControllerApi* | getallinboxes | Get /inboxes/paginated | List All Inboxes Paginated
*InboxControllerApi* | getemails | Get /inboxes/{inboxId}/emails | Get emails in an Inbox. This method is not idempotent as it allows retries and waits if you want certain conditions to be met before returning. For simple listing and sorting of known emails use the email controller instead.
InboxControllerApi | getinbox | Get /inboxes/{inboxId} | Get Inbox
*InboxControllerApi* | getinboxemailspaginated | Get /inboxes/{inboxId}/emails/paginated | Get inbox emails paginated
InboxControllerApi | getinboxsentemails | Get /inboxes/{inboxId}/sent | Get Inbox Sent Emails
*InboxControllerApi* | getinboxtags | Get /inboxes/tags | Get inbox tags
*InboxControllerApi* | getinboxes | Get /inboxes | List Inboxes / Email Addresses
InboxControllerApi | sendemail | Post /inboxes/{inboxId} | Send Email
*InboxControllerApi* | sendemailandconfirm | Post /inboxes/{inboxId}/confirm | Send email and return sent confirmation
InboxControllerApi | setinboxfavourited | Put /inboxes/{inboxId}/favourite | Set inbox favourited state
InboxControllerApi | updateinbox | Patch /inboxes/{inboxId} | Update Inbox
*MailServerControllerApi* | describemailserverdomain | Post /mail-server/describe/domain | Get DNS Mail Server records for a domain
MailServerControllerApi | getdnslookup | Post /mail-server/describe/dns-lookup | Lookup DNS records for a domain
MailServerControllerApi | getipaddress | Post /mail-server/describe/ip-address | Get IP address for a domain
MailServerControllerApi | verifyemailaddress | Post /mail-server/verify/email-address | Verify the existence of an email address at a given mail server.
SentEmailsControllerApi | getsentemail | Get /sent/{id} | Get sent email receipt
SentEmailsControllerApi | getsentemails | Get /sent | Get all sent emails in paginated form
TemplateControllerApi | createtemplate | Post /templates | Create a Template
*TemplateControllerApi* | deletetemplate | Delete /templates/{TemplateId} | Delete Template
TemplateControllerApi | getalltemplates | Get /templates/paginated | Get all Templates in paginated format
TemplateControllerApi | gettemplate | Get /templates/{TemplateId} | Get Template
*TemplateControllerApi* | gettemplates | Get /templates | Get all Templates
WaitForControllerApi | waitfor | Post /waitFor | Wait for conditions to be met
*WaitForControllerApi* | waitforemailcount | Get /waitForEmailCount | Wait for and return count number of emails
WaitForControllerApi | waitforlatestemail | Get /waitForLatestEmail | Fetch inbox's latest email or if empty wait for an email to arrive
*WaitForControllerApi* | waitformatchingemail | Post /waitForMatchingEmails | Wait or return list of emails that match simple matching patterns
WaitForControllerApi | waitformatchingfirstemail | Post /waitForMatchingFirstEmail | Wait for or return the first email that matches proved MatchOptions array
WaitForControllerApi | waitfornthemail | Get /waitForNthEmail | Wait for or fetch the email with a given index in the inbox specified
*WebhookControllerApi* | createwebhook | Post /inboxes/{inboxId}/webhooks | Attach a WebHook URL to an inbox
WebhookControllerApi | deletewebhook | Delete /inboxes/{inboxId}/webhooks/{webhookId} | Delete and disable a Webhook for an Inbox
*WebhookControllerApi* | getallwebhooks | Get /webhooks/paginated | List Webhooks Paginated
*WebhookControllerApi* | getwebhook | Get /webhooks/{webhookId} | Get a webhook for an Inbox
WebhookControllerApi | getwebhooks | Get /inboxes/{inboxId}/webhooks | Get all Webhooks for an Inbox
*WebhookControllerApi* | sendtest_data | Post /webhooks/{webhookId}/test | Send webhook test data
To get access to the crate's generated documentation, use:
cargo doc --open