tophatter / facebook-ruby-ads-sdk

The Facebook Marketing API in Ruby.
https://developers.facebook.com/docs/marketing-apis
MIT License
62 stars 39 forks source link

Add method: create_ad_audience_with_pixel #2

Closed sdlong closed 7 years ago

sdlong commented 7 years ago

Usage:

  1. Set account:

FacebookAds.access_token = '<ACCESS_TOKEN>' account = FacebookAds::AdAccount.find('< AD_ACCOUNT_ID >')

  1. create ad_audience with pixel:

account.create_ad_audience_with_pixel(name: '< NAME >', pixel_id: '< PIXEL_ID >', event_name: '< EVENT_NAME >')

PS: Use standard event name only

e.g. : account.create_ad_audience_with_pixel(name: 'order complated', pixel_id: '328989100788312', event: 'Purchase')

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-0.4%) to 67.939% when pulling 3513b28949cf338721cd17f48f5c8bb37857702b on superlanding:t205 into 8f681eb363e131e22d454e6eece5791ffaa67f76 on cte:master.

coveralls commented 7 years ago

Coverage Status

Coverage decreased (-0.4%) to 67.939% when pulling 8f285b561f755513d1f46d5244560162b93fcd15 on superlanding:t205 into 8f681eb363e131e22d454e6eece5791ffaa67f76 on cte:master.

cte commented 7 years ago

Thanks for the PR.