late-sdk 0.0.595 → 0.0.597

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +8 -0
  3. data/docs/AdInsightsApi.md +155 -9
  4. data/docs/GenerateKeywordHistoricalMetrics200Response.md +22 -0
  5. data/docs/GenerateKeywordHistoricalMetricsRequest.md +32 -0
  6. data/docs/GenerateKeywordIdeas200Response.md +24 -0
  7. data/docs/GenerateKeywordIdeas200ResponsePaging.md +18 -0
  8. data/docs/GenerateKeywordIdeasRequest.md +36 -0
  9. data/docs/GetAdsActivityLog200Response.md +1 -1
  10. data/docs/GetAdsActivityLog200ResponsePaging.md +18 -0
  11. data/docs/ListAdCreatives200Response.md +1 -1
  12. data/docs/ListAdImages200Response.md +1 -1
  13. data/docs/ListAdLabels200Response.md +1 -1
  14. data/docs/ListAdStudies200Response.md +1 -1
  15. data/docs/ListHighDemandPeriods200Response.md +1 -1
  16. data/docs/ListMetaBusinesses200Response.md +1 -1
  17. data/docs/QueryAdInsights200Response.md +5 -1
  18. data/docs/QueryAdInsights200ResponsePaging.md +4 -2
  19. data/docs/TwitterPlatformData.md +1 -1
  20. data/lib/zernio-sdk/api/ad_insights_api.rb +158 -13
  21. data/lib/zernio-sdk/models/generate_keyword_historical_metrics200_response.rb +169 -0
  22. data/lib/zernio-sdk/models/generate_keyword_historical_metrics_request.rb +337 -0
  23. data/lib/zernio-sdk/models/generate_keyword_ideas200_response.rb +178 -0
  24. data/lib/zernio-sdk/models/generate_keyword_ideas200_response_paging.rb +149 -0
  25. data/lib/zernio-sdk/models/generate_keyword_ideas_request.rb +378 -0
  26. data/lib/zernio-sdk/models/get_ads_activity_log200_response.rb +1 -1
  27. data/lib/zernio-sdk/models/get_ads_activity_log200_response_paging.rb +149 -0
  28. data/lib/zernio-sdk/models/list_ad_creatives200_response.rb +1 -1
  29. data/lib/zernio-sdk/models/list_ad_images200_response.rb +1 -1
  30. data/lib/zernio-sdk/models/list_ad_labels200_response.rb +1 -1
  31. data/lib/zernio-sdk/models/list_ad_studies200_response.rb +1 -1
  32. data/lib/zernio-sdk/models/list_high_demand_periods200_response.rb +1 -1
  33. data/lib/zernio-sdk/models/list_meta_businesses200_response.rb +1 -1
  34. data/lib/zernio-sdk/models/query_ad_insights200_response.rb +23 -1
  35. data/lib/zernio-sdk/models/query_ad_insights200_response_paging.rb +17 -6
  36. data/lib/zernio-sdk/models/twitter_platform_data.rb +1 -1
  37. data/lib/zernio-sdk/version.rb +1 -1
  38. data/lib/zernio-sdk.rb +6 -0
  39. data/openapi.yaml +130 -19
  40. data/spec/api/ad_insights_api_spec.rb +30 -3
  41. data/spec/models/generate_keyword_historical_metrics200_response_spec.rb +48 -0
  42. data/spec/models/generate_keyword_historical_metrics_request_spec.rb +82 -0
  43. data/spec/models/generate_keyword_ideas200_response_paging_spec.rb +36 -0
  44. data/spec/models/generate_keyword_ideas200_response_spec.rb +54 -0
  45. data/spec/models/generate_keyword_ideas_request_spec.rb +94 -0
  46. data/spec/models/get_ads_activity_log200_response_paging_spec.rb +36 -0
  47. data/spec/models/query_ad_insights200_response_paging_spec.rb +6 -0
  48. data/spec/models/query_ad_insights200_response_spec.rb +12 -0
  49. data/zernio-sdk-0.0.597.gem +0 -0
  50. metadata +26 -2
  51. data/zernio-sdk-0.0.595.gem +0 -0
