influship 0.2.0 → 0.3.2
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.
- package/CHANGELOG.md +62 -30
- package/LICENSE +1 -1
- package/README.md +88 -43
- package/client.d.mts +49 -29
- package/client.d.mts.map +1 -1
- package/client.d.ts +49 -29
- package/client.d.ts.map +1 -1
- package/client.js +89 -56
- package/client.js.map +1 -1
- package/client.mjs +89 -56
- package/client.mjs.map +1 -1
- package/core/api-promise.d.mts +2 -2
- package/core/api-promise.d.mts.map +1 -1
- package/core/api-promise.d.ts +2 -2
- package/core/api-promise.d.ts.map +1 -1
- package/core/api-promise.js.map +1 -1
- package/core/api-promise.mjs.map +1 -1
- package/core/error.d.mts +2 -2
- package/core/error.d.mts.map +1 -1
- package/core/error.d.ts +2 -2
- package/core/error.d.ts.map +1 -1
- package/core/error.js +4 -4
- package/core/error.js.map +1 -1
- package/core/error.mjs +2 -2
- package/core/error.mjs.map +1 -1
- package/core/pagination.d.mts +75 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +75 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +139 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +132 -0
- package/core/pagination.mjs.map +1 -0
- package/core/resource.d.mts +3 -3
- package/core/resource.d.mts.map +1 -1
- package/core/resource.d.ts +3 -3
- package/core/resource.d.ts.map +1 -1
- package/core/resource.js.map +1 -1
- package/core/resource.mjs.map +1 -1
- package/index.d.mts +4 -3
- package/index.d.mts.map +1 -1
- package/index.d.ts +4 -3
- package/index.d.ts.map +1 -1
- package/index.js +6 -4
- package/index.js.map +1 -1
- package/index.mjs +4 -3
- package/index.mjs.map +1 -1
- package/internal/parse.d.mts +2 -2
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts +2 -2
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.js +5 -0
- package/internal/parse.js.map +1 -1
- package/internal/parse.mjs +5 -0
- package/internal/parse.mjs.map +1 -1
- package/internal/shims.js +1 -1
- package/internal/shims.js.map +1 -1
- package/internal/shims.mjs +1 -1
- package/internal/shims.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/internal/uploads.d.mts +4 -4
- package/internal/uploads.d.mts.map +1 -1
- package/internal/uploads.d.ts +4 -4
- package/internal/uploads.d.ts.map +1 -1
- package/internal/uploads.js.map +1 -1
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/base64.js +2 -2
- package/internal/utils/base64.js.map +1 -1
- package/internal/utils/base64.mjs +3 -3
- package/internal/utils/base64.mjs.map +1 -1
- package/internal/utils/log.d.mts +3 -3
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts +3 -3
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/path.js +1 -1
- package/internal/utils/path.js.map +1 -1
- package/internal/utils/path.mjs +2 -2
- package/internal/utils/path.mjs.map +1 -1
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils/values.js +5 -5
- package/internal/utils/values.js.map +1 -1
- package/internal/utils/values.mjs +6 -6
- package/internal/utils/values.mjs.map +1 -1
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +24 -3
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +2 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +6 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +2 -0
- package/pagination.mjs.map +1 -0
- package/resources/creators.d.mts +326 -247
- package/resources/creators.d.mts.map +1 -1
- package/resources/creators.d.ts +326 -247
- package/resources/creators.d.ts.map +1 -1
- package/resources/creators.js +80 -63
- package/resources/creators.js.map +1 -1
- package/resources/creators.mjs +80 -63
- package/resources/creators.mjs.map +1 -1
- package/resources/health.d.mts +13 -1
- package/resources/health.d.mts.map +1 -1
- package/resources/health.d.ts +13 -1
- package/resources/health.d.ts.map +1 -1
- package/resources/health.js +4 -1
- package/resources/health.js.map +1 -1
- package/resources/health.mjs +4 -1
- package/resources/health.mjs.map +1 -1
- package/resources/index.d.mts +6 -7
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +6 -7
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +5 -7
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -3
- package/resources/index.mjs.map +1 -1
- package/resources/posts.d.mts +82 -202
- package/resources/posts.d.mts.map +1 -1
- package/resources/posts.d.ts +82 -202
- package/resources/posts.d.ts.map +1 -1
- package/resources/posts.js +17 -38
- package/resources/posts.js.map +1 -1
- package/resources/posts.mjs +17 -38
- package/resources/posts.mjs.map +1 -1
- package/resources/profiles.d.mts +208 -58
- package/resources/profiles.d.mts.map +1 -1
- package/resources/profiles.d.ts +208 -58
- package/resources/profiles.d.ts.map +1 -1
- package/resources/profiles.js +37 -41
- package/resources/profiles.js.map +1 -1
- package/resources/profiles.mjs +37 -41
- package/resources/profiles.mjs.map +1 -1
- package/resources/raw/index.d.mts +4 -0
- package/resources/raw/index.d.mts.map +1 -0
- package/resources/raw/index.d.ts +4 -0
- package/resources/raw/index.d.ts.map +1 -0
- package/resources/raw/index.js +11 -0
- package/resources/raw/index.js.map +1 -0
- package/resources/raw/index.mjs +5 -0
- package/resources/raw/index.mjs.map +1 -0
- package/resources/raw/instagram.d.mts +215 -0
- package/resources/raw/instagram.d.mts.map +1 -0
- package/resources/raw/instagram.d.ts +215 -0
- package/resources/raw/instagram.d.ts.map +1 -0
- package/resources/raw/instagram.js +31 -0
- package/resources/raw/instagram.js.map +1 -0
- package/resources/raw/instagram.mjs +27 -0
- package/resources/raw/instagram.mjs.map +1 -0
- package/resources/raw/raw.d.mts +14 -0
- package/resources/raw/raw.d.mts.map +1 -0
- package/resources/raw/raw.d.ts +14 -0
- package/resources/raw/raw.d.ts.map +1 -0
- package/resources/raw/raw.js +21 -0
- package/resources/raw/raw.js.map +1 -0
- package/resources/raw/raw.mjs +16 -0
- package/resources/raw/raw.mjs.map +1 -0
- package/resources/raw/youtube.d.mts +455 -0
- package/resources/raw/youtube.d.mts.map +1 -0
- package/resources/raw/youtube.d.ts +455 -0
- package/resources/raw/youtube.d.ts.map +1 -0
- package/resources/raw/youtube.js +61 -0
- package/resources/raw/youtube.js.map +1 -0
- package/resources/raw/youtube.mjs +57 -0
- package/resources/raw/youtube.mjs.map +1 -0
- package/resources/raw.d.mts +2 -0
- package/resources/raw.d.mts.map +1 -0
- package/resources/raw.d.ts +2 -0
- package/resources/raw.d.ts.map +1 -0
- package/resources/raw.js +6 -0
- package/resources/raw.js.map +1 -0
- package/resources/raw.mjs +3 -0
- package/resources/raw.mjs.map +1 -0
- package/resources/search.d.mts +126 -117
- package/resources/search.d.mts.map +1 -1
- package/resources/search.d.ts +126 -117
- package/resources/search.d.ts.map +1 -1
- package/resources/search.js +46 -13
- package/resources/search.js.map +1 -1
- package/resources/search.mjs +46 -13
- package/resources/search.mjs.map +1 -1
- package/resources/shared.d.mts +55 -0
- package/resources/shared.d.mts.map +1 -0
- package/resources/shared.d.ts +55 -0
- package/resources/shared.d.ts.map +1 -0
- package/resources/shared.js +4 -0
- package/resources/shared.js.map +1 -0
- package/resources/shared.mjs +3 -0
- package/resources/shared.mjs.map +1 -0
- package/src/client.ts +153 -127
- package/src/core/api-promise.ts +4 -4
- package/src/core/error.ts +2 -2
- package/src/core/pagination.ts +232 -0
- package/src/core/resource.ts +3 -3
- package/src/index.ts +4 -3
- package/src/internal/parse.ts +8 -2
- package/src/internal/shims.ts +1 -1
- package/src/internal/uploads.ts +5 -5
- package/src/internal/utils/base64.ts +3 -3
- package/src/internal/utils/log.ts +3 -3
- package/src/internal/utils/path.ts +2 -2
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils/values.ts +6 -6
- package/src/internal/utils.ts +1 -0
- package/src/pagination.ts +2 -0
- package/src/resources/creators.ts +369 -271
- package/src/resources/health.ts +13 -1
- package/src/resources/index.ts +22 -41
- package/src/resources/posts.ts +89 -232
- package/src/resources/profiles.ts +252 -59
- package/src/resources/raw/index.ts +16 -0
- package/src/resources/raw/instagram.ts +271 -0
- package/src/resources/raw/raw.ts +47 -0
- package/src/resources/raw/youtube.ts +585 -0
- package/src/resources/raw.ts +3 -0
- package/src/resources/search.ts +145 -131
- package/src/resources/shared.ts +66 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/brand-safety.d.mts +0 -234
- package/resources/brand-safety.d.mts.map +0 -1
- package/resources/brand-safety.d.ts +0 -234
- package/resources/brand-safety.d.ts.map +0 -1
- package/resources/brand-safety.js +0 -75
- package/resources/brand-safety.js.map +0 -1
- package/resources/brand-safety.mjs +0 -71
- package/resources/brand-safety.mjs.map +0 -1
- package/resources/lookalike.d.mts +0 -142
- package/resources/lookalike.d.mts.map +0 -1
- package/resources/lookalike.d.ts +0 -142
- package/resources/lookalike.d.ts.map +0 -1
- package/resources/lookalike.js +0 -28
- package/resources/lookalike.js.map +0 -1
- package/resources/lookalike.mjs +0 -24
- package/resources/lookalike.mjs.map +0 -1
- package/resources/match.d.mts +0 -90
- package/resources/match.d.mts.map +0 -1
- package/resources/match.d.ts +0 -90
- package/resources/match.d.ts.map +0 -1
- package/resources/match.js +0 -22
- package/resources/match.js.map +0 -1
- package/resources/match.mjs +0 -18
- package/resources/match.mjs.map +0 -1
- package/src/resources/brand-safety.ts +0 -304
- package/src/resources/lookalike.ts +0 -186
- package/src/resources/match.ts +0 -115
package/resources/profiles.js
CHANGED
|
@@ -3,66 +3,62 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.Profiles = void 0;
|
|
5
5
|
const resource_1 = require("../core/resource.js");
|
|
6
|
+
const path_1 = require("../internal/utils/path.js");
|
|
7
|
+
/**
|
|
8
|
+
* Access individual social media profiles with detailed metrics, growth data, and activity information. Profiles are platform-specific accounts linked to creators.
|
|
9
|
+
*/
|
|
6
10
|
class Profiles extends resource_1.APIResource {
|
|
7
11
|
/**
|
|
8
|
-
*
|
|
9
|
-
*
|
|
12
|
+
* Retrieve detailed profile data including metrics, growth statistics, and
|
|
13
|
+
* activity information from our database.
|
|
10
14
|
*
|
|
11
|
-
*
|
|
15
|
+
* **Response includes:**
|
|
12
16
|
*
|
|
13
|
-
* -
|
|
14
|
-
* -
|
|
15
|
-
* -
|
|
16
|
-
* -
|
|
17
|
+
* - Basic info (bio, avatar, verification status)
|
|
18
|
+
* - Performance metrics (followers, engagement rate, avg likes/comments)
|
|
19
|
+
* - Growth data (30-day follower growth, monthly rate)
|
|
20
|
+
* - Activity data (last post date, posting frequency)
|
|
17
21
|
*
|
|
18
|
-
*
|
|
22
|
+
* **Pricing**: 0.1 credits per request ($0.001)
|
|
19
23
|
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
* - Social account data includes: follower_count, engagement_rate, verified,
|
|
36
|
-
* platform-specific metrics
|
|
37
|
-
*
|
|
38
|
-
* **🔄 Typical Workflow:**
|
|
24
|
+
* @example
|
|
25
|
+
* ```ts
|
|
26
|
+
* const profile = await client.profiles.get(
|
|
27
|
+
* 'fitness_coach_jane',
|
|
28
|
+
* { platform: 'instagram' },
|
|
29
|
+
* );
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
32
|
+
get(username, params, options) {
|
|
33
|
+
const { platform } = params;
|
|
34
|
+
return this._client.get((0, path_1.path) `/v1/profiles/${platform}/${username}`, options);
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Look up multiple profiles in a single request. Efficiently retrieve data for up
|
|
38
|
+
* to 100 profiles at once.
|
|
39
39
|
*
|
|
40
|
-
*
|
|
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
|
|
40
|
+
* **Response includes:**
|
|
46
41
|
*
|
|
47
|
-
*
|
|
42
|
+
* - `found`: Array of profiles that exist in our database
|
|
43
|
+
* - `not_found`: Array of profiles that weren't found (consider live scraping
|
|
44
|
+
* these)
|
|
48
45
|
*
|
|
49
|
-
*
|
|
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)
|
|
46
|
+
* **Pricing**: 0.1 credits per profile ($0.001)
|
|
53
47
|
*
|
|
54
48
|
* @example
|
|
55
49
|
* ```ts
|
|
56
50
|
* const response = await client.profiles.lookup({
|
|
57
51
|
* profiles: [
|
|
58
|
-
* {
|
|
59
|
-
*
|
|
52
|
+
* {
|
|
53
|
+
* platform: 'instagram',
|
|
54
|
+
* username: 'fitness_coach_jane',
|
|
55
|
+
* },
|
|
60
56
|
* ],
|
|
61
57
|
* });
|
|
62
58
|
* ```
|
|
63
59
|
*/
|
|
64
60
|
lookup(body, options) {
|
|
65
|
-
return this._client.post('/v1/profiles', { body, ...options });
|
|
61
|
+
return this._client.post('/v1/profiles/lookup', { body, ...options });
|
|
66
62
|
}
|
|
67
63
|
}
|
|
68
64
|
exports.Profiles = Profiles;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"profiles.js","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;
|
|
1
|
+
{"version":3,"file":"profiles.js","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAG/C,oDAA8C;AAE9C;;GAEG;AACH,MAAa,QAAS,SAAQ,sBAAW;IACvC;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,GAAG,CAAC,QAAgB,EAAE,MAAwB,EAAE,OAAwB;QACtE,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,CAAC;QAC5B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,gBAAgB,QAAQ,IAAI,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC/E,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,MAAM,CAAC,IAAyB,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,qBAAqB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;CACF;AAtDD,4BAsDC"}
|
package/resources/profiles.mjs
CHANGED
|
@@ -1,65 +1,61 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../core/resource.mjs";
|
|
3
|
+
import { path } from "../internal/utils/path.mjs";
|
|
4
|
+
/**
|
|
5
|
+
* Access individual social media profiles with detailed metrics, growth data, and activity information. Profiles are platform-specific accounts linked to creators.
|
|
6
|
+
*/
|
|
3
7
|
export class Profiles extends APIResource {
|
|
4
8
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
9
|
+
* Retrieve detailed profile data including metrics, growth statistics, and
|
|
10
|
+
* activity information from our database.
|
|
7
11
|
*
|
|
8
|
-
*
|
|
12
|
+
* **Response includes:**
|
|
9
13
|
*
|
|
10
|
-
* -
|
|
11
|
-
* -
|
|
12
|
-
* -
|
|
13
|
-
* -
|
|
14
|
+
* - Basic info (bio, avatar, verification status)
|
|
15
|
+
* - Performance metrics (followers, engagement rate, avg likes/comments)
|
|
16
|
+
* - Growth data (30-day follower growth, monthly rate)
|
|
17
|
+
* - Activity data (last post date, posting frequency)
|
|
14
18
|
*
|
|
15
|
-
*
|
|
19
|
+
* **Pricing**: 0.1 credits per request ($0.001)
|
|
16
20
|
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
* - Social account data includes: follower_count, engagement_rate, verified,
|
|
33
|
-
* platform-specific metrics
|
|
34
|
-
*
|
|
35
|
-
* **🔄 Typical Workflow:**
|
|
21
|
+
* @example
|
|
22
|
+
* ```ts
|
|
23
|
+
* const profile = await client.profiles.get(
|
|
24
|
+
* 'fitness_coach_jane',
|
|
25
|
+
* { platform: 'instagram' },
|
|
26
|
+
* );
|
|
27
|
+
* ```
|
|
28
|
+
*/
|
|
29
|
+
get(username, params, options) {
|
|
30
|
+
const { platform } = params;
|
|
31
|
+
return this._client.get(path `/v1/profiles/${platform}/${username}`, options);
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Look up multiple profiles in a single request. Efficiently retrieve data for up
|
|
35
|
+
* to 100 profiles at once.
|
|
36
36
|
*
|
|
37
|
-
*
|
|
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
|
|
37
|
+
* **Response includes:**
|
|
43
38
|
*
|
|
44
|
-
*
|
|
39
|
+
* - `found`: Array of profiles that exist in our database
|
|
40
|
+
* - `not_found`: Array of profiles that weren't found (consider live scraping
|
|
41
|
+
* these)
|
|
45
42
|
*
|
|
46
|
-
*
|
|
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)
|
|
43
|
+
* **Pricing**: 0.1 credits per profile ($0.001)
|
|
50
44
|
*
|
|
51
45
|
* @example
|
|
52
46
|
* ```ts
|
|
53
47
|
* const response = await client.profiles.lookup({
|
|
54
48
|
* profiles: [
|
|
55
|
-
* {
|
|
56
|
-
*
|
|
49
|
+
* {
|
|
50
|
+
* platform: 'instagram',
|
|
51
|
+
* username: 'fitness_coach_jane',
|
|
52
|
+
* },
|
|
57
53
|
* ],
|
|
58
54
|
* });
|
|
59
55
|
* ```
|
|
60
56
|
*/
|
|
61
57
|
lookup(body, options) {
|
|
62
|
-
return this._client.post('/v1/profiles', { body, ...options });
|
|
58
|
+
return this._client.post('/v1/profiles/lookup', { body, ...options });
|
|
63
59
|
}
|
|
64
60
|
}
|
|
65
61
|
//# sourceMappingURL=profiles.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"profiles.mjs","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"profiles.mjs","sourceRoot":"","sources":["../src/resources/profiles.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf;;GAEG;AACH,MAAM,OAAO,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,GAAG,CAAC,QAAgB,EAAE,MAAwB,EAAE,OAAwB;QACtE,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,CAAC;QAC5B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,gBAAgB,QAAQ,IAAI,QAAQ,EAAE,EAAE,OAAO,CAAC,CAAC;IAC/E,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACH,MAAM,CAAC,IAAyB,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,qBAAqB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;CACF"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { Instagram, type InstagramGetProfileResponse, type InstagramGetProfileParams } from "./instagram.mjs";
|
|
2
|
+
export { Raw } from "./raw.mjs";
|
|
3
|
+
export { Youtube, type TranscriptSegment, type YoutubeGetChannelResponse, type YoutubeGetChannelTranscriptsResponse, type YoutubeGetTranscriptResponse, type YoutubeSearchResponse, type YoutubeGetChannelParams, type YoutubeGetChannelTranscriptsParams, type YoutubeGetTranscriptParams, type YoutubeSearchParams, } from "./youtube.mjs";
|
|
4
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/raw/index.ts"],"names":[],"mappings":"OAEO,EAAE,SAAS,EAAE,KAAK,2BAA2B,EAAE,KAAK,yBAAyB,EAAE;OAC/E,EAAE,GAAG,EAAE;OACP,EACL,OAAO,EACP,KAAK,iBAAiB,EACtB,KAAK,yBAAyB,EAC9B,KAAK,oCAAoC,EACzC,KAAK,4BAA4B,EACjC,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,KAAK,kCAAkC,EACvC,KAAK,0BAA0B,EAC/B,KAAK,mBAAmB,GACzB"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { Instagram, type InstagramGetProfileResponse, type InstagramGetProfileParams } from "./instagram.js";
|
|
2
|
+
export { Raw } from "./raw.js";
|
|
3
|
+
export { Youtube, type TranscriptSegment, type YoutubeGetChannelResponse, type YoutubeGetChannelTranscriptsResponse, type YoutubeGetTranscriptResponse, type YoutubeSearchResponse, type YoutubeGetChannelParams, type YoutubeGetChannelTranscriptsParams, type YoutubeGetTranscriptParams, type YoutubeSearchParams, } from "./youtube.js";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/raw/index.ts"],"names":[],"mappings":"OAEO,EAAE,SAAS,EAAE,KAAK,2BAA2B,EAAE,KAAK,yBAAyB,EAAE;OAC/E,EAAE,GAAG,EAAE;OACP,EACL,OAAO,EACP,KAAK,iBAAiB,EACtB,KAAK,yBAAyB,EAC9B,KAAK,oCAAoC,EACzC,KAAK,4BAA4B,EACjC,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,KAAK,kCAAkC,EACvC,KAAK,0BAA0B,EAC/B,KAAK,mBAAmB,GACzB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
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.Youtube = exports.Raw = exports.Instagram = void 0;
|
|
5
|
+
var instagram_1 = require("./instagram.js");
|
|
6
|
+
Object.defineProperty(exports, "Instagram", { enumerable: true, get: function () { return instagram_1.Instagram; } });
|
|
7
|
+
var raw_1 = require("./raw.js");
|
|
8
|
+
Object.defineProperty(exports, "Raw", { enumerable: true, get: function () { return raw_1.Raw; } });
|
|
9
|
+
var youtube_1 = require("./youtube.js");
|
|
10
|
+
Object.defineProperty(exports, "Youtube", { enumerable: true, get: function () { return youtube_1.Youtube; } });
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/raw/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,4CAA0G;AAAjG,sGAAA,SAAS,OAAA;AAClB,gCAA4B;AAAnB,0FAAA,GAAG,OAAA;AACZ,wCAWmB;AAVjB,kGAAA,OAAO,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/raw/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,SAAS,EAAoE;OAC/E,EAAE,GAAG,EAAE;OACP,EACL,OAAO,GAUR"}
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
import { APIResource } from "../../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../../core/api-promise.mjs";
|
|
3
|
+
import { RequestOptions } from "../../internal/request-options.mjs";
|
|
4
|
+
/**
|
|
5
|
+
* Fetch fresh data directly from social platforms in real-time. Use when you need the most current information or data for profiles not yet in our database.
|
|
6
|
+
*/
|
|
7
|
+
export declare class Instagram extends APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* Fetch fresh Instagram profile data directly from Instagram in real-time. Use
|
|
10
|
+
* this when you need the most current follower counts, bio, or recent activity.
|
|
11
|
+
*
|
|
12
|
+
* **When to use live scraping:**
|
|
13
|
+
*
|
|
14
|
+
* - Profile not found in our database
|
|
15
|
+
* - Need real-time follower/engagement data
|
|
16
|
+
* - Verifying current profile status before campaign
|
|
17
|
+
*
|
|
18
|
+
* **Note:** Live scraping is slower than cached data (2-5 seconds) and costs more.
|
|
19
|
+
* Use cached endpoints when freshness isn't critical.
|
|
20
|
+
*
|
|
21
|
+
* **Pricing**: 0.5 credits per profile scraped ($0.005)
|
|
22
|
+
*/
|
|
23
|
+
getProfile(username: string, query?: InstagramGetProfileParams | null | undefined, options?: RequestOptions): APIPromise<InstagramGetProfileResponse>;
|
|
24
|
+
}
|
|
25
|
+
export interface InstagramGetProfileResponse {
|
|
26
|
+
/**
|
|
27
|
+
* Live scraped profile data
|
|
28
|
+
*/
|
|
29
|
+
data: InstagramGetProfileResponse.Data;
|
|
30
|
+
}
|
|
31
|
+
export declare namespace InstagramGetProfileResponse {
|
|
32
|
+
/**
|
|
33
|
+
* Live scraped profile data
|
|
34
|
+
*/
|
|
35
|
+
interface Data {
|
|
36
|
+
/**
|
|
37
|
+
* Profile unique identifier
|
|
38
|
+
*/
|
|
39
|
+
id: string;
|
|
40
|
+
activity: Data.Activity;
|
|
41
|
+
/**
|
|
42
|
+
* Avatar URL
|
|
43
|
+
*/
|
|
44
|
+
avatar_url: string | null;
|
|
45
|
+
/**
|
|
46
|
+
* Profile bio
|
|
47
|
+
*/
|
|
48
|
+
bio: string | null;
|
|
49
|
+
/**
|
|
50
|
+
* Account category
|
|
51
|
+
*/
|
|
52
|
+
category: string | null;
|
|
53
|
+
/**
|
|
54
|
+
* Creator unique identifier
|
|
55
|
+
*/
|
|
56
|
+
creator_id: string;
|
|
57
|
+
/**
|
|
58
|
+
* Last data refresh timestamp
|
|
59
|
+
*/
|
|
60
|
+
data_updated_at: string | null;
|
|
61
|
+
/**
|
|
62
|
+
* Display name
|
|
63
|
+
*/
|
|
64
|
+
display_name: string | null;
|
|
65
|
+
/**
|
|
66
|
+
* External website URL
|
|
67
|
+
*/
|
|
68
|
+
external_url: string | null;
|
|
69
|
+
growth: Data.Growth;
|
|
70
|
+
/**
|
|
71
|
+
* Whether this is a business account
|
|
72
|
+
*/
|
|
73
|
+
is_business: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Whether the account is private
|
|
76
|
+
*/
|
|
77
|
+
is_private: boolean;
|
|
78
|
+
/**
|
|
79
|
+
* Whether the account is verified
|
|
80
|
+
*/
|
|
81
|
+
is_verified: boolean;
|
|
82
|
+
metrics: Data.Metrics;
|
|
83
|
+
/**
|
|
84
|
+
* Social media platform
|
|
85
|
+
*/
|
|
86
|
+
platform: 'instagram';
|
|
87
|
+
/**
|
|
88
|
+
* Listed pronouns
|
|
89
|
+
*/
|
|
90
|
+
pronouns: Array<string> | null;
|
|
91
|
+
/**
|
|
92
|
+
* When this data was scraped
|
|
93
|
+
*/
|
|
94
|
+
scraped_at: string;
|
|
95
|
+
/**
|
|
96
|
+
* Profile URL
|
|
97
|
+
*/
|
|
98
|
+
url: string;
|
|
99
|
+
/**
|
|
100
|
+
* Profile username
|
|
101
|
+
*/
|
|
102
|
+
username: string;
|
|
103
|
+
/**
|
|
104
|
+
* Recent posts (only included when include_posts=true)
|
|
105
|
+
*/
|
|
106
|
+
posts?: Array<Data.Post>;
|
|
107
|
+
}
|
|
108
|
+
namespace Data {
|
|
109
|
+
interface Activity {
|
|
110
|
+
/**
|
|
111
|
+
* Timestamp of last post
|
|
112
|
+
*/
|
|
113
|
+
last_post_at: string | null;
|
|
114
|
+
}
|
|
115
|
+
interface Growth {
|
|
116
|
+
/**
|
|
117
|
+
* Follower growth percentage over 30 days (e.g. 2.5 means +2.5%)
|
|
118
|
+
*/
|
|
119
|
+
followers_30d_pct: number;
|
|
120
|
+
}
|
|
121
|
+
interface Metrics {
|
|
122
|
+
/**
|
|
123
|
+
* Average comments on recent posts
|
|
124
|
+
*/
|
|
125
|
+
avg_comments_recent: number;
|
|
126
|
+
/**
|
|
127
|
+
* Average likes on recent posts
|
|
128
|
+
*/
|
|
129
|
+
avg_likes_recent: number;
|
|
130
|
+
/**
|
|
131
|
+
* Average views on recent posts
|
|
132
|
+
*/
|
|
133
|
+
avg_views_recent: number | null;
|
|
134
|
+
/**
|
|
135
|
+
* Engagement rate as a percentage (e.g. 3.5 means 3.5%)
|
|
136
|
+
*/
|
|
137
|
+
engagement_rate: number;
|
|
138
|
+
/**
|
|
139
|
+
* Follower count
|
|
140
|
+
*/
|
|
141
|
+
followers: number;
|
|
142
|
+
/**
|
|
143
|
+
* Following count
|
|
144
|
+
*/
|
|
145
|
+
following: number;
|
|
146
|
+
/**
|
|
147
|
+
* Total post count
|
|
148
|
+
*/
|
|
149
|
+
posts: number;
|
|
150
|
+
/**
|
|
151
|
+
* Posts in the last 30 days
|
|
152
|
+
*/
|
|
153
|
+
posts_last_30d: number;
|
|
154
|
+
/**
|
|
155
|
+
* Average posts per week
|
|
156
|
+
*/
|
|
157
|
+
posts_per_week: number;
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Simplified post from live scrape
|
|
161
|
+
*/
|
|
162
|
+
interface Post {
|
|
163
|
+
/**
|
|
164
|
+
* Post unique identifier
|
|
165
|
+
*/
|
|
166
|
+
id: string;
|
|
167
|
+
/**
|
|
168
|
+
* Post caption
|
|
169
|
+
*/
|
|
170
|
+
caption: string | null;
|
|
171
|
+
/**
|
|
172
|
+
* Comment count
|
|
173
|
+
*/
|
|
174
|
+
comments_count: number | null;
|
|
175
|
+
/**
|
|
176
|
+
* Like count
|
|
177
|
+
*/
|
|
178
|
+
likes_count: number | null;
|
|
179
|
+
/**
|
|
180
|
+
* Primary media URL
|
|
181
|
+
*/
|
|
182
|
+
media_url: string | null;
|
|
183
|
+
/**
|
|
184
|
+
* Platform-specific post ID
|
|
185
|
+
*/
|
|
186
|
+
platform_id: string;
|
|
187
|
+
/**
|
|
188
|
+
* Post timestamp
|
|
189
|
+
*/
|
|
190
|
+
posted_at: string;
|
|
191
|
+
/**
|
|
192
|
+
* Type of post
|
|
193
|
+
*/
|
|
194
|
+
type: 'image' | 'video' | 'carousel' | 'reel' | 'story';
|
|
195
|
+
/**
|
|
196
|
+
* Post URL
|
|
197
|
+
*/
|
|
198
|
+
url: string;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
export interface InstagramGetProfileParams {
|
|
203
|
+
/**
|
|
204
|
+
* Include recent posts in response
|
|
205
|
+
*/
|
|
206
|
+
include_posts?: boolean;
|
|
207
|
+
/**
|
|
208
|
+
* Number of posts to include
|
|
209
|
+
*/
|
|
210
|
+
post_limit?: number;
|
|
211
|
+
}
|
|
212
|
+
export declare namespace Instagram {
|
|
213
|
+
export { type InstagramGetProfileResponse as InstagramGetProfileResponse, type InstagramGetProfileParams as InstagramGetProfileParams, };
|
|
214
|
+
}
|
|
215
|
+
//# sourceMappingURL=instagram.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instagram.d.mts","sourceRoot":"","sources":["../../src/resources/raw/instagram.ts"],"names":[],"mappings":"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"}
|