zernio-sdk 0.0.524 → 0.0.526
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.
- checksums.yaml +4 -4
- data/docs/AdsApi.md +1 -1
- data/docs/CreateStandaloneAdRequest.md +4 -4
- data/docs/CreateStandaloneAdRequestRegionsInner.md +1 -1
- data/docs/UpdateGmbLocationRequest.md +1 -3
- data/docs/UpdateGoogleBusinessPlaceActionRequest.md +1 -1
- data/lib/zernio-sdk/api/ads_api.rb +2 -2
- data/lib/zernio-sdk/api/gmb_place_actions_api.rb +4 -0
- data/lib/zernio-sdk/models/create_standalone_ad_request.rb +4 -4
- data/lib/zernio-sdk/models/create_standalone_ad_request_regions_inner.rb +1 -1
- data/lib/zernio-sdk/models/update_gmb_location_request.rb +4 -33
- data/lib/zernio-sdk/models/update_google_business_place_action_request.rb +23 -1
- data/lib/zernio-sdk/models/update_google_business_services_request_service_items_inner_structured_service_item.rb +1 -0
- data/lib/zernio-sdk/version.rb +1 -1
- data/openapi.yaml +14 -18
- data/spec/api/ads_api_spec.rb +1 -1
- data/spec/models/update_gmb_location_request_spec.rb +0 -6
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 77f6144ef44a98297cee25ab4bb0e064a7df7d5365369f5ec8c2ccb26d1c9ac1
|
|
4
|
+
data.tar.gz: 0b2805651f93fc9039d4811ef3a350f851589d8b73f873225b21c07dea8003a9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 7ca42a1a9a7a56eca84f15e6e615eca720b2e4ece853541e9488b1ccb9eace0bb2a4f8794d0415eddfb721d0d48385bb4994ac958818378f157a17376bc275ee
|
|
7
|
+
data.tar.gz: 2eda0cb5d7d4057d8851963b351b01fb7b72e8c62ef1f57eda1ca97cb3259dc2d8fe3217a0e2c3dbdc5a39a316e3840fe6a6bbca57312f0a9afdffa5a104d92f
|
data/docs/AdsApi.md
CHANGED
|
@@ -3069,7 +3069,7 @@ end
|
|
|
3069
3069
|
|
|
3070
3070
|
Search targeting options
|
|
3071
3071
|
|
|
3072
|
-
Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
3072
|
+
Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. TikTok geo searches return every matching level in one list (`type` is `country`, `region`, `city`, `district`, or `metro` for DMA areas) — `geoType` is not applied. Results are scoped to the advertiser's targetable markets, and every id is usable in `regions`/`cities`/`metros` keys on `POST /v1/ads/create`. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
3073
3073
|
|
|
3074
3074
|
### Examples
|
|
3075
3075
|
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
| **billing_event** | **String** | Meta only. Explicit ad-set `billing_event`. Defaults to `IMPRESSIONS`. Forwarded verbatim to Meta, which validates compatibility with the optimization goal. | [optional] |
|
|
17
17
|
| **budget_amount** | **Float** | Required on legacy + multi-creative shapes. Inherited on attach. | [optional] |
|
|
18
18
|
| **budget_type** | **String** | Required on legacy + multi-creative shapes. Inherited on attach. | [optional] |
|
|
19
|
-
| **status** | **String** | Meta
|
|
19
|
+
| **status** | **String** | Meta and TikTok. Publish state of the created entities. Omitted or ACTIVE publishes live (default, back-compat); PAUSED creates them paused and skips activation, so you can review before they spend. On TikTok the whole campaign > ad group > ad hierarchy stays paused. | [optional] |
|
|
20
20
|
| **budget_level** | **String** | Meta only. Where the budget lives, which selects the Meta budget model: - `adset` (default): ABO (Ad-set Budget Optimization). The budget is set on the ad set. This is the back-compatible behaviour — omit this field to keep it. - `campaign`: CBO (Campaign Budget Optimization / Advantage Campaign Budget). The budget AND `bidStrategy` are set on the CAMPAIGN, and Meta distributes spend across ad sets automatically. Meta requires the budget at exactly one level, never both. Non-Meta platforms ignore this field. Ignored on the attach shape (`adSetId`), which inherits the existing budget. | [optional][default to 'adset'] |
|
|
21
21
|
| **currency** | **String** | | [optional] |
|
|
22
22
|
| **headline** | **String** | Required for Meta, Google, Pinterest, and LinkedIn on legacy + attach shapes (skip for multi-creative — use `creatives[].headline`). Ignored for TikTok and X/Twitter. Max: Meta=255, Google=30, Pinterest=100, LinkedIn=400. On LinkedIn this is the ad's headline (the bold text on the creative); for traffic ads it's the link card title. | [optional] |
|
|
@@ -38,13 +38,13 @@
|
|
|
38
38
|
| **organization_id** | **String** | LinkedIn only. The Company Page that authors the Direct Sponsored Content (\"dark\") post backing the ad — accepts a numeric organization ID or a full `urn:li:organization:N` URN. Required unless the resolved `accountId` is a connected LinkedIn Company-Page account (defaults to that page) or the LinkedIn ad account is org-owned (defaults to the account's owning organization). The authenticated member must be an ADMINISTRATOR or DIRECT_SPONSORED_CONTENT_POSTER of this page (and the page must be associated with the ad account), or LinkedIn returns 403. Ignored by every other platform. | [optional] |
|
|
39
39
|
| **targeting** | [**TargetingSpec**](TargetingSpec.md) | Nested targeting object — the same TargetingSpec shape as `POST /v1/ads/boost`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. Merged UNDER the flat inline targeting fields below: `savedTargetingId` < `targeting` < flat fields (a flat field present on the body replaces the nested value entirely). Both forms are equivalent; use whichever your integration already builds. | [optional] |
|
|
40
40
|
| **countries** | **Array<String>** | ISO 3166-1 alpha-2 country codes (e.g. ['NL']). Defaults to ['US'] when no other geo targeting (flat or nested `targeting`) is provided. (LinkedIn currently honours country-level targeting only.) | [optional] |
|
|
41
|
-
| **cities** | [**Array<CreateStandaloneAdRequestCitiesInner>**](CreateStandaloneAdRequestCitiesInner.md) |
|
|
42
|
-
| **regions** | [**Array<CreateStandaloneAdRequestRegionsInner>**](CreateStandaloneAdRequestRegionsInner.md) |
|
|
41
|
+
| **cities** | [**Array<CreateStandaloneAdRequestCitiesInner>**](CreateStandaloneAdRequestCitiesInner.md) | City-level geo targeting (Meta and TikTok). Each city is targeted by the platform's opaque `key` (the city ID) which can be looked up via `GET /v1/ads/targeting/search?dimension=geo&q=<name>&countryCode=<ISO>`. Optional `radius` + `distance_unit` (Meta only) extend the targeting beyond the city limits (e.g. radius 25 km around the city center). Both must be set together, or both omitted (Meta defaults to ~16 km when omitted). On Meta, cannot overlap with the same country in `countries` (Meta returns a \"locations overlap\" error). Either drop the country or scope it to a different country. On TikTok, keys are numeric location ids and can be sent without `countries`. | [optional] |
|
|
42
|
+
| **regions** | [**Array<CreateStandaloneAdRequestRegionsInner>**](CreateStandaloneAdRequestRegionsInner.md) | Region-level (state/province) geo targeting (Meta and TikTok). Each region is targeted by the platform's opaque `key` (the region ID) which can be looked up via `GET /v1/ads/targeting/search?dimension=geo&q=<name>&countryCode=<ISO>`. | [optional] |
|
|
43
43
|
| **age_min** | **Integer** | | [optional] |
|
|
44
44
|
| **age_max** | **Integer** | | [optional] |
|
|
45
45
|
| **interests** | [**Array<UpdateAdRequestTargetingInterestsInner>**](UpdateAdRequestTargetingInterestsInner.md) | Interest objects from /v1/ads/interests. Each must include id and name. | [optional] |
|
|
46
46
|
| **zips** | [**Array<BoostPostRequestTargetingRegionsInner>**](BoostPostRequestTargetingRegionsInner.md) | Postal/ZIP geo targeting. `key` is the platform's postal location ID from /v1/ads/targeting/search?dimension=geo&geoType=zip. Supported on Meta, Google, TikTok, Pinterest, X. | [optional] |
|
|
47
|
-
| **metros** | [**Array<BoostPostRequestTargetingRegionsInner>**](BoostPostRequestTargetingRegionsInner.md) | DMA / metro-area geo targeting. `key` is the platform's metro ID from /v1/ads/targeting/search?dimension=geo&geoType=metro. | [optional] |
|
|
47
|
+
| **metros** | [**Array<BoostPostRequestTargetingRegionsInner>**](BoostPostRequestTargetingRegionsInner.md) | DMA / metro-area geo targeting (Meta and TikTok). `key` is the platform's metro ID from /v1/ads/targeting/search?dimension=geo&geoType=metro (TikTok metros appear as type `metro`, e.g. the New York DMA). | [optional] |
|
|
48
48
|
| **custom_locations** | [**Array<CreateStandaloneAdRequestCustomLocationsInner>**](CreateStandaloneAdRequestCustomLocationsInner.md) | Point-radius (lat/lng) geo targeting. Meta only (custom_locations). Rejected on platforms without radius support. | [optional] |
|
|
49
49
|
| **behaviors** | [**Array<CreateStandaloneAdRequestBehaviorsInner>**](CreateStandaloneAdRequestBehaviorsInner.md) | Behaviour entities from /v1/ads/targeting/search?dimension=behavior. Supported on Meta and TikTok. Each must include id. | [optional] |
|
|
50
50
|
| **income_tier** | **String** | Normalized household-income tier. Meta and TikTok express all four; Google maps only `top_10`; rejected on LinkedIn, X, and Pinterest. On Meta, income targeting is incompatible with housing/employment/credit `specialAdCategories`. | [optional] |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **key** | **String** |
|
|
7
|
+
| **key** | **String** | Platform region ID, from /v1/ads/targeting/search results. | |
|
|
8
8
|
|
|
9
9
|
## Example
|
|
10
10
|
|
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **selected_location_id** | **String** | | |
|
|
8
8
|
| **google_account_id** | **String** | Optional but recommended. The Google Business Account resource name (\"accounts/123\") that owns the new location (from GET gmb-locations). When provided, the location is resolved directly instead of by enumerating the account, which is required for accounts with many locations. Named `googleAccountId` to disambiguate from the path `accountId` (the Zernio account). The legacy field name `accountId` is still accepted for backwards compatibility. | [optional] |
|
|
9
|
-
| **account_id** | **String** | Legacy alias for googleAccountId. Use googleAccountId for new integrations. | [optional] |
|
|
10
9
|
|
|
11
10
|
## Example
|
|
12
11
|
|
|
@@ -15,8 +14,7 @@ require 'zernio-sdk'
|
|
|
15
14
|
|
|
16
15
|
instance = Zernio::UpdateGmbLocationRequest.new(
|
|
17
16
|
selected_location_id: null,
|
|
18
|
-
google_account_id: null
|
|
19
|
-
account_id: null
|
|
17
|
+
google_account_id: null
|
|
20
18
|
)
|
|
21
19
|
```
|
|
22
20
|
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **name** | **String** | Resource name of the place action link (e.g. locations/123/placeActionLinks/456) | |
|
|
8
|
-
| **uri** | **String** | New action URL | [optional] |
|
|
8
|
+
| **uri** | **String** | New action URL. At least one of uri or placeActionType is required (enforced server-side; not modeled as anyOf because required-only anyOf branches break SDK generators). | [optional] |
|
|
9
9
|
| **place_action_type** | **String** | New action type | [optional] |
|
|
10
10
|
|
|
11
11
|
## Example
|
|
@@ -3101,7 +3101,7 @@ module Zernio
|
|
|
3101
3101
|
end
|
|
3102
3102
|
|
|
3103
3103
|
# Search targeting options
|
|
3104
|
-
# Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
3104
|
+
# Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. TikTok geo searches return every matching level in one list (`type` is `country`, `region`, `city`, `district`, or `metro` for DMA areas) — `geoType` is not applied. Results are scoped to the advertiser's targetable markets, and every id is usable in `regions`/`cities`/`metros` keys on `POST /v1/ads/create`. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
3105
3105
|
# @param account_id [String] Social account ID (a connected account on the target ad platform).
|
|
3106
3106
|
# @param q [String] Search query. For geo, the locality name only (no region/country suffix).
|
|
3107
3107
|
# @param [Hash] opts the optional parameters
|
|
@@ -3116,7 +3116,7 @@ module Zernio
|
|
|
3116
3116
|
end
|
|
3117
3117
|
|
|
3118
3118
|
# Search targeting options
|
|
3119
|
-
# Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
3119
|
+
# Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. TikTok geo searches return every matching level in one list (`type` is `country`, `region`, `city`, `district`, or `metro` for DMA areas) — `geoType` is not applied. Results are scoped to the advertiser's targetable markets, and every id is usable in `regions`/`cities`/`metros` keys on `POST /v1/ads/create`. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
3120
3120
|
# @param account_id [String] Social account ID (a connected account on the target ad platform).
|
|
3121
3121
|
# @param q [String] Search query. For geo, the locality name only (no region/country suffix).
|
|
3122
3122
|
# @param [Hash] opts the optional parameters
|
|
@@ -276,6 +276,10 @@ module Zernio
|
|
|
276
276
|
if @api_client.config.client_side_validation && account_id.nil?
|
|
277
277
|
fail ArgumentError, "Missing the required parameter 'account_id' when calling GMBPlaceActionsApi.update_google_business_place_action"
|
|
278
278
|
end
|
|
279
|
+
# verify the required parameter 'update_google_business_place_action_request' is set
|
|
280
|
+
if @api_client.config.client_side_validation && update_google_business_place_action_request.nil?
|
|
281
|
+
fail ArgumentError, "Missing the required parameter 'update_google_business_place_action_request' when calling GMBPlaceActionsApi.update_google_business_place_action"
|
|
282
|
+
end
|
|
279
283
|
# resource path
|
|
280
284
|
local_var_path = '/v1/accounts/{accountId}/gmb-place-actions'.sub('{' + 'accountId' + '}', CGI.escape(account_id.to_s))
|
|
281
285
|
|
|
@@ -47,7 +47,7 @@ module Zernio
|
|
|
47
47
|
# Required on legacy + multi-creative shapes. Inherited on attach.
|
|
48
48
|
attr_accessor :budget_type
|
|
49
49
|
|
|
50
|
-
# Meta
|
|
50
|
+
# Meta and TikTok. Publish state of the created entities. Omitted or ACTIVE publishes live (default, back-compat); PAUSED creates them paused and skips activation, so you can review before they spend. On TikTok the whole campaign > ad group > ad hierarchy stays paused.
|
|
51
51
|
attr_accessor :status
|
|
52
52
|
|
|
53
53
|
# Meta only. Where the budget lives, which selects the Meta budget model: - `adset` (default): ABO (Ad-set Budget Optimization). The budget is set on the ad set. This is the back-compatible behaviour — omit this field to keep it. - `campaign`: CBO (Campaign Budget Optimization / Advantage Campaign Budget). The budget AND `bidStrategy` are set on the CAMPAIGN, and Meta distributes spend across ad sets automatically. Meta requires the budget at exactly one level, never both. Non-Meta platforms ignore this field. Ignored on the attach shape (`adSetId`), which inherits the existing budget.
|
|
@@ -110,10 +110,10 @@ module Zernio
|
|
|
110
110
|
# ISO 3166-1 alpha-2 country codes (e.g. ['NL']). Defaults to ['US'] when no other geo targeting (flat or nested `targeting`) is provided. (LinkedIn currently honours country-level targeting only.)
|
|
111
111
|
attr_accessor :countries
|
|
112
112
|
|
|
113
|
-
#
|
|
113
|
+
# City-level geo targeting (Meta and TikTok). Each city is targeted by the platform's opaque `key` (the city ID) which can be looked up via `GET /v1/ads/targeting/search?dimension=geo&q=<name>&countryCode=<ISO>`. Optional `radius` + `distance_unit` (Meta only) extend the targeting beyond the city limits (e.g. radius 25 km around the city center). Both must be set together, or both omitted (Meta defaults to ~16 km when omitted). On Meta, cannot overlap with the same country in `countries` (Meta returns a \"locations overlap\" error). Either drop the country or scope it to a different country. On TikTok, keys are numeric location ids and can be sent without `countries`.
|
|
114
114
|
attr_accessor :cities
|
|
115
115
|
|
|
116
|
-
#
|
|
116
|
+
# Region-level (state/province) geo targeting (Meta and TikTok). Each region is targeted by the platform's opaque `key` (the region ID) which can be looked up via `GET /v1/ads/targeting/search?dimension=geo&q=<name>&countryCode=<ISO>`.
|
|
117
117
|
attr_accessor :regions
|
|
118
118
|
|
|
119
119
|
attr_accessor :age_min
|
|
@@ -126,7 +126,7 @@ module Zernio
|
|
|
126
126
|
# Postal/ZIP geo targeting. `key` is the platform's postal location ID from /v1/ads/targeting/search?dimension=geo&geoType=zip. Supported on Meta, Google, TikTok, Pinterest, X.
|
|
127
127
|
attr_accessor :zips
|
|
128
128
|
|
|
129
|
-
# DMA / metro-area geo targeting. `key` is the platform's metro ID from /v1/ads/targeting/search?dimension=geo&geoType=metro.
|
|
129
|
+
# DMA / metro-area geo targeting (Meta and TikTok). `key` is the platform's metro ID from /v1/ads/targeting/search?dimension=geo&geoType=metro (TikTok metros appear as type `metro`, e.g. the New York DMA).
|
|
130
130
|
attr_accessor :metros
|
|
131
131
|
|
|
132
132
|
# Point-radius (lat/lng) geo targeting. Meta only (custom_locations). Rejected on platforms without radius support.
|
|
@@ -15,7 +15,7 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class CreateStandaloneAdRequestRegionsInner < ApiModelBase
|
|
18
|
-
#
|
|
18
|
+
# Platform region ID, from /v1/ads/targeting/search results.
|
|
19
19
|
attr_accessor :key
|
|
20
20
|
|
|
21
21
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
@@ -20,15 +20,11 @@ module Zernio
|
|
|
20
20
|
# Optional but recommended. The Google Business Account resource name (\"accounts/123\") that owns the new location (from GET gmb-locations). When provided, the location is resolved directly instead of by enumerating the account, which is required for accounts with many locations. Named `googleAccountId` to disambiguate from the path `accountId` (the Zernio account). The legacy field name `accountId` is still accepted for backwards compatibility.
|
|
21
21
|
attr_accessor :google_account_id
|
|
22
22
|
|
|
23
|
-
# Legacy alias for googleAccountId. Use googleAccountId for new integrations.
|
|
24
|
-
attr_accessor :account_id
|
|
25
|
-
|
|
26
23
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
27
24
|
def self.attribute_map
|
|
28
25
|
{
|
|
29
26
|
:'selected_location_id' => :'selectedLocationId',
|
|
30
|
-
:'google_account_id' => :'googleAccountId'
|
|
31
|
-
:'account_id' => :'accountId'
|
|
27
|
+
:'google_account_id' => :'googleAccountId'
|
|
32
28
|
}
|
|
33
29
|
end
|
|
34
30
|
|
|
@@ -46,8 +42,7 @@ module Zernio
|
|
|
46
42
|
def self.openapi_types
|
|
47
43
|
{
|
|
48
44
|
:'selected_location_id' => :'String',
|
|
49
|
-
:'google_account_id' => :'String'
|
|
50
|
-
:'account_id' => :'String'
|
|
45
|
+
:'google_account_id' => :'String'
|
|
51
46
|
}
|
|
52
47
|
end
|
|
53
48
|
|
|
@@ -82,10 +77,6 @@ module Zernio
|
|
|
82
77
|
if attributes.key?(:'google_account_id')
|
|
83
78
|
self.google_account_id = attributes[:'google_account_id']
|
|
84
79
|
end
|
|
85
|
-
|
|
86
|
-
if attributes.key?(:'account_id')
|
|
87
|
-
self.account_id = attributes[:'account_id']
|
|
88
|
-
end
|
|
89
80
|
end
|
|
90
81
|
|
|
91
82
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -105,10 +96,6 @@ module Zernio
|
|
|
105
96
|
invalid_properties.push('invalid value for "google_account_id", the character length must be greater than or equal to 1.')
|
|
106
97
|
end
|
|
107
98
|
|
|
108
|
-
if !@account_id.nil? && @account_id.to_s.length < 1
|
|
109
|
-
invalid_properties.push('invalid value for "account_id", the character length must be greater than or equal to 1.')
|
|
110
|
-
end
|
|
111
|
-
|
|
112
99
|
invalid_properties
|
|
113
100
|
end
|
|
114
101
|
|
|
@@ -119,7 +106,6 @@ module Zernio
|
|
|
119
106
|
return false if @selected_location_id.nil?
|
|
120
107
|
return false if @selected_location_id.to_s.length < 1
|
|
121
108
|
return false if !@google_account_id.nil? && @google_account_id.to_s.length < 1
|
|
122
|
-
return false if !@account_id.nil? && @account_id.to_s.length < 1
|
|
123
109
|
true
|
|
124
110
|
end
|
|
125
111
|
|
|
@@ -151,28 +137,13 @@ module Zernio
|
|
|
151
137
|
@google_account_id = google_account_id
|
|
152
138
|
end
|
|
153
139
|
|
|
154
|
-
# Custom attribute writer method with validation
|
|
155
|
-
# @param [Object] account_id Value to be assigned
|
|
156
|
-
def account_id=(account_id)
|
|
157
|
-
if account_id.nil?
|
|
158
|
-
fail ArgumentError, 'account_id cannot be nil'
|
|
159
|
-
end
|
|
160
|
-
|
|
161
|
-
if account_id.to_s.length < 1
|
|
162
|
-
fail ArgumentError, 'invalid value for "account_id", the character length must be greater than or equal to 1.'
|
|
163
|
-
end
|
|
164
|
-
|
|
165
|
-
@account_id = account_id
|
|
166
|
-
end
|
|
167
|
-
|
|
168
140
|
# Checks equality by comparing each attribute.
|
|
169
141
|
# @param [Object] Object to be compared
|
|
170
142
|
def ==(o)
|
|
171
143
|
return true if self.equal?(o)
|
|
172
144
|
self.class == o.class &&
|
|
173
145
|
selected_location_id == o.selected_location_id &&
|
|
174
|
-
google_account_id == o.google_account_id
|
|
175
|
-
account_id == o.account_id
|
|
146
|
+
google_account_id == o.google_account_id
|
|
176
147
|
end
|
|
177
148
|
|
|
178
149
|
# @see the `==` method
|
|
@@ -184,7 +155,7 @@ module Zernio
|
|
|
184
155
|
# Calculates hash code according to all attributes.
|
|
185
156
|
# @return [Integer] Hash code
|
|
186
157
|
def hash
|
|
187
|
-
[selected_location_id, google_account_id
|
|
158
|
+
[selected_location_id, google_account_id].hash
|
|
188
159
|
end
|
|
189
160
|
|
|
190
161
|
# Builds the object from hash
|
|
@@ -18,12 +18,34 @@ module Zernio
|
|
|
18
18
|
# Resource name of the place action link (e.g. locations/123/placeActionLinks/456)
|
|
19
19
|
attr_accessor :name
|
|
20
20
|
|
|
21
|
-
# New action URL
|
|
21
|
+
# New action URL. At least one of uri or placeActionType is required (enforced server-side; not modeled as anyOf because required-only anyOf branches break SDK generators).
|
|
22
22
|
attr_accessor :uri
|
|
23
23
|
|
|
24
24
|
# New action type
|
|
25
25
|
attr_accessor :place_action_type
|
|
26
26
|
|
|
27
|
+
class EnumAttributeValidator
|
|
28
|
+
attr_reader :datatype
|
|
29
|
+
attr_reader :allowable_values
|
|
30
|
+
|
|
31
|
+
def initialize(datatype, allowable_values)
|
|
32
|
+
@allowable_values = allowable_values.map do |value|
|
|
33
|
+
case datatype.to_s
|
|
34
|
+
when /Integer/i
|
|
35
|
+
value.to_i
|
|
36
|
+
when /Float/i
|
|
37
|
+
value.to_f
|
|
38
|
+
else
|
|
39
|
+
value
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
def valid?(value)
|
|
45
|
+
!value || allowable_values.include?(value)
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
|
|
27
49
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
28
50
|
def self.attribute_map
|
|
29
51
|
{
|
|
@@ -14,6 +14,7 @@ require 'date'
|
|
|
14
14
|
require 'time'
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
|
+
# Exactly one of structuredServiceItem or freeFormServiceItem is required per item (enforced server-side; not modeled as oneOf because required-only oneOf branches break SDK generators).
|
|
17
18
|
class UpdateGoogleBusinessServicesRequestServiceItemsInnerStructuredServiceItem < ApiModelBase
|
|
18
19
|
attr_accessor :service_type_id
|
|
19
20
|
|
data/lib/zernio-sdk/version.rb
CHANGED
data/openapi.yaml
CHANGED
|
@@ -15888,9 +15888,6 @@ paths:
|
|
|
15888
15888
|
schema:
|
|
15889
15889
|
type: object
|
|
15890
15890
|
required: [name]
|
|
15891
|
-
anyOf:
|
|
15892
|
-
- required: [uri]
|
|
15893
|
-
- required: [placeActionType]
|
|
15894
15891
|
properties:
|
|
15895
15892
|
name:
|
|
15896
15893
|
type: string
|
|
@@ -15898,7 +15895,7 @@ paths:
|
|
|
15898
15895
|
uri:
|
|
15899
15896
|
type: string
|
|
15900
15897
|
format: uri
|
|
15901
|
-
description: New action URL
|
|
15898
|
+
description: "New action URL. At least one of uri or placeActionType is required (enforced server-side; not modeled as anyOf because required-only anyOf branches break SDK generators)."
|
|
15902
15899
|
placeActionType:
|
|
15903
15900
|
type: string
|
|
15904
15901
|
enum: [APPOINTMENT, ONLINE_APPOINTMENT, DINING_RESERVATION, FOOD_ORDERING, FOOD_DELIVERY, FOOD_TAKEOUT, SHOP_ONLINE]
|
|
@@ -16025,13 +16022,11 @@ paths:
|
|
|
16025
16022
|
type: array
|
|
16026
16023
|
items:
|
|
16027
16024
|
type: object
|
|
16028
|
-
oneOf:
|
|
16029
|
-
- required: [structuredServiceItem]
|
|
16030
|
-
- required: [freeFormServiceItem]
|
|
16031
16025
|
properties:
|
|
16032
16026
|
structuredServiceItem:
|
|
16033
16027
|
type: object
|
|
16034
16028
|
required: [serviceTypeId]
|
|
16029
|
+
description: "Exactly one of structuredServiceItem or freeFormServiceItem is required per item (enforced server-side; not modeled as oneOf because required-only oneOf branches break SDK generators)."
|
|
16035
16030
|
properties:
|
|
16036
16031
|
serviceTypeId: { type: string, minLength: 1 }
|
|
16037
16032
|
description: { type: string }
|
|
@@ -18620,11 +18615,6 @@ paths:
|
|
|
18620
18615
|
locations. Named `googleAccountId` to disambiguate from the path
|
|
18621
18616
|
`accountId` (the Zernio account). The legacy field name `accountId`
|
|
18622
18617
|
is still accepted for backwards compatibility.
|
|
18623
|
-
accountId:
|
|
18624
|
-
type: string
|
|
18625
|
-
minLength: 1
|
|
18626
|
-
deprecated: true
|
|
18627
|
-
description: Legacy alias for googleAccountId. Use googleAccountId for new integrations.
|
|
18628
18618
|
example:
|
|
18629
18619
|
selectedLocationId: "12345678901234567890"
|
|
18630
18620
|
googleAccountId: "accounts/123456789"
|
|
@@ -34171,7 +34161,7 @@ paths:
|
|
|
34171
34161
|
status:
|
|
34172
34162
|
type: string
|
|
34173
34163
|
enum: [ACTIVE, PAUSED]
|
|
34174
|
-
description: "Meta
|
|
34164
|
+
description: "Meta and TikTok. Publish state of the created entities. Omitted or ACTIVE publishes live (default, back-compat); PAUSED creates them paused and skips activation, so you can review before they spend. On TikTok the whole campaign > ad group > ad hierarchy stays paused."
|
|
34175
34165
|
budgetLevel:
|
|
34176
34166
|
type: string
|
|
34177
34167
|
enum: [adset, campaign]
|
|
@@ -34305,9 +34295,9 @@ paths:
|
|
|
34305
34295
|
cities:
|
|
34306
34296
|
type: array
|
|
34307
34297
|
description: |
|
|
34308
|
-
|
|
34298
|
+
City-level geo targeting (Meta and TikTok). Each city is targeted by the platform's opaque `key` (the city ID) which can be looked up via `GET /v1/ads/targeting/search?dimension=geo&q=<name>&countryCode=<ISO>`. Optional `radius` + `distance_unit` (Meta only) extend the targeting beyond the city limits (e.g. radius 25 km around the city center). Both must be set together, or both omitted (Meta defaults to ~16 km when omitted).
|
|
34309
34299
|
|
|
34310
|
-
|
|
34300
|
+
On Meta, cannot overlap with the same country in `countries` (Meta returns a "locations overlap" error). Either drop the country or scope it to a different country. On TikTok, keys are numeric location ids and can be sent without `countries`.
|
|
34311
34301
|
items:
|
|
34312
34302
|
type: object
|
|
34313
34303
|
required: [key]
|
|
@@ -34318,12 +34308,12 @@ paths:
|
|
|
34318
34308
|
regions:
|
|
34319
34309
|
type: array
|
|
34320
34310
|
description: |
|
|
34321
|
-
|
|
34311
|
+
Region-level (state/province) geo targeting (Meta and TikTok). Each region is targeted by the platform's opaque `key` (the region ID) which can be looked up via `GET /v1/ads/targeting/search?dimension=geo&q=<name>&countryCode=<ISO>`.
|
|
34322
34312
|
items:
|
|
34323
34313
|
type: object
|
|
34324
34314
|
required: [key]
|
|
34325
34315
|
properties:
|
|
34326
|
-
key: { type: string, description: "
|
|
34316
|
+
key: { type: string, description: "Platform region ID, from /v1/ads/targeting/search results." }
|
|
34327
34317
|
ageMin: { type: integer, minimum: 13, maximum: 65 }
|
|
34328
34318
|
ageMax: { type: integer, minimum: 13, maximum: 65 }
|
|
34329
34319
|
interests:
|
|
@@ -34346,7 +34336,7 @@ paths:
|
|
|
34346
34336
|
name: { type: string }
|
|
34347
34337
|
metros:
|
|
34348
34338
|
type: array
|
|
34349
|
-
description: "DMA / metro-area geo targeting. `key` is the platform's metro ID from /v1/ads/targeting/search?dimension=geo&geoType=metro."
|
|
34339
|
+
description: "DMA / metro-area geo targeting (Meta and TikTok). `key` is the platform's metro ID from /v1/ads/targeting/search?dimension=geo&geoType=metro (TikTok metros appear as type `metro`, e.g. the New York DMA)."
|
|
34350
34340
|
items:
|
|
34351
34341
|
type: object
|
|
34352
34342
|
required: [key]
|
|
@@ -35086,6 +35076,12 @@ paths:
|
|
|
35086
35076
|
across platforms into a single shape, so the same client code consumes Meta,
|
|
35087
35077
|
TikTok, LinkedIn, X, Pinterest, and Google results.
|
|
35088
35078
|
|
|
35079
|
+
TikTok geo searches return every matching level in one list (`type` is
|
|
35080
|
+
`country`, `region`, `city`, `district`, or `metro` for DMA areas) —
|
|
35081
|
+
`geoType` is not applied. Results are scoped to the advertiser's targetable
|
|
35082
|
+
markets, and every id is usable in `regions`/`cities`/`metros` keys on
|
|
35083
|
+
`POST /v1/ads/create`.
|
|
35084
|
+
|
|
35089
35085
|
For geo queries, `q` should contain only the locality name (e.g. `"Amsterdam"`,
|
|
35090
35086
|
not `"Amsterdam, NL"`). Use `countryCode` to disambiguate.
|
|
35091
35087
|
security:
|
data/spec/api/ads_api_spec.rb
CHANGED
|
@@ -602,7 +602,7 @@ describe 'AdsApi' do
|
|
|
602
602
|
|
|
603
603
|
# unit tests for search_ad_targeting
|
|
604
604
|
# Search targeting options
|
|
605
|
-
# Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
605
|
+
# Resolve a human-readable query into the platform's opaque targeting ids used in the `TargetingSpec` (`countries`/`regions`/`cities`/`zips`/`metros` geo keys, and `interests`/`behaviors` entity ids) on `POST /v1/ads/create`, `POST /v1/ads/targeting/reach-estimate`, and `saved_targeting` audiences. The `dimension` param selects what is searched, `geo` (locations, further scoped by `geoType`), `interest`, `behavior`, or `income`. Availability of each dimension varies by platform (e.g. behaviours are Meta/TikTok only). Results are normalized across platforms into a single shape, so the same client code consumes Meta, TikTok, LinkedIn, X, Pinterest, and Google results. TikTok geo searches return every matching level in one list (`type` is `country`, `region`, `city`, `district`, or `metro` for DMA areas) — `geoType` is not applied. Results are scoped to the advertiser's targetable markets, and every id is usable in `regions`/`cities`/`metros` keys on `POST /v1/ads/create`. For geo queries, `q` should contain only the locality name (e.g. `\"Amsterdam\"`, not `\"Amsterdam, NL\"`). Use `countryCode` to disambiguate.
|
|
606
606
|
# @param account_id Social account ID (a connected account on the target ad platform).
|
|
607
607
|
# @param q Search query. For geo, the locality name only (no region/country suffix).
|
|
608
608
|
# @param [Hash] opts the optional parameters
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: zernio-sdk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.526
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- OpenAPI-Generator
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-07-
|
|
11
|
+
date: 2026-07-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: typhoeus
|