30 static $instance =
null;
31 if ($instance ===
null)
33 $instance =
new static();
48 return static::GROUP.
'.'.$type;
60 static $account =
null;
61 if ($account ===
null)
63 $account = Account::create($type)
64 ->setService(static::getInstance());
78 return AdCampaign::create($type)
79 ->setService(static::getInstance())
80 ->createCampaign($data);
91 return Audience::create($type)
92 ->setService(static::getInstance())
104 return PostList::create($type)
105 ->setService(static::getInstance())
116 return Audience::create($type)
117 ->setService(static::getInstance());
128 return Audience::create($type)
129 ->setService(static::getInstance())
130 ->getList($accountId);
141 return AdCampaign::create($type)
142 ->setService(static::getInstance())
143 ->getAdSetList($accountId);
152 public static function getAds($type, $adsId)
154 return AdCampaign::create($type)
155 ->setService(static::getInstance())
167 return AdCampaign::create($type)
168 ->setService(static::getInstance())
169 ->searchTargetingData($params);
180 return AdCampaign::create($type)
181 ->setService(static::getInstance())
182 ->getCampaignList($accountId);
193 static::TYPE_FACEBOOK,
194 static::TYPE_INSTAGRAM,
207 return AuthAdapter::create($type)
208 ->setService(static::getInstance());
217 return $this->clientId;
240 return Option::get(
'seo',
'use_multiple_clients',
true);
248 foreach (static::getTypes() as $type)
250 if($engineCode === static::getEngineCode($type))
static createAudience($type, array $data)
static createCampaign($type, array $data)
static getEngineCode($type)
static getAdSetList($type, $accountId)
static getAudienceList($type, $accountId)
static getTypeByEngine(string $engineCode)
static getAds($type, $adsId)
static canUseAsInternal()
static getCampaignList($type, $accountId)
static getPostList($type, $params)
static getAudience($type)
static searchTargetingData($type, $params)
static getAuthAdapter($type)
static canUseMultipleClients()