- [[project - accuracy prompts digital ads]]
- 100 upload to twitter custom audience
- 32 can be reached in a campaign
- who are these 32?
- 16
- 16 / 100
- DL: no go. 70% bad!!!
---
- last year
- 1500 randomly selected users upload to twitter (n)
- 497 (min = 100)
- 1500 + 1 (puneet) upload to twitter
- 501
- k users
- k custom audiences
- 800k custom audiences
- n + 1
- n + 1
---
- 40k
- **create**/update/put/delete
- **update**
- c1 ........ c40000
- c1 - how many can be matched in c1 (500), then **update** c1 add puneet to it. (501)
- what's the new matched number in c1? (501)
- c20: 500
- +1 hause wait 24 hours
- 501
- c20: 501
- + puneet wait 24 hours
- 501 puneet cannot be reached
---
ONE API for TWITTER ADS - different regular API
```python
sn = ["a", "2", "3"]
audience1 = CustomAudience.create(account, aud_name)
sn = ["a", "2", "3", "puneet"]
audience2 = CustomAudience.create(account, aud_name)
id = "4rkgt"
# step1: get the EXISTING audience by id
audience_df = utils.audience_status(account, id) # 903/400
audience = account.custom_audiences(audid)
# step2: prepare audience
# https://twitterdev.github.io/twitter-python-ads-sdk/reference/twitter_ads/audience.html
sn = ["puneeet"]
payload_users = utils.list_to_payload_handles(sn) # create payload
payload_users_list = [
{
"operation_type": "Update",
"params": {
"expires_at": "2050-01-01T07:00:00Z",
"users": payload_users,
},
}
]
# upload/update to twitter platform
success_count, total_count = audience.users(payload_users_list)
# step3: get the EXISTING audience by id AGAIN (6-12 hours later)
audience = utils.audience_status(account, id) # 903/400 401?
```
```
aud_00000_220222220645_C_1157 4rkgt
aud_00001_O_220222215623_567582142_1158
aud_00000_220222215623_C_1157 4rkel
aud_00000_220222213530_C_1157 4rjzf
````