@anitrack/patreon-wrapper 1.5.3 → 1.6.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.
package/tsconfig.json CHANGED
@@ -1,102 +1,14 @@
1
- {
2
- "compilerOptions": {
3
- /* Visit https://aka.ms/tsconfig.json to read more about this file */
4
-
5
- /* Projects */
6
- // "incremental": true, /* Enable incremental compilation */
7
- // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */
8
- // "tsBuildInfoFile": "./", /* Specify the folder for .tsbuildinfo incremental compilation files. */
9
- // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects */
10
- // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */
11
- // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
12
-
13
- /* Language and Environment */
14
- "target": "es2021" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */,
15
- // "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */
16
- // "jsx": "preserve", /* Specify what JSX code is generated. */
17
- // "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */
18
- // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */
19
- // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h' */
20
- // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */
21
- // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using `jsx: react-jsx*`.` */
22
- // "reactNamespace": "", /* Specify the object invoked for `createElement`. This only applies when targeting `react` JSX emit. */
23
- // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */
24
- // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
25
-
26
- /* Modules */
27
- "module": "commonjs" /* Specify what module code is generated. */,
28
- // "rootDir": "./", /* Specify the root folder within your source files. */
29
- // "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */
30
- // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */
31
- // "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */
32
- // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */
33
- // "typeRoots": [], /* Specify multiple folders that act like `./node_modules/@types`. */
34
- // "types": [], /* Specify type package names to be included without being referenced in a source file. */
35
- // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */
36
- // "resolveJsonModule": true, /* Enable importing .json files */
37
- // "noResolve": true, /* Disallow `import`s, `require`s or `<reference>`s from expanding the number of files TypeScript should add to a project. */
38
-
39
- /* JavaScript Support */
40
- // "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the `checkJS` option to get errors from these files. */
41
- // "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */
42
- // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from `node_modules`. Only applicable with `allowJs`. */
43
-
44
- /* Emit */
45
- "declaration": true /* Generate .d.ts files from TypeScript and JavaScript files in your project. */,
46
- "declarationMap": true /* Create sourcemaps for d.ts files. */,
47
- // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */
48
- "sourceMap": true /* Create source map files for emitted JavaScript files. */,
49
- // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If `declaration` is true, also designates a file that bundles all .d.ts output. */
50
- "outDir": "lib" /* Specify an output folder for all emitted files. */,
51
- // "removeComments": true, /* Disable emitting comments. */
52
- // "noEmit": true, /* Disable emitting files from a compilation. */
53
- // "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */
54
- // "importsNotUsedAsValues": "remove", /* Specify emit/checking behavior for imports that are only used for types */
55
- // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */
56
- // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */
57
- // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
58
- // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */
59
- // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */
60
- // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */
61
- // "newLine": "crlf", /* Set the newline character for emitting files. */
62
- // "stripInternal": true, /* Disable emitting declarations that have `@internal` in their JSDoc comments. */
63
- // "noEmitHelpers": true, /* Disable generating custom helper functions like `__extends` in compiled output. */
64
- // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */
65
- // "preserveConstEnums": true, /* Disable erasing `const enum` declarations in generated code. */
66
- // "declarationDir": "./", /* Specify the output directory for generated declaration files. */
67
- // "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */
68
-
69
- /* Interop Constraints */
70
- // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */
71
- // "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */
72
- "esModuleInterop": true /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables `allowSyntheticDefaultImports` for type compatibility. */,
73
- // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */
74
- "forceConsistentCasingInFileNames": true /* Ensure that casing is correct in imports. */,
75
-
76
- /* Type Checking */
77
- "strict": true /* Enable all strict type-checking options. */,
78
- // "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied `any` type.. */
79
- // "strictNullChecks": true, /* When type checking, take into account `null` and `undefined`. */
80
- // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */
81
- // "strictBindCallApply": true, /* Check that the arguments for `bind`, `call`, and `apply` methods match the original function. */
82
- // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */
83
- // "noImplicitThis": true, /* Enable error reporting when `this` is given the type `any`. */
84
- // "useUnknownInCatchVariables": true, /* Type catch clause variables as 'unknown' instead of 'any'. */
85
- // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */
86
- // "noUnusedLocals": true, /* Enable error reporting when a local variables aren't read. */
87
- // "noUnusedParameters": true, /* Raise an error when a function parameter isn't read */
88
- // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */
89
- // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */
90
- // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */
91
- // "noUncheckedIndexedAccess": true, /* Include 'undefined' in index signature results */
92
- // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */
93
- // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type */
94
- // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */
95
- // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */
96
-
97
- /* Completeness */
98
- // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
99
- "skipLibCheck": true /* Skip type checking all .d.ts files. */
100
- },
101
- "include": ["src"]
102
- }
1
+ {
2
+ "compilerOptions": {
3
+ "target": "es2021",
4
+ "module": "commonjs",
5
+ "declaration": true,
6
+ "declarationMap": true,
7
+ "sourceMap": true,
8
+ "esModuleInterop": true,
9
+ "forceConsistentCasingInFileNames": true,
10
+ "strict": true,
11
+ "skipLibCheck": true,
12
+ },
13
+ "include": ["src"],
14
+ }
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,YAAY,GAClB,eAAe,GACf,iBAAiB,GACjB,eAAe,CAAC;AAEtB,MAAM,MAAM,aAAa,GAAG;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;I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,MAAM,GAAG,IAAI,CAAC;YAClB,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;SACtB,CAAC;KACL,CAAC;CACL,CAAC;AAEF,qBAAa,OAAO;IAChB,OAAO,CAAC,MAAM,CAAC,IAAI,CAAoD;IAEvE,OAAO,CAAC,MAAM,CAAC,YAAY,CAAS;IACpC,OAAO,CAAC,MAAM,CAAC,WAAW,CAAS;IACnC,OAAO,CAAC,MAAM,CAAC,eAAe,CAA6B;WAE7C,aAAa,CAAC,eAAe,EAAE,aAAa;mBAWrC,QAAQ;IAe7B,OAAO,CAAC,MAAM,CAAC,QAAQ;WAOH,YAAY,CAC5B,OAAO,GAAE,KAAK,CAAC,YAAY,CAAqB,EAChD,QAAQ,GAAE,MAAY,EACtB,kBAAkB,GAAE,OAAe;IAgIvC,SAAS,CAAC,MAAM,CAAC,iBAAiB,CAAC,MAAM,EAAE,cAAc;IAIzD,SAAS,CAAC,MAAM,CAAC,iBAAiB;CAOrC;AAED,qBAAa,OAAQ,SAAQ,OAAO;WAClB,UAAU;WAIV,SAAS,CAAC,MAAM,EAAE,cAAc;CAGjD"}
package/lib/index.js DELETED
@@ -1,157 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.Sandbox = exports.Patreon = void 0;
7
- const axios_1 = __importDefault(require("axios"));
8
- class Patreon {
9
- static Authorization(AuthCredentials) {
10
- if (!AuthCredentials.AccessToken || !AuthCredentials.CampaignID) {
11
- throw new Error('AccessToken and CampaignID are required on Authorization');
12
- }
13
- this._AccessToken = AuthCredentials.AccessToken;
14
- this._CampaignID = AuthCredentials.CampaignID;
15
- }
16
- static async FetchAPI(URI) {
17
- if (!this._AccessToken || !this._CampaignID) {
18
- throw new Error('AccessToken and CampaignID are required on Authorization');
19
- }
20
- return await (0, axios_1.default)(this._URL + URI, {
21
- method: 'GET',
22
- headers: { Authorization: 'Bearer ' + this._AccessToken },
23
- }).catch((err) => {
24
- throw new Error('Fetch API Failed...' + err);
25
- });
26
- }
27
- static CleanURL(query) {
28
- query = query.replaceAll('[', '%5B').replaceAll(']', '%5D');
29
- query = query.replaceAll(' ', '');
30
- return query;
31
- }
32
- static async FetchPatrons(filters = ['active_patron'], pageSize = 450, showSandboxPatrons = false) {
33
- const { data } = await this.FetchAPI(this.CleanURL(`campaigns/${this._CampaignID}/` +
34
- `members ? include = user, currently_entitled_tiers & page[count] = ${pageSize} & fields[member] = campaign_lifetime_support_cents, currently_entitled_amount_cents, email, full_name, is_follower, last_charge_date, last_charge_status, lifetime_support_cents, next_charge_date, note, patron_status, pledge_cadence, pledge_relationship_start, will_pay_amount_cents & fields[user] = social_connections & fields[tier] = title`));
35
- const Patrons = [];
36
- const PatreonAPIPatrons = data?.data || [];
37
- if (PatreonAPIPatrons.length == 0)
38
- return [];
39
- // Format Real Patrons
40
- for (let x = 0; x < PatreonAPIPatrons.length; x++) {
41
- const Relationships = PatreonAPIPatrons[x].relationships;
42
- const Attributes = PatreonAPIPatrons[x].attributes;
43
- if (!filters.includes(Attributes.patron_status))
44
- continue;
45
- const socialInfo = data.included.find((patron) => patron.id == Relationships.user.data.id &&
46
- patron.type === 'user');
47
- const tierInfo = data.included.find((patron) => patron.id ==
48
- Relationships.currently_entitled_tiers?.data[0]?.id &&
49
- patron.type === 'tier');
50
- Patrons.push({
51
- displayId: Relationships.user.data.id,
52
- displayName: Attributes.full_name,
53
- emailAddress: Attributes.email,
54
- isFollower: Attributes.is_follower,
55
- subscription: {
56
- note: Attributes.note,
57
- currentEntitled: {
58
- status: Attributes.patron_status,
59
- tier: {
60
- id: tierInfo ? tierInfo.id : null,
61
- title: tierInfo ? tierInfo.attributes.title : null,
62
- },
63
- cents: Attributes.currently_entitled_amount_cents != 0
64
- ? Attributes.currently_entitled_amount_cents
65
- : null,
66
- willPayCents: Attributes.will_pay_amount_cents,
67
- lifetimeCents: Attributes.lifetime_support_cents,
68
- firstCharge: Attributes.pledge_relationship_start,
69
- nextCharge: Attributes.next_charge_date,
70
- lastCharge: Attributes.last_charge_date,
71
- },
72
- },
73
- mediaConnection: {
74
- patreon: {
75
- id: Relationships.user.data.id,
76
- url: Relationships.user.links.related,
77
- },
78
- discord: {
79
- id: socialInfo?.attributes?.social_connections?.discord
80
- ?.user_id
81
- ? socialInfo?.attributes?.social_connections
82
- ?.discord?.user_id
83
- : null,
84
- url: 'https://discordapp.com/users/' +
85
- socialInfo?.attributes?.social_connections?.discord
86
- ?.user_id
87
- ? socialInfo?.attributes?.social_connections
88
- ?.discord?.user_id
89
- : null,
90
- },
91
- },
92
- });
93
- }
94
- if (showSandboxPatrons) {
95
- // Format Sandbox Patrons
96
- for (let x = 0; x < this._SandboxPatrons.length; x++) {
97
- const Patron = this._SandboxPatrons[x];
98
- Patrons.push({
99
- displayId: Patron.displayId,
100
- displayName: Patron.displayName,
101
- emailAddress: Patron.emailAddress,
102
- isFollower: false,
103
- subscription: {
104
- note: 'Sandbox',
105
- currentEntitled: {
106
- status: Patron.patronStatus,
107
- tier: {
108
- id: Patron.tier.id,
109
- title: Patron.tier.title,
110
- },
111
- cents: Patron.cents,
112
- willPayCents: Patron.willPayCents,
113
- lifetimeCents: Patron.lifetimeCents,
114
- firstCharge: Patron.firstCharge,
115
- nextCharge: Patron.nextCharge,
116
- lastCharge: Patron.lastCharge,
117
- },
118
- },
119
- mediaConnection: {
120
- patreon: {
121
- id: Patron.mediaConnection.patreon.id,
122
- url: Patron.mediaConnection.patreon.url,
123
- },
124
- discord: {
125
- id: Patron?.mediaConnection?.discord?.id
126
- ? Patron?.mediaConnection?.discord?.id
127
- : null,
128
- url: Patron?.mediaConnection?.discord?.url
129
- ? Patron?.mediaConnection?.discord?.id
130
- : null,
131
- },
132
- },
133
- });
134
- }
135
- }
136
- return Patrons;
137
- }
138
- static _SandboxAddPatron(Patron) {
139
- this._SandboxPatrons.push(Patron);
140
- }
141
- static _SandboxGetPatron() {
142
- return this._SandboxPatrons;
143
- }
144
- }
145
- exports.Patreon = Patreon;
146
- Patreon._URL = 'https://www.patreon.com/api/oauth2/v2/';
147
- Patreon._SandboxPatrons = [];
148
- class Sandbox extends Patreon {
149
- static GetPatrons() {
150
- return super._SandboxGetPatron();
151
- }
152
- static AddPatron(Patron) {
153
- super._SandboxAddPatron(Patron);
154
- }
155
- }
156
- exports.Sandbox = Sandbox;
157
- //# sourceMappingURL=index.js.map
package/lib/index.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAwE1B,MAAa,OAAO;IAOT,MAAM,CAAC,aAAa,CAAC,eAA8B;QACtD,IAAI,CAAC,eAAe,CAAC,WAAW,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;YAC9D,MAAM,IAAI,KAAK,CACX,0DAA0D,CAC7D,CAAC;QACN,CAAC;QAED,IAAI,CAAC,YAAY,GAAG,eAAe,CAAC,WAAW,CAAC;QAChD,IAAI,CAAC,WAAW,GAAG,eAAe,CAAC,UAAU,CAAC;IAClD,CAAC;IAEO,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAW;QACrC,IAAI,CAAC,IAAI,CAAC,YAAY,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC;YAC1C,MAAM,IAAI,KAAK,CACX,0DAA0D,CAC7D,CAAC;QACN,CAAC;QAED,OAAO,MAAM,IAAA,eAAK,EAAC,IAAI,CAAC,IAAI,GAAG,GAAG,EAAE;YAChC,MAAM,EAAE,KAAK;YACb,OAAO,EAAE,EAAE,aAAa,EAAE,SAAS,GAAG,IAAI,CAAC,YAAY,EAAE;SAC5D,CAAC,CAAC,KAAK,CAAC,CAAC,GAAU,EAAE,EAAE;YACpB,MAAM,IAAI,KAAK,CAAC,qBAAqB,GAAG,GAAG,CAAC,CAAC;QACjD,CAAC,CAAC,CAAC;IACP,C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