glitch-javascript-sdk 2.3.0 → 2.3.1
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/dist/cjs/index.js +21 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/SocialPosts.d.ts +15 -0
- package/dist/esm/index.js +21 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +15 -0
- package/package.json +1 -1
- package/src/api/SocialPosts.ts +21 -0
- package/src/routes/SocialPostsRoute.ts +11 -9
package/dist/index.d.ts
CHANGED
|
@@ -3588,6 +3588,21 @@ declare class SocialPosts {
|
|
|
3588
3588
|
* @returns A promise
|
|
3589
3589
|
*/
|
|
3590
3590
|
static createComment<T>(post_id: string, data: object): AxiosPromise<Response<T>>;
|
|
3591
|
+
/**
|
|
3592
|
+
* Get game install attribution data for a specific social media post.
|
|
3593
|
+
*
|
|
3594
|
+
* @param post_id The ID of the social media post.
|
|
3595
|
+
* @param params Optional query parameters (start_date, end_date, confidence_threshold).
|
|
3596
|
+
* @returns A promise
|
|
3597
|
+
*/
|
|
3598
|
+
static getPostAttribution<T>(post_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
3599
|
+
/**
|
|
3600
|
+
* Get a report of all social media posts for a title that are converting to game installs.
|
|
3601
|
+
*
|
|
3602
|
+
* @param params Query parameters (title_id, start_date, end_date, confidence_threshold).
|
|
3603
|
+
* @returns A promise
|
|
3604
|
+
*/
|
|
3605
|
+
static getSocialPostAttributionReport<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
|
|
3591
3606
|
}
|
|
3592
3607
|
|
|
3593
3608
|
declare class Titles {
|
package/package.json
CHANGED
package/src/api/SocialPosts.ts
CHANGED
|
@@ -297,6 +297,27 @@ class SocialPosts {
|
|
|
297
297
|
return Requests.processRoute(SocialPostsRoute.routes.createComment, data, { post_id });
|
|
298
298
|
}
|
|
299
299
|
|
|
300
|
+
/**
|
|
301
|
+
* Get game install attribution data for a specific social media post.
|
|
302
|
+
*
|
|
303
|
+
* @param post_id The ID of the social media post.
|
|
304
|
+
* @param params Optional query parameters (start_date, end_date, confidence_threshold).
|
|
305
|
+
* @returns A promise
|
|
306
|
+
*/
|
|
307
|
+
public static getPostAttribution<T>(post_id: string, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
308
|
+
return Requests.processRoute(SocialPostsRoute.routes.getPostAttribution, undefined, { post_id }, params);
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
/**
|
|
312
|
+
* Get a report of all social media posts for a title that are converting to game installs.
|
|
313
|
+
*
|
|
314
|
+
* @param params Query parameters (title_id, start_date, end_date, confidence_threshold).
|
|
315
|
+
* @returns A promise
|
|
316
|
+
*/
|
|
317
|
+
public static getSocialPostAttributionReport<T>(params: Record<string, any>): AxiosPromise<Response<T>> {
|
|
318
|
+
return Requests.processRoute(SocialPostsRoute.routes.getSocialPostAttributionReport, undefined, undefined, params);
|
|
319
|
+
}
|
|
320
|
+
|
|
300
321
|
}
|
|
301
322
|
|
|
302
323
|
export default SocialPosts;
|
|
@@ -2,21 +2,21 @@ import Route from "./interface";
|
|
|
2
2
|
import HTTP_METHODS from "../constants/HttpMethods";
|
|
3
3
|
|
|
4
4
|
class SocialPostsRoute {
|
|
5
|
-
|
|
5
|
+
|
|
6
6
|
public static routes: { [key: string]: Route } = {
|
|
7
7
|
getPosts: { url: '/socialposts', method: HTTP_METHODS.GET },
|
|
8
8
|
createPost: { url: '/socialposts', method: HTTP_METHODS.POST },
|
|
9
|
-
retrievePost
|
|
10
|
-
updatePost
|
|
11
|
-
deletePost
|
|
9
|
+
retrievePost: { url: '/socialposts/{post_id}', method: HTTP_METHODS.GET },
|
|
10
|
+
updatePost: { url: '/socialposts/{post_id}', method: HTTP_METHODS.PUT },
|
|
11
|
+
deletePost: { url: '/socialposts/{post_id}', method: HTTP_METHODS.DELETE },
|
|
12
12
|
dispute: { url: '/social/{post_id}/dispute', method: HTTP_METHODS.POST },
|
|
13
|
-
history
|
|
14
|
-
progression
|
|
13
|
+
history: { url: '/socialposts/{post_id}/history', method: HTTP_METHODS.GET },
|
|
14
|
+
progression: { url: '/socialposts/progression', method: HTTP_METHODS.GET },
|
|
15
15
|
addMedia: { url: '/socialposts/{post_id}/addMedia', method: HTTP_METHODS.POST },
|
|
16
16
|
removeMedia: { url: '/socialposts/{post_id}/removeMedia/{media_id}', method: HTTP_METHODS.DELETE },
|
|
17
17
|
reschedule: { url: '/socialposts/{post_id}/reschedule', method: HTTP_METHODS.POST },
|
|
18
18
|
reports: { url: '/socialposts/{post_id}/reports', method: HTTP_METHODS.GET },
|
|
19
|
-
updatePostImpressions
|
|
19
|
+
updatePostImpressions: { url: '/socialposts/{post_id}/impressions', method: HTTP_METHODS.PUT },
|
|
20
20
|
shortLinkReports: { url: '/socialposts/shortlinks/reports', method: HTTP_METHODS.GET },
|
|
21
21
|
|
|
22
22
|
// New Comment Routes
|
|
@@ -31,9 +31,11 @@ class SocialPostsRoute {
|
|
|
31
31
|
updateCommentMetrics: { url: '/socialposts/comments/{comment_id}/update-metrics', method: HTTP_METHODS.PUT },
|
|
32
32
|
createComment: { url: '/socialposts/{post_id}/comments', method: HTTP_METHODS.POST },
|
|
33
33
|
|
|
34
|
+
getPostAttribution: { url: '/socialposts/{post_id}/attribution', method: HTTP_METHODS.GET },
|
|
35
|
+
getSocialPostAttributionReport: { url: '/reports/fingerprinting/social-post-attribution', method: HTTP_METHODS.GET },
|
|
34
36
|
|
|
35
37
|
};
|
|
36
38
|
|
|
37
|
-
|
|
39
|
+
}
|
|
38
40
|
|
|
39
|
-
|
|
41
|
+
export default SocialPostsRoute;
|