influship 0.2.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 (426) hide show
  1. package/CHANGELOG.md +62 -0
  2. package/LICENSE +201 -0
  3. package/README.md +372 -0
  4. package/api-promise.d.mts +2 -0
  5. package/api-promise.d.mts.map +1 -0
  6. package/api-promise.d.ts +2 -0
  7. package/api-promise.d.ts.map +1 -0
  8. package/api-promise.js +6 -0
  9. package/api-promise.js.map +1 -0
  10. package/api-promise.mjs +2 -0
  11. package/api-promise.mjs.map +1 -0
  12. package/client.d.mts +198 -0
  13. package/client.d.mts.map +1 -0
  14. package/client.d.ts +198 -0
  15. package/client.d.ts.map +1 -0
  16. package/client.js +469 -0
  17. package/client.js.map +1 -0
  18. package/client.mjs +465 -0
  19. package/client.mjs.map +1 -0
  20. package/core/api-promise.d.mts +46 -0
  21. package/core/api-promise.d.mts.map +1 -0
  22. package/core/api-promise.d.ts +46 -0
  23. package/core/api-promise.d.ts.map +1 -0
  24. package/core/api-promise.js +74 -0
  25. package/core/api-promise.js.map +1 -0
  26. package/core/api-promise.mjs +70 -0
  27. package/core/api-promise.mjs.map +1 -0
  28. package/core/error.d.mts +46 -0
  29. package/core/error.d.mts.map +1 -0
  30. package/core/error.d.ts +46 -0
  31. package/core/error.d.ts.map +1 -0
  32. package/core/error.js +113 -0
  33. package/core/error.js.map +1 -0
  34. package/core/error.mjs +97 -0
  35. package/core/error.mjs.map +1 -0
  36. package/core/resource.d.mts +6 -0
  37. package/core/resource.d.mts.map +1 -0
  38. package/core/resource.d.ts +6 -0
  39. package/core/resource.d.ts.map +1 -0
  40. package/core/resource.js +11 -0
  41. package/core/resource.js.map +1 -0
  42. package/core/resource.mjs +7 -0
  43. package/core/resource.mjs.map +1 -0
  44. package/core/uploads.d.mts +3 -0
  45. package/core/uploads.d.mts.map +1 -0
  46. package/core/uploads.d.ts +3 -0
  47. package/core/uploads.d.ts.map +1 -0
  48. package/core/uploads.js +6 -0
  49. package/core/uploads.js.map +1 -0
  50. package/core/uploads.mjs +2 -0
  51. package/core/uploads.mjs.map +1 -0
  52. package/error.d.mts +2 -0
  53. package/error.d.mts.map +1 -0
  54. package/error.d.ts +2 -0
  55. package/error.d.ts.map +1 -0
  56. package/error.js +6 -0
  57. package/error.js.map +1 -0
  58. package/error.mjs +2 -0
  59. package/error.mjs.map +1 -0
  60. package/index.d.mts +6 -0
  61. package/index.d.mts.map +1 -0
  62. package/index.d.ts +6 -0
  63. package/index.d.ts.map +1 -0
  64. package/index.js +30 -0
  65. package/index.js.map +1 -0
  66. package/index.mjs +7 -0
  67. package/index.mjs.map +1 -0
  68. package/internal/builtin-types.d.mts +73 -0
  69. package/internal/builtin-types.d.mts.map +1 -0
  70. package/internal/builtin-types.d.ts +73 -0
  71. package/internal/builtin-types.d.ts.map +1 -0
  72. package/internal/builtin-types.js +4 -0
  73. package/internal/builtin-types.js.map +1 -0
  74. package/internal/builtin-types.mjs +3 -0
  75. package/internal/builtin-types.mjs.map +1 -0
  76. package/internal/detect-platform.d.mts +15 -0
  77. package/internal/detect-platform.d.mts.map +1 -0
  78. package/internal/detect-platform.d.ts +15 -0
  79. package/internal/detect-platform.d.ts.map +1 -0
  80. package/internal/detect-platform.js +162 -0
  81. package/internal/detect-platform.js.map +1 -0
  82. package/internal/detect-platform.mjs +157 -0
  83. package/internal/detect-platform.mjs.map +1 -0
  84. package/internal/errors.d.mts +3 -0
  85. package/internal/errors.d.mts.map +1 -0
  86. package/internal/errors.d.ts +3 -0
  87. package/internal/errors.d.ts.map +1 -0
  88. package/internal/errors.js +41 -0
  89. package/internal/errors.js.map +1 -0
  90. package/internal/errors.mjs +36 -0
  91. package/internal/errors.mjs.map +1 -0
  92. package/internal/headers.d.mts +20 -0
  93. package/internal/headers.d.mts.map +1 -0
  94. package/internal/headers.d.ts +20 -0
  95. package/internal/headers.d.ts.map +1 -0
  96. package/internal/headers.js +79 -0
  97. package/internal/headers.js.map +1 -0
  98. package/internal/headers.mjs +74 -0
  99. package/internal/headers.mjs.map +1 -0
  100. package/internal/parse.d.mts +12 -0
  101. package/internal/parse.d.mts.map +1 -0
  102. package/internal/parse.d.ts +12 -0
  103. package/internal/parse.d.ts.map +1 -0
  104. package/internal/parse.js +35 -0
  105. package/internal/parse.js.map +1 -0
  106. package/internal/parse.mjs +32 -0
  107. package/internal/parse.mjs.map +1 -0
  108. package/internal/qs/formats.d.mts +7 -0
  109. package/internal/qs/formats.d.mts.map +1 -0
  110. package/internal/qs/formats.d.ts +7 -0
  111. package/internal/qs/formats.d.ts.map +1 -0
  112. package/internal/qs/formats.js +13 -0
  113. package/internal/qs/formats.js.map +1 -0
  114. package/internal/qs/formats.mjs +9 -0
  115. package/internal/qs/formats.mjs.map +1 -0
  116. package/internal/qs/index.d.mts +10 -0
  117. package/internal/qs/index.d.mts.map +1 -0
  118. package/internal/qs/index.d.ts +10 -0
  119. package/internal/qs/index.d.ts.map +1 -0
  120. package/internal/qs/index.js +14 -0
  121. package/internal/qs/index.js.map +1 -0
  122. package/internal/qs/index.mjs +10 -0
  123. package/internal/qs/index.mjs.map +1 -0
  124. package/internal/qs/stringify.d.mts +3 -0
  125. package/internal/qs/stringify.d.mts.map +1 -0
  126. package/internal/qs/stringify.d.ts +3 -0
  127. package/internal/qs/stringify.d.ts.map +1 -0
  128. package/internal/qs/stringify.js +277 -0
  129. package/internal/qs/stringify.js.map +1 -0
  130. package/internal/qs/stringify.mjs +274 -0
  131. package/internal/qs/stringify.mjs.map +1 -0
  132. package/internal/qs/types.d.mts +57 -0
  133. package/internal/qs/types.d.mts.map +1 -0
  134. package/internal/qs/types.d.ts +57 -0
  135. package/internal/qs/types.d.ts.map +1 -0
  136. package/internal/qs/types.js +3 -0
  137. package/internal/qs/types.js.map +1 -0
  138. package/internal/qs/types.mjs +2 -0
  139. package/internal/qs/types.mjs.map +1 -0
  140. package/internal/qs/utils.d.mts +15 -0
  141. package/internal/qs/utils.d.mts.map +1 -0
  142. package/internal/qs/utils.d.ts +15 -0
  143. package/internal/qs/utils.d.ts.map +1 -0
  144. package/internal/qs/utils.js +230 -0
  145. package/internal/qs/utils.js.map +1 -0
  146. package/internal/qs/utils.mjs +217 -0
  147. package/internal/qs/utils.mjs.map +1 -0
  148. package/internal/request-options.d.mts +75 -0
  149. package/internal/request-options.d.mts.map +1 -0
  150. package/internal/request-options.d.ts +75 -0
  151. package/internal/request-options.d.ts.map +1 -0
  152. package/internal/request-options.js +14 -0
  153. package/internal/request-options.js.map +1 -0
  154. package/internal/request-options.mjs +10 -0
  155. package/internal/request-options.mjs.map +1 -0
  156. package/internal/shim-types.d.mts +17 -0
  157. package/internal/shim-types.d.mts.map +1 -0
  158. package/internal/shim-types.d.ts +17 -0
  159. package/internal/shim-types.d.ts.map +1 -0
  160. package/internal/shim-types.js +4 -0
  161. package/internal/shim-types.js.map +1 -0
  162. package/internal/shim-types.mjs +3 -0
  163. package/internal/shim-types.mjs.map +1 -0
  164. package/internal/shims.d.mts +20 -0
  165. package/internal/shims.d.mts.map +1 -0
  166. package/internal/shims.d.ts +20 -0
  167. package/internal/shims.d.ts.map +1 -0
  168. package/internal/shims.js +92 -0
  169. package/internal/shims.js.map +1 -0
  170. package/internal/shims.mjs +85 -0
  171. package/internal/shims.mjs.map +1 -0
  172. package/internal/to-file.d.mts +45 -0
  173. package/internal/to-file.d.mts.map +1 -0
  174. package/internal/to-file.d.ts +45 -0
  175. package/internal/to-file.d.ts.map +1 -0
  176. package/internal/to-file.js +91 -0
  177. package/internal/to-file.js.map +1 -0
  178. package/internal/to-file.mjs +88 -0
  179. package/internal/to-file.mjs.map +1 -0
  180. package/internal/tslib.js +81 -0
  181. package/internal/tslib.mjs +17 -0
  182. package/internal/types.d.mts +69 -0
  183. package/internal/types.d.mts.map +1 -0
  184. package/internal/types.d.ts +69 -0
  185. package/internal/types.d.ts.map +1 -0
  186. package/internal/types.js +4 -0
  187. package/internal/types.js.map +1 -0
  188. package/internal/types.mjs +3 -0
  189. package/internal/types.mjs.map +1 -0
  190. package/internal/uploads.d.mts +42 -0
  191. package/internal/uploads.d.mts.map +1 -0
  192. package/internal/uploads.d.ts +42 -0
  193. package/internal/uploads.d.ts.map +1 -0
  194. package/internal/uploads.js +141 -0
  195. package/internal/uploads.js.map +1 -0
  196. package/internal/uploads.mjs +131 -0
  197. package/internal/uploads.mjs.map +1 -0
  198. package/internal/utils/base64.d.mts +3 -0
  199. package/internal/utils/base64.d.mts.map +1 -0
  200. package/internal/utils/base64.d.ts +3 -0
  201. package/internal/utils/base64.d.ts.map +1 -0
  202. package/internal/utils/base64.js +38 -0
  203. package/internal/utils/base64.js.map +1 -0
  204. package/internal/utils/base64.mjs +33 -0
  205. package/internal/utils/base64.mjs.map +1 -0
  206. package/internal/utils/bytes.d.mts +4 -0
  207. package/internal/utils/bytes.d.mts.map +1 -0
  208. package/internal/utils/bytes.d.ts +4 -0
  209. package/internal/utils/bytes.d.ts.map +1 -0
  210. package/internal/utils/bytes.js +31 -0
  211. package/internal/utils/bytes.js.map +1 -0
  212. package/internal/utils/bytes.mjs +26 -0
  213. package/internal/utils/bytes.mjs.map +1 -0
  214. package/internal/utils/env.d.mts +9 -0
  215. package/internal/utils/env.d.mts.map +1 -0
  216. package/internal/utils/env.d.ts +9 -0
  217. package/internal/utils/env.d.ts.map +1 -0
  218. package/internal/utils/env.js +22 -0
  219. package/internal/utils/env.js.map +1 -0
  220. package/internal/utils/env.mjs +18 -0
  221. package/internal/utils/env.mjs.map +1 -0
  222. package/internal/utils/log.d.mts +37 -0
  223. package/internal/utils/log.d.mts.map +1 -0
  224. package/internal/utils/log.d.ts +37 -0
  225. package/internal/utils/log.d.ts.map +1 -0
  226. package/internal/utils/log.js +86 -0
  227. package/internal/utils/log.js.map +1 -0
  228. package/internal/utils/log.mjs +80 -0
  229. package/internal/utils/log.mjs.map +1 -0
  230. package/internal/utils/path.d.mts +15 -0
  231. package/internal/utils/path.d.mts.map +1 -0
  232. package/internal/utils/path.d.ts +15 -0
  233. package/internal/utils/path.d.ts.map +1 -0
  234. package/internal/utils/path.js +79 -0
  235. package/internal/utils/path.js.map +1 -0
  236. package/internal/utils/path.mjs +74 -0
  237. package/internal/utils/path.mjs.map +1 -0
  238. package/internal/utils/sleep.d.mts +2 -0
  239. package/internal/utils/sleep.d.mts.map +1 -0
  240. package/internal/utils/sleep.d.ts +2 -0
  241. package/internal/utils/sleep.d.ts.map +1 -0
  242. package/internal/utils/sleep.js +7 -0
  243. package/internal/utils/sleep.js.map +1 -0
  244. package/internal/utils/sleep.mjs +3 -0
  245. package/internal/utils/sleep.mjs.map +1 -0
  246. package/internal/utils/uuid.d.mts +5 -0
  247. package/internal/utils/uuid.d.mts.map +1 -0
  248. package/internal/utils/uuid.d.ts +5 -0
  249. package/internal/utils/uuid.d.ts.map +1 -0
  250. package/internal/utils/uuid.js +19 -0
  251. package/internal/utils/uuid.js.map +1 -0
  252. package/internal/utils/uuid.mjs +15 -0
  253. package/internal/utils/uuid.mjs.map +1 -0
  254. package/internal/utils/values.d.mts +18 -0
  255. package/internal/utils/values.d.mts.map +1 -0
  256. package/internal/utils/values.d.ts +18 -0
  257. package/internal/utils/values.d.ts.map +1 -0
  258. package/internal/utils/values.js +112 -0
  259. package/internal/utils/values.js.map +1 -0
  260. package/internal/utils/values.mjs +94 -0
  261. package/internal/utils/values.mjs.map +1 -0
  262. package/internal/utils.d.mts +7 -0
  263. package/internal/utils.d.mts.map +1 -0
  264. package/internal/utils.d.ts +7 -0
  265. package/internal/utils.d.ts.map +1 -0
  266. package/internal/utils.js +11 -0
  267. package/internal/utils.js.map +1 -0
  268. package/internal/utils.mjs +8 -0
  269. package/internal/utils.mjs.map +1 -0
  270. package/package.json +138 -0
  271. package/resource.d.mts +2 -0
  272. package/resource.d.mts.map +1 -0
  273. package/resource.d.ts +2 -0
  274. package/resource.d.ts.map +1 -0
  275. package/resource.js +6 -0
  276. package/resource.js.map +1 -0
  277. package/resource.mjs +2 -0
  278. package/resource.mjs.map +1 -0
  279. package/resources/brand-safety.d.mts +234 -0
  280. package/resources/brand-safety.d.mts.map +1 -0
  281. package/resources/brand-safety.d.ts +234 -0
  282. package/resources/brand-safety.d.ts.map +1 -0
  283. package/resources/brand-safety.js +75 -0
  284. package/resources/brand-safety.js.map +1 -0
  285. package/resources/brand-safety.mjs +71 -0
  286. package/resources/brand-safety.mjs.map +1 -0
  287. package/resources/creators.d.mts +364 -0
  288. package/resources/creators.d.mts.map +1 -0
  289. package/resources/creators.d.ts +364 -0
  290. package/resources/creators.d.ts.map +1 -0
  291. package/resources/creators.js +119 -0
  292. package/resources/creators.js.map +1 -0
  293. package/resources/creators.mjs +115 -0
  294. package/resources/creators.mjs.map +1 -0
  295. package/resources/health.d.mts +17 -0
  296. package/resources/health.d.mts.map +1 -0
  297. package/resources/health.d.ts +17 -0
  298. package/resources/health.d.ts.map +1 -0
  299. package/resources/health.js +15 -0
  300. package/resources/health.js.map +1 -0
  301. package/resources/health.mjs +11 -0
  302. package/resources/health.mjs.map +1 -0
  303. package/resources/index.d.mts +9 -0
  304. package/resources/index.d.mts.map +1 -0
  305. package/resources/index.d.ts +9 -0
  306. package/resources/index.d.ts.map +1 -0
  307. package/resources/index.js +21 -0
  308. package/resources/index.js.map +1 -0
  309. package/resources/index.mjs +10 -0
  310. package/resources/index.mjs.map +1 -0
  311. package/resources/lookalike.d.mts +142 -0
  312. package/resources/lookalike.d.mts.map +1 -0
  313. package/resources/lookalike.d.ts +142 -0
  314. package/resources/lookalike.d.ts.map +1 -0
  315. package/resources/lookalike.js +28 -0
  316. package/resources/lookalike.js.map +1 -0
  317. package/resources/lookalike.mjs +24 -0
  318. package/resources/lookalike.mjs.map +1 -0
  319. package/resources/match.d.mts +90 -0
  320. package/resources/match.d.mts.map +1 -0
  321. package/resources/match.d.ts +90 -0
  322. package/resources/match.d.ts.map +1 -0
  323. package/resources/match.js +22 -0
  324. package/resources/match.js.map +1 -0
  325. package/resources/match.mjs +18 -0
  326. package/resources/match.mjs.map +1 -0
  327. package/resources/posts.d.mts +284 -0
  328. package/resources/posts.d.mts.map +1 -0
  329. package/resources/posts.d.ts +284 -0
  330. package/resources/posts.d.ts.map +1 -0
  331. package/resources/posts.js +55 -0
  332. package/resources/posts.js.map +1 -0
  333. package/resources/posts.mjs +51 -0
  334. package/resources/posts.mjs.map +1 -0
  335. package/resources/profiles.d.mts +99 -0
  336. package/resources/profiles.d.mts.map +1 -0
  337. package/resources/profiles.d.ts +99 -0
  338. package/resources/profiles.d.ts.map +1 -0
  339. package/resources/profiles.js +69 -0
  340. package/resources/profiles.js.map +1 -0
  341. package/resources/profiles.mjs +65 -0
  342. package/resources/profiles.mjs.map +1 -0
  343. package/resources/search.d.mts +189 -0
  344. package/resources/search.d.mts.map +1 -0
  345. package/resources/search.d.ts +189 -0
  346. package/resources/search.d.ts.map +1 -0
  347. package/resources/search.js +33 -0
  348. package/resources/search.js.map +1 -0
  349. package/resources/search.mjs +29 -0
  350. package/resources/search.mjs.map +1 -0
  351. package/resources.d.mts +2 -0
  352. package/resources.d.mts.map +1 -0
  353. package/resources.d.ts +2 -0
  354. package/resources.d.ts.map +1 -0
  355. package/resources.js +5 -0
  356. package/resources.js.map +1 -0
  357. package/resources.mjs +2 -0
  358. package/resources.mjs.map +1 -0
  359. package/src/api-promise.ts +2 -0
  360. package/src/client.ts +845 -0
  361. package/src/core/README.md +3 -0
  362. package/src/core/api-promise.ts +92 -0
  363. package/src/core/error.ts +130 -0
  364. package/src/core/resource.ts +11 -0
  365. package/src/core/uploads.ts +2 -0
  366. package/src/error.ts +2 -0
  367. package/src/index.ts +22 -0
  368. package/src/internal/README.md +3 -0
  369. package/src/internal/builtin-types.ts +93 -0
  370. package/src/internal/detect-platform.ts +196 -0
  371. package/src/internal/errors.ts +33 -0
  372. package/src/internal/headers.ts +97 -0
  373. package/src/internal/parse.ts +50 -0
  374. package/src/internal/qs/LICENSE.md +13 -0
  375. package/src/internal/qs/README.md +3 -0
  376. package/src/internal/qs/formats.ts +10 -0
  377. package/src/internal/qs/index.ts +13 -0
  378. package/src/internal/qs/stringify.ts +385 -0
  379. package/src/internal/qs/types.ts +71 -0
  380. package/src/internal/qs/utils.ts +265 -0
  381. package/src/internal/request-options.ts +91 -0
  382. package/src/internal/shim-types.ts +26 -0
  383. package/src/internal/shims.ts +107 -0
  384. package/src/internal/to-file.ts +154 -0
  385. package/src/internal/types.ts +95 -0
  386. package/src/internal/uploads.ts +187 -0
  387. package/src/internal/utils/base64.ts +40 -0
  388. package/src/internal/utils/bytes.ts +32 -0
  389. package/src/internal/utils/env.ts +18 -0
  390. package/src/internal/utils/log.ts +127 -0
  391. package/src/internal/utils/path.ts +88 -0
  392. package/src/internal/utils/sleep.ts +3 -0
  393. package/src/internal/utils/uuid.ts +17 -0
  394. package/src/internal/utils/values.ts +105 -0
  395. package/src/internal/utils.ts +8 -0
  396. package/src/lib/.keep +4 -0
  397. package/src/resource.ts +2 -0
  398. package/src/resources/brand-safety.ts +304 -0
  399. package/src/resources/creators.ts +450 -0
  400. package/src/resources/health.ts +24 -0
  401. package/src/resources/index.ts +62 -0
  402. package/src/resources/lookalike.ts +186 -0
  403. package/src/resources/match.ts +115 -0
  404. package/src/resources/posts.ts +347 -0
  405. package/src/resources/profiles.ts +114 -0
  406. package/src/resources/search.ts +234 -0
  407. package/src/resources.ts +1 -0
  408. package/src/tsconfig.json +11 -0
  409. package/src/uploads.ts +2 -0
  410. package/src/version.ts +1 -0
  411. package/uploads.d.mts +2 -0
  412. package/uploads.d.mts.map +1 -0
  413. package/uploads.d.ts +2 -0
  414. package/uploads.d.ts.map +1 -0
  415. package/uploads.js +6 -0
  416. package/uploads.js.map +1 -0
  417. package/uploads.mjs +2 -0
  418. package/uploads.mjs.map +1 -0
  419. package/version.d.mts +2 -0
  420. package/version.d.mts.map +1 -0
  421. package/version.d.ts +2 -0
  422. package/version.d.ts.map +1 -0
  423. package/version.js +5 -0
  424. package/version.js.map +1 -0
  425. package/version.mjs +2 -0
  426. package/version.mjs.map +1 -0
