@bitgo/public-types 2.32.0 → 2.32.2

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.
@@ -1,20 +1,6 @@
1
1
  import * as t from "io-ts";
2
2
  export declare const AddWalletWebhookRequestBody: {
3
- type: t.KeyofC<{
4
- txRequest: number;
5
- txRequestTransaction: number;
6
- transfer: number;
7
- transaction: number;
8
- transactionRemoved: number;
9
- transactionExpire: number;
10
- pendingapproval: number;
11
- block: number;
12
- admin: number;
13
- address_confirmation: number;
14
- lowFee: number;
15
- circuitBreaker: number;
16
- wireWithdrawal: number;
17
- }>;
3
+ type: t.KeyofC<typeof import("./webhookType").WalletWebhookTypeEnum>;
18
4
  url: import("io-ts-types").NonEmptyStringC;
19
5
  label: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
20
6
  numConfirmations: t.UnionC<[t.NumberC, import("io-ts-types").NumberFromStringC, t.UndefinedC]>;
@@ -24,21 +10,7 @@ export declare const AddWalletWebhookRequestBody: {
24
10
  txRequestTransactionStates: t.UnionC<[t.Type<("initialized" | "pendingSignature" | "eddsaPendingCommitment" | "eddsaPendingRShare" | "eddsaPendingGShare" | "ecdsaMPCv2Round1" | "ecdsaMPCv2Round2" | "ecdsaMPCv2Round3" | "readyToCombineShares" | "signed" | "held" | "delivered" | "invalidSignature" | "rejected")[], ("initialized" | "pendingSignature" | "eddsaPendingCommitment" | "eddsaPendingRShare" | "eddsaPendingGShare" | "ecdsaMPCv2Round1" | "ecdsaMPCv2Round2" | "ecdsaMPCv2Round3" | "readyToCombineShares" | "signed" | "held" | "delivered" | "invalidSignature" | "rejected")[], unknown>, t.UndefinedC]>;
25
11
  };
26
12
  export declare const AddWalletWebhookRequestBodyC: t.TypeC<{
27
- type: t.KeyofC<{
28
- txRequest: number;
29
- txRequestTransaction: number;
30
- transfer: number;
31
- transaction: number;
32
- transactionRemoved: number;
33
- transactionExpire: number;
34
- pendingapproval: number;
35
- block: number;
36
- admin: number;
37
- address_confirmation: number;
38
- lowFee: number;
39
- circuitBreaker: number;
40
- wireWithdrawal: number;
41
- }>;
13
+ type: t.KeyofC<typeof import("./webhookType").WalletWebhookTypeEnum>;
42
14
  url: import("io-ts-types").NonEmptyStringC;
43
15
  label: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
44
16
  numConfirmations: t.UnionC<[t.NumberC, import("io-ts-types").NumberFromStringC, t.UndefinedC]>;
@@ -1 +1 @@
1
- {"version":3,"file":"addWalletWebhookRequest.js","sourceRoot":"","sources":["../../../../src/schema/webhook/addWalletWebhookRequest.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAC3B,6CAA+D;AAC/D,mDAAgD;AAChD,2FAAwF;AACxF,6EAA0E;AAC1E,+CAAkD;AAErC,QAAA,2BAA2B,GAAG;IACzC,IAAI,EAAE,+BAAiB;IAMvB,GAAG,EAAE,4BAAc;IAEnB,KAAK,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,MAAM,CAAC;IAOzB,gBAAgB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,8BAAgB,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC;IAKpE,QAAQ,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,OAAO,CAAC;IAE7B,qBAAqB,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,OAAO,CAAC;IAC1C,eAAe,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,KAAK,CAAC,iDAAuB,CAAC,CAAC;IAC3D,0BAA0B,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,KAAK,CAAC,mCAAgB,CAAC,CAAC;CAChE,CAAC;AACW,QAAA,4BAA4B,GAAG,CAAC,CAAC,IAAI,CAAC;IACjD,GAAG,mCAA2B;CAC/B,CAAC,CAAC"}
1
+ {"version":3,"file":"addWalletWebhookRequest.js","sourceRoot":"","sources":["../../../../src/schema/webhook/addWalletWebhookRequest.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAC3B,6CAA+D;AAC/D,mDAAgD;AAChD,2FAAwF;AACxF,6EAA0E;AAC1E,+CAAkD;AAErC,QAAA,2BAA2B,GAAG;IAEzC,IAAI,EAAE,+BAAiB;IAMvB,GAAG,EAAE,4BAAc;IAEnB,KAAK,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,MAAM,CAAC;IAOzB,gBAAgB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,8BAAgB,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC;IAKpE,QAAQ,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,OAAO,CAAC;IAE7B,qBAAqB,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,OAAO,CAAC;IAC1C,eAAe,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,KAAK,CAAC,iDAAuB,CAAC,CAAC;IAC3D,0BAA0B,EAAE,IAAA,mBAAQ,EAAC,CAAC,CAAC,KAAK,CAAC,mCAAgB,CAAC,CAAC;CAChE,CAAC;AACW,QAAA,4BAA4B,GAAG,CAAC,CAAC,IAAI,CAAC;IACjD,GAAG,mCAA2B;CAC/B,CAAC,CAAC"}
@@ -1,17 +1,11 @@
1
1
  import * as t from "io-ts";
2
2
  export declare const AddEnterpriseWebhookRequestBody: {
3
- type: t.KeyofC<{
4
- bankAccount: number;
5
- accessToken: number;
6
- }>;
3
+ type: t.KeyofC<typeof import("./webhookType").EnterpriseWebhookTypeEnum>;
7
4
  url: import("io-ts-types").NonEmptyStringC;
8
5
  label: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
9
6
  };
10
7
  export declare const AddEnterpriseWebhookRequestBodyC: t.TypeC<{
11
- type: t.KeyofC<{
12
- bankAccount: number;
13
- accessToken: number;
14
- }>;
8
+ type: t.KeyofC<typeof import("./webhookType").EnterpriseWebhookTypeEnum>;
15
9
  url: import("io-ts-types").NonEmptyStringC;
16
10
  label: t.UnionC<[t.Type<string, string, unknown>, t.UndefinedC]>;
17
11
  }>;
@@ -44,27 +38,7 @@ export declare const ListEnterpriseWebhooksResponse: t.IntersectionC<[t.TypeC<{
44
38
  enterpriseId: t.StringC;
45
39
  organizationId: t.StringC;
46
40
  userId: t.StringC;
47
- type: t.KeyofC<{
48
- txRequest: number;
49
- txRequestTransaction: number;
50
- transfer: number;
51
- transaction: number;
52
- transactionRemoved: number;
53
- transactionExpire: number;
54
- pendingapproval: number;
55
- block: number;
56
- admin: number;
57
- address_confirmation: number;
58
- lowFee: number;
59
- circuitBreaker: number;
60
- wallet_confirmation: number;
61
- wireWithdrawal: number;
62
- bankAccount: number;
63
- userKycState: number;
64
- enterpriseKycState: number;
65
- identityStatus: number;
66
- accessToken: number;
67
- }>;
41
+ type: t.KeyofC<typeof import("./webhookType").WebhookTypeEnum>;
68
42
  numConfirmations: t.NumberC;
69
43
  lastAttempt: import("io-ts-types").DateFromISOStringC;
70
44
  failingSince: import("io-ts-types").DateFromISOStringC;
@@ -15,27 +15,7 @@ export declare const Webhook: t.IntersectionC<[t.TypeC<{
15
15
  enterpriseId: t.StringC;
16
16
  organizationId: t.StringC;
17
17
  userId: t.StringC;
18
- type: t.KeyofC<{
19
- txRequest: number;
20
- txRequestTransaction: number;
21
- transfer: number;
22
- transaction: number;
23
- transactionRemoved: number;
24
- transactionExpire: number;
25
- pendingapproval: number;
26
- block: number;
27
- admin: number;
28
- address_confirmation: number;
29
- lowFee: number;
30
- circuitBreaker: number;
31
- wallet_confirmation: number;
32
- wireWithdrawal: number;
33
- bankAccount: number;
34
- userKycState: number;
35
- enterpriseKycState: number;
36
- identityStatus: number;
37
- accessToken: number;
38
- }>;
18
+ type: t.KeyofC<typeof import("./webhookType").WebhookTypeEnum>;
39
19
  numConfirmations: t.NumberC;
40
20
  lastAttempt: import("io-ts-types").DateFromISOStringC;
41
21
  failingSince: import("io-ts-types").DateFromISOStringC;
@@ -4,27 +4,7 @@ export type WebhookNotificationState = t.TypeOf<typeof WebhookNotificationState>
4
4
  export declare const WebhookNotification: t.IntersectionC<[t.TypeC<{
5
5
  id: t.StringC;
6
6
  }>, t.PartialC<{
7
- type: t.KeyofC<{
8
- txRequest: number;
9
- txRequestTransaction: number;
10
- transfer: number;
11
- transaction: number;
12
- transactionRemoved: number;
13
- transactionExpire: number;
14
- pendingapproval: number;
15
- block: number;
16
- admin: number;
17
- address_confirmation: number;
18
- lowFee: number;
19
- circuitBreaker: number;
20
- wallet_confirmation: number;
21
- wireWithdrawal: number;
22
- bankAccount: number;
23
- userKycState: number;
24
- enterpriseKycState: number;
25
- identityStatus: number;
26
- accessToken: number;
27
- }>;
7
+ type: t.KeyofC<typeof import("./webhookType").WebhookTypeEnum>;
28
8
  wallet: t.StringC;
29
9
  url: t.StringC;
30
10
  hash: t.StringC;
@@ -1,44 +1,47 @@
1
1
  import * as t from "io-ts";
2
- export declare const WebhookType: t.KeyofC<{
3
- txRequest: number;
4
- txRequestTransaction: number;
5
- transfer: number;
6
- transaction: number;
7
- transactionRemoved: number;
8
- transactionExpire: number;
9
- pendingapproval: number;
10
- block: number;
11
- admin: number;
12
- address_confirmation: number;
13
- lowFee: number;
14
- circuitBreaker: number;
15
- wallet_confirmation: number;
16
- wireWithdrawal: number;
17
- bankAccount: number;
18
- userKycState: number;
19
- enterpriseKycState: number;
20
- identityStatus: number;
21
- accessToken: number;
22
- }>;
2
+ export declare enum WebhookTypeEnum {
3
+ "txRequest" = "txRequest",
4
+ "txRequestTransaction" = "txRequestTransaction",
5
+ "transfer" = "transfer",
6
+ "transaction" = "transaction",
7
+ "transactionRemoved" = "transactionRemoved",
8
+ "transactionExpire" = "transactionExpire",
9
+ "pendingapproval" = "pendingapproval",
10
+ "block" = "block",
11
+ "admin" = "admin",
12
+ "address_confirmation" = "address_confirmation",
13
+ "lowFee" = "lowFee",
14
+ "circuitBreaker" = "circuitBreaker",
15
+ "wallet_confirmation" = "wallet_confirmation",
16
+ "wireWithdrawal" = "wireWithdrawal",
17
+ "bankAccount" = "bankAccount",
18
+ "userKycState" = "userKycState",
19
+ "enterpriseKycState" = "enterpriseKycState",
20
+ "identityStatus" = "identityStatus",
21
+ "accessToken" = "accessToken"
22
+ }
23
+ export declare const WebhookType: t.KeyofC<typeof WebhookTypeEnum>;
23
24
  export type WebhookType = t.TypeOf<typeof WebhookType>;
24
- export declare const WalletWebhookType: t.KeyofC<{
25
- txRequest: number;
26
- txRequestTransaction: number;
27
- transfer: number;
28
- transaction: number;
29
- transactionRemoved: number;
30
- transactionExpire: number;
31
- pendingapproval: number;
32
- block: number;
33
- admin: number;
34
- address_confirmation: number;
35
- lowFee: number;
36
- circuitBreaker: number;
37
- wireWithdrawal: number;
38
- }>;
25
+ export declare enum WalletWebhookTypeEnum {
26
+ "txRequest" = "txRequest",
27
+ "txRequestTransaction" = "txRequestTransaction",
28
+ "transfer" = "transfer",
29
+ "transaction" = "transaction",
30
+ "transactionRemoved" = "transactionRemoved",
31
+ "transactionExpire" = "transactionExpire",
32
+ "pendingapproval" = "pendingapproval",
33
+ "block" = "block",
34
+ "admin" = "admin",
35
+ "address_confirmation" = "address_confirmation",
36
+ "lowFee" = "lowFee",
37
+ "circuitBreaker" = "circuitBreaker",
38
+ "wireWithdrawal" = "wireWithdrawal"
39
+ }
40
+ export declare const WalletWebhookType: t.KeyofC<typeof WalletWebhookTypeEnum>;
39
41
  export type WalletWebhookType = t.TypeOf<typeof WalletWebhookType>;
40
- export declare const EnterpriseWebhookType: t.KeyofC<{
41
- bankAccount: number;
42
- accessToken: number;
43
- }>;
42
+ export declare enum EnterpriseWebhookTypeEnum {
43
+ "bankAccount" = "bankAccount",
44
+ "accessToken" = "accessToken"
45
+ }
46
+ export declare const EnterpriseWebhookType: t.KeyofC<typeof EnterpriseWebhookTypeEnum>;
44
47
  export type EnterpriseWebhookType = t.TypeOf<typeof EnterpriseWebhookType>;
@@ -23,46 +23,52 @@ var __importStar = (this && this.__importStar) || function (mod) {
23
23
  return result;
24
24
  };
25
25
  Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.EnterpriseWebhookType = exports.WalletWebhookType = exports.WebhookType = void 0;
26
+ exports.EnterpriseWebhookType = exports.EnterpriseWebhookTypeEnum = exports.WalletWebhookType = exports.WalletWebhookTypeEnum = exports.WebhookType = exports.WebhookTypeEnum = void 0;
27
27
  const t = __importStar(require("io-ts"));
28
- exports.WebhookType = t.keyof({
29
- txRequest: 1,
30
- txRequestTransaction: 1,
31
- transfer: 1,
32
- transaction: 1,
33
- transactionRemoved: 1,
34
- transactionExpire: 1,
35
- pendingapproval: 1,
36
- block: 1,
37
- admin: 1,
38
- address_confirmation: 1,
39
- lowFee: 1,
40
- circuitBreaker: 1,
41
- wallet_confirmation: 1,
42
- wireWithdrawal: 1,
43
- bankAccount: 1,
44
- userKycState: 1,
45
- enterpriseKycState: 1,
46
- identityStatus: 1,
47
- accessToken: 1,
48
- }, "WebhookType");
49
- exports.WalletWebhookType = t.keyof({
50
- txRequest: 1,
51
- txRequestTransaction: 1,
52
- transfer: 1,
53
- transaction: 1,
54
- transactionRemoved: 1,
55
- transactionExpire: 1,
56
- pendingapproval: 1,
57
- block: 1,
58
- admin: 1,
59
- address_confirmation: 1,
60
- lowFee: 1,
61
- circuitBreaker: 1,
62
- wireWithdrawal: 1,
63
- }, "WalletWebhookType");
64
- exports.EnterpriseWebhookType = t.keyof({
65
- bankAccount: 1,
66
- accessToken: 1,
67
- }, "EnterpriseWebhookType");
28
+ var WebhookTypeEnum;
29
+ (function (WebhookTypeEnum) {
30
+ WebhookTypeEnum["txRequest"] = "txRequest";
31
+ WebhookTypeEnum["txRequestTransaction"] = "txRequestTransaction";
32
+ WebhookTypeEnum["transfer"] = "transfer";
33
+ WebhookTypeEnum["transaction"] = "transaction";
34
+ WebhookTypeEnum["transactionRemoved"] = "transactionRemoved";
35
+ WebhookTypeEnum["transactionExpire"] = "transactionExpire";
36
+ WebhookTypeEnum["pendingapproval"] = "pendingapproval";
37
+ WebhookTypeEnum["block"] = "block";
38
+ WebhookTypeEnum["admin"] = "admin";
39
+ WebhookTypeEnum["address_confirmation"] = "address_confirmation";
40
+ WebhookTypeEnum["lowFee"] = "lowFee";
41
+ WebhookTypeEnum["circuitBreaker"] = "circuitBreaker";
42
+ WebhookTypeEnum["wallet_confirmation"] = "wallet_confirmation";
43
+ WebhookTypeEnum["wireWithdrawal"] = "wireWithdrawal";
44
+ WebhookTypeEnum["bankAccount"] = "bankAccount";
45
+ WebhookTypeEnum["userKycState"] = "userKycState";
46
+ WebhookTypeEnum["enterpriseKycState"] = "enterpriseKycState";
47
+ WebhookTypeEnum["identityStatus"] = "identityStatus";
48
+ WebhookTypeEnum["accessToken"] = "accessToken";
49
+ })(WebhookTypeEnum || (exports.WebhookTypeEnum = WebhookTypeEnum = {}));
50
+ exports.WebhookType = t.keyof(WebhookTypeEnum, "WebhookType");
51
+ var WalletWebhookTypeEnum;
52
+ (function (WalletWebhookTypeEnum) {
53
+ WalletWebhookTypeEnum["txRequest"] = "txRequest";
54
+ WalletWebhookTypeEnum["txRequestTransaction"] = "txRequestTransaction";
55
+ WalletWebhookTypeEnum["transfer"] = "transfer";
56
+ WalletWebhookTypeEnum["transaction"] = "transaction";
57
+ WalletWebhookTypeEnum["transactionRemoved"] = "transactionRemoved";
58
+ WalletWebhookTypeEnum["transactionExpire"] = "transactionExpire";
59
+ WalletWebhookTypeEnum["pendingapproval"] = "pendingapproval";
60
+ WalletWebhookTypeEnum["block"] = "block";
61
+ WalletWebhookTypeEnum["admin"] = "admin";
62
+ WalletWebhookTypeEnum["address_confirmation"] = "address_confirmation";
63
+ WalletWebhookTypeEnum["lowFee"] = "lowFee";
64
+ WalletWebhookTypeEnum["circuitBreaker"] = "circuitBreaker";
65
+ WalletWebhookTypeEnum["wireWithdrawal"] = "wireWithdrawal";
66
+ })(WalletWebhookTypeEnum || (exports.WalletWebhookTypeEnum = WalletWebhookTypeEnum = {}));
67
+ exports.WalletWebhookType = t.keyof(WalletWebhookTypeEnum, "WalletWebhookType");
68
+ var EnterpriseWebhookTypeEnum;
69
+ (function (EnterpriseWebhookTypeEnum) {
70
+ EnterpriseWebhookTypeEnum["bankAccount"] = "bankAccount";
71
+ EnterpriseWebhookTypeEnum["accessToken"] = "accessToken";
72
+ })(EnterpriseWebhookTypeEnum || (exports.EnterpriseWebhookTypeEnum = EnterpriseWebhookTypeEnum = {}));
73
+ exports.EnterpriseWebhookType = t.keyof(EnterpriseWebhookTypeEnum, "EnterpriseWebhookType");
68
74
  //# sourceMappingURL=webhookType.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"webhookType.js","sourceRoot":"","sources":["../../../../src/schema/webhook/webhookType.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAEd,QAAA,WAAW,GAAG,CAAC,CAAC,KAAK,CAChC;IAEE,SAAS,EAAE,CAAC;IAEZ,oBAAoB,EAAE,CAAC;IACvB,QAAQ,EAAE,CAAC;IACX,WAAW,EAAE,CAAC;IACd,kBAAkB,EAAE,CAAC;IACrB,iBAAiB,EAAE,CAAC;IACpB,eAAe,EAAE,CAAC;IAClB,KAAK,EAAE,CAAC;IACR,KAAK,EAAE,CAAC;IACR,oBAAoB,EAAE,CAAC;IACvB,MAAM,EAAE,CAAC;IACT,cAAc,EAAE,CAAC;IAGjB,mBAAmB,EAAE,CAAC;IAEtB,cAAc,EAAE,CAAC;IACjB,WAAW,EAAE,CAAC;IACd,YAAY,EAAE,CAAC;IACf,kBAAkB,EAAE,CAAC;IACrB,cAAc,EAAE,CAAC;IAEjB,WAAW,EAAE,CAAC;CACf,EACD,aAAa,CACd,CAAC;AAKW,QAAA,iBAAiB,GAAG,CAAC,CAAC,KAAK,CACtC;IACE,SAAS,EAAE,CAAC;IACZ,oBAAoB,EAAE,CAAC;IACvB,QAAQ,EAAE,CAAC;IACX,WAAW,EAAE,CAAC;IACd,kBAAkB,EAAE,CAAC;IACrB,iBAAiB,EAAE,CAAC;IACpB,eAAe,EAAE,CAAC;IAClB,KAAK,EAAE,CAAC;IACR,KAAK,EAAE,CAAC;IACR,oBAAoB,EAAE,CAAC;IACvB,MAAM,EAAE,CAAC;IACT,cAAc,EAAE,CAAC;IACjB,cAAc,EAAE,CAAC;CAClB,EACD,mBAAmB,CACpB,CAAC;AAGW,QAAA,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAC1C;IACE,WAAW,EAAE,CAAC;IACd,WAAW,EAAE,CAAC;CACf,EACD,uBAAuB,CACxB,CAAC"}
1
+ {"version":3,"file":"webhookType.js","sourceRoot":"","sources":["../../../../src/schema/webhook/webhookType.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,yCAA2B;AAE3B,IAAY,eA0BX;AA1BD,WAAY,eAAe;IAEzB,0CAAyB,CAAA;IAEzB,gEAA+C,CAAA;IAC/C,wCAAuB,CAAA;IACvB,8CAA6B,CAAA;IAC7B,4DAA2C,CAAA;IAC3C,0DAAyC,CAAA;IACzC,sDAAqC,CAAA;IACrC,kCAAiB,CAAA;IACjB,kCAAiB,CAAA;IACjB,gEAA+C,CAAA;IAC/C,oCAAmB,CAAA;IACnB,oDAAmC,CAAA;IAGnC,8DAA6C,CAAA;IAE7C,oDAAmC,CAAA;IACnC,8CAA6B,CAAA;IAC7B,gDAA+B,CAAA;IAC/B,4DAA2C,CAAA;IAC3C,oDAAmC,CAAA;IAEnC,8CAA6B,CAAA;AAC/B,CAAC,EA1BW,eAAe,+BAAf,eAAe,QA0B1B;AAEY,QAAA,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,eAAe,EAAE,aAAa,CAAC,CAAC;AAGnE,IAAY,qBAcX;AAdD,WAAY,qBAAqB;IAC/B,gDAAyB,CAAA;IACzB,sEAA+C,CAAA;IAC/C,8CAAuB,CAAA;IACvB,oDAA6B,CAAA;IAC7B,kEAA2C,CAAA;IAC3C,gEAAyC,CAAA;IACzC,4DAAqC,CAAA;IACrC,wCAAiB,CAAA;IACjB,wCAAiB,CAAA;IACjB,sEAA+C,CAAA;IAC/C,0CAAmB,CAAA;IACnB,0DAAmC,CAAA;IACnC,0DAAmC,CAAA;AACrC,CAAC,EAdW,qBAAqB,qCAArB,qBAAqB,QAchC;AAEY,QAAA,iBAAiB,GAAG,CAAC,CAAC,KAAK,CACtC,qBAAqB,EACrB,mBAAmB,CACpB,CAAC;AAGF,IAAY,yBAGX;AAHD,WAAY,yBAAyB;IACnC,wDAA6B,CAAA;IAC7B,wDAA6B,CAAA;AAC/B,CAAC,EAHW,yBAAyB,yCAAzB,yBAAyB,QAGpC;AACY,QAAA,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAC1C,yBAAyB,EACzB,uBAAuB,CACxB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bitgo/public-types",
3
- "version": "2.32.0",
3
+ "version": "2.32.2",
4
4
  "description": "Collection of types exposed externally as part of the BitGo public API",
5
5
  "license": "UNLICENSED",
6
6
  "author": "",
@@ -6,6 +6,7 @@ import { TransactionState } from "../transactionRequest/transactionState";
6
6
  import { WalletWebhookType } from "./webhookType";
7
7
 
8
8
  export const AddWalletWebhookRequestBody = {
9
+ /** Event type to listen to. */
9
10
  type: WalletWebhookType,
10
11
  /**
11
12
  * URL to fire the webhook to.
@@ -1,64 +1,64 @@
1
1
  import * as t from "io-ts";
2
2
 
3
- export const WebhookType = t.keyof(
4
- {
5
- // Webhook for txRequest.state changes
6
- txRequest: 1,
7
- // Webhook for any txRequest.transactions[].state changes
8
- txRequestTransaction: 1,
9
- transfer: 1,
10
- transaction: 1,
11
- transactionRemoved: 1,
12
- transactionExpire: 1,
13
- pendingapproval: 1,
14
- block: 1,
15
- admin: 1,
16
- address_confirmation: 1,
17
- lowFee: 1,
18
- circuitBreaker: 1,
3
+ export enum WebhookTypeEnum {
4
+ // Webhook for txRequest.state changes
5
+ "txRequest" = "txRequest",
6
+ // Webhook for any txRequest.transactions[].state changes
7
+ "txRequestTransaction" = "txRequestTransaction",
8
+ "transfer" = "transfer",
9
+ "transaction" = "transaction",
10
+ "transactionRemoved" = "transactionRemoved",
11
+ "transactionExpire" = "transactionExpire",
12
+ "pendingapproval" = "pendingapproval",
13
+ "block" = "block",
14
+ "admin" = "admin",
15
+ "address_confirmation" = "address_confirmation",
16
+ "lowFee" = "lowFee",
17
+ "circuitBreaker" = "circuitBreaker",
19
18
 
20
- // Specific to User Webhooks
21
- wallet_confirmation: 1,
19
+ // Specific to User Webhooks
20
+ "wallet_confirmation" = "wallet_confirmation",
22
21
 
23
- wireWithdrawal: 1,
24
- bankAccount: 1,
25
- userKycState: 1,
26
- enterpriseKycState: 1,
27
- identityStatus: 1,
22
+ "wireWithdrawal" = "wireWithdrawal",
23
+ "bankAccount" = "bankAccount",
24
+ "userKycState" = "userKycState",
25
+ "enterpriseKycState" = "enterpriseKycState",
26
+ "identityStatus" = "identityStatus",
28
27
 
29
- accessToken: 1,
30
- },
31
- "WebhookType",
32
- );
28
+ "accessToken" = "accessToken",
29
+ }
33
30
 
31
+ export const WebhookType = t.keyof(WebhookTypeEnum, "WebhookType");
34
32
  export type WebhookType = t.TypeOf<typeof WebhookType>;
35
33
 
36
- /** Subscribe to Transaction Request Transaction State Changes */
34
+ export enum WalletWebhookTypeEnum {
35
+ "txRequest" = "txRequest",
36
+ "txRequestTransaction" = "txRequestTransaction",
37
+ "transfer" = "transfer",
38
+ "transaction" = "transaction",
39
+ "transactionRemoved" = "transactionRemoved",
40
+ "transactionExpire" = "transactionExpire",
41
+ "pendingapproval" = "pendingapproval",
42
+ "block" = "block",
43
+ "admin" = "admin",
44
+ "address_confirmation" = "address_confirmation",
45
+ "lowFee" = "lowFee",
46
+ "circuitBreaker" = "circuitBreaker",
47
+ "wireWithdrawal" = "wireWithdrawal",
48
+ }
49
+
37
50
  export const WalletWebhookType = t.keyof(
38
- {
39
- txRequest: 1,
40
- txRequestTransaction: 1,
41
- transfer: 1,
42
- transaction: 1,
43
- transactionRemoved: 1,
44
- transactionExpire: 1,
45
- pendingapproval: 1,
46
- block: 1,
47
- admin: 1,
48
- address_confirmation: 1,
49
- lowFee: 1,
50
- circuitBreaker: 1,
51
- wireWithdrawal: 1,
52
- },
51
+ WalletWebhookTypeEnum,
53
52
  "WalletWebhookType",
54
53
  );
55
54
  export type WalletWebhookType = t.TypeOf<typeof WalletWebhookType>;
56
55
 
56
+ export enum EnterpriseWebhookTypeEnum {
57
+ "bankAccount" = "bankAccount",
58
+ "accessToken" = "accessToken",
59
+ }
57
60
  export const EnterpriseWebhookType = t.keyof(
58
- {
59
- bankAccount: 1,
60
- accessToken: 1,
61
- },
61
+ EnterpriseWebhookTypeEnum,
62
62
  "EnterpriseWebhookType",
63
63
  );
64
64
  export type EnterpriseWebhookType = t.TypeOf<typeof EnterpriseWebhookType>;