@volter/twin-tiktok 0.1.37 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (202) hide show
  1. package/README.md +25 -308
  2. package/business/spec/SOURCE.md +17 -0
  3. package/business/spec/openapi.json +1045 -0
  4. package/business/spec/sources.json +84 -0
  5. package/business/src/fetch.ts +14 -0
  6. package/business/src/generated/surface.gen.json +1 -0
  7. package/business/src/generated/ui.gen.json +1 -0
  8. package/business/src/index.ts +3 -0
  9. package/business/src/manifest.ts +38 -0
  10. package/business/src/semantics/index.ts +16 -0
  11. package/business/src/semantics/open_api.ts +142 -0
  12. package/business/src/semantics/shared.ts +119 -0
  13. package/business/src/semantics/states.ts +3 -0
  14. package/dist/business/spec/SOURCE.md +17 -0
  15. package/dist/business/spec/openapi.json +1045 -0
  16. package/dist/business/spec/sources.json +84 -0
  17. package/dist/business/src/fetch.d.ts +2 -0
  18. package/dist/business/src/fetch.js +13 -0
  19. package/dist/business/src/fetch.ts +14 -0
  20. package/dist/business/src/generated/surface.gen.json +1 -0
  21. package/dist/business/src/generated/ui.gen.json +1 -0
  22. package/dist/business/src/index.d.ts +2 -0
  23. package/dist/business/src/index.js +3 -0
  24. package/dist/business/src/index.ts +3 -0
  25. package/dist/business/src/manifest.d.ts +2 -0
  26. package/dist/business/src/manifest.js +33 -0
  27. package/dist/business/src/manifest.ts +38 -0
  28. package/dist/business/src/semantics/index.d.ts +2 -0
  29. package/dist/business/src/semantics/index.js +12 -0
  30. package/dist/business/src/semantics/index.ts +16 -0
  31. package/dist/business/src/semantics/open_api.d.ts +10 -0
  32. package/dist/business/src/semantics/open_api.js +162 -0
  33. package/dist/business/src/semantics/open_api.ts +142 -0
  34. package/dist/business/src/semantics/shared.d.ts +31 -0
  35. package/dist/business/src/semantics/shared.js +109 -0
  36. package/dist/business/src/semantics/shared.ts +119 -0
  37. package/dist/business/src/semantics/states.d.ts +8 -0
  38. package/dist/business/src/semantics/states.js +3 -0
  39. package/dist/business/src/semantics/states.ts +3 -0
  40. package/dist/generated/pack-facts.json +55 -0
  41. package/dist/journeys/coverage.json +220 -0
  42. package/dist/journeys/customer-life.json +2950 -0
  43. package/dist/journeys/customer-life.outline.md +59 -0
  44. package/dist/journeys/decisions.json +161 -0
  45. package/dist/journeys/demand.json +142 -0
  46. package/dist/journeys/score.json +294 -0
  47. package/dist/journeys/unreachable.json +13 -0
  48. package/dist/open/spec/SOURCE.md +20 -0
  49. package/dist/open/spec/openapi.json +1417 -0
  50. package/dist/open/spec/sources.json +124 -0
  51. package/dist/open/src/engine/mp4.d.ts +6 -0
  52. package/dist/open/src/engine/mp4.js +55 -0
  53. package/dist/open/src/engine/mp4.ts +48 -0
  54. package/dist/open/src/fetch.d.ts +2 -0
  55. package/dist/open/src/fetch.js +17 -0
  56. package/dist/open/src/fetch.ts +18 -0
  57. package/dist/open/src/generated/surface.gen.json +1 -0
  58. package/dist/open/src/generated/ui.gen.json +1 -0
  59. package/dist/open/src/index.d.ts +2 -0
  60. package/dist/open/src/index.js +3 -0
  61. package/dist/open/src/index.ts +3 -0
  62. package/dist/open/src/manifest.d.ts +2 -0
  63. package/dist/open/src/manifest.js +53 -0
  64. package/dist/open/src/manifest.ts +59 -0
  65. package/dist/open/src/screens/authorize.d.ts +2 -0
  66. package/dist/open/src/screens/authorize.js +53 -0
  67. package/dist/open/src/screens/authorize.ts +53 -0
  68. package/dist/open/src/semantics/doors.d.ts +10 -0
  69. package/dist/open/src/semantics/doors.js +118 -0
  70. package/dist/open/src/semantics/doors.ts +121 -0
  71. package/dist/open/src/semantics/index.d.ts +2 -0
  72. package/dist/open/src/semantics/index.js +16 -0
  73. package/dist/open/src/semantics/index.ts +20 -0
  74. package/dist/open/src/semantics/oauth.d.ts +2 -0
  75. package/dist/open/src/semantics/oauth.js +30 -0
  76. package/dist/open/src/semantics/oauth.ts +28 -0
  77. package/dist/open/src/semantics/post.d.ts +6 -0
  78. package/dist/open/src/semantics/post.js +66 -0
  79. package/dist/open/src/semantics/post.ts +60 -0
  80. package/dist/open/src/semantics/shared.d.ts +51 -0
  81. package/dist/open/src/semantics/shared.js +196 -0
  82. package/dist/open/src/semantics/shared.ts +197 -0
  83. package/dist/open/src/semantics/states.d.ts +20 -0
  84. package/dist/open/src/semantics/states.js +15 -0
  85. package/dist/open/src/semantics/states.ts +23 -0
  86. package/dist/open/src/semantics/user.d.ts +2 -0
  87. package/dist/open/src/semantics/user.js +24 -0
  88. package/dist/open/src/semantics/user.ts +24 -0
  89. package/dist/open/src/semantics/video.d.ts +4 -0
  90. package/dist/open/src/semantics/video.js +112 -0
  91. package/dist/open/src/semantics/video.ts +97 -0
  92. package/dist/src/cli.js +11 -34
  93. package/dist/src/fetch.d.ts +2 -0
  94. package/dist/src/fetch.js +9 -0
  95. package/dist/src/index.d.ts +5 -22
  96. package/dist/src/index.js +13 -167
  97. package/dist/src/manifest.d.ts +2 -0
  98. package/dist/src/manifest.js +28 -0
  99. package/dist/src/semantics/shared.d.ts +49 -0
  100. package/dist/src/semantics/shared.js +61 -0
  101. package/dist/src/server.d.ts +7 -0
  102. package/dist/src/server.js +7 -0
  103. package/generated/pack-facts.json +55 -0
  104. package/journeys/coverage.json +220 -0
  105. package/journeys/customer-life.json +2950 -0
  106. package/journeys/customer-life.outline.md +59 -0
  107. package/journeys/decisions.json +161 -0
  108. package/journeys/demand.json +142 -0
  109. package/journeys/score.json +294 -0
  110. package/journeys/unreachable.json +13 -0
  111. package/open/spec/SOURCE.md +20 -0
  112. package/open/spec/openapi.json +1417 -0
  113. package/open/spec/sources.json +124 -0
  114. package/open/src/engine/mp4.ts +48 -0
  115. package/open/src/fetch.ts +18 -0
  116. package/open/src/generated/surface.gen.json +1 -0
  117. package/open/src/generated/ui.gen.json +1 -0
  118. package/open/src/index.ts +3 -0
  119. package/open/src/manifest.ts +59 -0
  120. package/open/src/screens/authorize.ts +53 -0
  121. package/open/src/semantics/doors.ts +121 -0
  122. package/open/src/semantics/index.ts +20 -0
  123. package/open/src/semantics/oauth.ts +28 -0
  124. package/open/src/semantics/post.ts +60 -0
  125. package/open/src/semantics/shared.ts +197 -0
  126. package/open/src/semantics/states.ts +23 -0
  127. package/open/src/semantics/user.ts +24 -0
  128. package/open/src/semantics/video.ts +97 -0
  129. package/package.json +13 -41
  130. package/src/cli.ts +11 -32
  131. package/src/fetch.ts +10 -0
  132. package/src/index.ts +15 -270
  133. package/src/manifest.ts +33 -0
  134. package/src/semantics/shared.ts +78 -0
  135. package/src/server.ts +8 -0
  136. package/client/tiktok-consent.tsx +0 -154
  137. package/client/tiktok-mirror.css +0 -137
  138. package/client/tiktok-mirror.tsx +0 -497
  139. package/dist/client/tiktok-consent.bundle.js +0 -18
  140. package/dist/client/tiktok-consent.d.ts +0 -47
  141. package/dist/client/tiktok-consent.js +0 -20
  142. package/dist/client/tiktok-consent.tsx +0 -154
  143. package/dist/client/tiktok-mirror.bundle.js +0 -484
  144. package/dist/client/tiktok-mirror.css +0 -137
  145. package/dist/client/tiktok-mirror.d.ts +0 -42
  146. package/dist/client/tiktok-mirror.js +0 -325
  147. package/dist/client/tiktok-mirror.tsx +0 -497
  148. package/dist/src/tiktok-blobs.d.ts +0 -66
  149. package/dist/src/tiktok-blobs.js +0 -161
  150. package/dist/src/tiktok-budget.d.ts +0 -56
  151. package/dist/src/tiktok-budget.js +0 -136
  152. package/dist/src/tiktok-capabilities.d.ts +0 -7
  153. package/dist/src/tiktok-capabilities.js +0 -1855
  154. package/dist/src/tiktok-conformance.d.ts +0 -11
  155. package/dist/src/tiktok-conformance.js +0 -498
  156. package/dist/src/tiktok-connector.d.ts +0 -158
  157. package/dist/src/tiktok-connector.js +0 -600
  158. package/dist/src/tiktok-consent-ui.d.ts +0 -19
  159. package/dist/src/tiktok-consent-ui.js +0 -127
  160. package/dist/src/tiktok-errors.d.ts +0 -78
  161. package/dist/src/tiktok-errors.js +0 -175
  162. package/dist/src/tiktok-ids.d.ts +0 -16
  163. package/dist/src/tiktok-ids.js +0 -48
  164. package/dist/src/tiktok-media.d.ts +0 -7
  165. package/dist/src/tiktok-media.js +0 -86
  166. package/dist/src/tiktok-mirror-ui.d.ts +0 -61
  167. package/dist/src/tiktok-mirror-ui.js +0 -187
  168. package/dist/src/tiktok-pkce.d.ts +0 -25
  169. package/dist/src/tiktok-pkce.js +0 -56
  170. package/dist/src/tiktok-posting.d.ts +0 -100
  171. package/dist/src/tiktok-posting.js +0 -599
  172. package/dist/src/tiktok-sample-mp4.d.ts +0 -10
  173. package/dist/src/tiktok-sample-mp4.js +0 -55
  174. package/dist/src/tiktok-scopes.d.ts +0 -29
  175. package/dist/src/tiktok-scopes.js +0 -106
  176. package/dist/src/tiktok-server.d.ts +0 -28
  177. package/dist/src/tiktok-server.js +0 -99
  178. package/dist/src/tiktok-store.d.ts +0 -164
  179. package/dist/src/tiktok-store.js +0 -451
  180. package/dist/src/tiktok-twin.d.ts +0 -70
  181. package/dist/src/tiktok-twin.js +0 -1197
  182. package/dist/src/tiktok-user.d.ts +0 -28
  183. package/dist/src/tiktok-user.js +0 -174
  184. package/src/tiktok-blobs.ts +0 -217
  185. package/src/tiktok-budget.ts +0 -163
  186. package/src/tiktok-capabilities.ts +0 -2022
  187. package/src/tiktok-conformance.ts +0 -526
  188. package/src/tiktok-connector.ts +0 -637
  189. package/src/tiktok-consent-ui.ts +0 -146
  190. package/src/tiktok-errors.ts +0 -197
  191. package/src/tiktok-ids.ts +0 -51
  192. package/src/tiktok-journey.uitest.ts +0 -305
  193. package/src/tiktok-media.ts +0 -89
  194. package/src/tiktok-mirror-ui.ts +0 -193
  195. package/src/tiktok-pkce.ts +0 -61
  196. package/src/tiktok-posting.ts +0 -617
  197. package/src/tiktok-sample-mp4.ts +0 -54
  198. package/src/tiktok-scopes.ts +0 -122
  199. package/src/tiktok-server.ts +0 -110
  200. package/src/tiktok-store.ts +0 -543
  201. package/src/tiktok-twin.ts +0 -1361
  202. package/src/tiktok-user.ts +0 -137