@@ -15,13 +15,17 @@ require 'time'
15
15
 
16
16
  module Zernio
17
17
  class QueryAdInsights200ResponsePaging < ApiModelBase
18
- # Cursor for the next page; null when exhausted.
18
+ # Meta cursor for the next page; null when exhausted.
19
19
  attr_accessor :after
20
20
 
21
+ # Google cursor for the next page; null when exhausted.
22
+ attr_accessor :next_page_token
23
+
21
24
  # Attribute mapping from ruby-style variable name to JSON key.
22
25
  def self.attribute_map
23
26
  {
24
- :'after' => :'after'
27
+ :'after' => :'after',
28
+ :'next_page_token' => :'nextPageToken'
25
29
  }
26
30
  end
27
31
 
@@ -38,14 +42,16 @@ module Zernio
38
42
  # Attribute type mapping.
39
43
  def self.openapi_types
40
44
  {
41
- :'after' => :'String'
45
+ :'after' => :'String',
46
+ :'next_page_token' => :'String'
42
47
  }
43
48
  end
44
49
 
45
50
  # List of attributes with nullable: true
46
51
  def self.openapi_nullable
47
52
  Set.new([
48
- :'after'
53
+ :'after',
54
+ :'next_page_token'
49
55
  ])
50
56
  end
51
57
 
@@ -68,6 +74,10 @@ module Zernio
68
74
  if attributes.key?(:'after')
69
75
  self.after = attributes[:'after']
70
76
  end
77
+
78
+ if attributes.key?(:'next_page_token')
79
+ self.next_page_token = attributes[:'next_page_token']
80
+ end
71
81
  end
72
82
 
73
83
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -90,7 +100,8 @@ module Zernio
90
100
  def ==(o)
91
101
  return true if self.equal?(o)
92
102
  self.class == o.class &&
93
- after == o.after
103
+ after == o.after &&
104
+ next_page_token == o.next_page_token
94
105
  end
95
106
 
96
107
  # @see the `==` method
@@ -102,7 +113,7 @@ module Zernio
102
113
  # Calculates hash code according to all attributes.
103
114
  # @return [Integer] Hash code
104
115
  def hash
105
- [after].hash
116
+ [after, next_page_token].hash
106
117
  end
107
118
 
108
119
  # Builds the object from hash
@@ -16,7 +16,7 @@ require 'time'
16
16
  module Zernio
17
17
  # X (Twitter) geo-restriction applies at the media level. Media in geo-restricted tweets will be hidden for users outside the specified countries; the tweet text itself remains visible globally. Requires media to be attached (ignored for text-only tweets).
18
18
  class TwitterPlatformData < ApiModelBase
19
- # ID of an existing tweet to reply to. The published tweet will appear as a reply in that tweet's thread. For threads, only the first tweet replies to the target; subsequent tweets chain normally.
19
+ # ID of an existing tweet to reply to. The published tweet will appear as a reply in that tweet's thread. For threads, only the first tweet replies to the target; subsequent tweets chain normally. X only permits replying to your own posts or posts you are mentioned in; replying to an arbitrary other account's post is rejected by X.
20
20
  attr_accessor :reply_to_tweet_id
21
21
 
22
22
  # ID (or full status URL) of an existing tweet to quote-repost. The published tweet becomes a quote tweet of the target. Mutually exclusive with media and poll. X only permits quoting your own posts or posts you are mentioned in / part of the conversation thread of; quoting an arbitrary other account's post is rejected by X. Billed at the standard create rate ($0.015), unlike pasting a tweet URL into the text which is billed at the URL rate ($0.20). For threads, applies to the first tweet only.
@@ -11,5 +11,5 @@ Generator version: 7.19.0
11
11
  =end
12
12
 
13
13
  module Zernio
14
- VERSION = '0.0.595'
14
+ VERSION = '0.0.597'
15
15
  end
data/lib/zernio-sdk.rb CHANGED
@@ -413,6 +413,11 @@ require 'zernio-sdk/models/gbp_update_free_form_service_item_label'
413
413
  require 'zernio-sdk/models/generate_ad_previews200_response'
