Skip to main content
POST
Create email account

Authorizations

Authorization
string
header
required

Access token issued by gtm.service.id. Its access_identity claim carries team_sid, actor_sid and actor_type, and that team scope is authoritative.

Team-SID
string
header
required

Team scope for tokens that do not carry one. Ignored when the token already names a team.

Headers

Email-Box-SID
string

Email server (em_bx_...) the call is for, from search_email_boxes. Omitted: the primary server.

Pattern: ^em_bx_[A-Za-z0-9]{12}$

Body

application/json

Request body of create_email_account.

provider
enum<string>
required
Available options:
google,
microsoft,
imap_smtp,
gtm_hosted
address
string<email> | null

Required for imap_smtp, gtm_hosted and the grant form.

Maximum string length: 320
display_name
string | null
Maximum string length: 255
label
string | null

The customer's own tag.

Maximum string length: 64
backfill_days
integer | null

Days of history to mirror. Default 90.

Required range: 0 <= x <= 3650
email_oauth_app_sid
string

google and microsoft: the sign-in application. Required for both forms.

Required string length: 18
Pattern: ^em_oa_
oauth_refresh_token
string | null

google and microsoft, the token form: a refresh token that application issued.

Maximum string length: 4096
connection
object

imap_smtp: the IMAP and SMTP servers.

imap_password
string
Maximum string length: 1024
smtp_password
string
Maximum string length: 1024
email_sending_domain_sid
string

gtm_hosted: the verified sending domain the address is on.

Required string length: 18
Pattern: ^em_sd_

Response

create success envelope.

success
enum<boolean>
required
Available options:
true
operation
enum<string>
required
Available options:
create
item
object
required
already_exists
boolean
required
meta
object
required