@@ -0,0 +1,1045 @@
1
+ {
2
+ "openapi": "3.0.3",
3
+ "info": {
4
+ "title": "TikTok API for Business: Accounts API and Discovery (v1.3)",
5
+ "version": "v1.3",
6
+ "description": "Written from the TikTok API for Business v1.3 documentation (spec/SOURCE.md): TikTok publishes no OpenAPI document of these endpoints."
7
+ },
8
+ "servers": [
9
+ {
10
+ "url": "https://business-api.tiktok.com"
11
+ }
12
+ ],
13
+ "paths": {
14
+ "/open_api/v1.3/tt_user/oauth2/token/": {
15
+ "post": {
16
+ "operationId": "ttUserOauth2Token",
17
+ "summary": "Get a TikTok account access token",
18
+ "externalDocs": {
19
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1738084387220481&language=ENGLISH"
20
+ },
21
+ "requestBody": {
22
+ "required": true,
23
+ "content": {
24
+ "application/json": {
25
+ "schema": {
26
+ "type": "object",
27
+ "properties": {
28
+ "client_id": {
29
+ "type": "string"
30
+ },
31
+ "client_secret": {
32
+ "type": "string"
33
+ },
34
+ "grant_type": {
35
+ "type": "string"
36
+ },
37
+ "auth_code": {
38
+ "type": "string"
39
+ },
40
+ "redirect_uri": {
41
+ "type": "string"
42
+ }
43
+ }
44
+ }
45
+ }
46
+ }
47
+ },
48
+ "responses": {
49
+ "200": {
50
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
51
+ "content": {
52
+ "application/json": {
53
+ "schema": {
54
+ "type": "object",
55
+ "properties": {
56
+ "code": {
57
+ "type": "integer"
58
+ },
59
+ "message": {
60
+ "type": "string"
61
+ },
62
+ "request_id": {
63
+ "type": "string"
64
+ },
65
+ "data": {
66
+ "type": "object",
67
+ "properties": {
68
+ "access_token": {
69
+ "type": "string"
70
+ },
71
+ "token_type": {
72
+ "type": "string"
73
+ },
74
+ "scope": {
75
+ "type": "string"
76
+ },
77
+ "expires_in": {
78
+ "type": "integer"
79
+ },
80
+ "refresh_token": {
81
+ "type": "string"
82
+ },
83
+ "refresh_token_expires_in": {
84
+ "type": "integer"
85
+ },
86
+ "open_id": {
87
+ "type": "string"
88
+ }
89
+ }
90
+ }
91
+ }
92
+ }
93
+ }
94
+ }
95
+ }
96
+ }
97
+ }
98
+ },
99
+ "/open_api/v1.3/tt_user/oauth2/refresh_token/": {
100
+ "post": {
101
+ "operationId": "ttUserOauth2RefreshToken",
102
+ "summary": "Renew a TikTok account access token",
103
+ "externalDocs": {
104
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1738084387220481&language=ENGLISH"
105
+ },
106
+ "requestBody": {
107
+ "required": true,
108
+ "content": {
109
+ "application/json": {
110
+ "schema": {
111
+ "type": "object",
112
+ "properties": {
113
+ "client_id": {
114
+ "type": "string"
115
+ },
116
+ "client_secret": {
117
+ "type": "string"
118
+ },
119
+ "grant_type": {
120
+ "type": "string"
121
+ },
122
+ "refresh_token": {
123
+ "type": "string"
124
+ }
125
+ }
126
+ }
127
+ }
128
+ }
129
+ },
130
+ "responses": {
131
+ "200": {
132
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
133
+ "content": {
134
+ "application/json": {
135
+ "schema": {
136
+ "type": "object",
137
+ "properties": {
138
+ "code": {
139
+ "type": "integer"
140
+ },
141
+ "message": {
142
+ "type": "string"
143
+ },
144
+ "request_id": {
145
+ "type": "string"
146
+ },
147
+ "data": {
148
+ "type": "object",
149
+ "properties": {
150
+ "access_token": {
151
+ "type": "string"
152
+ },
153
+ "token_type": {
154
+ "type": "string"
155
+ },
156
+ "scope": {
157
+ "type": "string"
158
+ },
159
+ "expires_in": {
160
+ "type": "integer"
161
+ },
162
+ "refresh_token": {
163
+ "type": "string"
164
+ },
165
+ "refresh_token_expires_in": {
166
+ "type": "integer"
167
+ },
168
+ "open_id": {
169
+ "type": "string"
170
+ }
171
+ }
172
+ }
173
+ }
174
+ }
175
+ }
176
+ }
177
+ }
178
+ }
179
+ }
180
+ },
181
+ "/open_api/v1.3/tt_user/oauth2/revoke/": {
182
+ "post": {
183
+ "operationId": "ttUserOauth2Revoke",
184
+ "summary": "Revoke a TikTok account access token",
185
+ "externalDocs": {
186
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1738084387220481&language=ENGLISH"
187
+ },
188
+ "requestBody": {
189
+ "required": true,
190
+ "content": {
191
+ "application/json": {
192
+ "schema": {
193
+ "type": "object",
194
+ "properties": {
195
+ "client_id": {
196
+ "type": "string"
197
+ },
198
+ "client_secret": {
199
+ "type": "string"
200
+ },
201
+ "access_token": {
202
+ "type": "string"
203
+ }
204
+ }
205
+ }
206
+ }
207
+ }
208
+ },
209
+ "responses": {
210
+ "200": {
211
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
212
+ "content": {
213
+ "application/json": {
214
+ "schema": {
215
+ "type": "object",
216
+ "properties": {
217
+ "code": {
218
+ "type": "integer"
219
+ },
220
+ "message": {
221
+ "type": "string"
222
+ },
223
+ "request_id": {
224
+ "type": "string"
225
+ },
226
+ "data": {
227
+ "type": "object"
228
+ }
229
+ }
230
+ }
231
+ }
232
+ }
233
+ }
234
+ }
235
+ }
236
+ },
237
+ "/open_api/v1.3/tt_user/token_info/get/": {
238
+ "post": {
239
+ "operationId": "ttUserTokenInfoGet",
240
+ "summary": "Get the permission scopes in an access token",
241
+ "externalDocs": {
242
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1765927978092545&language=ENGLISH"
243
+ },
244
+ "requestBody": {
245
+ "required": true,
246
+ "content": {
247
+ "application/json": {
248
+ "schema": {
249
+ "type": "object",
250
+ "properties": {
251
+ "app_id": {
252
+ "type": "string"
253
+ },
254
+ "access_token": {
255
+ "type": "string"
256
+ }
257
+ }
258
+ }
259
+ }
260
+ }
261
+ },
262
+ "responses": {
263
+ "200": {
264
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
265
+ "content": {
266
+ "application/json": {
267
+ "schema": {
268
+ "type": "object",
269
+ "properties": {
270
+ "code": {
271
+ "type": "integer"
272
+ },
273
+ "message": {
274
+ "type": "string"
275
+ },
276
+ "request_id": {
277
+ "type": "string"
278
+ },
279
+ "data": {
280
+ "type": "object"
281
+ }
282
+ }
283
+ }
284
+ }
285
+ }
286
+ }
287
+ }
288
+ }
289
+ },
290
+ "/open_api/v1.3/business/get/": {
291
+ "get": {
292
+ "operationId": "businessGet",
293
+ "summary": "Get profile data of a TikTok account",
294
+ "externalDocs": {
295
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1762228399168514&language=ENGLISH"
296
+ },
297
+ "parameters": [
298
+ {
299
+ "name": "Access-Token",
300
+ "in": "header",
301
+ "required": true,
302
+ "schema": {
303
+ "type": "string",
304
+ "description": "Access token authorized by TikTok creators"
305
+ }
306
+ },
307
+ {
308
+ "name": "business_id",
309
+ "in": "query",
310
+ "required": true,
311
+ "schema": {
312
+ "type": "string",
313
+ "description": "The TikTok account's open_id"
314
+ }
315
+ },
316
+ {
317
+ "name": "fields",
318
+ "in": "query",
319
+ "required": false,
320
+ "schema": {
321
+ "type": "string",
322
+ "description": "A JSON array of the fields to answer"
323
+ }
324
+ }
325
+ ],
326
+ "responses": {
327
+ "200": {
328
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
329
+ "content": {
330
+ "application/json": {
331
+ "schema": {
332
+ "type": "object",
333
+ "properties": {
334
+ "code": {
335
+ "type": "integer"
336
+ },
337
+ "message": {
338
+ "type": "string"
339
+ },
340
+ "request_id": {
341
+ "type": "string"
342
+ },
343
+ "data": {
344
+ "type": "object",
345
+ "properties": {
346
+ "display_name": {
347
+ "type": "string"
348
+ },
349
+ "profile_image": {
350
+ "type": "string"
351
+ },
352
+ "username": {
353
+ "type": "string"
354
+ },
355
+ "profile_deep_link": {
356
+ "type": "string"
357
+ },
358
+ "bio_description": {
359
+ "type": "string"
360
+ },
361
+ "is_verified": {
362
+ "type": "boolean"
363
+ },
364
+ "followers_count": {
365
+ "type": "integer"
366
+ },
367
+ "following_count": {
368
+ "type": "integer"
369
+ },
370
+ "total_likes": {
371
+ "type": "integer"
372
+ },
373
+ "videos_count": {
374
+ "type": "integer"
375
+ }
376
+ }
377
+ }
378
+ }
379
+ }
380
+ }
381
+ }
382
+ }
383
+ }
384
+ }
385
+ },
386
+ "/open_api/v1.3/business/video/list/": {
387
+ "get": {
388
+ "operationId": "businessVideoList",
389
+ "summary": "Get post data of a TikTok account",
390
+ "externalDocs": {
391
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1762228421622786&language=ENGLISH"
392
+ },
393
+ "parameters": [
394
+ {
395
+ "name": "Access-Token",
396
+ "in": "header",
397
+ "required": true,
398
+ "schema": {
399
+ "type": "string",
400
+ "description": "Access token authorized by TikTok creators"
401
+ }
402
+ },
403
+ {
404
+ "name": "business_id",
405
+ "in": "query",
406
+ "required": true,
407
+ "schema": {
408
+ "type": "string",
409
+ "description": "The TikTok account's open_id"
410
+ }
411
+ },
412
+ {
413
+ "name": "fields",
414
+ "in": "query",
415
+ "required": false,
416
+ "schema": {
417
+ "type": "string",
418
+ "description": "A JSON array of the fields to answer"
419
+ }
420
+ },
421
+ {
422
+ "name": "cursor",
423
+ "in": "query",
424
+ "schema": {
425
+ "type": "integer"
426
+ }
427
+ },
428
+ {
429
+ "name": "max_count",
430
+ "in": "query",
431
+ "schema": {
432
+ "type": "integer"
433
+ }
434
+ }
435
+ ],
436
+ "responses": {
437
+ "200": {
438
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
439
+ "content": {
440
+ "application/json": {
441
+ "schema": {
442
+ "type": "object",
443
+ "properties": {
444
+ "code": {
445
+ "type": "integer"
446
+ },
447
+ "message": {
448
+ "type": "string"
449
+ },
450
+ "request_id": {
451
+ "type": "string"
452
+ },
453
+ "data": {
454
+ "type": "object",
455
+ "properties": {
456
+ "videos": {
457
+ "type": "array",
458
+ "items": {
459
+ "type": "object",
460
+ "properties": {
461
+ "item_id": {
462
+ "type": "string"
463
+ },
464
+ "create_time": {
465
+ "type": "integer"
466
+ },
467
+ "thumbnail_url": {
468
+ "type": "string"
469
+ },
470
+ "share_url": {
471
+ "type": "string"
472
+ },
473
+ "embed_url": {
474
+ "type": "string"
475
+ },
476
+ "caption": {
477
+ "type": "string"
478
+ },
479
+ "video_duration": {
480
+ "type": "number"
481
+ },
482
+ "likes": {
483
+ "type": "integer"
484
+ },
485
+ "comments": {
486
+ "type": "integer"
487
+ },
488
+ "shares": {
489
+ "type": "integer"
490
+ },
491
+ "video_views": {
492
+ "type": "integer"
493
+ }
494
+ }
495
+ }
496
+ },
497
+ "cursor": {
498
+ "type": "integer"
499
+ },
500
+ "has_more": {
501
+ "type": "boolean"
502
+ }
503
+ }
504
+ }
505
+ }
506
+ }
507
+ }
508
+ }
509
+ }
510
+ }
511
+ }
512
+ },
513
+ "/open_api/v1.3/business/video/publish/": {
514
+ "post": {
515
+ "operationId": "businessVideoPublish",
516
+ "summary": "Publish a public video post to an owned account",
517
+ "externalDocs": {
518
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1762228496095234&language=ENGLISH"
519
+ },
520
+ "parameters": [
521
+ {
522
+ "name": "Access-Token",
523
+ "in": "header",
524
+ "required": true,
525
+ "schema": {
526
+ "type": "string",
527
+ "description": "Access token authorized by TikTok creators"
528
+ }
529
+ }
530
+ ],
531
+ "requestBody": {
532
+ "required": true,
533
+ "content": {
534
+ "application/json": {
535
+ "schema": {
536
+ "type": "object",
537
+ "properties": {
538
+ "business_id": {
539
+ "type": "string"
540
+ },
541
+ "video_url": {
542
+ "type": "string"
543
+ },
544
+ "custom_thumbnail_url": {
545
+ "type": "string"
546
+ },
547
+ "post_info": {
548
+ "type": "object",
549
+ "properties": {
550
+ "caption": {
551
+ "type": "string"
552
+ },
553
+ "title": {
554
+ "type": "string"
555
+ },
556
+ "privacy_level": {
557
+ "type": "string"
558
+ },
559
+ "is_brand_organic": {
560
+ "type": "boolean"
561
+ },
562
+ "is_branded_content": {
563
+ "type": "boolean"
564
+ },
565
+ "disable_comment": {
566
+ "type": "boolean"
567
+ },
568
+ "disable_duet": {
569
+ "type": "boolean"
570
+ },
571
+ "disable_stitch": {
572
+ "type": "boolean"
573
+ },
574
+ "is_ai_generated": {
575
+ "type": "boolean"
576
+ },
577
+ "upload_to_draft": {
578
+ "type": "boolean"
579
+ },
580
+ "is_draft": {
581
+ "type": "boolean"
582
+ },
583
+ "auto_add_music": {
584
+ "type": "boolean"
585
+ },
586
+ "thumbnail_offset": {
587
+ "type": "integer"
588
+ },
589
+ "location_id": {
590
+ "type": "string"
591
+ },
592
+ "location_name": {
593
+ "type": "string"
594
+ },
595
+ "music_sound_info": {
596
+ "type": "object"
597
+ }
598
+ }
599
+ }
600
+ }
601
+ }
602
+ }
603
+ }
604
+ },
605
+ "responses": {
606
+ "200": {
607
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
608
+ "content": {
609
+ "application/json": {
610
+ "schema": {
611
+ "type": "object",
612
+ "properties": {
613
+ "code": {
614
+ "type": "integer"
615
+ },
616
+ "message": {
617
+ "type": "string"
618
+ },
619
+ "request_id": {
620
+ "type": "string"
621
+ },
622
+ "data": {
623
+ "type": "object",
624
+ "properties": {
625
+ "share_id": {
626
+ "type": "string"
627
+ }
628
+ }
629
+ }
630
+ }
631
+ }
632
+ }
633
+ }
634
+ }
635
+ }
636
+ }
637
+ },
638
+ "/open_api/v1.3/business/photo/publish/": {
639
+ "post": {
640
+ "operationId": "businessPhotoPublish",
641
+ "summary": "Publish a photo post to an owned account",
642
+ "externalDocs": {
643
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1803630424390658&language=ENGLISH"
644
+ },
645
+ "parameters": [
646
+ {
647
+ "name": "Access-Token",
648
+ "in": "header",
649
+ "required": true,
650
+ "schema": {
651
+ "type": "string",
652
+ "description": "Access token authorized by TikTok creators"
653
+ }
654
+ }
655
+ ],
656
+ "requestBody": {
657
+ "required": true,
658
+ "content": {
659
+ "application/json": {
660
+ "schema": {
661
+ "type": "object",
662
+ "properties": {
663
+ "business_id": {
664
+ "type": "string"
665
+ },
666
+ "photo_images": {
667
+ "type": "array",
668
+ "items": {
669
+ "type": "string"
670
+ },
671
+ "maxItems": 35
672
+ },
673
+ "photo_cover_index": {
674
+ "type": "integer"
675
+ },
676
+ "post_info": {
677
+ "type": "object",
678
+ "properties": {
679
+ "caption": {
680
+ "type": "string"
681
+ },
682
+ "title": {
683
+ "type": "string"
684
+ },
685
+ "privacy_level": {
686
+ "type": "string"
687
+ },
688
+ "is_brand_organic": {
689
+ "type": "boolean"
690
+ },
691
+ "is_branded_content": {
692
+ "type": "boolean"
693
+ },
694
+ "disable_comment": {
695
+ "type": "boolean"
696
+ },
697
+ "disable_duet": {
698
+ "type": "boolean"
699
+ },
700
+ "disable_stitch": {
701
+ "type": "boolean"
702
+ },
703
+ "is_ai_generated": {
704
+ "type": "boolean"
705
+ },
706
+ "upload_to_draft": {
707
+ "type": "boolean"
708
+ },
709
+ "is_draft": {
710
+ "type": "boolean"
711
+ },
712
+ "auto_add_music": {
713
+ "type": "boolean"
714
+ },
715
+ "thumbnail_offset": {
716
+ "type": "integer"
717
+ },
718
+ "location_id": {
719
+ "type": "string"
720
+ },
721
+ "location_name": {
722
+ "type": "string"
723
+ },
724
+ "music_sound_info": {
725
+ "type": "object"
726
+ }
727
+ }
728
+ }
729
+ }
730
+ }
731
+ }
732
+ }
733
+ },
734
+ "responses": {
735
+ "200": {
736
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
737
+ "content": {
738
+ "application/json": {
739
+ "schema": {
740
+ "type": "object",
741
+ "properties": {
742
+ "code": {
743
+ "type": "integer"
744
+ },
745
+ "message": {
746
+ "type": "string"
747
+ },
748
+ "request_id": {
749
+ "type": "string"
750
+ },
751
+ "data": {
752
+ "type": "object",
753
+ "properties": {
754
+ "share_id": {
755
+ "type": "string"
756
+ }
757
+ }
758
+ }
759
+ }
760
+ }
761
+ }
762
+ }
763
+ }
764
+ }
765
+ }
766
+ },
767
+ "/open_api/v1.3/business/publish/status/": {
768
+ "get": {
769
+ "operationId": "businessPublishStatus",
770
+ "summary": "Get the publishing status of a TikTok post",
771
+ "externalDocs": {
772
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1816387106635778&language=ENGLISH"
773
+ },
774
+ "parameters": [
775
+ {
776
+ "name": "Access-Token",
777
+ "in": "header",
778
+ "required": true,
779
+ "schema": {
780
+ "type": "string",
781
+ "description": "Access token authorized by TikTok creators"
782
+ }
783
+ },
784
+ {
785
+ "name": "business_id",
786
+ "in": "query",
787
+ "required": true,
788
+ "schema": {
789
+ "type": "string",
790
+ "description": "The TikTok account's open_id"
791
+ }
792
+ },
793
+ {
794
+ "name": "publish_id",
795
+ "in": "query",
796
+ "required": true,
797
+ "schema": {
798
+ "type": "string"
799
+ }
800
+ }
801
+ ],
802
+ "responses": {
803
+ "200": {
804
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
805
+ "content": {
806
+ "application/json": {
807
+ "schema": {
808
+ "type": "object",
809
+ "properties": {
810
+ "code": {
811
+ "type": "integer"
812
+ },
813
+ "message": {
814
+ "type": "string"
815
+ },
816
+ "request_id": {
817
+ "type": "string"
818
+ },
819
+ "data": {
820
+ "type": "object",
821
+ "properties": {
822
+ "status": {
823
+ "type": "string",
824
+ "enum": [
825
+ "PROCESSING_DOWNLOAD",
826
+ "PUBLISH_COMPLETE",
827
+ "FAILED",
828
+ "SEND_TO_USER_INBOX"
829
+ ]
830
+ },
831
+ "post_ids": {
832
+ "type": "array",
833
+ "items": {
834
+ "type": "string"
835
+ }
836
+ },
837
+ "reason": {
838
+ "type": "string"
839
+ }
840
+ }
841
+ }
842
+ }
843
+ }
844
+ }
845
+ }
846
+ }
847
+ }
848
+ }
849
+ },
850
+ "/open_api/v1.3/business/publish/location/": {
851
+ "get": {
852
+ "operationId": "businessPublishLocation",
853
+ "summary": "Get the location tags for a TikTok account",
854
+ "externalDocs": {
855
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1870580030749698&language=ENGLISH"
856
+ },
857
+ "parameters": [
858
+ {
859
+ "name": "Access-Token",
860
+ "in": "header",
861
+ "required": true,
862
+ "schema": {
863
+ "type": "string",
864
+ "description": "Access token authorized by TikTok creators"
865
+ }
866
+ },
867
+ {
868
+ "name": "business_id",
869
+ "in": "query",
870
+ "required": true,
871
+ "schema": {
872
+ "type": "string",
873
+ "description": "The TikTok account's open_id"
874
+ }
875
+ },
876
+ {
877
+ "name": "search_query",
878
+ "in": "query",
879
+ "required": true,
880
+ "schema": {
881
+ "type": "string"
882
+ }
883
+ }
884
+ ],
885
+ "responses": {
886
+ "200": {
887
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
888
+ "content": {
889
+ "application/json": {
890
+ "schema": {
891
+ "type": "object",
892
+ "properties": {
893
+ "code": {
894
+ "type": "integer"
895
+ },
896
+ "message": {
897
+ "type": "string"
898
+ },
899
+ "request_id": {
900
+ "type": "string"
901
+ },
902
+ "data": {
903
+ "type": "object",
904
+ "properties": {
905
+ "locations": {
906
+ "type": "array",
907
+ "items": {
908
+ "type": "object",
909
+ "properties": {
910
+ "location_id": {
911
+ "type": "string"
912
+ },
913
+ "location_name": {
914
+ "type": "string"
915
+ },
916
+ "location_address": {
917
+ "type": "string"
918
+ }
919
+ }
920
+ }
921
+ }
922
+ }
923
+ }
924
+ }
925
+ }
926
+ }
927
+ }
928
+ }
929
+ }
930
+ }
931
+ },
932
+ "/open_api/v1.3/discovery/cml/trending_list/": {
933
+ "get": {
934
+ "operationId": "discoveryCmlTrendingList",
935
+ "summary": "Get popular tracks from the Commercial Music Library",
936
+ "externalDocs": {
937
+ "url": "https://business-api.tiktok.com/gateway/api/doc/client/node/get/v2/?identify_key=c0138ffadd90a955c1f0670a56fe348d1d40680b3c89461e09f78ed26785164b&doc_id=1825119063013505&language=ENGLISH"
938
+ },
939
+ "parameters": [
940
+ {
941
+ "name": "Access-Token",
942
+ "in": "header",
943
+ "required": true,
944
+ "schema": {
945
+ "type": "string",
946
+ "description": "Access token authorized by TikTok creators"
947
+ }
948
+ },
949
+ {
950
+ "name": "business_id",
951
+ "in": "query",
952
+ "required": true,
953
+ "schema": {
954
+ "type": "string",
955
+ "description": "The TikTok account's open_id"
956
+ }
957
+ },
958
+ {
959
+ "name": "genre",
960
+ "in": "query",
961
+ "schema": {
962
+ "type": "string"
963
+ }
964
+ }
965
+ ],
966
+ "responses": {
967
+ "200": {
968
+ "description": "{code, message, request_id, data}: code 0 on success; a refusal is a non-zero code, answered HTTP 200",
969
+ "content": {
970
+ "application/json": {
971
+ "schema": {
972
+ "type": "object",
973
+ "properties": {
974
+ "code": {
975
+ "type": "integer"
976
+ },
977
+ "message": {
978
+ "type": "string"
979
+ },
980
+ "request_id": {
981
+ "type": "string"
982
+ },
983
+ "data": {
984
+ "type": "object",
985
+ "properties": {
986
+ "list": {
987
+ "type": "array",
988
+ "items": {
989
+ "type": "object",
990
+ "properties": {
991
+ "commercial_music_id": {
992
+ "type": "string"
993
+ },
994
+ "commercial_music_name": {
995
+ "type": "string"
996
+ },
997
+ "artist": {
998
+ "type": "string"
999
+ },
1000
+ "thumbnail_url": {
1001
+ "type": "string"
1002
+ },
1003
+ "duration": {
1004
+ "type": "integer"
1005
+ },
1006
+ "preview_url": {
1007
+ "type": "string"
1008
+ },
1009
+ "full_duration_song_clip": {
1010
+ "type": "object",
1011
+ "properties": {
1012
+ "song_clip_id": {
1013
+ "type": "string"
1014
+ }
1015
+ }
1016
+ },
1017
+ "trending_song_clip": {
1018
+ "type": "object",
1019
+ "properties": {
1020
+ "song_clip_id": {
1021
+ "type": "string"
1022
+ },
1023
+ "duration": {
1024
+ "type": "integer"
1025
+ },
1026
+ "preview_url": {
1027
+ "type": "string"
1028
+ }
1029
+ }
1030
+ }
1031
+ }
1032
+ }
1033
+ }
1034
+ }
1035
+ }
1036
+ }
1037
+ }
1038
+ }
1039
+ }
1040
+ }
1041
+ }
1042
+ }
1043
+ }
1044
+ }
1045
+ }