414
414
  require 'zernio-sdk/models/generate_ad_previews200_response_previews_inner'
415
415
  require 'zernio-sdk/models/generate_ad_previews_request'
416
+ require 'zernio-sdk/models/generate_keyword_historical_metrics200_response'
417
+ require 'zernio-sdk/models/generate_keyword_historical_metrics_request'
418
+ require 'zernio-sdk/models/generate_keyword_ideas200_response'
419
+ require 'zernio-sdk/models/generate_keyword_ideas200_response_paging'
420
+ require 'zernio-sdk/models/generate_keyword_ideas_request'
416
421
  require 'zernio-sdk/models/geo_restriction'
417
422
  require 'zernio-sdk/models/get_account_health200_response'
418
423
  require 'zernio-sdk/models/get_account_health200_response_permissions'
@@ -435,6 +440,7 @@ require 'zernio-sdk/models/get_ad_set_details200_response'
435
440
  require 'zernio-sdk/models/get_ad_tracking_tags200_response'
436
441
  require 'zernio-sdk/models/get_ad_tree200_response'
437
442
  require 'zernio-sdk/models/get_ads_activity_log200_response'
443
+ require 'zernio-sdk/models/get_ads_activity_log200_response_paging'
438
444
  require 'zernio-sdk/models/get_ads_timeline200_response'
439
445
  require 'zernio-sdk/models/get_ads_timeline200_response_rows_inner'
440
446
  require 'zernio-sdk/models/get_all_accounts_health200_response'
data/openapi.yaml CHANGED
@@ -4239,7 +4239,7 @@ components:
4239
4239
  properties:
4240
4240
  replyToTweetId:
4241
4241
  type: string
4242
- description: ID of an existing tweet to reply to. The published tweet will appear as a reply in that tweet's thread. For threads, only the first tweet replies to the target; subsequent tweets chain normally.
4242
+ description: ID of an existing tweet to reply to. The published tweet will appear as a reply in that tweet's thread. For threads, only the first tweet replies to the target; subsequent tweets chain normally. X only permits replying to your own posts or posts you are mentioned in; replying to an arbitrary other account's post is rejected by X.
4243
4243
  quoteTweetId:
4244
4244
  type: string
4245
4245
  description: ID (or full status URL) of an existing tweet to quote-repost. The published tweet becomes a quote tweet of the target. Mutually exclusive with media and poll. X only permits quoting your own posts or posts you are mentioned in / part of the conversation thread of; quoting an arbitrary other account's post is rejected by X. Billed at the standard create rate ($0.015), unlike pasting a tweet URL into the text which is billed at the URL rate ($0.20). For threads, applies to the first tweet only.
@@ -35203,28 +35203,136 @@ paths:
35203
35203
  '429': { description: Meta rate limit reached }
35204
35204
  '501': { description: Only supported on Meta (facebook/instagram) }
35205
35205
 
