late-sdk 0.0.954 → 0.0.955

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d478030911a4eaf3e1d62d522cdc2cfea66f726769f2d3e3245fc933a26991be
4
- data.tar.gz: e709dd1af44949a0675e26229695b10ebcf8a46083353d47b198438ea17e6811
3
+ metadata.gz: 7d5064a8f4a62d993abf6a398bc6e5b5d3a70c9bfefbb09845f169ba21ddbf51
4
+ data.tar.gz: 9da5aba2d5467ebdf3aa90608bedd81698a9f9cef369aa4c6a001bcf4f3990db
5
5
  SHA512:
6
- metadata.gz: af88a66eb0464dae89b7c373318e4abddd62af32d6edf92b21698039e5db8a19e8163bcdd29eebada718dde99eb8615264462c538ad15938976930a4fa845259
7
- data.tar.gz: bbb5647a2df9132c8bef5db8bb8aa75a544511fd33f1a9431d4a8c50ce2adaec5739db2cf6fd545f31eb99ca1541812cc4e39901971e58bca0e67739fac1ac2e
6
+ metadata.gz: 557e48ff95a01ac3d531067cd54a88abb9b3be47de2b31826de639089cd99defa8f3e807c132899d0797f241c744d1ade158ee11c9718aff7985c157167f9dd3
7
+ data.tar.gz: c3d527e7d1d3ab6c395236b557132f44e1945fced74eef936163e5fda8184c258a3911d1ff16023816af1a82fad95b0ebafd02e4ac5242bb0cd9a6407b3f50cc
data/README.md CHANGED
@@ -104,6 +104,7 @@ Class | Method | HTTP request | Description
104
104
  *Zernio::AccountsApi* | [**list_accounts**](docs/AccountsApi.md#list_accounts) | **GET** /v1/accounts | List accounts
105
105
  *Zernio::AccountsApi* | [**list_tik_tok_commercial_music**](docs/AccountsApi.md#list_tik_tok_commercial_music) | **GET** /v1/accounts/{accountId}/tiktok/commercial-music | List trending commercial music
106
106
  *Zernio::AccountsApi* | [**move_account_to_profile**](docs/AccountsApi.md#move_account_to_profile) | **PATCH** /v1/accounts/{accountId} | Move account to another profile
107
+ *Zernio::AccountsApi* | [**search_tik_tok_locations**](docs/AccountsApi.md#search_tik_tok_locations) | **GET** /v1/accounts/{accountId}/tiktok/locations | Search TikTok location tags
107
108
  *Zernio::AccountsApi* | [**update_account**](docs/AccountsApi.md#update_account) | **PUT** /v1/accounts/{accountId} | Update account
108
109
  *Zernio::AccountsApi* | [**update_bluesky_settings**](docs/AccountsApi.md#update_bluesky_settings) | **PATCH** /v1/accounts/{accountId}/bluesky-settings | Update Bluesky account settings
109
110
  *Zernio::AccountsApi* | [**update_slack_settings**](docs/AccountsApi.md#update_slack_settings) | **PATCH** /v1/accounts/{accountId}/slack-settings | Update Slack account settings
@@ -2251,6 +2252,8 @@ Class | Method | HTTP request | Description
2251
2252
  - [Zernio::SearchInboxConversations200ResponseMetaFailedAccountsInner](docs/SearchInboxConversations200ResponseMetaFailedAccountsInner.md)
2252
2253
  - [Zernio::SearchInstagramAudio200Response](docs/SearchInstagramAudio200Response.md)
2253
2254
  - [Zernio::SearchReddit200Response](docs/SearchReddit200Response.md)
2255
+ - [Zernio::SearchTikTokLocations200Response](docs/SearchTikTokLocations200Response.md)
2256
+ - [Zernio::SearchTikTokLocations200ResponseLocationsInner](docs/SearchTikTokLocations200ResponseLocationsInner.md)
2254
2257
  - [Zernio::SearchTweets200Response](docs/SearchTweets200Response.md)
2255
2258
  - [Zernio::SearchTweets200ResponseMeta](docs/SearchTweets200ResponseMeta.md)
2256
2259
  - [Zernio::SearchTweets200ResponsePagination](docs/SearchTweets200ResponsePagination.md)
data/docs/AccountsApi.md CHANGED
@@ -16,6 +16,7 @@ All URIs are relative to *https://zernio.com/api*
16
16
  | [**list_accounts**](AccountsApi.md#list_accounts) | **GET** /v1/accounts | List accounts |
17
17
  | [**list_tik_tok_commercial_music**](AccountsApi.md#list_tik_tok_commercial_music) | **GET** /v1/accounts/{accountId}/tiktok/commercial-music | List trending commercial music |
18
18
  | [**move_account_to_profile**](AccountsApi.md#move_account_to_profile) | **PATCH** /v1/accounts/{accountId} | Move account to another profile |
19
+ | [**search_tik_tok_locations**](AccountsApi.md#search_tik_tok_locations) | **GET** /v1/accounts/{accountId}/tiktok/locations | Search TikTok location tags |
19
20
  | [**update_account**](AccountsApi.md#update_account) | **PUT** /v1/accounts/{accountId} | Update account |
20
21
  | [**update_bluesky_settings**](AccountsApi.md#update_bluesky_settings) | **PATCH** /v1/accounts/{accountId}/bluesky-settings | Update Bluesky account settings |
21
22
  | [**update_slack_settings**](AccountsApi.md#update_slack_settings) | **PATCH** /v1/accounts/{accountId}/slack-settings | Update Slack account settings |
@@ -893,6 +894,77 @@ end
893
894
  - **Accept**: application/json
894
895
 
895
896
 
897
+ ## search_tik_tok_locations
898
+
899
+ > <SearchTikTokLocations200Response> search_tik_tok_locations(account_id, query)
900
+
901
+ Search TikTok location tags
902
+
903
+ Searches the location tags a TikTok account connected through the TikTok for Business app can attach to a video post. Send a result's id and name as tiktokSettings.locationId and locationName when creating a post. TikTok answers the 20 closest matches and fills the list with fuzzy matches when nothing matches, so an unrelated result does not mean the place is missing.
904
+
905
+ ### Examples
906
+
907
+ ```ruby
908
+ require 'time'
909
+ require 'zernio-sdk'
910
+ # setup authorization
911
+ Zernio.configure do |config|
912
+ # Configure Bearer authorization (JWT): bearerAuth
913
+ config.access_token = 'YOUR_BEARER_TOKEN'
914
+ end
915
+
916
+ api_instance = Zernio::AccountsApi.new
917
+ account_id = 'account_id_example' # String | The TikTok account ID
918
+ query = 'query_example' # String | Place name to search, for example a city, a venue or an address
919
+
920
+ begin
921
+ # Search TikTok location tags
922
+ result = api_instance.search_tik_tok_locations(account_id, query)
923
+ p result
924
+ rescue Zernio::ApiError => e
925
+ puts "Error when calling AccountsApi->search_tik_tok_locations: #{e}"
926
+ end
927
+ ```
928
+
929
+ #### Using the search_tik_tok_locations_with_http_info variant
930
+
931
+ This returns an Array which contains the response data, status code and headers.
932
+
933
+ > <Array(<SearchTikTokLocations200Response>, Integer, Hash)> search_tik_tok_locations_with_http_info(account_id, query)
934
+
935
+ ```ruby
936
+ begin
937
+ # Search TikTok location tags
938
+ data, status_code, headers = api_instance.search_tik_tok_locations_with_http_info(account_id, query)
939
+ p status_code # => 2xx
940
+ p headers # => { ... }
941
+ p data # => <SearchTikTokLocations200Response>
942
+ rescue Zernio::ApiError => e
943
+ puts "Error when calling AccountsApi->search_tik_tok_locations_with_http_info: #{e}"
944
+ end
945
+ ```
946
+
947
+ ### Parameters
948
+
949
+ | Name | Type | Description | Notes |
950
+ | ---- | ---- | ----------- | ----- |
951
+ | **account_id** | **String** | The TikTok account ID | |
952
+ | **query** | **String** | Place name to search, for example a city, a venue or an address | |
953
+
954
+ ### Return type
955
+
956
+ [**SearchTikTokLocations200Response**](SearchTikTokLocations200Response.md)
957
+
958
+ ### Authorization
959
+
960
+ [bearerAuth](../README.md#bearerAuth)
961
+
962
+ ### HTTP request headers
963
+
964
+ - **Content-Type**: Not defined
965
+ - **Accept**: application/json
966
+
967
+
896
968
  ## update_account
897
969
 
898
970
  > <UpdateAccount200Response> update_account(account_id, update_account_request)
@@ -0,0 +1,18 @@
1
+ # Zernio::SearchTikTokLocations200Response
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **locations** | [**Array&lt;SearchTikTokLocations200ResponseLocationsInner&gt;**](SearchTikTokLocations200ResponseLocationsInner.md) | | [optional] |
8
+
9
+ ## Example
10
+
11
+ ```ruby
12
+ require 'zernio-sdk'
13
+
14
+ instance = Zernio::SearchTikTokLocations200Response.new(
15
+ locations: null
16
+ )
17
+ ```
18
+
@@ -0,0 +1,22 @@
1
+ # Zernio::SearchTikTokLocations200ResponseLocationsInner
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **id** | **String** | The value to send as locationId | [optional] |
8
+ | **name** | **String** | The value to send as locationName | [optional] |
9
+ | **address** | **String** | Address or region TikTok shows for the place, for disambiguation | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'zernio-sdk'
15
+
16
+ instance = Zernio::SearchTikTokLocations200ResponseLocationsInner.new(
17
+ id: null,
18
+ name: null,
19
+ address: null
20
+ )
21
+ ```
22
+
@@ -22,6 +22,9 @@
22
22
  | **music_sound_info** | [**TikTokPlatformDataMusicSoundInfo**](TikTokPlatformDataMusicSoundInfo.md) | | [optional] |
23
23
  | **video_original_sound_volume** | **Integer** | Volume of the video&#39;s own sound when a commercial track is attached (0 to 100). Requires musicSoundInfo. Video posts only. | [optional] |
24
24
  | **video_made_with_ai** | **Boolean** | Set true to disclose AI-generated content. Accounts connected through the TikTok for Business app carry the disclosure on video posts only: the business photo endpoint has no AI disclosure field, so true on a direct photo post is rejected at creation rather than published undisclosed. Send draft true to publish such a photo post and set the disclosure in the TikTok app. | [optional] |
25
+ | **location_id** | **String** | Location tag to attach, as the id of a result from GET /v1/accounts/{accountId}/tiktok/locations. Accounts connected through the TikTok for Business app and video posts only: a developer-app account rejects the post at publish time with a message that says so, and a direct photo post is rejected at creation since the business photo endpoint has no location field. Requires locationName. Ignored on drafts, where TikTok ignores every post_info field. | [optional] |
26
+ | **location_name** | **String** | Display name of the location tag, as returned next to its id. Required with locationId; a locationId without it is rejected at creation. | [optional] |
27
+ | **is_ads_only** | **Boolean** | Set true to publish the video as an \&quot;Only show in ads\&quot; post: it is kept off the profile and exists to be used as a Spark Ad. Accounts connected through the TikTok for Business app and video posts only, with the same rejections as locationId. Ignored on drafts. | [optional] |
25
28
  | **description** | **String** | Optional long-form caption for photo posts (max 4000 chars). Recommended when content exceeds 90 chars, as photo titles are auto-truncated. Falls back to the post content when omitted. | [optional] |
26
29
 
27
30
  ## Example
@@ -48,6 +51,9 @@ instance = Zernio::TikTokPlatformData.new(
48
51
  music_sound_info: null,
49
52
  video_original_sound_volume: null,
50
53
  video_made_with_ai: null,
54
+ location_id: null,
55
+ location_name: null,
56
+ is_ads_only: null,
51
57
  description: null
52
58
  )
53
59
  ```
@@ -865,6 +865,84 @@ module Zernio
865
865
  return data, status_code, headers
866
866
  end
867
867
 
868
+ # Search TikTok location tags
869
+ # Searches the location tags a TikTok account connected through the TikTok for Business app can attach to a video post. Send a result's id and name as tiktokSettings.locationId and locationName when creating a post. TikTok answers the 20 closest matches and fills the list with fuzzy matches when nothing matches, so an unrelated result does not mean the place is missing.
870
+ # @param account_id [String] The TikTok account ID
871
+ # @param query [String] Place name to search, for example a city, a venue or an address
872
+ # @param [Hash] opts the optional parameters
873
+ # @return [SearchTikTokLocations200Response]
874
+ def search_tik_tok_locations(account_id, query, opts = {})
875
+ data, _status_code, _headers = search_tik_tok_locations_with_http_info(account_id, query, opts)
876
+ data
877
+ end
878
+
879
+ # Search TikTok location tags
880
+ # Searches the location tags a TikTok account connected through the TikTok for Business app can attach to a video post. Send a result&#39;s id and name as tiktokSettings.locationId and locationName when creating a post. TikTok answers the 20 closest matches and fills the list with fuzzy matches when nothing matches, so an unrelated result does not mean the place is missing.
881
+ # @param account_id [String] The TikTok account ID
882
+ # @param query [String] Place name to search, for example a city, a venue or an address
883
+ # @param [Hash] opts the optional parameters
884
+ # @return [Array<(SearchTikTokLocations200Response, Integer, Hash)>] SearchTikTokLocations200Response data, response status code and response headers
885
+ def search_tik_tok_locations_with_http_info(account_id, query, opts = {})
886
+ if @api_client.config.debugging
887
+ @api_client.config.logger.debug 'Calling API: AccountsApi.search_tik_tok_locations ...'
888
+ end
889
+ # verify the required parameter 'account_id' is set
890
+ if @api_client.config.client_side_validation && account_id.nil?
891
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling AccountsApi.search_tik_tok_locations"
892
+ end
893
+ # verify the required parameter 'query' is set
894
+ if @api_client.config.client_side_validation && query.nil?
895
+ fail ArgumentError, "Missing the required parameter 'query' when calling AccountsApi.search_tik_tok_locations"
896
+ end
897
+ if @api_client.config.client_side_validation && query.to_s.length > 100
898
+ fail ArgumentError, 'invalid value for "query" when calling AccountsApi.search_tik_tok_locations, the character length must be smaller than or equal to 100.'
899
+ end
900
+
901
+ if @api_client.config.client_side_validation && query.to_s.length < 1
902
+ fail ArgumentError, 'invalid value for "query" when calling AccountsApi.search_tik_tok_locations, the character length must be greater than or equal to 1.'
903
+ end
904
+
905
+ # resource path
906
+ local_var_path = '/v1/accounts/{accountId}/tiktok/locations'.sub('{' + 'accountId' + '}', CGI.escape(account_id.to_s))
907
+
908
+ # query parameters
909
+ query_params = opts[:query_params] || {}
910
+ query_params[:'query'] = query
911
+
912
+ # header parameters
913
+ header_params = opts[:header_params] || {}
914
+ # HTTP header 'Accept' (if needed)
915
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
916
+
917
+ # form parameters
918
+ form_params = opts[:form_params] || {}
919
+
920
+ # http body (model)
921
+ post_body = opts[:debug_body]
922
+
923
+ # return_type
924
+ return_type = opts[:debug_return_type] || 'SearchTikTokLocations200Response'
925
+
926
+ # auth_names
927
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
928
+
929
+ new_options = opts.merge(
930
+ :operation => :"AccountsApi.search_tik_tok_locations",
931
+ :header_params => header_params,
932
+ :query_params => query_params,
933
+ :form_params => form_params,
934
+ :body => post_body,
935
+ :auth_names => auth_names,
936
+ :return_type => return_type
937
+ )
938
+
939
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
940
+ if @api_client.config.debugging
941
+ @api_client.config.logger.debug "API called: AccountsApi#search_tik_tok_locations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
942
+ end
943
+ return data, status_code, headers
944
+ end
945
+
868
946
  # Update account
869
947
  # Updates a connected account's display name or username override. For X accounts on usage-based billing, also accepts an `xCapabilities` object to toggle background API operations that incur X API pass-through costs. Both fields are opt-in (default `false`). When off, no analytics syncs or DM polling are performed for that account, and no API call is metered for those operations. Publishing and deleting posts are always available regardless of these toggles. Setting `xCapabilities` on a non-X account returns 400.
870
948
  # @param account_id [String]
@@ -0,0 +1,149 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
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 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ class SearchTikTokLocations200Response < ApiModelBase
18
+ attr_accessor :locations
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'locations' => :'locations'
24
+ }
25
+ end
26
+
27
+ # Returns attribute mapping this model knows about
28
+ def self.acceptable_attribute_map
29
+ attribute_map
30
+ end
31
+
32
+ # Returns all the JSON keys this model knows about
33
+ def self.acceptable_attributes
34
+ acceptable_attribute_map.values
35
+ end
36
+
37
+ # Attribute type mapping.
38
+ def self.openapi_types
39
+ {
40
+ :'locations' => :'Array<SearchTikTokLocations200ResponseLocationsInner>'
41
+ }
42
+ end
43
+
44
+ # List of attributes with nullable: true
45
+ def self.openapi_nullable
46
+ Set.new([
47
+ ])
48
+ end
49
+
50
+ # Initializes the object
51
+ # @param [Hash] attributes Model attributes in the form of hash
52
+ def initialize(attributes = {})
53
+ if (!attributes.is_a?(Hash))
54
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::SearchTikTokLocations200Response` initialize method"
55
+ end
56
+
57
+ # check to see if the attribute exists and convert string to symbol for hash key
58
+ acceptable_attribute_map = self.class.acceptable_attribute_map
59
+ attributes = attributes.each_with_object({}) { |(k, v), h|
60
+ if (!acceptable_attribute_map.key?(k.to_sym))
61
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::SearchTikTokLocations200Response`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
62
+ end
63
+ h[k.to_sym] = v
64
+ }
65
+
66
+ if attributes.key?(:'locations')
67
+ if (value = attributes[:'locations']).is_a?(Array)
68
+ self.locations = value
69
+ end
70
+ end
71
+ end
72
+
73
+ # Show invalid properties with the reasons. Usually used together with valid?
74
+ # @return Array for valid properties with the reasons
75
+ def list_invalid_properties
76
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
77
+ invalid_properties = Array.new
78
+ invalid_properties
79
+ end
80
+
81
+ # Check to see if the all the properties in the model are valid
82
+ # @return true if the model is valid
83
+ def valid?
84
+ warn '[DEPRECATED] the `valid?` method is obsolete'
85
+ true
86
+ end
87
+
88
+ # Checks equality by comparing each attribute.
89
+ # @param [Object] Object to be compared
90
+ def ==(o)
91
+ return true if self.equal?(o)
92
+ self.class == o.class &&
93
+ locations == o.locations
94
+ end
95
+
96
+ # @see the `==` method
97
+ # @param [Object] Object to be compared
98
+ def eql?(o)
99
+ self == o
100
+ end
101
+
102
+ # Calculates hash code according to all attributes.
103
+ # @return [Integer] Hash code
104
+ def hash
105
+ [locations].hash
106
+ end
107
+
108
+ # Builds the object from hash
109
+ # @param [Hash] attributes Model attributes in the form of hash
110
+ # @return [Object] Returns the model itself
111
+ def self.build_from_hash(attributes)
112
+ return nil unless attributes.is_a?(Hash)
113
+ attributes = attributes.transform_keys(&:to_sym)
114
+ transformed_hash = {}
115
+ openapi_types.each_pair do |key, type|
116
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
117
+ transformed_hash["#{key}"] = nil
118
+ elsif type =~ /\AArray<(.*)>/i
119
+ # check to ensure the input is an array given that the attribute
120
+ # is documented as an array but the input is not
121
+ if attributes[attribute_map[key]].is_a?(Array)
122
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
123
+ end
124
+ elsif !attributes[attribute_map[key]].nil?
125
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
126
+ end
127
+ end
128
+ new(transformed_hash)
129
+ end
130
+
131
+ # Returns the object in the form of hash
132
+ # @return [Hash] Returns the object in the form of hash
133
+ def to_hash
134
+ hash = {}
135
+ self.class.attribute_map.each_pair do |attr, param|
136
+ value = self.send(attr)
137
+ if value.nil?
138
+ is_nullable = self.class.openapi_nullable.include?(attr)
139
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
140
+ end
141
+
142
+ hash[param] = _to_hash(value)
143
+ end
144
+ hash
145
+ end
146
+
147
+ end
148
+
149
+ end
@@ -0,0 +1,168 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
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 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ class SearchTikTokLocations200ResponseLocationsInner < ApiModelBase
18
+ # The value to send as locationId
19
+ attr_accessor :id
20
+
21
+ # The value to send as locationName
22
+ attr_accessor :name
23
+
24
+ # Address or region TikTok shows for the place, for disambiguation
25
+ attr_accessor :address
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ def self.attribute_map
29
+ {
30
+ :'id' => :'id',
31
+ :'name' => :'name',
32
+ :'address' => :'address'
33
+ }
34
+ end
35
+
36
+ # Returns attribute mapping this model knows about
37
+ def self.acceptable_attribute_map
38
+ attribute_map
39
+ end
40
+
41
+ # Returns all the JSON keys this model knows about
42
+ def self.acceptable_attributes
43
+ acceptable_attribute_map.values
44
+ end
45
+
46
+ # Attribute type mapping.
47
+ def self.openapi_types
48
+ {
49
+ :'id' => :'String',
50
+ :'name' => :'String',
51
+ :'address' => :'String'
52
+ }
53
+ end
54
+
55
+ # List of attributes with nullable: true
56
+ def self.openapi_nullable
57
+ Set.new([
58
+ ])
59
+ end
60
+
61
+ # Initializes the object
62
+ # @param [Hash] attributes Model attributes in the form of hash
63
+ def initialize(attributes = {})
64
+ if (!attributes.is_a?(Hash))
65
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::SearchTikTokLocations200ResponseLocationsInner` initialize method"
66
+ end
67
+
68
+ # check to see if the attribute exists and convert string to symbol for hash key
69
+ acceptable_attribute_map = self.class.acceptable_attribute_map
70
+ attributes = attributes.each_with_object({}) { |(k, v), h|
71
+ if (!acceptable_attribute_map.key?(k.to_sym))
72
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::SearchTikTokLocations200ResponseLocationsInner`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
73
+ end
74
+ h[k.to_sym] = v
75
+ }
76
+
77
+ if attributes.key?(:'id')
78
+ self.id = attributes[:'id']
79
+ end
80
+
81
+ if attributes.key?(:'name')
82
+ self.name = attributes[:'name']
83
+ end
84
+
85
+ if attributes.key?(:'address')
86
+ self.address = attributes[:'address']
87
+ end
88
+ end
89
+
90
+ # Show invalid properties with the reasons. Usually used together with valid?
91
+ # @return Array for valid properties with the reasons
92
+ def list_invalid_properties
93
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
94
+ invalid_properties = Array.new
95
+ invalid_properties
96
+ end
97
+
98
+ # Check to see if the all the properties in the model are valid
99
+ # @return true if the model is valid
100
+ def valid?
101
+ warn '[DEPRECATED] the `valid?` method is obsolete'
102
+ true
103
+ end
104
+
105
+ # Checks equality by comparing each attribute.
106
+ # @param [Object] Object to be compared
107
+ def ==(o)
108
+ return true if self.equal?(o)
109
+ self.class == o.class &&
110
+ id == o.id &&
111
+ name == o.name &&
112
+ address == o.address
113
+ end
114
+
115
+ # @see the `==` method
116
+ # @param [Object] Object to be compared
117
+ def eql?(o)
118
+ self == o
119
+ end
120
+
121
+ # Calculates hash code according to all attributes.
122
+ # @return [Integer] Hash code
123
+ def hash
124
+ [id, name, address].hash
125
+ end
126
+
127
+ # Builds the object from hash
128
+ # @param [Hash] attributes Model attributes in the form of hash
129
+ # @return [Object] Returns the model itself
130
+ def self.build_from_hash(attributes)
131
+ return nil unless attributes.is_a?(Hash)
132
+ attributes = attributes.transform_keys(&:to_sym)
133
+ transformed_hash = {}
134
+ openapi_types.each_pair do |key, type|
135
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
136
+ transformed_hash["#{key}"] = nil
137
+ elsif type =~ /\AArray<(.*)>/i
138
+ # check to ensure the input is an array given that the attribute
139
+ # is documented as an array but the input is not
140
+ if attributes[attribute_map[key]].is_a?(Array)
141
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
142
+ end
143
+ elsif !attributes[attribute_map[key]].nil?
144
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
145
+ end
146
+ end
147
+ new(transformed_hash)
148
+ end
149
+
150
+ # Returns the object in the form of hash
151
+ # @return [Hash] Returns the object in the form of hash
152
+ def to_hash
153
+ hash = {}
154
+ self.class.attribute_map.each_pair do |attr, param|
155
+ value = self.send(attr)
156
+ if value.nil?
157
+ is_nullable = self.class.openapi_nullable.include?(attr)
158
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
159
+ end
160
+
161
+ hash[param] = _to_hash(value)
162
+ end
163
+ hash
164
+ end
165
+
166
+ end
167
+
168
+ end
@@ -69,6 +69,15 @@ module Zernio
69
69
  # Set true to disclose AI-generated content. Accounts connected through the TikTok for Business app carry the disclosure on video posts only: the business photo endpoint has no AI disclosure field, so true on a direct photo post is rejected at creation rather than published undisclosed. Send draft true to publish such a photo post and set the disclosure in the TikTok app.
70
70
  attr_accessor :video_made_with_ai
71
71
 
72
+ # Location tag to attach, as the id of a result from GET /v1/accounts/{accountId}/tiktok/locations. Accounts connected through the TikTok for Business app and video posts only: a developer-app account rejects the post at publish time with a message that says so, and a direct photo post is rejected at creation since the business photo endpoint has no location field. Requires locationName. Ignored on drafts, where TikTok ignores every post_info field.
73
+ attr_accessor :location_id
74
+
75
+ # Display name of the location tag, as returned next to its id. Required with locationId; a locationId without it is rejected at creation.
76
+ attr_accessor :location_name
77
+
78
+ # Set true to publish the video as an \"Only show in ads\" post: it is kept off the profile and exists to be used as a Spark Ad. Accounts connected through the TikTok for Business app and video posts only, with the same rejections as locationId. Ignored on drafts.
79
+ attr_accessor :is_ads_only
80
+
72
81
  # Optional long-form caption for photo posts (max 4000 chars). Recommended when content exceeds 90 chars, as photo titles are auto-truncated. Falls back to the post content when omitted.
73
82
  attr_accessor :description
74
83
 
@@ -115,6 +124,9 @@ module Zernio
115
124
  :'music_sound_info' => :'musicSoundInfo',
116
125
  :'video_original_sound_volume' => :'videoOriginalSoundVolume',
117
126
  :'video_made_with_ai' => :'videoMadeWithAi',
127
+ :'location_id' => :'locationId',
128
+ :'location_name' => :'locationName',
129
+ :'is_ads_only' => :'isAdsOnly',
118
130
  :'description' => :'description'
119
131
  }
120
132
  end
@@ -150,6 +162,9 @@ module Zernio
150
162
  :'music_sound_info' => :'TikTokPlatformDataMusicSoundInfo',
151
163
  :'video_original_sound_volume' => :'Integer',
152
164
  :'video_made_with_ai' => :'Boolean',
165
+ :'location_id' => :'String',
166
+ :'location_name' => :'String',
167
+ :'is_ads_only' => :'Boolean',
153
168
  :'description' => :'String'
154
169
  }
155
170
  end
@@ -248,6 +263,18 @@ module Zernio
248
263
  self.video_made_with_ai = attributes[:'video_made_with_ai']
249
264
  end
250
265
 
266
+ if attributes.key?(:'location_id')
267
+ self.location_id = attributes[:'location_id']
268
+ end
269
+
270
+ if attributes.key?(:'location_name')
271
+ self.location_name = attributes[:'location_name']
272
+ end
273
+
274
+ if attributes.key?(:'is_ads_only')
275
+ self.is_ads_only = attributes[:'is_ads_only']
276
+ end
277
+
251
278
  if attributes.key?(:'description')
252
279
  self.description = attributes[:'description']
253
280
  end
@@ -400,6 +427,9 @@ module Zernio
400
427
  music_sound_info == o.music_sound_info &&
401
428
  video_original_sound_volume == o.video_original_sound_volume &&
402
429
  video_made_with_ai == o.video_made_with_ai &&
430
+ location_id == o.location_id &&
431
+ location_name == o.location_name &&
432
+ is_ads_only == o.is_ads_only &&
403
433
  description == o.description
404
434
  end
405
435
 
@@ -412,7 +442,7 @@ module Zernio
412
442
  # Calculates hash code according to all attributes.
413
443
  # @return [Integer] Hash code
414
444
  def hash
415
- [draft, privacy_level, allow_comment, allow_duet, allow_stitch, commercial_content_type, brand_partner_promote, is_brand_organic_post, content_preview_confirmed, express_consent_given, media_type, video_cover_timestamp_ms, video_cover_image_url, photo_cover_index, auto_add_music, music_sound_info, video_original_sound_volume, video_made_with_ai, description].hash
445
+ [draft, privacy_level, allow_comment, allow_duet, allow_stitch, commercial_content_type, brand_partner_promote, is_brand_organic_post, content_preview_confirmed, express_consent_given, media_type, video_cover_timestamp_ms, video_cover_image_url, photo_cover_index, auto_add_music, music_sound_info, video_original_sound_volume, video_made_with_ai, location_id, location_name, is_ads_only, description].hash
416
446
  end
417
447
 
418
448
  # Builds the object from hash
@@ -11,5 +11,5 @@ Generator version: 7.19.0
11
11
  =end
12
12
 
13
13
  module Zernio
14
- VERSION = '0.0.954'
14
+ VERSION = '0.0.955'
15
15
  end
data/lib/zernio-sdk.rb CHANGED
@@ -1463,6 +1463,8 @@ require 'zernio-sdk/models/search_inbox_conversations200_response_meta'
1463
1463
  require 'zernio-sdk/models/search_inbox_conversations200_response_meta_failed_accounts_inner'
1464
1464
  require 'zernio-sdk/models/search_instagram_audio200_response'
1465
1465
  require 'zernio-sdk/models/search_reddit200_response'
1466
+ require 'zernio-sdk/models/search_tik_tok_locations200_response'
1467
+ require 'zernio-sdk/models/search_tik_tok_locations200_response_locations_inner'
1466
1468
  require 'zernio-sdk/models/search_tweets200_response'
1467
1469
  require 'zernio-sdk/models/search_tweets200_response_meta'
1468
1470
  require 'zernio-sdk/models/search_tweets200_response_pagination'
data/openapi.yaml CHANGED
@@ -6993,6 +6993,15 @@ components:
6993
6993
  videoMadeWithAi:
6994
6994
  type: boolean
6995
6995
  description: 'Set true to disclose AI-generated content. Accounts connected through the TikTok for Business app carry the disclosure on video posts only: the business photo endpoint has no AI disclosure field, so true on a direct photo post is rejected at creation rather than published undisclosed. Send draft true to publish such a photo post and set the disclosure in the TikTok app.'
6996
+ locationId:
6997
+ type: string
6998
+ description: 'Location tag to attach, as the id of a result from GET /v1/accounts/{accountId}/tiktok/locations. Accounts connected through the TikTok for Business app and video posts only: a developer-app account rejects the post at publish time with a message that says so, and a direct photo post is rejected at creation since the business photo endpoint has no location field. Requires locationName. Ignored on drafts, where TikTok ignores every post_info field.'
6999
+ locationName:
7000
+ type: string
7001
+ description: 'Display name of the location tag, as returned next to its id. Required with locationId; a locationId without it is rejected at creation.'
7002
+ isAdsOnly:
7003
+ type: boolean
7004
+ description: 'Set true to publish the video as an "Only show in ads" post: it is kept off the profile and exists to be used as a Spark Ad. Accounts connected through the TikTok for Business app and video posts only, with the same rejections as locationId. Ignored on drafts.'
6996
7005
  description:
6997
7006
  type: string
6998
7007
  maxLength: 4000
@@ -19230,6 +19239,45 @@ paths:
19230
19239
  '404':
19231
19240
  description: Account not found
19232
19241
 
19242
+ /v1/accounts/{accountId}/tiktok/locations:
19243
+ get:
19244
+ x-resource-group: "accounts"
19245
+ operationId: searchTikTokLocations
19246
+ tags: [Accounts]
19247
+ summary: Search TikTok location tags
19248
+ description: 'Searches the location tags a TikTok account connected through the TikTok for Business app can attach to a video post. Send a result''s id and name as tiktokSettings.locationId and locationName when creating a post. TikTok answers the 20 closest matches and fills the list with fuzzy matches when nothing matches, so an unrelated result does not mean the place is missing.'
19249
+ parameters:
19250
+ - name: accountId
19251
+ in: path
19252
+ required: true
19253
+ schema: { type: string }
19254
+ description: The TikTok account ID
19255
+ - name: query
19256
+ in: query
19257
+ required: true
19258
+ schema: { type: string, minLength: 1, maxLength: 100 }
19259
+ description: 'Place name to search, for example a city, a venue or an address'
19260
+ responses:
19261
+ '200':
19262
+ description: The closest location tags, best match first
19263
+ content:
19264
+ application/json:
19265
+ schema:
19266
+ type: object
19267
+ properties:
19268
+ locations:
19269
+ type: array
19270
+ items:
19271
+ type: object
19272
+ properties:
19273
+ id: { type: string, description: 'The value to send as locationId' }
19274
+ name: { type: string, description: 'The value to send as locationName' }
19275
+ address: { type: string, description: 'Address or region TikTok shows for the place, for disambiguation' }
19276
+ '400':
19277
+ $ref: '#/components/responses/BadRequest'
19278
+ '404':
19279
+ description: Account not found
19280
+
19233
19281
  /v1/accounts/{accountId}/tiktok/creator-info:
19234
19282
  get:
19235
19283
  x-resource-group: "accounts"
@@ -192,6 +192,19 @@ describe 'AccountsApi' do
192
192
  end
193
193
  end
194
194
 
195
+ # unit tests for search_tik_tok_locations
196
+ # Search TikTok location tags
197
+ # Searches the location tags a TikTok account connected through the TikTok for Business app can attach to a video post. Send a result&#39;s id and name as tiktokSettings.locationId and locationName when creating a post. TikTok answers the 20 closest matches and fills the list with fuzzy matches when nothing matches, so an unrelated result does not mean the place is missing.
198
+ # @param account_id The TikTok account ID
199
+ # @param query Place name to search, for example a city, a venue or an address
200
+ # @param [Hash] opts the optional parameters
201
+ # @return [SearchTikTokLocations200Response]
202
+ describe 'search_tik_tok_locations test' do
203
+ it 'should work' do
204
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
205
+ end
206
+ end
207
+
195
208
  # unit tests for update_account
196
209
  # Update account
197
210
  # Updates a connected account&#39;s display name or username override. For X accounts on usage-based billing, also accepts an &#x60;xCapabilities&#x60; object to toggle background API operations that incur X API pass-through costs. Both fields are opt-in (default &#x60;false&#x60;). When off, no analytics syncs or DM polling are performed for that account, and no API call is metered for those operations. Publishing and deleting posts are always available regardless of these toggles. Setting &#x60;xCapabilities&#x60; on a non-X account returns 400.
@@ -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 Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
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::SearchTikTokLocations200ResponseLocationsInner
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::SearchTikTokLocations200ResponseLocationsInner do
21
+ #let(:instance) { Zernio::SearchTikTokLocations200ResponseLocationsInner.new }
22
+
23
+ describe 'test an instance of SearchTikTokLocations200ResponseLocationsInner' do
24
+ it 'should create an instance of SearchTikTokLocations200ResponseLocationsInner' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::SearchTikTokLocations200ResponseLocationsInner)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "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 "name"' 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 "address"' 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,36 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
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::SearchTikTokLocations200Response
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::SearchTikTokLocations200Response do
21
+ #let(:instance) { Zernio::SearchTikTokLocations200Response.new }
22
+
23
+ describe 'test an instance of SearchTikTokLocations200Response' do
24
+ it 'should create an instance of SearchTikTokLocations200Response' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::SearchTikTokLocations200Response)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "locations"' 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
@@ -143,6 +143,24 @@ describe Zernio::TikTokPlatformData do
143
143
  end
144
144
  end
145
145
 
146
+ describe 'test attribute "location_id"' do
147
+ it 'should work' do
148
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
149
+ end
150
+ end
151
+
152
+ describe 'test attribute "location_name"' do
153
+ it 'should work' do
154
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
155
+ end
156
+ end
157
+
158
+ describe 'test attribute "is_ads_only"' do
159
+ it 'should work' do
160
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
161
+ end
162
+ end
163
+
146
164
  describe 'test attribute "description"' do
147
165
  it 'should work' do
148
166
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: late-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.954
4
+ version: 0.0.955
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
@@ -1563,6 +1563,8 @@ files:
1563
1563
  - docs/SearchInboxConversations200ResponseMetaFailedAccountsInner.md
1564
1564
  - docs/SearchInstagramAudio200Response.md
1565
1565
  - docs/SearchReddit200Response.md
1566
+ - docs/SearchTikTokLocations200Response.md
1567
+ - docs/SearchTikTokLocations200ResponseLocationsInner.md
1566
1568
  - docs/SearchTweets200Response.md
1567
1569
  - docs/SearchTweets200ResponseMeta.md
1568
1570
  - docs/SearchTweets200ResponsePagination.md
@@ -3722,6 +3724,8 @@ files:
3722
3724
  - lib/zernio-sdk/models/search_inbox_conversations200_response_meta_failed_accounts_inner.rb
3723
3725
  - lib/zernio-sdk/models/search_instagram_audio200_response.rb
3724
3726
  - lib/zernio-sdk/models/search_reddit200_response.rb
3727
+ - lib/zernio-sdk/models/search_tik_tok_locations200_response.rb
3728
+ - lib/zernio-sdk/models/search_tik_tok_locations200_response_locations_inner.rb
3725
3729
  - lib/zernio-sdk/models/search_tweets200_response.rb
3726
3730
  - lib/zernio-sdk/models/search_tweets200_response_meta.rb
3727
3731
  - lib/zernio-sdk/models/search_tweets200_response_pagination.rb
@@ -5856,6 +5860,8 @@ files:
5856
5860
  - spec/models/search_inbox_conversations200_response_spec.rb
5857
5861
  - spec/models/search_instagram_audio200_response_spec.rb
5858
5862
  - spec/models/search_reddit200_response_spec.rb
5863
+ - spec/models/search_tik_tok_locations200_response_locations_inner_spec.rb
5864
+ - spec/models/search_tik_tok_locations200_response_spec.rb
5859
5865
  - spec/models/search_tweets200_response_meta_spec.rb
5860
5866
  - spec/models/search_tweets200_response_pagination_spec.rb
5861
5867
  - spec/models/search_tweets200_response_spec.rb
@@ -6475,7 +6481,7 @@ files:
6475
6481
  - spec/models/you_tube_video_retention_response_retention_curve_inner_spec.rb
6476
6482
  - spec/models/you_tube_video_retention_response_spec.rb
6477
6483
  - spec/spec_helper.rb
6478
- - zernio-sdk-0.0.954.gem
6484
+ - zernio-sdk-0.0.955.gem
6479
6485
  - zernio-sdk.gemspec
6480
6486
  homepage: https://openapi-generator.tech
6481
6487
  licenses:
@@ -7462,6 +7468,7 @@ test_files:
7462
7468
  - spec/models/restore_workflow_version200_response_spec.rb
7463
7469
  - spec/models/list_phone_numbers200_response_sandbox_template_spec.rb
7464
7470
  - spec/models/get_conversions_quality200_response_rows_inner_match_keys_inner_spec.rb
7471
+ - spec/models/search_tik_tok_locations200_response_spec.rb
7465
7472
  - spec/models/ad_daily_metrics_spec.rb
7466
7473
  - spec/models/edit_inbox_comment200_response_spec.rb
7467
7474
  - spec/models/validate_subreddit200_response_spec.rb
@@ -7885,6 +7892,7 @@ test_files:
7885
7892
  - spec/models/send_conversions_request_spec.rb
7886
7893
  - spec/models/webhook_payload_account_ads_initial_sync_completed_spec.rb
7887
7894
  - spec/models/assign_google_business_location200_response_account_spec.rb
7895
+ - spec/models/search_tik_tok_locations200_response_locations_inner_spec.rb
7888
7896
  - spec/models/create_invite_token201_response_spec.rb
7889
7897
  - spec/models/list_value_rule_sets200_response_paging_spec.rb
7890
7898
  - spec/models/update_whats_app_template_request_spec.rb
Binary file