curl --request POST \
--url https://api.hubapi.com/marketing/v3/transactional/smtp-tokens \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"campaignName": "<string>",
"createContact": true
}
'{
"campaignName": "<string>",
"createContact": true,
"createdAt": "2023-11-07T05:31:56Z",
"createdBy": "<string>",
"emailCampaignId": "<string>",
"id": "<string>",
"password": "<string>"
}Create a SMTP API token.
curl --request POST \
--url https://api.hubapi.com/marketing/v3/transactional/smtp-tokens \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"campaignName": "<string>",
"createContact": true
}
'{
"campaignName": "<string>",
"createContact": true,
"createdAt": "2023-11-07T05:31:56Z",
"createdBy": "<string>",
"emailCampaignId": "<string>",
"id": "<string>",
"password": "<string>"
}Supported products
Required Scopes
The access token received from the authorization server in the OAuth 2.0 flow.
successful operation
A SMTP API token provides both an ID and password that can be used to send email through the HubSpot SMTP API.
A name for the campaign tied to the token.
Indicates whether a contact should be created for email recipients.
Timestamp generated when a token is created.
Email address of the user that sent the token creation request.
Identifier assigned to the campaign provided in the token creation request.
User name to log into the HubSpot SMTP server.
Password used to log into the HubSpot SMTP server.
Was this page helpful?