35206
+ /v1/ads/keywords/ideas:
35207
+ post:
35208
+ operationId: generateKeywordIdeas
35209
+ tags: ["Ad Insights"]
35210
+ x-platforms: ["google"]
35211
+ summary: Generate keyword ideas (Google Keyword Planner)
35212
+ description: |
35213
+ Google Ads only. Runs Keyword Planner's generateKeywordIdeas from seed keywords, a seed URL,
35214
+ or both, returning idea rows verbatim (avgMonthlySearches, competition, competitionIndex,
35215
+ top-of-page bid micros, monthlySearchVolumes). Counters are int64s encoded as strings; bid
35216
+ values are micros of the account currency. Omitting `countries` targets worldwide.
35217
+ security:
35218
+ - bearerAuth: []
35219
+ requestBody:
35220
+ required: true
35221
+ content:
35222
+ application/json:
35223
+ schema:
35224
+ type: object
35225
+ required: [accountId]
35226
+ properties:
35227
+ accountId: { type: string, description: "Zernio googleads SocialAccount id." }
35228
+ customerId: { type: string, description: "Numeric Google Ads customer id (no dashes); only needed when the connection has several accounts." }
35229
+ seedKeywords: { type: array, items: { type: string, maxLength: 80 }, minItems: 1, maxItems: 20, description: "Seed terms. Provide these, seedUrl, or both." }
35230
+ seedUrl: { type: string, format: uri, description: "Landing page to mine for ideas. Provide this, seedKeywords, or both." }
35231
+ countries: { type: array, items: { type: string, minLength: 2, maxLength: 2 }, minItems: 1, maxItems: 10, description: "ISO 3166-1 alpha-2 country codes. Omitted = worldwide." }
35232
+ languageConstantId: { type: string, default: "1000", description: "Google languageConstant id (1000 = English)." }
35233
+ network: { type: string, enum: [GOOGLE_SEARCH, GOOGLE_SEARCH_AND_PARTNERS], default: GOOGLE_SEARCH }
35234
+ includeAdultKeywords: { type: boolean }
35235
+ pageSize: { type: integer, minimum: 1, maximum: 10000 }
35236
+ pageToken: { type: string, description: "Cursor from paging.nextPageToken of the previous page." }
35237
+ responses:
35238
+ '200':
35239
+ description: Keyword idea rows (raw Keyword Planner shape)
35240
+ content:
35241
+ application/json:
35242
+ schema:
35243
+ type: object
35244
+ properties:
35245
+ customerId: { type: string, description: "The customer the request ran against." }
35246
+ data:
35247
+ type: array
35248
+ items: { type: object, description: "Raw GenerateKeywordIdeaResult: text + keywordIdeaMetrics." }
35249
+ aggregateMetricResults: { type: [object, "null"] }
35250
+ paging:
35251
+ type: object
35252
+ properties:
35253
+ nextPageToken: { type: [string, "null"], description: "Cursor for the next page; null when exhausted." }
35254
+ '400': { description: "Invalid input, or Google rejected the request — message carries Google's error" }
35255
+ '401': { $ref: '#/components/responses/Unauthorized' }
35256
+ '429': { description: "Per-user Google Ads operations budget or the shared Google quota reached; the message says which and when it resets." }
35257
+ '501': { description: Only supported on Google Ads }
35258
+
35259
+ /v1/ads/keywords/historical-metrics:
35260
+ post:
35261
+ operationId: generateKeywordHistoricalMetrics
35262
+ tags: ["Ad Insights"]
35263
+ x-platforms: ["google"]
35264
+ summary: Historical keyword metrics (Google Keyword Planner)
35265
+ description: |
35266
+ Google Ads only. Runs Keyword Planner's generateKeywordHistoricalMetrics for up to 1,000
35267
+ exact keywords: historical search volume, competition and top-of-page bid ranges, plus
35268
+ averageCpcMicros when includeAverageCpc is set. Rows come back verbatim; counters are int64s
35269
+ encoded as strings, bid/CPC values are micros of the account currency.
35270
+ security:
35271
+ - bearerAuth: []
35272
+ requestBody:
35273
+ required: true
35274
+ content:
35275
+ application/json:
35276
+ schema:
35277
+ type: object
35278
+ required: [accountId, keywords]
35279
+ properties:
35280
+ accountId: { type: string, description: "Zernio googleads SocialAccount id." }
35281
+ customerId: { type: string, description: "Numeric Google Ads customer id (no dashes); only needed when the connection has several accounts." }
35282
+ keywords: { type: array, items: { type: string, maxLength: 80 }, minItems: 1, maxItems: 1000 }
35283
+ countries: { type: array, items: { type: string, minLength: 2, maxLength: 2 }, minItems: 1, maxItems: 10, description: "ISO 3166-1 alpha-2 country codes. Omitted = worldwide." }
35284
+ languageConstantId: { type: string, default: "1000", description: "Google languageConstant id (1000 = English)." }
35285
+ network: { type: string, enum: [GOOGLE_SEARCH, GOOGLE_SEARCH_AND_PARTNERS], default: GOOGLE_SEARCH }
35286
+ includeAdultKeywords: { type: boolean }
35287
+ includeAverageCpc: { type: boolean, description: "Adds averageCpcMicros to each row's keywordMetrics." }
35288
+ responses:
35289
+ '200':
35290
+ description: Historical metric rows (raw Keyword Planner shape)
35291
+ content:
35292
+ application/json:
35293
+ schema:
35294
+ type: object
35295
+ properties:
35296
+ customerId: { type: string, description: "The customer the request ran against." }
35297
+ data:
35298
+ type: array
35299
+ items: { type: object, description: "Raw KeywordHistoricalMetricsResult: text, closeVariants, keywordMetrics." }
35300
+ aggregateMetricResults: { type: [object, "null"] }
35301
+ '400': { description: "Invalid input, or Google rejected the request — message carries Google's error" }
35302
+ '401': { $ref: '#/components/responses/Unauthorized' }
35303
+ '429': { description: "Per-user Google Ads operations budget or the shared Google quota reached; the message says which and when it resets." }
35304
+ '501': { description: Only supported on Google Ads }
35305
+
35206
35306
  /v1/ads/insights:
