示例#1
0
        // Retrieves all the requested campaign types in the account.

        private async Task <GetCampaignsByAccountIdResponse> GetCampaignsByAccountIdAsync(
            long accountId,
            CampaignType campaignType,
            CampaignAdditionalField returnAdditionalFields)
        {
            var request = new GetCampaignsByAccountIdRequest
            {
                AccountId              = accountId,
                CampaignType           = campaignType,
                ReturnAdditionalFields = returnAdditionalFields
            };

            return(await CampaignService.CallAsync((s, r) => s.GetCampaignsByAccountIdAsync(r), request));
        }
示例#2
0
        // Gets one or more campaigns for the specified campaign identifiers.

        private async Task <IList <Campaign> > GetCampaignsByIdsAsync(
            long accountId,
            IList <long> campaignIds,
            CampaignType campaignType,
            CampaignAdditionalField returnAdditionalFields)
        {
            var request = new GetCampaignsByIdsRequest
            {
                AccountId              = accountId,
                CampaignIds            = campaignIds,
                CampaignType           = campaignType,
                ReturnAdditionalFields = returnAdditionalFields
            };

            return((await Service.CallAsync((s, r) => s.GetCampaignsByIdsAsync(r), request)).Campaigns);
        }
示例#3
0
        // Retrieves all the requested campaign types in the account.

        private async Task<GetCampaignsByAccountIdResponse> GetCampaignsByAccountIdAsync(
            long accountId,
            CampaignType campaignType,
            CampaignAdditionalField returnAdditionalFields)
        {
            var request = new GetCampaignsByAccountIdRequest
            {
                AccountId = accountId,
                CampaignType = campaignType,
                ReturnAdditionalFields = returnAdditionalFields
            };

            return (await CampaignService.CallAsync((s, r) => s.GetCampaignsByAccountIdAsync(r), request));
        }