revenuecat-api 1.0.2 → 1.0.4
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/README.md +2 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -4
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -64,6 +64,8 @@ The client can optionally handle RevenueCat's rate limiting by:
|
|
|
64
64
|
- Automatically retrying failed requests (up to 3 times by default)
|
|
65
65
|
- Managing per-endpoint rate limit states
|
|
66
66
|
|
|
67
|
+
_Note that automatic rate limiting functionality is still in early development stages and may not be production ready_
|
|
68
|
+
|
|
67
69
|
You can opt into automatic rate limiting if desired:
|
|
68
70
|
|
|
69
71
|
```typescript
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import createClient, { type ClientOptions } from "openapi-fetch";
|
|
2
|
-
import type { paths } from "./__generated/revenuecat-api-v2";
|
|
3
|
-
export
|
|
2
|
+
import type { paths, components } from "./__generated/revenuecat-api-v2";
|
|
3
|
+
export type { paths, components };
|
|
4
4
|
export type CreateRevenueCatClientOptions = ClientOptions & {
|
|
5
5
|
automaticRateLimit?: boolean;
|
|
6
6
|
};
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,EAAE,EACnB,KAAK,aAAa,EAEnB,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,iCAAiC,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,EAAE,EACnB,KAAK,aAAa,EAEnB,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAGzE,YAAY,EAAE,KAAK,EAAE,UAAU,EAAE,CAAC;AAElC,MAAM,MAAM,6BAA6B,GAAG,aAAa,GAAG;IAC1D,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B,CAAC;AAOF,wBAAgB,sBAAsB,CACpC,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,6BAA6B,8DA2BxC"}
|
package/dist/index.js
CHANGED
|
@@ -32,14 +32,10 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
32
32
|
return result;
|
|
33
33
|
};
|
|
34
34
|
})();
|
|
35
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
36
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
|
-
};
|
|
38
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
36
|
exports.createRevenueCatClient = createRevenueCatClient;
|
|
40
37
|
const openapi_fetch_1 = __importStar(require("openapi-fetch"));
|
|
41
38
|
const rateLimitMiddleware_1 = require("./rateLimitMiddleware");
|
|
42
|
-
__exportStar(require("./__generated/revenuecat-api-v2"), exports);
|
|
43
39
|
const defaultOptions = {
|
|
44
40
|
baseUrl: "https://api.revenuecat.com/v2",
|
|
45
41
|
automaticRateLimit: false,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "revenuecat-api",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "Type-safe RevenueCat API client using fetch with automatic rate limiting",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
"openapi-fetch": "^0.14.0"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
|
-
"@eslint/js": "^9.
|
|
26
|
-
"@types/node": "^24.0
|
|
27
|
-
"eslint": "^9.
|
|
25
|
+
"@eslint/js": "^9.32.0",
|
|
26
|
+
"@types/node": "^24.1.0",
|
|
27
|
+
"eslint": "^9.32.0",
|
|
28
28
|
"globals": "^16.3.0",
|
|
29
29
|
"openapi-typescript": "^7.8.0",
|
|
30
30
|
"typescript": "^5.8.3",
|
|
31
|
-
"typescript-eslint": "^8.
|
|
31
|
+
"typescript-eslint": "^8.38.0",
|
|
32
32
|
"vitest": "^3.2.4"
|
|
33
33
|
},
|
|
34
34
|
"scripts": {
|