@silexpert/core 1.3.82 → 1.3.83
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/api/resources/Subscription.d.ts +2 -1
- package/dist/cjs/api/resources/Subscription.d.ts.map +1 -1
- package/dist/cjs/api/resources/Subscription.js +3 -0
- package/dist/cjs/api/resources/Subscription.js.map +1 -1
- package/dist/cjs/types/Enum/Feature.d.ts +2 -1
- package/dist/cjs/types/Enum/Feature.d.ts.map +1 -1
- package/dist/cjs/types/Enum/Feature.js +1 -0
- package/dist/cjs/types/Enum/Feature.js.map +1 -1
- package/dist/cjs/types/Enum/TerminationList.js +1 -1
- package/dist/cjs/types/Enum/TerminationList.js.map +1 -1
- package/dist/cjs/types/Interface/api/stripe/Update.d.ts +4 -0
- package/dist/cjs/types/Interface/api/stripe/Update.d.ts.map +1 -0
- package/dist/cjs/types/Interface/api/stripe/Update.js +26 -0
- package/dist/cjs/types/Interface/api/stripe/Update.js.map +1 -0
- package/dist/cjs/types/index.d.ts +1 -0
- package/dist/cjs/types/index.d.ts.map +1 -1
- package/dist/cjs/types/index.js +1 -0
- package/dist/cjs/types/index.js.map +1 -1
- package/dist/mjs/api/resources/Subscription.d.ts +2 -1
- package/dist/mjs/api/resources/Subscription.d.ts.map +1 -1
- package/dist/mjs/api/resources/Subscription.js +3 -0
- package/dist/mjs/api/resources/Subscription.js.map +1 -1
- package/dist/mjs/types/Enum/Feature.d.ts +2 -1
- package/dist/mjs/types/Enum/Feature.d.ts.map +1 -1
- package/dist/mjs/types/Enum/Feature.js +1 -0
- package/dist/mjs/types/Enum/Feature.js.map +1 -1
- package/dist/mjs/types/Enum/TerminationList.js +1 -1
- package/dist/mjs/types/Enum/TerminationList.js.map +1 -1
- package/dist/mjs/types/Interface/api/stripe/Update.d.ts +4 -0
- package/dist/mjs/types/Interface/api/stripe/Update.d.ts.map +1 -0
- package/dist/mjs/types/Interface/api/stripe/Update.js +23 -0
- package/dist/mjs/types/Interface/api/stripe/Update.js.map +1 -0
- package/dist/mjs/types/index.d.ts +1 -0
- package/dist/mjs/types/index.d.ts.map +1 -1
- package/dist/mjs/types/index.js +1 -0
- package/dist/mjs/types/index.js.map +1 -1
- package/package.json +13 -13
- package/ts/api/resources/Subscription.ts +10 -1
- package/ts/types/Enum/Feature.ts +1 -0
- package/ts/types/Enum/TerminationList.ts +1 -1
- package/ts/types/Interface/api/stripe/Update.ts +11 -0
- package/ts/types/index.ts +1 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@silexpert/core",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.83",
|
|
4
4
|
"description": "Silex Core perform HTTP Request and object binding. Silex core helps developers to retrieve and return formatted object",
|
|
5
5
|
"homepage": "https://gitlab.compta-clementine.fr/dev/silex-api",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -32,17 +32,17 @@
|
|
|
32
32
|
"author": "Silex",
|
|
33
33
|
"license": "ISC",
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@babel/cli": "^7.
|
|
36
|
-
"@babel/core": "^7.
|
|
37
|
-
"@babel/plugin-transform-runtime": "^7.
|
|
38
|
-
"@babel/preset-env": "^7.
|
|
39
|
-
"@babel/runtime": "^7.
|
|
35
|
+
"@babel/cli": "^7.28.0",
|
|
36
|
+
"@babel/core": "^7.28.0",
|
|
37
|
+
"@babel/plugin-transform-runtime": "^7.28.0",
|
|
38
|
+
"@babel/preset-env": "^7.28.0",
|
|
39
|
+
"@babel/runtime": "^7.28.2",
|
|
40
40
|
"@types/bluebird": "^3.5.34",
|
|
41
41
|
"@types/browser-or-node": "^1.3.0",
|
|
42
42
|
"@types/ejs": "^3.0.6",
|
|
43
43
|
"@types/node": "^22.10.5",
|
|
44
44
|
"@types/validator": "^13.11.1",
|
|
45
|
-
"babel-plugin-replace-import-extension": "^1.1.
|
|
45
|
+
"babel-plugin-replace-import-extension": "^1.1.5",
|
|
46
46
|
"babel-preset-env": "^1.7.0",
|
|
47
47
|
"eslint": "^9.17.0",
|
|
48
48
|
"eslint-config-airbnb-typescript": "^18.0.0",
|
|
@@ -63,17 +63,17 @@
|
|
|
63
63
|
},
|
|
64
64
|
"types": "dist/cjs/index.d.ts",
|
|
65
65
|
"dependencies": {
|
|
66
|
-
"@types/geojson": "^7946.0.
|
|
67
|
-
"@types/mailparser": "^3.4.
|
|
66
|
+
"@types/geojson": "^7946.0.16",
|
|
67
|
+
"@types/mailparser": "^3.4.6",
|
|
68
68
|
"axios": "0.22.0",
|
|
69
69
|
"browser-or-node": "^3.0.0",
|
|
70
70
|
"class-transformer": "^0.5.1",
|
|
71
|
-
"class-validator": "^0.14.
|
|
71
|
+
"class-validator": "^0.14.2",
|
|
72
72
|
"dayjs": "^1.11.11",
|
|
73
73
|
"ejs": "^3.1.9",
|
|
74
|
-
"libphonenumber-js": "^1.
|
|
75
|
-
"mailparser": "^3.4
|
|
76
|
-
"rxjs": "^7.
|
|
74
|
+
"libphonenumber-js": "^1.12.10",
|
|
75
|
+
"mailparser": "^3.7.4",
|
|
76
|
+
"rxjs": "^7.8.2",
|
|
77
77
|
"sms-segments-calculator": "^1.2.0",
|
|
78
78
|
"stripe": "^18.1.1",
|
|
79
79
|
"ts-enum-util": "^4.0.2"
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { Resource } from '../Resource';
|
|
2
|
-
import {
|
|
2
|
+
import {
|
|
3
|
+
CreateSubscriptionSession,
|
|
4
|
+
CreateStripePortals,
|
|
5
|
+
CreateCommercialSession,
|
|
6
|
+
UpdateStripeSubscription,
|
|
7
|
+
} from '../../types';
|
|
3
8
|
import type Stripe from 'stripe';
|
|
4
9
|
|
|
5
10
|
export class Subscription extends Resource {
|
|
@@ -42,4 +47,8 @@ export class Subscription extends Resource {
|
|
|
42
47
|
get(): Promise<Stripe.Response<Stripe.Subscription> | null> {
|
|
43
48
|
return this.axios.$get('/stripe/subscriptions');
|
|
44
49
|
}
|
|
50
|
+
|
|
51
|
+
update(payload: UpdateStripeSubscription): Promise<Stripe.Response<Stripe.Subscription>> {
|
|
52
|
+
return this.axios.$put('/stripe/subscriptions', payload);
|
|
53
|
+
}
|
|
45
54
|
}
|
package/ts/types/Enum/Feature.ts
CHANGED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { IsBoolean, IsOptional } from 'class-validator';
|
|
2
|
+
import { ApiPropertyOptional } from '../../../../utils';
|
|
3
|
+
import { ToBoolean } from '../../../../utils/transforms/boolean.transform';
|
|
4
|
+
|
|
5
|
+
export class UpdateStripeSubscription {
|
|
6
|
+
@ApiPropertyOptional({ description: 'If true, it will end the trial period' })
|
|
7
|
+
@IsBoolean()
|
|
8
|
+
@ToBoolean()
|
|
9
|
+
@IsOptional()
|
|
10
|
+
shouldEndTrial?: boolean;
|
|
11
|
+
}
|
package/ts/types/index.ts
CHANGED
|
@@ -998,6 +998,7 @@ export * from './Interface/api/connection/ReadConnectionState';
|
|
|
998
998
|
export * from './Interface/api/qonto/Query';
|
|
999
999
|
export * from './Interface/api/qonto/Create';
|
|
1000
1000
|
export * from './Interface/api/stripe/Create';
|
|
1001
|
+
export * from './Interface/api/stripe/Update';
|
|
1001
1002
|
export * from './Interface/api/qonto/UpdateConnection';
|
|
1002
1003
|
export * from './Interface/api/qonto/GetConnectionInformation';
|
|
1003
1004
|
export * from './Interface/api/qonto/Read';
|