Get Sample Contacts



GET/v3/marketing/contacts

Base url: https://api.sendgrid.com (The Twilio SendGrid v3 API)

This endpoint will return up to 50 of the most recent contacts uploaded or attached to a list.

This list will then be sorted by email address.

The full contact count is also returned.

Please note that pagination of the contacts has been deprecated.

Twilio SendGrid recommends exporting your contacts regularly as a backup to avoid issues or lost data.


Property nameTypeRequiredDescription
authorizationstring
required
Default: Bearer <<YOUR_API_KEY_HERE>>
200400401403404500
Schema
Property nameTypeRequiredDescriptionChild properties
resultarray[contact-details3]

Optional


MetadataselfMetadata

Optional


contactCountinteger

Optional

1
const client = require("@sendgrid/client");
2
client.setApiKey(process.env.SENDGRID_API_KEY);
3
4
const request = {
5
url: `/v3/marketing/contacts`,
6
method: "GET",
7
};
8
9
client
10
.request(request)
11
.then(([response, body]) => {
12
console.log(response.statusCode);
13
console.log(response.body);
14
})
15
.catch((error) => {
16
console.error(error);
17
});