glitch-javascript-sdk 1.1.3 → 1.1.5
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 +68 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Campaigns.d.ts +10 -0
- package/dist/esm/api/Influencers.d.ts +40 -0
- package/dist/esm/index.js +68 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +50 -0
- package/package.json +1 -1
- package/src/api/Campaigns.ts +14 -0
- package/src/api/Influencers.ts +56 -0
- package/src/routes/CampaignsRoute.ts +1 -0
- package/src/routes/InfluencerRoutes.ts +5 -1
|
@@ -413,6 +413,16 @@ declare class Campaigns {
|
|
|
413
413
|
*/
|
|
414
414
|
static widthdrawInfluencerInvite<T>(campaign_id: string, influencer_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
415
415
|
/**
|
|
416
|
+
* The route to mark an influencer reachout and finished, and it will no longer send reachouts.
|
|
417
|
+
*
|
|
418
|
+
* @see https://api.glitch.fun/api/documentation#/Campaigns/finishInfluencerInvite
|
|
419
|
+
*
|
|
420
|
+
* @param campaign_id The id fo the campaign to retrieve.
|
|
421
|
+
*
|
|
422
|
+
* @returns promise
|
|
423
|
+
*/
|
|
424
|
+
static finishInfluencerInvite<T>(campaign_id: string, influencer_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
425
|
+
/**
|
|
416
426
|
* The route to accept an influnecers request to join the campaign.
|
|
417
427
|
*
|
|
418
428
|
* @see https://api.glitch.fun/api/documentation#/Campaigns/acceptInfluencer
|
|
@@ -25,5 +25,45 @@ declare class Influencers {
|
|
|
25
25
|
* @returns promise
|
|
26
26
|
*/
|
|
27
27
|
static generateProfile<T>(influencer_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
28
|
+
/**
|
|
29
|
+
* List all the notes left about an influencer.
|
|
30
|
+
*
|
|
31
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/getInfluencersNotes
|
|
32
|
+
*
|
|
33
|
+
* @returns promise
|
|
34
|
+
*/
|
|
35
|
+
static listNotes<T>(influencer_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
36
|
+
/**
|
|
37
|
+
* View a note left about an influencer.
|
|
38
|
+
*
|
|
39
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/getInfluencersNote
|
|
40
|
+
*
|
|
41
|
+
* @returns promise
|
|
42
|
+
*/
|
|
43
|
+
static viewNote<T>(influencer_id: string, note_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
44
|
+
/**
|
|
45
|
+
* Create a new note about an influencer.
|
|
46
|
+
*
|
|
47
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/createInfluencersNotes
|
|
48
|
+
*
|
|
49
|
+
* @returns promise
|
|
50
|
+
*/
|
|
51
|
+
static createNote<T>(influencer_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
52
|
+
/**
|
|
53
|
+
* Update a note about an influencer.
|
|
54
|
+
*
|
|
55
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/updateInfluencersNote
|
|
56
|
+
*
|
|
57
|
+
* @returns promise
|
|
58
|
+
*/
|
|
59
|
+
static updateNote<T>(influencer_id: string, note_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
60
|
+
/**
|
|
61
|
+
* Delete a note about an influencer.
|
|
62
|
+
*
|
|
63
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/deleteInfluencersNote
|
|
64
|
+
*
|
|
65
|
+
* @returns promise
|
|
66
|
+
*/
|
|
67
|
+
static deleteNote<T>(influencer_id: string, note_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
28
68
|
}
|
|
29
69
|
export default Influencers;
|
package/dist/esm/index.js
CHANGED
|
@@ -9143,6 +9143,7 @@ var CampaignsRoute = /** @class */ (function () {
|
|
|
9143
9143
|
acceptInfluencerInvite: { url: '/campaigns/{campaign_id}/influencers/invites/{influencer_id}/accept', method: HTTP_METHODS.POST },
|
|
9144
9144
|
declineInfluencerInvite: { url: '/campaigns/{campaign_id}/influencers/invites/{influencer_id}/decline', method: HTTP_METHODS.POST },
|
|
9145
9145
|
widthdrawInfluencerInvite: { url: '/campaigns/{campaign_id}/influencers/invites/{influencer_id}/withdraw', method: HTTP_METHODS.POST },
|
|
9146
|
+
finishInfluencerInvite: { url: '/campaigns/{campaign_id}/influencers/invites/{influencer_id}/finish', method: HTTP_METHODS.POST },
|
|
9146
9147
|
acceptInfluencerRequest: { url: '/campaigns/{campaign_id}/influencers/{user_id}/accept', method: HTTP_METHODS.POST },
|
|
9147
9148
|
declineInfluencerRequest: { url: '/campaigns/{campaign_id}/influencers/{user_id}/deny', method: HTTP_METHODS.POST },
|
|
9148
9149
|
reviewInfluencerRequest: { url: '/campaigns/{campaign_id}/influencers/{user_id}/review', method: HTTP_METHODS.POST },
|
|
@@ -9656,6 +9657,18 @@ var Campaigns = /** @class */ (function () {
|
|
|
9656
9657
|
return Requests.processRoute(CampaignsRoute.routes.widthdrawInfluencerInvite, data, { campaign_id: campaign_id, influencer_id: influencer_id }, params);
|
|
9657
9658
|
};
|
|
9658
9659
|
/**
|
|
9660
|
+
* The route to mark an influencer reachout and finished, and it will no longer send reachouts.
|
|
9661
|
+
*
|
|
9662
|
+
* @see https://api.glitch.fun/api/documentation#/Campaigns/finishInfluencerInvite
|
|
9663
|
+
*
|
|
9664
|
+
* @param campaign_id The id fo the campaign to retrieve.
|
|
9665
|
+
*
|
|
9666
|
+
* @returns promise
|
|
9667
|
+
*/
|
|
9668
|
+
Campaigns.finishInfluencerInvite = function (campaign_id, influencer_id, data, params) {
|
|
9669
|
+
return Requests.processRoute(CampaignsRoute.routes.finishInfluencerInvite, data, { campaign_id: campaign_id, influencer_id: influencer_id }, params);
|
|
9670
|
+
};
|
|
9671
|
+
/**
|
|
9659
9672
|
* The route to accept an influnecers request to join the campaign.
|
|
9660
9673
|
*
|
|
9661
9674
|
* @see https://api.glitch.fun/api/documentation#/Campaigns/acceptInfluencer
|
|
@@ -9981,6 +9994,11 @@ var InfluencerRoutes = /** @class */ (function () {
|
|
|
9981
9994
|
listInfluencers: { url: '/influencers', method: HTTP_METHODS.GET },
|
|
9982
9995
|
viewInfluencer: { url: '/influencers/{influencer_id}', method: HTTP_METHODS.GET },
|
|
9983
9996
|
generateProfile: { url: '/influencers/{influencer_id}/generateProfile', method: HTTP_METHODS.POST },
|
|
9997
|
+
listNotes: { url: '/influencers/{influencer_id}/notes', method: HTTP_METHODS.GET },
|
|
9998
|
+
viewNote: { url: '/influencers/{influencer_id}/notes/{note_id}', method: HTTP_METHODS.GET },
|
|
9999
|
+
createNote: { url: '/influencers/{influencer_id}/notes', method: HTTP_METHODS.POST },
|
|
10000
|
+
updateNote: { url: '/influencers/{influencer_id}/notes/{note_id}', method: HTTP_METHODS.PUT },
|
|
10001
|
+
deleteNote: { url: '/influencers/{influencer_id}/notes/{note_id}', method: HTTP_METHODS.DELETE },
|
|
9984
10002
|
};
|
|
9985
10003
|
return InfluencerRoutes;
|
|
9986
10004
|
}());
|
|
@@ -10018,6 +10036,56 @@ var Influencers = /** @class */ (function () {
|
|
|
10018
10036
|
Influencers.generateProfile = function (influencer_id, params) {
|
|
10019
10037
|
return Requests.processRoute(InfluencerRoutes.routes.generateProfile, undefined, { influencer_id: influencer_id }, params);
|
|
10020
10038
|
};
|
|
10039
|
+
/**
|
|
10040
|
+
* List all the notes left about an influencer.
|
|
10041
|
+
*
|
|
10042
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/getInfluencersNotes
|
|
10043
|
+
*
|
|
10044
|
+
* @returns promise
|
|
10045
|
+
*/
|
|
10046
|
+
Influencers.listNotes = function (influencer_id, params) {
|
|
10047
|
+
return Requests.processRoute(InfluencerRoutes.routes.listNotes, undefined, { influencer_id: influencer_id }, params);
|
|
10048
|
+
};
|
|
10049
|
+
/**
|
|
10050
|
+
* View a note left about an influencer.
|
|
10051
|
+
*
|
|
10052
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/getInfluencersNote
|
|
10053
|
+
*
|
|
10054
|
+
* @returns promise
|
|
10055
|
+
*/
|
|
10056
|
+
Influencers.viewNote = function (influencer_id, note_id, params) {
|
|
10057
|
+
return Requests.processRoute(InfluencerRoutes.routes.viewNote, undefined, { influencer_id: influencer_id, note_id: note_id }, params);
|
|
10058
|
+
};
|
|
10059
|
+
/**
|
|
10060
|
+
* Create a new note about an influencer.
|
|
10061
|
+
*
|
|
10062
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/createInfluencersNotes
|
|
10063
|
+
*
|
|
10064
|
+
* @returns promise
|
|
10065
|
+
*/
|
|
10066
|
+
Influencers.createNote = function (influencer_id, data, params) {
|
|
10067
|
+
return Requests.processRoute(InfluencerRoutes.routes.createNote, data, { influencer_id: influencer_id }, params);
|
|
10068
|
+
};
|
|
10069
|
+
/**
|
|
10070
|
+
* Update a note about an influencer.
|
|
10071
|
+
*
|
|
10072
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/updateInfluencersNote
|
|
10073
|
+
*
|
|
10074
|
+
* @returns promise
|
|
10075
|
+
*/
|
|
10076
|
+
Influencers.updateNote = function (influencer_id, note_id, data, params) {
|
|
10077
|
+
return Requests.processRoute(InfluencerRoutes.routes.updateNote, data, { influencer_id: influencer_id, note_id: note_id }, params);
|
|
10078
|
+
};
|
|
10079
|
+
/**
|
|
10080
|
+
* Delete a note about an influencer.
|
|
10081
|
+
*
|
|
10082
|
+
* @see https://api.glitch.fun/api/documentation#/Influencers/deleteInfluencersNote
|
|
10083
|
+
*
|
|
10084
|
+
* @returns promise
|
|
10085
|
+
*/
|
|
10086
|
+
Influencers.deleteNote = function (influencer_id, note_id, data, params) {
|
|
10087
|
+
return Requests.processRoute(InfluencerRoutes.routes.deleteNote, data, { influencer_id: influencer_id, note_id: note_id }, params);
|
|
10088
|
+
};
|
|
10021
10089
|
return Influencers;
|
|
10022
10090
|
}());
|
|
10023
10091
|
|