35207
35307
  get:
35208
35308
  operationId: queryAdInsights
35209
35309
  tags: ["Ad Insights"]
35210
- x-platforms: ["meta"]
35310
+ x-platforms: ["meta", "google"]
35211
35311
  summary: Flexible live insights query
35212
35312
  description: |
35213
- Live, flexible insights query against Meta's Graph API. Unlike GET /v1/ads/{adId}/analytics
35214
- (fixed metric set, cached), this forwards caller-chosen `fields`, `breakdowns` and `filtering`
35215
- to any Meta insights node and returns Meta's rows verbatim.
35313
+ Live, flexible insights query. The account's platform picks the contract:
35216
35314
 
35217
- `objectId` selects the node: an ad account, campaign, ad set or ad platform id.
35218
- `level` sets row granularity independently of the node.
35315
+ **Meta (facebook/instagram)**: forwards caller-chosen `fields`, `breakdowns` and `filtering`
35316
+ to any Meta insights node and returns Meta's rows verbatim. `objectId` (required) selects the
35317
+ node; `level` sets row granularity. Semantic validation is Meta's: an unknown field or invalid
35318
+ breakdown combination returns a 400 carrying Meta's message. For long ranges or agency-scale
35319
+ accounts prefer the async variant (POST /v1/ads/insights/reports).
35219
35320
 
35220
- Semantic validation is Meta's: an unknown field or invalid breakdown combination returns a 400
35221
- carrying Meta's message. For long ranges or agency-scale accounts prefer the async variant
35222
- (POST /v1/ads/insights/reports).
35321
+ **Google Ads (googleads)**: raw GAQL passthrough. Send any read-only GAQL SELECT via `query`
35322
+ (campaign/keyword/search-term/geo/demographic/asset/shopping resources, `change_event`, any
35323
+ `segments.*`) and rows come back verbatim (camelCase, counters as strings). Results are paged
35324
+ at a fixed 10,000 rows; follow `paging.nextPageToken` with `pageToken`. `customerId` is only
35325
+ needed when the connection has several Google Ads accounts. Semantic validation is Google's:
35326
+ an invalid query returns a 400 carrying Google's message (note: selecting `segments.date`
35327
+ requires a finite date filter).
35223
35328
  security:
35224
35329
  - bearerAuth: []
35225
35330
  parameters:
35226
- - { name: accountId, in: query, required: true, schema: { type: string }, description: "Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token." }
35227
- - { name: objectId, in: query, required: true, schema: { type: string }, description: "Meta insights node: act_<n>, campaign id, ad set id or ad id." }
35331
+ - { name: accountId, in: query, required: true, schema: { type: string }, description: "Zernio SocialAccount id (posting or ads variant); its platform selects the Meta or Google contract." }
35332
+ - { name: objectId, in: query, schema: { type: string }, description: "Meta only (required there): insights node act_<n>, campaign id, ad set id or ad id." }
35333
+ - { name: query, in: query, schema: { type: string, maxLength: 10000 }, description: "Google only (required there): the GAQL SELECT statement to run." }
35334
+ - { name: customerId, in: query, schema: { type: string }, description: "Google only: numeric customer id (no dashes) when the connection has several Google Ads accounts." }
35335
+ - { name: pageToken, in: query, schema: { type: string }, description: "Google only: cursor from paging.nextPageToken of the previous page." }
35228
35336
  - { name: level, in: query, schema: { type: string, enum: [ad, adset, campaign, account] }, description: Row granularity }
