Supported methods


GET: Attempts to discover connection settings for a given email address

This is useful when you want to add an email account under your API key (see email_accounts) and you'd like to make the settings easier to fill by the user with pre-populated data.

This will also figure out if OAuth2 over IMAP is available.

GET it


source_typestringThe type of email account you want to discover settings for. Right now, the only supported email account type is IMAP
emailstringAn email address you want to discover settings for.

Response body

If the Context.IO API has some best-guess connection settings for the given email address, the response will include them. These settings could be used, for instance, to pre-populate a form before showing it to an end-user.

  "email": stringThe email address requested for discovery,
  "found": booleantrue if settings were found, false otherwise,
  "type": stringType of provider, (eg. "gmail"),
  "imap": {
    "server": stringfully qualified domain name of the email server,
    "username": stringWhat the username should be for authentication,
    "port": numberNetwork port email server is listening on,
    "use_ssl": booleanWhether that server:port uses SSL encrypted connections,
    "oauth": booleantrue if the email server support authentication through OAuth2 (setting related OAuth2 consumers)
  "documentation": arrayList of documentation pages that may be useful for end-users for this specific email provider

Note that if the found property is false, the type, imap, and documentation properties won't appear in the response.