- 2 Minutes to read
Email / Phone Number Audiences
- 2 Minutes to read
Important
This Email / Phone Number Audiences endpoint is scheduled for future removal. This endpoint is being replaced by the
customsegmentsendpoint.
Custom audiences that can be built by providing email addresses or phone numbers.
Hierarchy
Define an Email Address or Phone Number audience at the advertiser level.
Endpoint
/traffic/audiences/email_addressUse the following HTTP methods:
Use the
GETmethod to read an existing email address or phone number audience.Use the
POSTmethod to create a new email address or phone number audience.Use the
PUTmethod to update an existing email address or phone number audience.
Resources
The following parameters are supported.
Field | Description | Data Type | Create | Update |
|---|---|---|---|---|
| Specifies the audience ID. |
| N/A | Required |
| Specifies the name of the audience. |
| Required | Optional |
| Specifies the current status of the audience. Allowed values:
Defaults to |
| Optional | Optional |
| Specifies the advertiser ID. An audience is tied to its advertiser and you can only use it in that advertiser’s campaigns. To learn more, refer to Advertisers. |
| Required | Required |
| Specifies an array of email addresses or phone numbers hashed using the SHA256 cryptographic hashing algorithm. The limit is 50K items per request. |
| Required | Optional |
| A read-only field that specifies when the audience was created. |
| N/A | N/A |
Read Audience
Read an email address audience.
GET traffic/audiences/email_address/{id}?accountId={accountId}Parameters
Parameter | Parameter Type | Description | Data Type | Required |
|---|---|---|---|---|
| path | Specifies the audience ID. |
| Y |
| query | Specifies the advertiser ID. |
| Y |
Sample Request URL
GET https://dspapi.admanagerplus.yahoo.com/traffic/audiences/email_address/50351924?accountId=1356341Sample Response
{
"response": {
"status": "ACTIVE",
"id": 50351924,
"name": "audienceTest",
"accountId": 1356341,
"createdAt": "2017-10-20",
"retentionDays": 730
},
"errors": null,
"timeStamp": "2017-10-20T19:04:17Z"
}Read History
Get the history and status of an email address or phone number audience.
GET /traffic/audiences/email_address/{id}/history?accountId={accountId}Parameters
Parameter | Parameter Type | Description | Data Type | Required |
|---|---|---|---|---|
| path | Specifies the audience ID. |
| Y |
| query | Specifies the advertiser ID. |
| Y |
Sample Request URL
GET https://dspapi.admanagerplus.yahoo.com/traffic/audiences/email_address/50351924/history?accountId=1356341Sample Response
{
"response": [
{
"id": "AUDAP_Email_20171020T2233502619009",/co
"status": "Active",
"failPercentage": 0,
"type": "SHA256EMAIL",
"createdDate": "2017-10-20T22:33:50",
"errorMessage": "",
"failedRecords": [],
"totalIds": 1,
"duplicated": 0,
"totalFailed": 0
}
],
"errors": null,
"timeStamp": "2018-09-04T19:04:38Z"
}Create Audience
Create a new email address or phone number audience.
POST /traffic/audiences/email_addressParameters
All fields are specified in the body of the application/json payload.
Sample Request URL
POST https://dspapi.admanagerplus.yahoo.com/traffic/audiences/email_addressSample Request Body
{
"name": "audience3",
"accountId": 1356341,
"seedList": [
"251014dafc651f68edac7e583edab8ed4fbdbe176b9b4c81f67e9e87a66da103",
"afbc34416ac6e7fbb97331a21fa2823f56952c0796a615d05a07a08cc52704da",
"42cbe7eebb412bbcd5b566945df59f67962106041ae7ea39f5bc6ee99307c19e",
"379b4653a40878da7a58458e4d9a99f834fb12179a5d4e2a840f77dc090c9a98"
]
}Sample Response
{
"response": {
"id": 50351924,
"name": "audience3",
"status": "ACTIVE",
"accountId": 1356341,
"createdAt": "2017-10-11",
"retentionDays": 730
},
"errors": null,
"timeStamp": "2017-10-11T00:33:54Z"
}Update Audience
Update an existing email address or phone number audience.
PUT /traffic/audiences/email_address/{id}Partial updates are supported; values of supported fields that are not in the payload remain unchanged.
Parameters
The audience id is specified in the endpoint path. All other fields are specified in the body of the application/json payload.
Sample Request URL
PUT https://dspapi.admanagerplus.yahoo.com/traffic/audiences/email_address/50351924Sample Request Body
{
"name": "audienceTest_2",
"accountId": 1356341
}Sample Response
{
"response": {
"id": 50351924,
"name": "audienceTest_2",
"status": "ACTIVE",
"accountId": 1356341,
"createdAt": "2017-10-20",
"retentionDays": 730
},
"errors": null,
"timeStamp": "2017-10-20T19:23:53Z"
}Delete Audience
The DSP Traffic API does not support the deletion of email address or phone number audiences.