35229
35337
  - { name: fields, in: query, schema: { type: string }, description: "Comma-separated Graph insights fields (e.g. spend,impressions,frequency,website_purchase_roas). Omitted = Meta's default set." }
35230
35338
  - { name: breakdowns, in: query, schema: { type: string }, description: "Comma-separated Graph breakdowns (e.g. age,gender or publisher_platform)." }
@@ -35241,24 +35349,27 @@ paths:
35241
35349
  - { name: after, in: query, schema: { type: string }, description: "Cursor from paging.after of the previous page." }
35242
35350
  responses:
35243
35351
  '200':
35244
- description: Insight rows (raw Meta shape)
35352
+ description: Insight rows (raw platform shape)
35245
35353
  content:
35246
35354
  application/json:
35247
35355
  schema:
35248
35356
  type: object
35249
35357
  properties:
35250
- objectId: { type: string }
35358
+ objectId: { type: string, description: "Meta responses only." }
35359
+ customerId: { type: string, description: "Google responses only: the customer the query ran against." }
35360
+ fieldMask: { type: [string, "null"], description: "Google responses only: the selected fields echoed by Google." }
35251
35361
  data:
35252
35362
  type: array
35253
- items: { type: object, description: "Raw Meta insights row; keys are the requested Graph fields plus date_start/date_stop." }
35363
+ items: { type: object, description: "Raw platform row. Meta: keys are the requested Graph fields plus date_start/date_stop. Google: nested GAQL resources in camelCase, int64 counters as strings." }
35254
35364
  paging:
35255
35365
  type: object
35256
35366
  properties:
35257
- after: { type: [string, "null"], description: "Cursor for the next page; null when exhausted." }
35258
- '400': { description: "Invalid input, or Meta rejected the query (unknown field, invalid breakdown combo) — message carries Meta's error" }
35367
+ after: { type: [string, "null"], description: "Meta cursor for the next page; null when exhausted." }
35368
+ nextPageToken: { type: [string, "null"], description: "Google cursor for the next page; null when exhausted." }
35369
+ '400': { description: "Invalid input, or the platform rejected the query (unknown field, invalid breakdown combo, malformed GAQL) — message carries the platform's error" }
35259
35370
  '401': { $ref: '#/components/responses/Unauthorized' }
35260
- '429': { description: Meta rate limit reached }
35261
- '501': { description: Only supported on Meta (facebook/instagram) }
35371
+ '429': { description: "Platform rate limit reached. For Google this is the per-user operations budget or the shared quota; the message says which and when it resets." }
35372
+ '501': { description: Only supported on Meta (facebook/instagram) and Google Ads }
35262
35373
 
35263
35374
  /v1/ads/insights/reports:
35264
35375
  post:
@@ -44,6 +44,30 @@ describe 'AdInsightsApi' do
44
44
  end
45
45
  end
46
46
 
47
+ # unit tests for generate_keyword_historical_metrics
48
+ # Historical keyword metrics (Google Keyword Planner)
49
+ # Google Ads only. Runs Keyword Planner&#39;s generateKeywordHistoricalMetrics for up to 1,000 exact keywords: historical search volume, competition and top-of-page bid ranges, plus averageCpcMicros when includeAverageCpc is set. Rows come back verbatim; counters are int64s encoded as strings, bid/CPC values are micros of the account currency.
50
+ # @param generate_keyword_historical_metrics_request
51
+ # @param [Hash] opts the optional parameters
52
+ # @return [GenerateKeywordHistoricalMetrics200Response]
53
+ describe 'generate_keyword_historical_metrics test' do
54
+ it 'should work' do
55
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
56
+ end
57
+ end
58
+
59
+ # unit tests for generate_keyword_ideas
60
+ # Generate keyword ideas (Google Keyword Planner)
61
+ # Google Ads only. Runs Keyword Planner&#39;s generateKeywordIdeas from seed keywords, a seed URL, or both, returning idea rows verbatim (avgMonthlySearches, competition, competitionIndex, top-of-page bid micros, monthlySearchVolumes). Counters are int64s encoded as strings; bid values are micros of the account currency. Omitting &#x60;countries&#x60; targets worldwide.
62
+ # @param generate_keyword_ideas_request
63
+ # @param [Hash] opts the optional parameters
64
+ # @return [GenerateKeywordIdeas200Response]
65
+ describe 'generate_keyword_ideas test' do
66
+ it 'should work' do
67
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
68
+ end
69
+ end
70
+
47
71
  # unit tests for get_ad_analytics
