Module: OpenaiAds
- Defined in:
- app/services/openai_ads/api_client.rb,
app/services/openai_ads/advertiser_api_client.rb
Overview
Faraday-backed client for the OpenAI Ads (ChatGPT) Advertiser API —
the campaign / ad-group / ads / insights surface, NOT the Conversions
API (ApiClient). Different base URL, same Bearer-token
auth shape.
Used by OpenaiAdsCampaignSyncWorker to fetch the ad-account's
campaigns once a day and mirror them into the sources table —
the direct parallel to Invoicing::GoogleConversionReporter.client
driving GoogleAdsCampaignSyncWorker.
Account scoping is auth-implicit: OpenAI infers the ad account from
the API key on every request. There's no /accounts/{id} path
segment to thread through.
Defined Under Namespace
Classes: AdvertiserApiClient, ApiClient, ConversionReporter