@@ -0,0 +1,51 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../core/resource.mjs";
3
+ export class Posts extends APIResource {
4
+ /**
5
+ * Analyze a social media post for engagement metrics, content insights, and brand
6
+ * safety.
7
+ *
8
+ * Provide post via URL or post_id+platform. Optionally include AI analysis and/or
9
+ * brand safety features.
10
+ *
11
+ * **Pricing**:
12
+ *
13
+ * - Base: 1.0 credit per post
14
+ * - AI Analysis feature: +0.5 credits (includes summary and transcript)
15
+ * - Brand Safety feature: +0.5 credits (includes rating and risk flags)
16
+ * - **Example**: 1 post with both features = 1.0 + 0.5 + 0.5 = 2.0 credits
17
+ *
18
+ * @example
19
+ * ```ts
20
+ * const postAnalysis = await client.posts.analyze({
21
+ * url: 'https://example.com',
22
+ * });
23
+ * ```
24
+ */
25
+ analyze(body, options) {
26
+ return this._client.post('/v1/posts/analyze', { body, ...options });
27
+ }
28
+ /**
29
+ * Retrieve posts for a specific creator using cursor-based pagination.
30
+ *
31
+ * This endpoint allows you to fetch posts from a creator's social media accounts
32
+ * with optional analysis features and date filtering.
33
+ *
34
+ * **Pricing**:
35
+ *
36
+ * - Base: 0.01 credits per post returned
37
+ * - The more posts you request, the more you pay
38
+ * - Use the `limit` parameter to control costs
39
+ * - **Example**: 25 posts = 0.25 credits
40
+ * - **Example**: 100 posts = 1.0 credit
41
+ *
42
+ * @example
43
+ * ```ts
44
+ * const response = await client.posts.listByCreator();
45
+ * ```
46
+ */
47
+ listByCreator(query = {}, options) {
48
+ return this._client.get('/v1/posts/by-creator', { query, ...options });
49
+ }
50
+ }
51
+ //# sourceMappingURL=posts.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"posts.mjs","sourceRoot":"","sources":["../src/resources/posts.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAKtB,MAAM,OAAO,KAAM,SAAQ,WAAW;IACpC;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,OAAO,CAAC,IAAuB,EAAE,OAAwB;QACvD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,mBAAmB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtE,CAAC;IAED;;;;;;;;;;;;;;;;;;OAkBG;IACH,aAAa,CACX,QAAoD,EAAE,EACtD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,sBAAsB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACzE,CAAC;CACF"}
@@ -0,0 +1,99 @@
1
+ import { APIResource } from "../core/resource.mjs";
2
+ import * as CreatorsAPI from "./creators.mjs";
3
+ import { APIPromise } from "../core/api-promise.mjs";
4
+ import { RequestOptions } from "../internal/request-options.mjs";
5
+ export declare class Profiles extends APIResource {
6
+ /**
7
+ * **DISCOVERY ENDPOINT**: Look up social account data when you know a username and
8
+ * platform.
9
+ *
10
+ * **🎯 When to use this endpoint:**
11
+ *
12
+ * - ✅ You have a username and platform (e.g., @fitness_guru on Instagram)
13
+ * - ✅ You want to discover who a social account belongs to
14
+ * - ✅ You need to look up specific social accounts by username
15
+ * - ✅ You want to get social account metrics for known usernames
16
+ *
17
+ * **❌ When NOT to use this endpoint:**
18
+ *
19
+ * - ❌ You already have a creator UUID (use `/v1/creators/{id}/profiles` instead)
20
+ * - ❌ You want to get all accounts for a creator (use
21
+ * `/v1/creators/{id}/profiles` instead)
22
+ *
23
+ * **📊 Response Format:** Returns `SocialAccountLite` or `SocialAccountDetailed`
24
+ * objects with identical structure to `/v1/creators/{id}/profiles`. Both endpoints
25
+ * return the same data structure for consistency.
26
+ *
27
+ * **🔗 Data Relationships:**
28
+ *
29
+ * - Use the `creator_profile_id` field to fetch creator-level data via
30
+ * `/v1/creators`
31
+ * - Use the `creator_profile_id` to get all social accounts via
32
+ * `/v1/creators/{id}/profiles`
33
+ * - Creator-level data includes: name, bio, avatar, ai_one_line_bio
34
+ * - Social account data includes: follower_count, engagement_rate, verified,
35
+ * platform-specific metrics
36
+ *
37
+ * **🔄 Typical Workflow:**
38
+ *
39
+ * 1. **Discovery**: Call `/v1/profiles` with username+platform → get social
40
+ * account data + creator_profile_id
41
+ * 2. **Creator Data**: Call `/v1/creators` with creator_profile_id → get
42
+ * creator-level data
43
+ * 3. **All Accounts**: Call `/v1/creators/{id}/profiles` with creator_profile_id →
44
+ * get all social accounts for that creator
45
+ *
46
+ * **⚙️ Parameters:**
47
+ *
48
+ * - `mode`: `lite` (default) or `detailed` - controls response detail level
49
+ * - `platforms`: Array of platform names to filter results (e.g.,
50
+ * `["instagram", "tiktok"]`) **Pricing**: 0.01-0.05 credits per profile
51
+ * (lite/detailed mode)
52
+ *
53
+ * @example
54
+ * ```ts
55
+ * const response = await client.profiles.lookup({
56
+ * profiles: [
57
+ * { platform: 'instagram', username: 'fitness_guru' },
58
+ * { platform: 'tiktok', username: 'fitness_guru' },
59
+ * ],
60
+ * });
61
+ * ```
62
+ */
63
+ lookup(body: ProfileLookupParams, options?: RequestOptions): APIPromise<ProfileLookupResponse>;
64
+ }
65
+ export interface CreatorReferenceByHandle {
66
+ /**
67
+ * Social platform where the creator exists
68
+ */
69
+ platform: 'instagram' | 'tiktok';
70
+ /**
71
+ * Username on the platform
72
+ */
73
+ username: string;
74
+ }
75
+ export interface ProfileLookupResponse {
76
+ /**
77
+ * Array of social account objects. The structure depends on the `mode` parameter:
78
+ *
79
+ * - If `mode: "lite"`: Returns SocialAccountLite objects
80
+ * - If `mode: "detailed"`: Returns SocialAccountDetailed objects with additional
81
+ * fields
82
+ */
83
+ profiles?: Array<CreatorsAPI.SocialAccountLite | CreatorsAPI.SocialAccountDetailed>;
84
+ }
85
+ export interface ProfileLookupParams {
86
+ profiles: Array<CreatorReferenceByHandle>;
87
+ /**
88
+ * Response detail level - lite for basic fields, detailed for additional metrics
89
+ */
90
+ mode?: 'lite' | 'detailed';
91
+ /**
92
+ * Filter results to only include these platforms
93
+ */
94
+ platforms?: Array<'instagram' | 'tiktok'>;
95
+ }
96
+ export declare namespace Profiles {
97
+ export { type CreatorReferenceByHandle as CreatorReferenceByHandle, type ProfileLookupResponse as ProfileLookupResponse, type ProfileLookupParams as ProfileLookupParams, };
98
+ }
99
+ //# sourceMappingURL=profiles.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.d.mts","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAwDG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG/F;AAED,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,QAAQ,EAAE,WAAW,GAAG,QAAQ,CAAC;IAEjC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,qBAAqB;IACpC;;;;;;OAMG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,iBAAiB,GAAG,WAAW,CAAC,qBAAqB,CAAC,CAAC;CACrF;AAED,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,KAAK,CAAC,wBAAwB,CAAC,CAAC;IAE1C;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,GAAG,UAAU,CAAC;IAE3B;;OAEG;IACH,SAAS,CAAC,EAAE,KAAK,CAAC,WAAW,GAAG,QAAQ,CAAC,CAAC;CAC3C;AAED,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -0,0 +1,99 @@
1
+ import { APIResource } from "../core/resource.js";
2
+ import * as CreatorsAPI from "./creators.js";
3
+ import { APIPromise } from "../core/api-promise.js";
4
+ import { RequestOptions } from "../internal/request-options.js";
5
+ export declare class Profiles extends APIResource {
6
+ /**
7
+ * **DISCOVERY ENDPOINT**: Look up social account data when you know a username and
8
+ * platform.
9
+ *
10
+ * **🎯 When to use this endpoint:**
11
+ *
12
+ * - ✅ You have a username and platform (e.g., @fitness_guru on Instagram)
13
+ * - ✅ You want to discover who a social account belongs to
14
+ * - ✅ You need to look up specific social accounts by username
15
+ * - ✅ You want to get social account metrics for known usernames
16
+ *
17
+ * **❌ When NOT to use this endpoint:**
18
+ *
19
+ * - ❌ You already have a creator UUID (use `/v1/creators/{id}/profiles` instead)
20
+ * - ❌ You want to get all accounts for a creator (use
21
+ * `/v1/creators/{id}/profiles` instead)
22
+ *
23
+ * **📊 Response Format:** Returns `SocialAccountLite` or `SocialAccountDetailed`
24
+ * objects with identical structure to `/v1/creators/{id}/profiles`. Both endpoints
25
+ * return the same data structure for consistency.
26
+ *
27
+ * **🔗 Data Relationships:**
28
+ *
29
+ * - Use the `creator_profile_id` field to fetch creator-level data via
30
+ * `/v1/creators`
31
+ * - Use the `creator_profile_id` to get all social accounts via
32
+ * `/v1/creators/{id}/profiles`
33
+ * - Creator-level data includes: name, bio, avatar, ai_one_line_bio
34
+ * - Social account data includes: follower_count, engagement_rate, verified,
35
+ * platform-specific metrics
36
+ *
37
+ * **🔄 Typical Workflow:**
38
+ *
39
+ * 1. **Discovery**: Call `/v1/profiles` with username+platform → get social
40
+ * account data + creator_profile_id
41
+ * 2. **Creator Data**: Call `/v1/creators` with creator_profile_id → get
42
+ * creator-level data
43
+ * 3. **All Accounts**: Call `/v1/creators/{id}/profiles` with creator_profile_id →
44
+ * get all social accounts for that creator
45
+ *
46
+ * **⚙️ Parameters:**
47
+ *
48
+ * - `mode`: `lite` (default) or `detailed` - controls response detail level
49
+ * - `platforms`: Array of platform names to filter results (e.g.,
50
+ * `["instagram", "tiktok"]`) **Pricing**: 0.01-0.05 credits per profile
51
+ * (lite/detailed mode)
52
+ *
53
+ * @example
54
+ * ```ts
55
+ * const response = await client.profiles.lookup({
56
+ * profiles: [
57
+ * { platform: 'instagram', username: 'fitness_guru' },
58
+ * { platform: 'tiktok', username: 'fitness_guru' },
59
+ * ],
60
+ * });
61
+ * ```
62
+ */
63
+ lookup(body: ProfileLookupParams, options?: RequestOptions): APIPromise<ProfileLookupResponse>;
64
+ }
65
+ export interface CreatorReferenceByHandle {
66
+ /**
67
+ * Social platform where the creator exists
68
+ */
69
+ platform: 'instagram' | 'tiktok';
70
+ /**
71
+ * Username on the platform
72
+ */
73
+ username: string;
74
+ }
75
+ export interface ProfileLookupResponse {
76
+ /**
77
+ * Array of social account objects. The structure depends on the `mode` parameter:
78
+ *
79
+ * - If `mode: "lite"`: Returns SocialAccountLite objects
80
+ * - If `mode: "detailed"`: Returns SocialAccountDetailed objects with additional
81
+ * fields
82
+ */
83
+ profiles?: Array<CreatorsAPI.SocialAccountLite | CreatorsAPI.SocialAccountDetailed>;
84
+ }
85
+ export interface ProfileLookupParams {
86
+ profiles: Array<CreatorReferenceByHandle>;
87
+ /**
88
+ * Response detail level - lite for basic fields, detailed for additional metrics
89
+ */
90
+ mode?: 'lite' | 'detailed';
91
+ /**
92
+ * Filter results to only include these platforms
93
+ */
94
+ platforms?: Array<'instagram' | 'tiktok'>;
95
+ }
96
+ export declare namespace Profiles {
97
+ export { type CreatorReferenceByHandle as CreatorReferenceByHandle, type ProfileLookupResponse as ProfileLookupResponse, type ProfileLookupParams as ProfileLookupParams, };
98
+ }
99
+ //# sourceMappingURL=profiles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.d.ts","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAwDG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG/F;AAED,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,QAAQ,EAAE,WAAW,GAAG,QAAQ,CAAC;IAEjC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,qBAAqB;IACpC;;;;;;OAMG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,iBAAiB,GAAG,WAAW,CAAC,qBAAqB,CAAC,CAAC;CACrF;AAED,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,KAAK,CAAC,wBAAwB,CAAC,CAAC;IAE1C;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,GAAG,UAAU,CAAC;IAE3B;;OAEG;IACH,SAAS,CAAC,EAAE,KAAK,CAAC,WAAW,GAAG,QAAQ,CAAC,CAAC;CAC3C;AAED,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Profiles = void 0;
5
+ const resource_1 = require("../core/resource.js");
6
+ class Profiles extends resource_1.APIResource {
7
+ /**
8
+ * **DISCOVERY ENDPOINT**: Look up social account data when you know a username and
9
+ * platform.
10
+ *
11
+ * **🎯 When to use this endpoint:**
12
+ *
13
+ * - ✅ You have a username and platform (e.g., @fitness_guru on Instagram)
14
+ * - ✅ You want to discover who a social account belongs to
15
+ * - ✅ You need to look up specific social accounts by username
16
+ * - ✅ You want to get social account metrics for known usernames
17
+ *
18
+ * **❌ When NOT to use this endpoint:**
19
+ *
20
+ * - ❌ You already have a creator UUID (use `/v1/creators/{id}/profiles` instead)
21
+ * - ❌ You want to get all accounts for a creator (use
22
+ * `/v1/creators/{id}/profiles` instead)
23
+ *
24
+ * **📊 Response Format:** Returns `SocialAccountLite` or `SocialAccountDetailed`
25
+ * objects with identical structure to `/v1/creators/{id}/profiles`. Both endpoints
26
+ * return the same data structure for consistency.
27
+ *
28
+ * **🔗 Data Relationships:**
29
+ *
30
+ * - Use the `creator_profile_id` field to fetch creator-level data via
31
+ * `/v1/creators`
32
+ * - Use the `creator_profile_id` to get all social accounts via
33
+ * `/v1/creators/{id}/profiles`
34
+ * - Creator-level data includes: name, bio, avatar, ai_one_line_bio
35
+ * - Social account data includes: follower_count, engagement_rate, verified,
36
+ * platform-specific metrics
37
+ *
38
+ * **🔄 Typical Workflow:**
39
+ *
40
+ * 1. **Discovery**: Call `/v1/profiles` with username+platform → get social
41
+ * account data + creator_profile_id
42
+ * 2. **Creator Data**: Call `/v1/creators` with creator_profile_id → get
43
+ * creator-level data
44
+ * 3. **All Accounts**: Call `/v1/creators/{id}/profiles` with creator_profile_id →
45
+ * get all social accounts for that creator
46
+ *
47
+ * **⚙️ Parameters:**
48
+ *
49
+ * - `mode`: `lite` (default) or `detailed` - controls response detail level
50
+ * - `platforms`: Array of platform names to filter results (e.g.,
51
+ * `["instagram", "tiktok"]`) **Pricing**: 0.01-0.05 credits per profile
52
+ * (lite/detailed mode)
53
+ *
54
+ * @example
55
+ * ```ts
56
+ * const response = await client.profiles.lookup({
57
+ * profiles: [
58
+ * { platform: 'instagram', username: 'fitness_guru' },
59
+ * { platform: 'tiktok', username: 'fitness_guru' },
60
+ * ],
61
+ * });
62
+ * ```
63
+ */
64
+ lookup(body, options) {
65
+ return this._client.post('/v1/profiles', { body, ...options });
66
+ }
67
+ }
68
+ exports.Profiles = Profiles;
69
+ //# sourceMappingURL=profiles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.js","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAK/C,MAAa,QAAS,SAAQ,sBAAW;IACvC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAwDG;IACH,MAAM,CAAC,IAAyB,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjE,CAAC;CACF;AA7DD,4BA6DC"}
@@ -0,0 +1,65 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../core/resource.mjs";
3
+ export class Profiles extends APIResource {
4
+ /**
5
+ * **DISCOVERY ENDPOINT**: Look up social account data when you know a username and
6
+ * platform.
7
+ *
8
+ * **🎯 When to use this endpoint:**
9
+ *
10
+ * - ✅ You have a username and platform (e.g., @fitness_guru on Instagram)
11
+ * - ✅ You want to discover who a social account belongs to
12
+ * - ✅ You need to look up specific social accounts by username
13
+ * - ✅ You want to get social account metrics for known usernames
14
+ *
15
+ * **❌ When NOT to use this endpoint:**
16
+ *
17
+ * - ❌ You already have a creator UUID (use `/v1/creators/{id}/profiles` instead)
18
+ * - ❌ You want to get all accounts for a creator (use
19
+ * `/v1/creators/{id}/profiles` instead)
20
+ *
21
+ * **📊 Response Format:** Returns `SocialAccountLite` or `SocialAccountDetailed`
22
+ * objects with identical structure to `/v1/creators/{id}/profiles`. Both endpoints
23
+ * return the same data structure for consistency.
24
+ *
25
+ * **🔗 Data Relationships:**
26
+ *
27
+ * - Use the `creator_profile_id` field to fetch creator-level data via
28
+ * `/v1/creators`
29
+ * - Use the `creator_profile_id` to get all social accounts via
30
+ * `/v1/creators/{id}/profiles`
31
+ * - Creator-level data includes: name, bio, avatar, ai_one_line_bio
32
+ * - Social account data includes: follower_count, engagement_rate, verified,
33
+ * platform-specific metrics
34
+ *
35
+ * **🔄 Typical Workflow:**
36
+ *
37
+ * 1. **Discovery**: Call `/v1/profiles` with username+platform → get social
38
+ * account data + creator_profile_id
39
+ * 2. **Creator Data**: Call `/v1/creators` with creator_profile_id → get
40
+ * creator-level data
41
+ * 3. **All Accounts**: Call `/v1/creators/{id}/profiles` with creator_profile_id →
42
+ * get all social accounts for that creator
43
+ *
44
+ * **⚙️ Parameters:**
45
+ *
46
+ * - `mode`: `lite` (default) or `detailed` - controls response detail level
47
+ * - `platforms`: Array of platform names to filter results (e.g.,
48
+ * `["instagram", "tiktok"]`) **Pricing**: 0.01-0.05 credits per profile
49
+ * (lite/detailed mode)
50
+ *
51
+ * @example
52
+ * ```ts
53
+ * const response = await client.profiles.lookup({
54
+ * profiles: [
55
+ * { platform: 'instagram', username: 'fitness_guru' },
56
+ * { platform: 'tiktok', username: 'fitness_guru' },
57
+ * ],
58
+ * });
59
+ * ```
60
+ */
61
+ lookup(body, options) {
62
+ return this._client.post('/v1/profiles', { body, ...options });
63
+ }
64
+ }
65
+ //# sourceMappingURL=profiles.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.mjs","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAKtB,MAAM,OAAO,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAwDG;IACH,MAAM,CAAC,IAAyB,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,cAAc,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjE,CAAC;CACF"}
@@ -0,0 +1,189 @@
1
+ import { APIResource } from "../core/resource.mjs";
2
+ import * as CreatorsAPI from "./creators.mjs";
3
+ import { APIPromise } from "../core/api-promise.mjs";
4
+ import { RequestOptions } from "../internal/request-options.mjs";
5
+ export declare class Search extends APIResource {
6
+ /**
7
+ * Find influencers using AI-powered search with natural language queries and
8
+ * optional filters.
9
+ *
10
+ * **Pricing**:
11
+ *
12
+ * - Base: 2.0 credits per creator returned
13
+ * - Detailed mode: Additional 0.05 credits per social account profile
14
+ * - **Example**: 10 creators in lite mode = 20 credits
15
+ * - **Example**: 10 creators with avg 2 profiles each in detailed mode = 20 + (10
16
+ * × 2 × 0.05) = 21 credits
17
+ *
18
+ * @example
19
+ * ```ts
20
+ * const response = await client.search.findCreators({
21
+ * query:
22
+ * 'fitness influencers with 100k+ followers who post workout content',
23
+ * });
24
+ * ```
25
+ */
26
+ findCreators(params: SearchFindCreatorsParams, options?: RequestOptions): APIPromise<SearchFindCreatorsResponse>;
27
+ }
28
+ /**
29
+ * Search result item containing creator information and all social media profiles
30
+ */
31
+ export interface SearchItem {
32
+ /**
33
+ * Unique creator identifier (UUID v4)
34
+ */
35
+ id: string;
36
+ /**
37
+ * AI-powered recommendation analysis explaining why this creator matches your
38
+ * query
39
+ */
40
+ ai_recommendation: SearchItem.AIRecommendation;
41
+ /**
42
+ * Creator's display name or full name
43
+ */
44
+ name: string;
45
+ /**
46
+ * Array of ALL social media profiles for this creator
47
+ */
48
+ profiles: Array<CreatorsAPI.SocialAccountLite | CreatorsAPI.SocialAccountDetailed>;
49
+ /**
50
+ * Profile picture URL. null if no avatar is available. URLs are typically valid
51
+ * for 24 hours.
52
+ */
53
+ avatar_url?: string | null;
54
+ /**
55
+ * Creator's biography or description text. May be aggregated from multiple
56
+ * platforms. null if unavailable.
57
+ */
58
+ bio?: string | null;
59
+ }
60
+ export declare namespace SearchItem {
61
+ /**
62
+ * AI-powered recommendation analysis explaining why this creator matches your
63
+ * query
64
+ */
65
+ interface AIRecommendation {
66
+ /**
67
+ * Human-readable explanation of why this creator was recommended. Highlights key
68
+ * matching factors from the query.
69
+ */
70
+ explanation: string;
71
+ /**
72
+ * Relevance score from 0 to 1, where 1 is a perfect match. Scores above 0.7
73
+ * indicate strong relevance.
74
+ */
75
+ score: number;
76
+ /**
77
+ * Fact-level evidence from hybrid search explaining why this creator matched. Each
78
+ * fact represents specific, verifiable information about the creator.
79
+ */
80
+ evidence?: Array<AIRecommendation.Evidence>;
81
+ }
82
+ namespace AIRecommendation {
83
+ /**
84
+ * Individual fact from hybrid search providing evidence for why a creator matched.
85
+ * Facts are specific, verifiable pieces of information extracted from creator
86
+ * data.
87
+ */
88
+ interface Evidence {
89
+ /**
90
+ * The actual fact text describing specific information about the creator
91
+ */
92
+ fact: string;
93
+ /**
94
+ * Unique identifier for this fact
95
+ */
96
+ factId: string;
97
+ /**
98
+ * Combined relevance score (similarity × confidence × temporal decay). Higher
99
+ * scores indicate stronger evidence for the match.
100
+ */
101
+ score: number;
102
+ /**
103
+ * When this fact was created or observed (ISO 8601 format)
104
+ */
105
+ created_at?: string;
106
+ /**
107
+ * Array of source post IDs where this fact originated. A single fact may come from
108
+ * multiple posts.
109
+ */
110
+ source_post_id?: Array<string>;
111
+ }
112
+ }
113
+ }
114
+ export interface SearchFindCreatorsResponse {
115
+ /**
116
+ * Total number of matching results in the database before pagination. Use this
117
+ * with `has_more` to display "Showing 25 of 1,247 results" in your UI.
118
+ */
119
+ filtered_total?: number;
120
+ /**
121
+ * Whether there are more results available for pagination. If true, use the
122
+ * `next_cursor` value in your next request.
123
+ */
124
+ has_more?: boolean;
125
+ items?: Array<SearchItem>;
126
+ /**
127
+ * Opaque cursor for fetching the next page of results. Pass this value as the
128
+ * `cursor` query parameter. Only present when `has_more` is true.
129
+ */
130
+ next_cursor?: string;
131
+ }
132
+ export interface SearchFindCreatorsParams {
133
+ /**
134
+ * Body param: Natural language search query
135
+ */
136
+ query: string;
137
+ /**
138
+ * Query param: Opaque pagination cursor from previous response's `next_cursor`. Do
139
+ * not construct manually.
140
+ */
141
+ cursor?: string;
142
+ /**
143
+ * Query param: Maximum number of results to return
144
+ */
145
+ limit?: number;
146
+ /**
147
+ * Body param:
148
+ */
149
+ filters?: SearchFindCreatorsParams.Filters;
150
+ /**
151
+ * Body param: Filter social accounts to only these platforms. Reduces payload
152
+ * size. Does not affect search results or costs.
153
+ */
154
+ include_platforms?: Array<'instagram' | 'tiktok'>;
155
+ /**
156
+ * Body param: Response detail level. `lite` returns basic fields (username,
157
+ * follower_count, engagement_rate). `detailed` adds avg_comments_recent,
158
+ * avg_video_views_recent, follower_change_rate, etc. Detailed mode costs 5x more
159
+ * (0.05 vs 0.01 credits per profile).
160
+ */
161
+ mode?: 'lite' | 'detailed';
162
+ }
163
+ export declare namespace SearchFindCreatorsParams {
164
+ interface Filters {
165
+ /**
166
+ * Per-platform filter definitions
167
+ */
168
+ platform_filters?: Array<Filters.PlatformFilter>;
169
+ /**
170
+ * How to combine platform_filters. `OR` = creator matches ANY platform filter.
171
+ * `AND` = creator must match ALL platform filters. Default: OR.
172
+ */
173
+ platform_logic?: 'AND' | 'OR';
174
+ }
175
+ namespace Filters {
176
+ interface PlatformFilter {
177
+ platform: 'instagram' | 'tiktok';
178
+ max_engagement_rate?: number;
179
+ max_followers?: number;
180
+ min_engagement_rate?: number;
181
+ min_followers?: number;
182
+ verified_only?: boolean;
183
+ }
184
+ }
185
+ }
186
+ export declare namespace Search {
187
+ export { type SearchItem as SearchItem, type SearchFindCreatorsResponse as SearchFindCreatorsResponse, type SearchFindCreatorsParams as SearchFindCreatorsParams, };
188
+ }
189
+ //# sourceMappingURL=search.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"search.d.mts","sourceRoot":"","sources":["../src/resources/search.ts"],"names":[],"mappings":"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"}