48
72
  # Get ad analytics
49
73
  # Returns detailed performance analytics for an ad. Includes summary metrics, a daily timeline over the requested date range, and optional demographic breakdowns (Meta and TikTok only). If no date range is provided, defaults to the last 90 days. Date range is capped at 730 days max.
@@ -92,10 +116,13 @@ describe 'AdInsightsApi' do
92
116
 
93
117
  # unit tests for query_ad_insights
94
118
  # Flexible live insights query
95
- # Live, flexible insights query against Meta&#39;s Graph API. Unlike GET /v1/ads/{adId}/analytics (fixed metric set, cached), this forwards caller-chosen &#x60;fields&#x60;, &#x60;breakdowns&#x60; and &#x60;filtering&#x60; to any Meta insights node and returns Meta&#39;s rows verbatim. &#x60;objectId&#x60; selects the node: an ad account, campaign, ad set or ad platform id. &#x60;level&#x60; sets row granularity independently of the node. Semantic validation is Meta&#39;s: an unknown field or invalid breakdown combination returns a 400 carrying Meta&#39;s message. For long ranges or agency-scale accounts prefer the async variant (POST /v1/ads/insights/reports).
96
- # @param account_id Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
97
- # @param object_id Meta insights node: act_&lt;n&gt;, campaign id, ad set id or ad id.
119
+ # Live, flexible insights query. The account&#39;s platform picks the contract: **Meta (facebook/instagram)**: forwards caller-chosen &#x60;fields&#x60;, &#x60;breakdowns&#x60; and &#x60;filtering&#x60; to any Meta insights node and returns Meta&#39;s rows verbatim. &#x60;objectId&#x60; (required) selects the node; &#x60;level&#x60; sets row granularity. Semantic validation is Meta&#39;s: an unknown field or invalid breakdown combination returns a 400 carrying Meta&#39;s message. For long ranges or agency-scale accounts prefer the async variant (POST /v1/ads/insights/reports). **Google Ads (googleads)**: raw GAQL passthrough. Send any read-only GAQL SELECT via &#x60;query&#x60; (campaign/keyword/search-term/geo/demographic/asset/shopping resources, &#x60;change_event&#x60;, any &#x60;segments.*&#x60;) and rows come back verbatim (camelCase, counters as strings). Results are paged at a fixed 10,000 rows; follow &#x60;paging.nextPageToken&#x60; with &#x60;pageToken&#x60;. &#x60;customerId&#x60; is only needed when the connection has several Google Ads accounts. Semantic validation is Google&#39;s: an invalid query returns a 400 carrying Google&#39;s message (note: selecting &#x60;segments.date&#x60; requires a finite date filter).
120
+ # @param account_id Zernio SocialAccount id (posting or ads variant); its platform selects the Meta or Google contract.
98
121
  # @param [Hash] opts the optional parameters
122
+ # @option opts [String] :object_id Meta only (required there): insights node — act_&lt;n&gt;, campaign id, ad set id or ad id.
123
+ # @option opts [String] :query Google only (required there): the GAQL SELECT statement to run.
124
+ # @option opts [String] :customer_id Google only: numeric customer id (no dashes) when the connection has several Google Ads accounts.
125
+ # @option opts [String] :page_token Google only: cursor from paging.nextPageToken of the previous page.
99
126
  # @option opts [String] :level Row granularity
