late-sdk 0.0.656 → 0.0.658
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/README.md +3 -0
- data/docs/AdCampaignsApi.md +2 -2
- data/docs/AdDailyMetrics.md +1 -1
- data/docs/AdMetrics.md +1 -1
- data/docs/DiscordApi.md +3 -3
- data/docs/GetCampaignAnalytics200ResponseAnalyticsDailyInner.md +1 -1
- data/docs/GetTweet200Response.md +20 -0
- data/docs/GetTweet200ResponseTweet.md +40 -0
- data/docs/TwitterEngagementApi.md +72 -0
- data/lib/zernio-sdk/api/ad_campaigns_api.rb +2 -2
- data/lib/zernio-sdk/api/discord_api.rb +6 -6
- data/lib/zernio-sdk/api/twitter_engagement_api.rb +71 -0
- data/lib/zernio-sdk/models/ad_daily_metrics.rb +2 -2
- data/lib/zernio-sdk/models/ad_metrics.rb +1 -1
- data/lib/zernio-sdk/models/get_campaign_analytics200_response_analytics_daily_inner.rb +1 -1
- data/lib/zernio-sdk/models/get_tweet200_response.rb +156 -0
- data/lib/zernio-sdk/models/get_tweet200_response_tweet.rb +248 -0
- data/lib/zernio-sdk/version.rb +1 -1
- data/lib/zernio-sdk.rb +2 -0
- data/openapi.yaml +74 -16
- data/spec/api/ad_campaigns_api_spec.rb +1 -1
- data/spec/api/discord_api_spec.rb +3 -3
- data/spec/api/twitter_engagement_api_spec.rb +13 -0
- data/spec/models/get_tweet200_response_spec.rb +42 -0
- data/spec/models/get_tweet200_response_tweet_spec.rb +102 -0
- data/zernio-sdk-0.0.658.gem +0 -0
- metadata +11 -3
- data/zernio-sdk-0.0.656.gem +0 -0
|
@@ -0,0 +1,248 @@
|
|
|
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 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Zernio
|
|
17
|
+
class GetTweet200ResponseTweet < ApiModelBase
|
|
18
|
+
attr_accessor :id
|
|
19
|
+
|
|
20
|
+
attr_accessor :text
|
|
21
|
+
|
|
22
|
+
attr_accessor :created
|
|
23
|
+
|
|
24
|
+
attr_accessor :conversation_id
|
|
25
|
+
|
|
26
|
+
# Parent tweet ID when the tweet is itself a reply
|
|
27
|
+
attr_accessor :in_reply_to_tweet_id
|
|
28
|
+
|
|
29
|
+
attr_accessor :lang
|
|
30
|
+
|
|
31
|
+
attr_accessor :author
|
|
32
|
+
|
|
33
|
+
attr_accessor :like_count
|
|
34
|
+
|
|
35
|
+
attr_accessor :reply_count
|
|
36
|
+
|
|
37
|
+
attr_accessor :retweet_count
|
|
38
|
+
|
|
39
|
+
attr_accessor :quote_count
|
|
40
|
+
|
|
41
|
+
attr_accessor :platform
|
|
42
|
+
|
|
43
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
44
|
+
def self.attribute_map
|
|
45
|
+
{
|
|
46
|
+
:'id' => :'id',
|
|
47
|
+
:'text' => :'text',
|
|
48
|
+
:'created' => :'created',
|
|
49
|
+
:'conversation_id' => :'conversationId',
|
|
50
|
+
:'in_reply_to_tweet_id' => :'inReplyToTweetId',
|
|
51
|
+
:'lang' => :'lang',
|
|
52
|
+
:'author' => :'author',
|
|
53
|
+
:'like_count' => :'likeCount',
|
|
54
|
+
:'reply_count' => :'replyCount',
|
|
55
|
+
:'retweet_count' => :'retweetCount',
|
|
56
|
+
:'quote_count' => :'quoteCount',
|
|
57
|
+
:'platform' => :'platform'
|
|
58
|
+
}
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# Returns attribute mapping this model knows about
|
|
62
|
+
def self.acceptable_attribute_map
|
|
63
|
+
attribute_map
|
|
64
|
+
end
|
|
65
|
+
|
|
66
|
+
# Returns all the JSON keys this model knows about
|
|
67
|
+
def self.acceptable_attributes
|
|
68
|
+
acceptable_attribute_map.values
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
# Attribute type mapping.
|
|
72
|
+
def self.openapi_types
|
|
73
|
+
{
|
|
74
|
+
:'id' => :'String',
|
|
75
|
+
:'text' => :'String',
|
|
76
|
+
:'created' => :'Time',
|
|
77
|
+
:'conversation_id' => :'String',
|
|
78
|
+
:'in_reply_to_tweet_id' => :'String',
|
|
79
|
+
:'lang' => :'String',
|
|
80
|
+
:'author' => :'SearchTweets200ResponseTweetsInnerAuthor',
|
|
81
|
+
:'like_count' => :'Integer',
|
|
82
|
+
:'reply_count' => :'Integer',
|
|
83
|
+
:'retweet_count' => :'Integer',
|
|
84
|
+
:'quote_count' => :'Integer',
|
|
85
|
+
:'platform' => :'String'
|
|
86
|
+
}
|
|
87
|
+
end
|
|
88
|
+
|
|
89
|
+
# List of attributes with nullable: true
|
|
90
|
+
def self.openapi_nullable
|
|
91
|
+
Set.new([
|
|
92
|
+
:'in_reply_to_tweet_id',
|
|
93
|
+
])
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
# Initializes the object
|
|
97
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
98
|
+
def initialize(attributes = {})
|
|
99
|
+
if (!attributes.is_a?(Hash))
|
|
100
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::GetTweet200ResponseTweet` initialize method"
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
104
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
105
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
106
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
107
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::GetTweet200ResponseTweet`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
108
|
+
end
|
|
109
|
+
h[k.to_sym] = v
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
if attributes.key?(:'id')
|
|
113
|
+
self.id = attributes[:'id']
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
if attributes.key?(:'text')
|
|
117
|
+
self.text = attributes[:'text']
|
|
118
|
+
end
|
|
119
|
+
|
|
120
|
+
if attributes.key?(:'created')
|
|
121
|
+
self.created = attributes[:'created']
|
|
122
|
+
end
|
|
123
|
+
|
|
124
|
+
if attributes.key?(:'conversation_id')
|
|
125
|
+
self.conversation_id = attributes[:'conversation_id']
|
|
126
|
+
end
|
|
127
|
+
|
|
128
|
+
if attributes.key?(:'in_reply_to_tweet_id')
|
|
129
|
+
self.in_reply_to_tweet_id = attributes[:'in_reply_to_tweet_id']
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
if attributes.key?(:'lang')
|
|
133
|
+
self.lang = attributes[:'lang']
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
if attributes.key?(:'author')
|
|
137
|
+
self.author = attributes[:'author']
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
if attributes.key?(:'like_count')
|
|
141
|
+
self.like_count = attributes[:'like_count']
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
if attributes.key?(:'reply_count')
|
|
145
|
+
self.reply_count = attributes[:'reply_count']
|
|
146
|
+
end
|
|
147
|
+
|
|
148
|
+
if attributes.key?(:'retweet_count')
|
|
149
|
+
self.retweet_count = attributes[:'retweet_count']
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
if attributes.key?(:'quote_count')
|
|
153
|
+
self.quote_count = attributes[:'quote_count']
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
if attributes.key?(:'platform')
|
|
157
|
+
self.platform = attributes[:'platform']
|
|
158
|
+
end
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
162
|
+
# @return Array for valid properties with the reasons
|
|
163
|
+
def list_invalid_properties
|
|
164
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
165
|
+
invalid_properties = Array.new
|
|
166
|
+
invalid_properties
|
|
167
|
+
end
|
|
168
|
+
|
|
169
|
+
# Check to see if the all the properties in the model are valid
|
|
170
|
+
# @return true if the model is valid
|
|
171
|
+
def valid?
|
|
172
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
173
|
+
true
|
|
174
|
+
end
|
|
175
|
+
|
|
176
|
+
# Checks equality by comparing each attribute.
|
|
177
|
+
# @param [Object] Object to be compared
|
|
178
|
+
def ==(o)
|
|
179
|
+
return true if self.equal?(o)
|
|
180
|
+
self.class == o.class &&
|
|
181
|
+
id == o.id &&
|
|
182
|
+
text == o.text &&
|
|
183
|
+
created == o.created &&
|
|
184
|
+
conversation_id == o.conversation_id &&
|
|
185
|
+
in_reply_to_tweet_id == o.in_reply_to_tweet_id &&
|
|
186
|
+
lang == o.lang &&
|
|
187
|
+
author == o.author &&
|
|
188
|
+
like_count == o.like_count &&
|
|
189
|
+
reply_count == o.reply_count &&
|
|
190
|
+
retweet_count == o.retweet_count &&
|
|
191
|
+
quote_count == o.quote_count &&
|
|
192
|
+
platform == o.platform
|
|
193
|
+
end
|
|
194
|
+
|
|
195
|
+
# @see the `==` method
|
|
196
|
+
# @param [Object] Object to be compared
|
|
197
|
+
def eql?(o)
|
|
198
|
+
self == o
|
|
199
|
+
end
|
|
200
|
+
|
|
201
|
+
# Calculates hash code according to all attributes.
|
|
202
|
+
# @return [Integer] Hash code
|
|
203
|
+
def hash
|
|
204
|
+
[id, text, created, conversation_id, in_reply_to_tweet_id, lang, author, like_count, reply_count, retweet_count, quote_count, platform].hash
|
|
205
|
+
end
|
|
206
|
+
|
|
207
|
+
# Builds the object from hash
|
|
208
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
209
|
+
# @return [Object] Returns the model itself
|
|
210
|
+
def self.build_from_hash(attributes)
|
|
211
|
+
return nil unless attributes.is_a?(Hash)
|
|
212
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
213
|
+
transformed_hash = {}
|
|
214
|
+
openapi_types.each_pair do |key, type|
|
|
215
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
216
|
+
transformed_hash["#{key}"] = nil
|
|
217
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
218
|
+
# check to ensure the input is an array given that the attribute
|
|
219
|
+
# is documented as an array but the input is not
|
|
220
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
221
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
222
|
+
end
|
|
223
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
224
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
225
|
+
end
|
|
226
|
+
end
|
|
227
|
+
new(transformed_hash)
|
|
228
|
+
end
|
|
229
|
+
|
|
230
|
+
# Returns the object in the form of hash
|
|
231
|
+
# @return [Hash] Returns the object in the form of hash
|
|
232
|
+
def to_hash
|
|
233
|
+
hash = {}
|
|
234
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
235
|
+
value = self.send(attr)
|
|
236
|
+
if value.nil?
|
|
237
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
238
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
239
|
+
end
|
|
240
|
+
|
|
241
|
+
hash[param] = _to_hash(value)
|
|
242
|
+
end
|
|
243
|
+
hash
|
|
244
|
+
end
|
|
245
|
+
|
|
246
|
+
end
|
|
247
|
+
|
|
248
|
+
end
|
data/lib/zernio-sdk/version.rb
CHANGED
data/lib/zernio-sdk.rb
CHANGED
|
@@ -671,6 +671,8 @@ require 'zernio-sdk/models/get_tik_tok_creator_info200_response_privacy_levels_i
|
|
|
671
671
|
require 'zernio-sdk/models/get_tracking_tag200_response'
|
|
672
672
|
require 'zernio-sdk/models/get_tracking_tag_stats200_response'
|
|
673
673
|
require 'zernio-sdk/models/get_tracking_tag_stats200_response_stats'
|
|
674
|
+
require 'zernio-sdk/models/get_tweet200_response'
|
|
675
|
+
require 'zernio-sdk/models/get_tweet200_response_tweet'
|
|
674
676
|
require 'zernio-sdk/models/get_usage200_response'
|
|
675
677
|
require 'zernio-sdk/models/get_user200_response'
|
|
676
678
|
require 'zernio-sdk/models/get_user200_response_user'
|
data/openapi.yaml
CHANGED
|
@@ -6585,7 +6585,7 @@ components:
|
|
|
6585
6585
|
impressions: { type: integer }
|
|
6586
6586
|
reach:
|
|
6587
6587
|
type: integer
|
|
6588
|
-
description: "Unique people reached in the requested date range. Meta (facebook/instagram):
|
|
6588
|
+
description: "Unique people reached in the requested date range. Meta (facebook/instagram) and TikTok: the platform's own de-duplicated reach for the exact range, fetched live and cached up to ~1 hour (may lag recent delivery; on a transient platform error the value temporarily falls back to a sum of per-day reach, which overcounts people reached on multiple days or by multiple child ads). Because it is de-duplicated, reach is NOT additive on these platforms: neither daily values nor child nodes sum to the range total. Google, LinkedIn, X, Pinterest and OpenAI report 0 (reach not synced). Frequency (impressions / reach) is only meaningful for Meta and TikTok."
|
|
6589
6589
|
clicks: { type: integer }
|
|
6590
6590
|
ctr: { type: number, description: Click-through rate (%) }
|
|
6591
6591
|
cpc: { type: number, description: Cost per click }
|
|
@@ -6641,9 +6641,9 @@ components:
|
|
|
6641
6641
|
called with `timeIncrement=1`. Rate metrics (ctr/cpc/cpm/costPerConversion/
|
|
6642
6642
|
roas/videoAvgTimeWatchedActions) are recomputed per day from that day's
|
|
6643
6643
|
sums, so summing the additive fields across a node's `daily[]` reproduces
|
|
6644
|
-
its aggregated `metrics` total. `reach` is the exception: on Meta
|
|
6645
|
-
aggregated total is de-duplicated across the range, so daily
|
|
6646
|
-
not sum to it. Do NOT sum or plain-average
|
|
6644
|
+
its aggregated `metrics` total. `reach` is the exception: on Meta and
|
|
6645
|
+
TikTok the aggregated total is de-duplicated across the range, so daily
|
|
6646
|
+
reach does not sum to it. Do NOT sum or plain-average
|
|
6647
6647
|
`videoAvgTimeWatchedActions` across days: the range value is the
|
|
6648
6648
|
play-weighted average of the daily values.
|
|
6649
6649
|
allOf:
|
|
@@ -21111,12 +21111,6 @@ paths:
|
|
|
21111
21111
|
objects so callers can build community-ops automation (e.g. "add role
|
|
21112
21112
|
to all members joined in the last 7 days") on the actual platform shape.
|
|
21113
21113
|
|
|
21114
|
-
**Important:** this endpoint requires the privileged "Server Members
|
|
21115
|
-
Intent" on the Discord application. If the intent is not enabled,
|
|
21116
|
-
Discord rejects the call and this endpoint returns **403**. Single
|
|
21117
|
-
member lookup and prefix search (see the sibling endpoints) do not
|
|
21118
|
-
need the intent.
|
|
21119
|
-
|
|
21120
21114
|
Pagination: pass `after` = the last `user.id` from the previous page.
|
|
21121
21115
|
Omit on the first call. Response includes a `nextCursor` and `hasMore`
|
|
21122
21116
|
flag so callers don't need to know Discord's pagination shape.
|
|
@@ -21143,7 +21137,7 @@ paths:
|
|
|
21143
21137
|
hasMore: { type: boolean }
|
|
21144
21138
|
'400': { description: Invalid query params. }
|
|
21145
21139
|
'401': { $ref: '#/components/responses/Unauthorized' }
|
|
21146
|
-
'403': { description:
|
|
21140
|
+
'403': { description: 'Discord denied access to the guild members (the bot is no longer in the guild).' }
|
|
21147
21141
|
'404': { description: Discord account not found or not in this guild. }
|
|
21148
21142
|
|
|
21149
21143
|
/v1/discord/guilds/{guildId}/members/search:
|
|
@@ -21155,8 +21149,8 @@ paths:
|
|
|
21155
21149
|
Search guild members whose username or nickname **starts with** the
|
|
21156
21150
|
query (Discord matches prefixes only, not substrings).
|
|
21157
21151
|
|
|
21158
|
-
|
|
21159
|
-
|
|
21152
|
+
Cheaper than paginating the full member listing when you already know
|
|
21153
|
+
who you are looking for.
|
|
21160
21154
|
parameters:
|
|
21161
21155
|
- { name: guildId, in: path, required: true, schema: { type: string } }
|
|
21162
21156
|
- { name: accountId, in: query, required: true, schema: { type: string } }
|
|
@@ -21185,8 +21179,8 @@ paths:
|
|
|
21185
21179
|
description: |
|
|
21186
21180
|
Fetch a single guild member by Discord user id.
|
|
21187
21181
|
|
|
21188
|
-
|
|
21189
|
-
|
|
21182
|
+
Cheaper than paginating the full member listing when you already know
|
|
21183
|
+
who you are looking for.
|
|
21190
21184
|
parameters:
|
|
21191
21185
|
- { name: guildId, in: path, required: true, schema: { type: string } }
|
|
21192
21186
|
- { name: userId, in: path, required: true, schema: { type: string }, description: Discord user snowflake. }
|
|
@@ -25728,6 +25722,70 @@ paths:
|
|
|
25728
25722
|
'404': { description: Account not found }
|
|
25729
25723
|
'429': { description: 'X search rate limit exceeded (300 requests per 15 minutes)' }
|
|
25730
25724
|
|
|
25725
|
+
/v1/twitter/tweet:
|
|
25726
|
+
get:
|
|
25727
|
+
operationId: getTweet
|
|
25728
|
+
summary: Look up a tweet
|
|
25729
|
+
description: |
|
|
25730
|
+
Resolve a single tweet by ID or URL into its text, author and public metrics.
|
|
25731
|
+
|
|
25732
|
+
Use this to render a post you are referencing, e.g. the tweet quoted by a quote-style post.
|
|
25733
|
+
Unlike `/v1/twitter/search` this is not limited to the last 7 days and works for any tweet
|
|
25734
|
+
visible to the connected account.
|
|
25735
|
+
|
|
25736
|
+
Billed as an X posts read ($0.005). Repeat lookups of the same tweet within the same UTC day
|
|
25737
|
+
are charged once.
|
|
25738
|
+
tags: [Twitter Engagement]
|
|
25739
|
+
security: [{ bearerAuth: [] }]
|
|
25740
|
+
parameters:
|
|
25741
|
+
- name: accountId
|
|
25742
|
+
in: query
|
|
25743
|
+
required: true
|
|
25744
|
+
schema: { type: string }
|
|
25745
|
+
description: The social account ID whose X token is used for the lookup
|
|
25746
|
+
- name: id
|
|
25747
|
+
in: query
|
|
25748
|
+
required: true
|
|
25749
|
+
schema: { type: string }
|
|
25750
|
+
description: 'Numeric tweet ID or a tweet URL (e.g. https://x.com/user/status/123...)'
|
|
25751
|
+
responses:
|
|
25752
|
+
'200':
|
|
25753
|
+
description: The resolved tweet
|
|
25754
|
+
content:
|
|
25755
|
+
application/json:
|
|
25756
|
+
schema:
|
|
25757
|
+
type: object
|
|
25758
|
+
properties:
|
|
25759
|
+
status: { type: string, example: success }
|
|
25760
|
+
tweet:
|
|
25761
|
+
type: object
|
|
25762
|
+
properties:
|
|
25763
|
+
id: { type: string }
|
|
25764
|
+
text: { type: string }
|
|
25765
|
+
created: { type: string, format: date-time }
|
|
25766
|
+
conversationId: { type: string }
|
|
25767
|
+
inReplyToTweetId: { type: [string, "null"], description: 'Parent tweet ID when the tweet is itself a reply' }
|
|
25768
|
+
lang: { type: string }
|
|
25769
|
+
author:
|
|
25770
|
+
type: object
|
|
25771
|
+
properties:
|
|
25772
|
+
id: { type: string }
|
|
25773
|
+
username: { type: string }
|
|
25774
|
+
displayName: { type: string }
|
|
25775
|
+
avatar: { type: string }
|
|
25776
|
+
verifiedType: { type: string }
|
|
25777
|
+
likeCount: { type: integer }
|
|
25778
|
+
replyCount: { type: integer }
|
|
25779
|
+
retweetCount: { type: integer }
|
|
25780
|
+
quoteCount: { type: integer }
|
|
25781
|
+
platform: { type: string, example: twitter }
|
|
25782
|
+
'400': { $ref: '#/components/responses/BadRequest' }
|
|
25783
|
+
'401': { $ref: '#/components/responses/Unauthorized' }
|
|
25784
|
+
'402': { description: 'X API spend cap reached for this billing period' }
|
|
25785
|
+
'403': { description: 'X analytics capability not enabled for this account (code X_ANALYTICS_NOT_ENABLED), or the tweet author is protected or suspended' }
|
|
25786
|
+
'404': { description: 'Account not found, or the tweet was deleted or never existed' }
|
|
25787
|
+
'429': { description: 'X rate limit exceeded' }
|
|
25788
|
+
|
|
25731
25789
|
/v1/inbox/mentions:
|
|
25732
25790
|
get:
|
|
25733
25791
|
operationId: listInboxMentions
|
|
@@ -35951,7 +36009,7 @@ paths:
|
|
|
35951
36009
|
- { name: fromDate, in: query, schema: { type: string, format: date }, description: "Start of the METRICS date range (YYYY-MM-DD). Affects only the spend/impression numbers overlaid on each node, NOT which campaigns are returned. Defaults to 90 days ago." }
|
|
35952
36010
|
- { name: toDate, in: query, schema: { type: string, format: date }, description: "End of metrics date range (YYYY-MM-DD). Defaults to today. Max 730-day range." }
|
|
35953
36011
|
- { name: sort, in: query, schema: { type: string, enum: [newest, oldest, spend_desc, spend_asc], default: newest }, description: "Campaign-level sort order. `newest` (default) / `oldest` order by the campaign's newest-ad createdAt. `spend_desc` / `spend_asc` order by aggregated spend in the requested date range; campaigns with no spend land at the end." }
|
|
35954
|
-
- { name: timeIncrement, in: query, schema: { type: integer, enum: [1] }, description: "Set to `1` to also return a daily breakdown. Mirrors Meta Insights' `time_increment=1`: each node gains a `daily[]` array of per-day metrics (same fields as the aggregated `metrics`) alongside the range total, so you get per-entity daily trends in ONE call instead of calling the tree once per day. Only `1` (daily) is supported. The daily series covers the same date range and uses the same source data as `metrics`, except
|
|
36012
|
+
- { name: timeIncrement, in: query, schema: { type: integer, enum: [1] }, description: "Set to `1` to also return a daily breakdown. Mirrors Meta Insights' `time_increment=1`: each node gains a `daily[]` array of per-day metrics (same fields as the aggregated `metrics`) alongside the range total, so you get per-entity daily trends in ONE call instead of calling the tree once per day. Only `1` (daily) is supported. The daily series covers the same date range and uses the same source data as `metrics`, except `reach` on Meta and TikTok: the range total is the platform's de-duplicated value, so daily reach does not sum to it. See `dailyLevel` to control which levels carry it." }
|
|
35955
36013
|
- { name: dailyLevel, in: query, schema: { type: string, enum: [campaign, adset, ad], default: campaign }, description: "Which tree levels get the `daily[]` series when `timeIncrement=1`. `campaign` (default) attaches it on campaign nodes only — the common per-campaign-trend case, and the smallest payload. `adset` adds it on ad sets too; `ad` adds it on every ad in `ads[]` as well (heaviest — a long range × up to 100 ads per ad set). Scope with `campaignId` to keep `ad`-level responses small. Ignored when `timeIncrement` is unset." }
|
|
35956
36014
|
responses:
|
|
35957
36015
|
'200':
|
|
@@ -192,7 +192,7 @@ describe 'AdCampaignsApi' do
|
|
|
192
192
|
# @option opts [Date] :from_date Start of the METRICS date range (YYYY-MM-DD). Affects only the spend/impression numbers overlaid on each node, NOT which campaigns are returned. Defaults to 90 days ago.
|
|
193
193
|
# @option opts [Date] :to_date End of metrics date range (YYYY-MM-DD). Defaults to today. Max 730-day range.
|
|
194
194
|
# @option opts [String] :sort Campaign-level sort order. `newest` (default) / `oldest` order by the campaign's newest-ad createdAt. `spend_desc` / `spend_asc` order by aggregated spend in the requested date range; campaigns with no spend land at the end.
|
|
195
|
-
# @option opts [Integer] :time_increment Set to `1` to also return a daily breakdown. Mirrors Meta Insights' `time_increment=1`: each node gains a `daily[]` array of per-day metrics (same fields as the aggregated `metrics`) alongside the range total, so you get per-entity daily trends in ONE call instead of calling the tree once per day. Only `1` (daily) is supported. The daily series covers the same date range and uses the same source data as `metrics`, except
|
|
195
|
+
# @option opts [Integer] :time_increment Set to `1` to also return a daily breakdown. Mirrors Meta Insights' `time_increment=1`: each node gains a `daily[]` array of per-day metrics (same fields as the aggregated `metrics`) alongside the range total, so you get per-entity daily trends in ONE call instead of calling the tree once per day. Only `1` (daily) is supported. The daily series covers the same date range and uses the same source data as `metrics`, except `reach` on Meta and TikTok: the range total is the platform's de-duplicated value, so daily reach does not sum to it. See `dailyLevel` to control which levels carry it.
|
|
196
196
|
# @option opts [String] :daily_level Which tree levels get the `daily[]` series when `timeIncrement=1`. `campaign` (default) attaches it on campaign nodes only — the common per-campaign-trend case, and the smallest payload. `adset` adds it on ad sets too; `ad` adds it on every ad in `ads[]` as well (heaviest — a long range × up to 100 ads per ad set). Scope with `campaignId` to keep `ad`-level responses small. Ignored when `timeIncrement` is unset.
|
|
197
197
|
# @return [GetAdTree200Response]
|
|
198
198
|
describe 'get_ad_tree test' do
|
|
@@ -173,7 +173,7 @@ describe 'DiscordApi' do
|
|
|
173
173
|
|
|
174
174
|
# unit tests for get_discord_guild_member
|
|
175
175
|
# Get a Discord guild member
|
|
176
|
-
# Fetch a single guild member by Discord user id.
|
|
176
|
+
# Fetch a single guild member by Discord user id. Cheaper than paginating the full member listing when you already know who you are looking for.
|
|
177
177
|
# @param guild_id
|
|
178
178
|
# @param user_id Discord user snowflake.
|
|
179
179
|
# @param account_id
|
|
@@ -212,7 +212,7 @@ describe 'DiscordApi' do
|
|
|
212
212
|
|
|
213
213
|
# unit tests for list_discord_guild_members
|
|
214
214
|
# List Discord guild members
|
|
215
|
-
# Cursor-paginated list of guild members. Returns Discord's raw member objects so callers can build community-ops automation (e.g. \"add role to all members joined in the last 7 days\") on the actual platform shape.
|
|
215
|
+
# Cursor-paginated list of guild members. Returns Discord's raw member objects so callers can build community-ops automation (e.g. \"add role to all members joined in the last 7 days\") on the actual platform shape. Pagination: pass `after` = the last `user.id` from the previous page. Omit on the first call. Response includes a `nextCursor` and `hasMore` flag so callers don't need to know Discord's pagination shape.
|
|
216
216
|
# @param guild_id
|
|
217
217
|
# @param account_id
|
|
218
218
|
# @param [Hash] opts the optional parameters
|
|
@@ -296,7 +296,7 @@ describe 'DiscordApi' do
|
|
|
296
296
|
|
|
297
297
|
# unit tests for search_discord_guild_members
|
|
298
298
|
# Search Discord guild members
|
|
299
|
-
# Search guild members whose username or nickname **starts with** the query (Discord matches prefixes only, not substrings).
|
|
299
|
+
# Search guild members whose username or nickname **starts with** the query (Discord matches prefixes only, not substrings). Cheaper than paginating the full member listing when you already know who you are looking for.
|
|
300
300
|
# @param guild_id
|
|
301
301
|
# @param account_id
|
|
302
302
|
# @param query Username or nickname prefix to match.
|
|
@@ -56,6 +56,19 @@ describe 'TwitterEngagementApi' do
|
|
|
56
56
|
end
|
|
57
57
|
end
|
|
58
58
|
|
|
59
|
+
# unit tests for get_tweet
|
|
60
|
+
# Look up a tweet
|
|
61
|
+
# Resolve a single tweet by ID or URL into its text, author and public metrics. Use this to render a post you are referencing, e.g. the tweet quoted by a quote-style post. Unlike `/v1/twitter/search` this is not limited to the last 7 days and works for any tweet visible to the connected account. Billed as an X posts read ($0.005). Repeat lookups of the same tweet within the same UTC day are charged once.
|
|
62
|
+
# @param account_id The social account ID whose X token is used for the lookup
|
|
63
|
+
# @param id Numeric tweet ID or a tweet URL (e.g. https://x.com/user/status/123...)
|
|
64
|
+
# @param [Hash] opts the optional parameters
|
|
65
|
+
# @return [GetTweet200Response]
|
|
66
|
+
describe 'get_tweet test' do
|
|
67
|
+
it 'should work' do
|
|
68
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
|
|
59
72
|
# unit tests for remove_bookmark
|
|
60
73
|
# Remove bookmark
|
|
61
74
|
# Remove a bookmark from a tweet.
|
|
@@ -0,0 +1,42 @@
|
|
|
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::GetTweet200Response
|
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
|
19
|
+
# Please update as you see appropriate
|
|
20
|
+
describe Zernio::GetTweet200Response do
|
|
21
|
+
#let(:instance) { Zernio::GetTweet200Response.new }
|
|
22
|
+
|
|
23
|
+
describe 'test an instance of GetTweet200Response' do
|
|
24
|
+
it 'should create an instance of GetTweet200Response' do
|
|
25
|
+
# uncomment below to test the instance creation
|
|
26
|
+
#expect(instance).to be_instance_of(Zernio::GetTweet200Response)
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
describe 'test attribute "status"' 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 "tweet"' 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
|
+
end
|
|
@@ -0,0 +1,102 @@
|
|
|
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::GetTweet200ResponseTweet
|
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
|
19
|
+
# Please update as you see appropriate
|
|
20
|
+
describe Zernio::GetTweet200ResponseTweet do
|
|
21
|
+
#let(:instance) { Zernio::GetTweet200ResponseTweet.new }
|
|
22
|
+
|
|
23
|
+
describe 'test an instance of GetTweet200ResponseTweet' do
|
|
24
|
+
it 'should create an instance of GetTweet200ResponseTweet' do
|
|
25
|
+
# uncomment below to test the instance creation
|
|
26
|
+
#expect(instance).to be_instance_of(Zernio::GetTweet200ResponseTweet)
|
|
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 "text"' 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 "created"' 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 "conversation_id"' 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 "in_reply_to_tweet_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 "lang"' do
|
|
61
|
+
it 'should work' do
|
|
62
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
63
|
+
end
|
|
64
|
+
end
|
|
65
|
+
|
|
66
|
+
describe 'test attribute "author"' do
|
|
67
|
+
it 'should work' do
|
|
68
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
describe 'test attribute "like_count"' do
|
|
73
|
+
it 'should work' do
|
|
74
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
75
|
+
end
|
|
76
|
+
end
|
|
77
|
+
|
|
78
|
+
describe 'test attribute "reply_count"' do
|
|
79
|
+
it 'should work' do
|
|
80
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
describe 'test attribute "retweet_count"' do
|
|
85
|
+
it 'should work' do
|
|
86
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
87
|
+
end
|
|
88
|
+
end
|
|
89
|
+
|
|
90
|
+
describe 'test attribute "quote_count"' do
|
|
91
|
+
it 'should work' do
|
|
92
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
93
|
+
end
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
describe 'test attribute "platform"' do
|
|
97
|
+
it 'should work' do
|
|
98
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
99
|
+
end
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
end
|
|
Binary file
|