This endpoint allows you to manage and create Sender Addresses (formerly Identities) associated with the Marketing Email feature.

add

Create a new Address.

Parameter Required Requirements Description
identity Yes None Create an Address named this.
name Yes None Specify the name to be used for this Address.
email Yes Email address format, complying with RFC 5322 Specify the email address to be used for this Address.
replyto No Email address format, complying with RFC 5322 Specify an email address to be used in the Reply-To field. If not defined, will default to the email parameter.
address Yes None Specify the physical address to be used for this Address.
city Yes None Specify the city to be used for this Address.
state Yes None Specify the state to be used for this Address.
zip Yes None Specify the zipcode/postal code to be used for this Address.
country Yes None Specify the country to be used for this Address.
Parameter Value Requirements Description

Call

POST https://api.sendgrid.com/api/newsletter/identity/add.json
POST Data identity=Sender_Address1&name=Grant&email=grant.hull%40sendgrid.com&address=929_Pearl_Stree&city=Boulder&state=Colorado&zip=80302&country=US&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
{
  "message": "success"
}

Call

POST https://api.sendgrid.com/api/newsletter/identity/add.xml
POST Data identity=Sender_Address1&name=Grant&email=grant.hull%40sendgrid.com&address=929_Pearl_Stree&city=Boulder&state=Colorado&zip=80302&country=US&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
<result>
   <message>success</message>
</result>

edit

Edit an existing Address.

Parameter Required Requirements Description
identity Yes Must be an existing Address. The Address you wish to edit.
newidentity No None Specify the new name to be used for this Address.
name No None Specify the new name to be used for this Address.
email Yes Email address format, complying with RFC 5322 Specify the email address to be used for this Address.
replyto No Email address format, complying with RFC 5322 Specify an email address to be used in the Reply-To field. If not defined, will default to the email parameter.
address No None Specify the new physical address to be used for this Address.
Parameter Value Requirements Description

Call

POST https://api.sendgrid.com/api/newsletter/identity/edit.json
POST Data identity=Sender_Address2&newidentity=Sender_Address3&name=Grant&email=grant.hull%40sendgrid.com&address=929_Pearl_Street&city=Boulder&state=Colorado&zip=80302&country=US&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
{
  "message": "success"
}

Call

POST https://api.sendgrid.com/api/newsletter/identity/edit.xml
POST Data identity=Sender_Address2&newidentity=Sender_Address3&name=Grant&email=grant.hull%40sendgrid.com&address=929_Pearl_Street&city=Boulder&state=Colorado&zip=80302&country=US&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
<result>
   <message>success</message>
</result>

get

Retrieve information associated with a particular Address.

Parameter Required Requirements Description
identity Yes Must be an existing Address. Retrieve contents of the specified Address.
Parameter Value Requirements Description

Call

POST https://api.sendgrid.com/api/newsletter/identity/get.json
POST Data identity=Sender_Address&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
4
5
6
7
8
9
10
11
{
  "city": "Boulder",
  "name": "Name",
  "zip": "80302",
  "replyto": "Email Address",
  "country": "US",
  "state": "CO",
  "address": "929 Pearl Street ste 200 ",
  "email": "example@sendgrid.com",
  "identity": "Sender_Address "
}

Call

POST https://api.sendgrid.com/api/newsletter/identity/get.xml
POST Data identity=Sender_Address&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
4
5
6
7
8
9
10
11
12
13
14
<identity>
   <city>Boulder</city>
   <name>Example Name</name>
   <zip>80302</zip>
   <replyto>example@sendgrid.com</replyto>
   <country>US</country>
   <state>CO</state>
   <address>
929 Pearl Street ste 200

</address>
   <email>example@sendgrid.com</email>
   <identity>Sender_Address </identity>
</identity>

list

List all Addresses on your account, or check if a particular Address exists.

Parameter Required Requirements Description
identity No Must be an existing Address. Check for this particular Identity. (To list all Addresses on your account exclude this parameter)
Parameter Value Requirements Description

Call

POST https://api.sendgrid.com/api/newsletter/identity/list.json
POST Data identity=Sender_Address4&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
4
5
[
  {
    "identity": "Sender_Address4"
  }
]

Call

POST https://api.sendgrid.com/api/newsletter/identity/list.xml
POST Data identity=Sender_Address4&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
<result>
   <message>success</message>
</result>

delete

Remove an Address from your account.

Parameter Required Requirements Description
identity Yes Must be an existing Address. Remove the specified Address from your account.
Parameter Value Requirements Description

Call

POST https://api.sendgrid.com/api/newsletter/identity/delete.json
POST Data identity=Sender_Address4&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
{
  "message": "success"
}

Call

POST https://api.sendgrid.com/api/newsletter/identity/delete.xml
POST Data identity=Sender_Address4&api_user=your_sendgrid_username&api_key=your_sendgrid_password

Response

1
2
3
<result>
   <message>success</message>
</result>