@blocklet/payment-types 1.13.113

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.
@@ -0,0 +1,63 @@
1
+ import { CreationOptional, DataTypes, InferAttributes, InferCreationAttributes, Model } from 'sequelize';
2
+ import type { LiteralUnion } from 'type-fest';
3
+ export declare class WebhookAttempt extends Model<InferAttributes<WebhookAttempt>, InferCreationAttributes<WebhookAttempt>> {
4
+ id: CreationOptional<string>;
5
+ livemode: boolean;
6
+ event_id: string;
7
+ webhook_endpoint_id: string;
8
+ status: LiteralUnion<'succeeded' | 'failed', string>;
9
+ response_status: number;
10
+ response_body: any;
11
+ retry_count: number;
12
+ created_at: CreationOptional<Date>;
13
+ updated_at: CreationOptional<Date>;
14
+ static readonly GENESIS_ATTRIBUTES: {
15
+ id: {
16
+ type: DataTypes.StringDataType;
17
+ primaryKey: boolean;
18
+ allowNull: boolean;
19
+ defaultValue: (size?: number | undefined) => string;
20
+ };
21
+ livemode: {
22
+ type: DataTypes.AbstractDataTypeConstructor;
23
+ allowNull: boolean;
24
+ };
25
+ event_id: {
26
+ type: DataTypes.StringDataType;
27
+ allowNull: boolean;
28
+ };
29
+ webhook_endpoint_id: {
30
+ type: DataTypes.StringDataType;
31
+ allowNull: boolean;
32
+ };
33
+ status: {
34
+ type: DataTypes.EnumDataType<"enabled" | "disabled">;
35
+ allowNull: boolean;
36
+ };
37
+ response_status: {
38
+ type: DataTypes.IntegerDataTypeConstructor;
39
+ allowNull: boolean;
40
+ };
41
+ response_body: {
42
+ type: DataTypes.AbstractDataTypeConstructor;
43
+ allowNull: boolean;
44
+ };
45
+ retry_count: {
46
+ type: DataTypes.IntegerDataTypeConstructor;
47
+ defaultValue: number;
48
+ };
49
+ created_at: {
50
+ type: DataTypes.DateDataTypeConstructor;
51
+ defaultValue: DataTypes.AbstractDataTypeConstructor;
52
+ allowNull: boolean;
53
+ };
54
+ updated_at: {
55
+ type: DataTypes.DateDataTypeConstructor;
56
+ defaultValue: DataTypes.AbstractDataTypeConstructor;
57
+ allowNull: boolean;
58
+ };
59
+ };
60
+ static initialize(sequelize: any): void;
61
+ static associate(models: any): void;
62
+ }
63
+ export type TWebhookAttempt = InferAttributes<WebhookAttempt>;
@@ -0,0 +1,68 @@
1
+ import { CreationOptional, DataTypes, InferAttributes, InferCreationAttributes, Model } from 'sequelize';
2
+ import type { LiteralUnion } from 'type-fest';
3
+ import type { EventType } from './types';
4
+ export declare class WebhookEndpoint extends Model<InferAttributes<WebhookEndpoint>, InferCreationAttributes<WebhookEndpoint>> {
5
+ id: CreationOptional<string>;
6
+ livemode: boolean;
7
+ api_version: string;
8
+ url: string;
9
+ description: string;
10
+ enabled_events: EventType[];
11
+ metadata: Record<string, any>;
12
+ status: LiteralUnion<'enabled' | 'disabled', string>;
13
+ created_at: CreationOptional<Date>;
14
+ created_via: LiteralUnion<'api' | 'dashboard' | 'portal', string>;
15
+ updated_at: CreationOptional<Date>;
16
+ static readonly GENESIS_ATTRIBUTES: {
17
+ id: {
18
+ type: DataTypes.StringDataType;
19
+ primaryKey: boolean;
20
+ allowNull: boolean;
21
+ defaultValue: (size?: number | undefined) => string;
22
+ };
23
+ livemode: {
24
+ type: DataTypes.AbstractDataTypeConstructor;
25
+ allowNull: boolean;
26
+ };
27
+ api_version: {
28
+ type: DataTypes.StringDataType;
29
+ allowNull: boolean;
30
+ };
31
+ url: {
32
+ type: DataTypes.StringDataType;
33
+ allowNull: boolean;
34
+ };
35
+ description: {
36
+ type: DataTypes.StringDataType;
37
+ allowNull: boolean;
38
+ };
39
+ enabled_events: {
40
+ type: DataTypes.AbstractDataTypeConstructor;
41
+ allowNull: boolean;
42
+ };
43
+ metadata: {
44
+ type: DataTypes.AbstractDataTypeConstructor;
45
+ allowNull: boolean;
46
+ };
47
+ status: {
48
+ type: DataTypes.EnumDataType<"enabled" | "disabled">;
49
+ allowNull: boolean;
50
+ };
51
+ created_at: {
52
+ type: DataTypes.DateDataTypeConstructor;
53
+ defaultValue: DataTypes.AbstractDataTypeConstructor;
54
+ allowNull: boolean;
55
+ };
56
+ created_via: {
57
+ type: DataTypes.EnumDataType<"api" | "dashboard" | "portal">;
58
+ };
59
+ updated_at: {
60
+ type: DataTypes.DateDataTypeConstructor;
61
+ defaultValue: DataTypes.AbstractDataTypeConstructor;
62
+ allowNull: boolean;
63
+ };
64
+ };
65
+ static initialize(sequelize: any): void;
66
+ static associate(models: any): void;
67
+ }
68
+ export type TWebhookEndpoint = InferAttributes<WebhookEndpoint>;
package/package.json ADDED
@@ -0,0 +1,52 @@
1
+ {
2
+ "name": "@blocklet/payment-types",
3
+ "version": "1.13.113",
4
+ "description": "Typings for Payment Kit SDK",
5
+ "keywords": [
6
+ "types",
7
+ "stripe"
8
+ ],
9
+ "author": "wangshijun <wangshijun2010@gmail.com>",
10
+ "homepage": "https://github.com/blocklet/payment-kit#readme",
11
+ "license": "Apache-2.0",
12
+ "main": "index.js",
13
+ "typings": "lib/index.d.ts",
14
+ "files": [
15
+ "lib",
16
+ "index.js",
17
+ "LICENSE",
18
+ "package.json",
19
+ "README.md"
20
+ ],
21
+ "publishConfig": {
22
+ "access": "public"
23
+ },
24
+ "repository": {
25
+ "type": "git",
26
+ "url": "git+https://github.com/blocklet/payment-kit.git"
27
+ },
28
+ "scripts": {},
29
+ "bugs": {
30
+ "url": "https://github.com/blocklet/payment-kit/issues"
31
+ },
32
+ "importSort": {
33
+ ".js, .jsx, .mjs": {
34
+ "parser": "babylon",
35
+ "style": "module"
36
+ },
37
+ ".ts, .tsx": {
38
+ "style": "module",
39
+ "parser": "typescript"
40
+ }
41
+ },
42
+ "devDependencies": {
43
+ "@arcblock/eslint-config": "^0.2.4",
44
+ "@arcblock/eslint-config-ts": "^0.2.4",
45
+ "import-sort-style-module": "^6.0.0",
46
+ "prettier": "^2.8.8",
47
+ "prettier-plugin-import-sort": "^0.0.7",
48
+ "sequelize": "^6.35.1",
49
+ "type-fest": "^4.8.3"
50
+ },
51
+ "gitHead": "d1a99d9bbdb06d4e7742d7741ec511fa0fee4663"
52
+ }