100
127
  # @option opts [String] :fields Comma-separated Graph insights fields (e.g. spend,impressions,frequency,website_purchase_roas). Omitted &#x3D; Meta&#39;s default set.
101
128
  # @option opts [String] :breakdowns Comma-separated Graph breakdowns (e.g. age,gender or publisher_platform).
@@ -0,0 +1,48 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::GenerateKeywordHistoricalMetrics200Response
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::GenerateKeywordHistoricalMetrics200Response do
21
+ #let(:instance) { Zernio::GenerateKeywordHistoricalMetrics200Response.new }
22
+
23
+ describe 'test an instance of GenerateKeywordHistoricalMetrics200Response' do
24
+ it 'should create an instance of GenerateKeywordHistoricalMetrics200Response' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::GenerateKeywordHistoricalMetrics200Response)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "customer_id"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ describe 'test attribute "data"' do
37
+ it 'should work' do
38
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
+ end
40
+ end
41
+
42
+ describe 'test attribute "aggregate_metric_results"' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
+ end
46
+ end
47
+
48
+ end
@@ -0,0 +1,82 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::GenerateKeywordHistoricalMetricsRequest
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::GenerateKeywordHistoricalMetricsRequest do
21
+ #let(:instance) { Zernio::GenerateKeywordHistoricalMetricsRequest.new }
22
+
23
+ describe 'test an instance of GenerateKeywordHistoricalMetricsRequest' do
24
+ it 'should create an instance of GenerateKeywordHistoricalMetricsRequest' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::GenerateKeywordHistoricalMetricsRequest)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "account_id"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ describe 'test attribute "customer_id"' do
37
+ it 'should work' do
38
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
+ end
40
+ end
41
+
42
+ describe 'test attribute "keywords"' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
+ end
46
+ end
47
+
48
+ describe 'test attribute "countries"' do
49
+ it 'should work' do
50
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
51
+ end
52
+ end
53
+
54
+ describe 'test attribute "language_constant_id"' do
55
+ it 'should work' do
56
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
57
+ end
58
+ end
59
+
60
+ describe 'test attribute "network"' do
61
+ it 'should work' do
62
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
63
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["GOOGLE_SEARCH", "GOOGLE_SEARCH_AND_PARTNERS"])
64
+ # validator.allowable_values.each do |value|
65
+ # expect { instance.network = value }.not_to raise_error
66
+ # end
67
+ end
68
+ end
69
+
70
+ describe 'test attribute "include_adult_keywords"' do
71
+ it 'should work' do
72
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
73
+ end
74
+ end
75
+
76
+ describe 'test attribute "include_average_cpc"' do
77
+ it 'should work' do
78
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
79
+ end
80
+ end
81
+
82
+ end
@@ -0,0 +1,36 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::GenerateKeywordIdeas200ResponsePaging
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::GenerateKeywordIdeas200ResponsePaging do
21
+ #let(:instance) { Zernio::GenerateKeywordIdeas200ResponsePaging.new }
22
+
23
+ describe 'test an instance of GenerateKeywordIdeas200ResponsePaging' do
24
+ it 'should create an instance of GenerateKeywordIdeas200ResponsePaging' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::GenerateKeywordIdeas200ResponsePaging)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "next_page_token"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ end
@@ -0,0 +1,54 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::GenerateKeywordIdeas200Response
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::GenerateKeywordIdeas200Response do
21
+ #let(:instance) { Zernio::GenerateKeywordIdeas200Response.new }
22
+
23
+ describe 'test an instance of GenerateKeywordIdeas200Response' do
24
+ it 'should create an instance of GenerateKeywordIdeas200Response' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::GenerateKeywordIdeas200Response)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "customer_id"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ describe 'test attribute "data"' do
37
+ it 'should work' do
38
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
+ end
40
+ end
41
+
42
+ describe 'test attribute "aggregate_metric_results"' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
45
+ end
46
+ end
47
+
48
+ describe 'test attribute "paging"' do
49
+ it 'should work' do
50
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
51
+ end
52
+ end
53
+
54
+ end