@pax2pay/model-banking 0.1.584 → 0.1.585
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/Transaction/Amount/Charge/index.ts +0 -39
- package/dist/cjs/Audit.d.ts +1 -1
- package/dist/cjs/Client/Transactions/index.d.ts +2 -2
- package/dist/cjs/Operation/Status.d.ts +1 -1
- package/dist/cjs/Rail/index.d.ts +2 -2
- package/dist/cjs/Transaction/Amount/Charge/index.d.ts +0 -9
- package/dist/cjs/Transaction/Amount/Charge/index.js +0 -20
- package/dist/cjs/Transaction/Amount/Charge/index.js.map +1 -1
- package/dist/cjs/Transaction/index.d.ts +1 -1
- package/dist/cjs/User/Access/Permission.d.ts +4 -4
- package/dist/cjs/User/Access/index.d.ts +4 -4
- package/dist/cjs/User/JWT/Payload.d.ts +12 -12
- package/dist/cjs/User/index.d.ts +8 -8
- package/dist/mjs/Audit.d.ts +1 -1
- package/dist/mjs/Client/Transactions/index.d.ts +2 -2
- package/dist/mjs/Operation/Status.d.ts +1 -1
- package/dist/mjs/Rail/index.d.ts +2 -2
- package/dist/mjs/Transaction/Amount/Charge/index.d.ts +0 -9
- package/dist/mjs/Transaction/Amount/Charge/index.js +0 -20
- package/dist/mjs/Transaction/Amount/Charge/index.js.map +1 -1
- package/dist/mjs/Transaction/index.d.ts +1 -1
- package/dist/mjs/User/Access/Permission.d.ts +4 -4
- package/dist/mjs/User/Access/index.d.ts +4 -4
- package/dist/mjs/User/JWT/Payload.d.ts +12 -12
- package/dist/mjs/User/index.d.ts +8 -8
- package/package.json +1 -1
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { isoly } from "isoly"
|
|
2
2
|
import { isly } from "isly"
|
|
3
3
|
import { Card } from "../../../Card"
|
|
4
|
-
import { Rail } from "../../../Rail"
|
|
5
|
-
import { PreTransaction } from "../../PreTransaction"
|
|
6
4
|
|
|
7
5
|
export interface Charge {
|
|
8
6
|
merchant?: Charge.Merchant
|
|
@@ -39,46 +37,9 @@ export namespace Charge {
|
|
|
39
37
|
}),
|
|
40
38
|
})
|
|
41
39
|
}
|
|
42
|
-
export type ChargeTransaction = PreTransaction.Incoming & { account: Rail.Address.Internal }
|
|
43
40
|
export function total(currency: isoly.Currency, charges: Charge): number {
|
|
44
41
|
return isoly.Currency.add(currency, charges.fx?.amount ?? 0, charges.merchant?.amount ?? 0)
|
|
45
42
|
}
|
|
46
|
-
export function toTransactions(
|
|
47
|
-
charge: Charge,
|
|
48
|
-
account: string,
|
|
49
|
-
id: string,
|
|
50
|
-
currency: isoly.Currency,
|
|
51
|
-
fxCollectAccount: string
|
|
52
|
-
): {
|
|
53
|
-
merchant: ChargeTransaction | undefined
|
|
54
|
-
fx: ChargeTransaction | undefined
|
|
55
|
-
} {
|
|
56
|
-
const merchant =
|
|
57
|
-
charge.merchant && toTransaction(charge.merchant, account, id, currency, fxCollectAccount, "merchant")
|
|
58
|
-
const fx = charge.fx && toTransaction(charge.fx, account, id, currency, fxCollectAccount, "fx")
|
|
59
|
-
return { merchant, fx }
|
|
60
|
-
}
|
|
61
|
-
function toTransaction(
|
|
62
|
-
charge: Charge.Merchant | Charge.Fx,
|
|
63
|
-
account: string,
|
|
64
|
-
id: string,
|
|
65
|
-
currency: isoly.Currency,
|
|
66
|
-
fxCollectAccount: string,
|
|
67
|
-
type: "merchant" | "fx"
|
|
68
|
-
): ChargeTransaction {
|
|
69
|
-
const accountId = Merchant.type.is(charge) ? charge.destination.account : fxCollectAccount
|
|
70
|
-
return {
|
|
71
|
-
type: "incoming",
|
|
72
|
-
account: { type: "internal", identifier: accountId },
|
|
73
|
-
counterpart: { type: "internal", identifier: account },
|
|
74
|
-
currency: currency,
|
|
75
|
-
amount: charge.amount,
|
|
76
|
-
description: `${type} charge for transaction ${id}`,
|
|
77
|
-
posted: isoly.DateTime.now(),
|
|
78
|
-
rail: "internal",
|
|
79
|
-
reference: { reference: id, returnId: id },
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
43
|
export const type = isly.object<Charge>({
|
|
83
44
|
merchant: Charge.Merchant.type.optional(),
|
|
84
45
|
fx: Charge.Fx.type.optional(),
|
package/dist/cjs/Audit.d.ts
CHANGED
|
@@ -20,6 +20,6 @@ export declare namespace Audit {
|
|
|
20
20
|
readonly clearbank: readonly ["assessmentFailed", "validationFailed"];
|
|
21
21
|
};
|
|
22
22
|
const keys: (keyof typeof value)[];
|
|
23
|
-
const type: isly.Type<"clearbank" | "rule" | "
|
|
23
|
+
const type: isly.Type<"clearbank" | "rule" | "account" | "transaction" | "organization" | "user" | "settlements" | "marqeta" | "label" | "route">;
|
|
24
24
|
}
|
|
25
25
|
}
|
|
@@ -50,8 +50,8 @@ export declare namespace Transactions {
|
|
|
50
50
|
end: string | undefined;
|
|
51
51
|
currency: string | undefined;
|
|
52
52
|
organization: string | undefined;
|
|
53
|
-
rail: "paxgiro" | "mastercard" | "diners" | "visa" | "paxgiro-credit" | "
|
|
54
|
-
type: "
|
|
53
|
+
rail: "paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "transfer" | "fasterpayments" | "chaps" | "bacs" | "credit" | undefined;
|
|
54
|
+
type: "internal" | "card" | "external" | "system" | undefined;
|
|
55
55
|
}>;
|
|
56
56
|
function parse(query: string | http.Request["search"]): Query;
|
|
57
57
|
}
|
|
@@ -2,5 +2,5 @@ import { isly } from "isly";
|
|
|
2
2
|
export type Status = typeof Status.values[number];
|
|
3
3
|
export declare namespace Status {
|
|
4
4
|
const values: readonly ["pending", "success", "failed"];
|
|
5
|
-
const type: isly.Type<"
|
|
5
|
+
const type: isly.Type<"pending" | "success" | "failed">;
|
|
6
6
|
}
|
package/dist/cjs/Rail/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { Address as RailAddress } from "./Address";
|
|
|
4
4
|
export type Rail = typeof Rail.rails[number];
|
|
5
5
|
export declare namespace Rail {
|
|
6
6
|
const rails: readonly ["internal", "paxgiro", "paxgiro-credit", "mastercard", "diners", "visa", "fasterpayments", "chaps", "bacs", "transfer", "credit"];
|
|
7
|
-
const type: isly.Type<"paxgiro" | "mastercard" | "diners" | "visa" | "paxgiro-credit" | "
|
|
8
|
-
const type2: isly2.String<"paxgiro" | "mastercard" | "diners" | "visa" | "paxgiro-credit" | "
|
|
7
|
+
const type: isly.Type<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "transfer" | "fasterpayments" | "chaps" | "bacs" | "credit">;
|
|
8
|
+
const type2: isly2.String<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "transfer" | "fasterpayments" | "chaps" | "bacs" | "credit">;
|
|
9
9
|
export import Address = RailAddress;
|
|
10
10
|
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { isoly } from "isoly";
|
|
2
2
|
import { Card } from "../../../Card";
|
|
3
|
-
import { Rail } from "../../../Rail";
|
|
4
|
-
import { PreTransaction } from "../../PreTransaction";
|
|
5
3
|
export interface Charge {
|
|
6
4
|
merchant?: Charge.Merchant;
|
|
7
5
|
fx?: Charge.Fx;
|
|
@@ -27,13 +25,6 @@ export declare namespace Charge {
|
|
|
27
25
|
namespace Merchant {
|
|
28
26
|
const type: import("isly/dist/cjs/object").IslyObject<Merchant, object>;
|
|
29
27
|
}
|
|
30
|
-
type ChargeTransaction = PreTransaction.Incoming & {
|
|
31
|
-
account: Rail.Address.Internal;
|
|
32
|
-
};
|
|
33
28
|
function total(currency: isoly.Currency, charges: Charge): number;
|
|
34
|
-
function toTransactions(charge: Charge, account: string, id: string, currency: isoly.Currency, fxCollectAccount: string): {
|
|
35
|
-
merchant: ChargeTransaction | undefined;
|
|
36
|
-
fx: ChargeTransaction | undefined;
|
|
37
|
-
};
|
|
38
29
|
const type: import("isly/dist/cjs/object").IslyObject<Charge, object>;
|
|
39
30
|
}
|
|
@@ -30,26 +30,6 @@ var Charge;
|
|
|
30
30
|
return isoly_1.isoly.Currency.add(currency, charges.fx?.amount ?? 0, charges.merchant?.amount ?? 0);
|
|
31
31
|
}
|
|
32
32
|
Charge.total = total;
|
|
33
|
-
function toTransactions(charge, account, id, currency, fxCollectAccount) {
|
|
34
|
-
const merchant = charge.merchant && toTransaction(charge.merchant, account, id, currency, fxCollectAccount, "merchant");
|
|
35
|
-
const fx = charge.fx && toTransaction(charge.fx, account, id, currency, fxCollectAccount, "fx");
|
|
36
|
-
return { merchant, fx };
|
|
37
|
-
}
|
|
38
|
-
Charge.toTransactions = toTransactions;
|
|
39
|
-
function toTransaction(charge, account, id, currency, fxCollectAccount, type) {
|
|
40
|
-
const accountId = Merchant.type.is(charge) ? charge.destination.account : fxCollectAccount;
|
|
41
|
-
return {
|
|
42
|
-
type: "incoming",
|
|
43
|
-
account: { type: "internal", identifier: accountId },
|
|
44
|
-
counterpart: { type: "internal", identifier: account },
|
|
45
|
-
currency: currency,
|
|
46
|
-
amount: charge.amount,
|
|
47
|
-
description: `${type} charge for transaction ${id}`,
|
|
48
|
-
posted: isoly_1.isoly.DateTime.now(),
|
|
49
|
-
rail: "internal",
|
|
50
|
-
reference: { reference: id, returnId: id },
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
33
|
Charge.type = isly_1.isly.object({
|
|
54
34
|
merchant: Charge.Merchant.type.optional(),
|
|
55
35
|
fx: Charge.Fx.type.optional(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../Transaction/Amount/Charge/index.ts"],"names":[],"mappings":";;;AAAA,iCAA6B;AAC7B,+BAA2B;AAC3B,wCAAoC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../Transaction/Amount/Charge/index.ts"],"names":[],"mappings":";;;AAAA,iCAA6B;AAC7B,+BAA2B;AAC3B,wCAAoC;AAMpC,IAAiB,MAAM,CAsCtB;AAtCD,WAAiB,MAAM;IAMtB,IAAiB,EAAE,CAMlB;IAND,WAAiB,EAAE;QACL,OAAI,GAAG,WAAI,CAAC,MAAM,CAAK;YACnC,MAAM,EAAE,WAAI,CAAC,MAAM,EAAE;YACrB,IAAI,EAAE,WAAI,CAAC,MAAM,EAAE;YACnB,MAAM,EAAE,WAAI,CAAC,KAAK,CAAC,WAAI,CAAC,MAAM,CAAC,IAAI,EAAE,WAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;SAC5D,CAAC,CAAA;IACH,CAAC,EANgB,EAAE,GAAF,SAAE,KAAF,SAAE,QAMlB;IAQD,IAAiB,QAAQ,CAUxB;IAVD,WAAiB,QAAQ;QACX,aAAI,GAAG,WAAI,CAAC,MAAM,CAAW;YACzC,MAAM,EAAE,WAAI,CAAC,MAAM,EAAE;YACrB,IAAI,EAAE,WAAI,CAAC,MAAM,EAAE;YACnB,QAAQ,EAAE,WAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,IAAI;YACxC,MAAM,EAAE,WAAI,CAAC,KAAK,CAAC,WAAI,CAAC,MAAM,CAAC,IAAI,EAAE,WAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAC5D,WAAW,EAAE,WAAI,CAAC,MAAM,CAAC;gBACxB,OAAO,EAAE,WAAI,CAAC,MAAM,EAAE;aACtB,CAAC;SACF,CAAC,CAAA;IACH,CAAC,EAVgB,QAAQ,GAAR,eAAQ,KAAR,eAAQ,QAUxB;IACD,SAAgB,KAAK,CAAC,QAAwB,EAAE,OAAe;QAC9D,OAAO,aAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,QAAQ,EAAE,OAAO,CAAC,EAAE,EAAE,MAAM,IAAI,CAAC,EAAE,OAAO,CAAC,QAAQ,EAAE,MAAM,IAAI,CAAC,CAAC,CAAA;IAC5F,CAAC;IAFe,YAAK,QAEpB,CAAA;IACY,WAAI,GAAG,WAAI,CAAC,MAAM,CAAS;QACvC,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,EAAE;QACzC,EAAE,EAAE,MAAM,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE;KAC7B,CAAC,CAAA;AACH,CAAC,EAtCgB,MAAM,sBAAN,MAAM,QAsCtB"}
|
|
@@ -142,6 +142,6 @@ export declare namespace Transaction {
|
|
|
142
142
|
counterpart: Extract<Transaction["counterpart"], Rail.Address.Card.Counterpart>;
|
|
143
143
|
};
|
|
144
144
|
namespace CardTransaction {
|
|
145
|
-
const type: import("isly/dist/cjs/object").IslyObject<CardTransaction, Omit<Transaction, "
|
|
145
|
+
const type: import("isly/dist/cjs/object").IslyObject<CardTransaction, Omit<Transaction, "account" | "counterpart">>;
|
|
146
146
|
}
|
|
147
147
|
}
|
|
@@ -32,24 +32,24 @@ export declare namespace Permission {
|
|
|
32
32
|
const typeZod: zod.ZodEnum<{
|
|
33
33
|
rule: "rule";
|
|
34
34
|
card: "card";
|
|
35
|
-
organization: "organization";
|
|
36
35
|
transaction: "transaction";
|
|
37
36
|
settlement: "settlement";
|
|
37
|
+
organization: "organization";
|
|
38
38
|
user: "user";
|
|
39
39
|
log: "log";
|
|
40
40
|
operation: "operation";
|
|
41
41
|
"*": "*";
|
|
42
42
|
treasury: "treasury";
|
|
43
43
|
}>;
|
|
44
|
-
const type: isly.Type<"rule" | "card" | "
|
|
44
|
+
const type: isly.Type<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury">;
|
|
45
45
|
}
|
|
46
|
-
const type: isly.Type<Partial<Record<"rule" | "card" | "
|
|
46
|
+
const type: isly.Type<Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>>;
|
|
47
47
|
const typeZod: zod.ZodRecord<zod.ZodEnum<{
|
|
48
48
|
rule: "rule";
|
|
49
49
|
card: "card";
|
|
50
|
-
organization: "organization";
|
|
51
50
|
transaction: "transaction";
|
|
52
51
|
settlement: "settlement";
|
|
52
|
+
organization: "organization";
|
|
53
53
|
user: "user";
|
|
54
54
|
log: "log";
|
|
55
55
|
operation: "operation";
|
|
@@ -8,9 +8,9 @@ export declare namespace Access {
|
|
|
8
8
|
uk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
9
9
|
rule: "rule";
|
|
10
10
|
card: "card";
|
|
11
|
-
organization: "organization";
|
|
12
11
|
transaction: "transaction";
|
|
13
12
|
settlement: "settlement";
|
|
13
|
+
organization: "organization";
|
|
14
14
|
user: "user";
|
|
15
15
|
log: "log";
|
|
16
16
|
operation: "operation";
|
|
@@ -25,9 +25,9 @@ export declare namespace Access {
|
|
|
25
25
|
uguk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
26
26
|
rule: "rule";
|
|
27
27
|
card: "card";
|
|
28
|
-
organization: "organization";
|
|
29
28
|
transaction: "transaction";
|
|
30
29
|
settlement: "settlement";
|
|
30
|
+
organization: "organization";
|
|
31
31
|
user: "user";
|
|
32
32
|
log: "log";
|
|
33
33
|
operation: "operation";
|
|
@@ -42,9 +42,9 @@ export declare namespace Access {
|
|
|
42
42
|
eea: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
43
43
|
rule: "rule";
|
|
44
44
|
card: "card";
|
|
45
|
-
organization: "organization";
|
|
46
45
|
transaction: "transaction";
|
|
47
46
|
settlement: "settlement";
|
|
47
|
+
organization: "organization";
|
|
48
48
|
user: "user";
|
|
49
49
|
log: "log";
|
|
50
50
|
operation: "operation";
|
|
@@ -59,9 +59,9 @@ export declare namespace Access {
|
|
|
59
59
|
test: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
60
60
|
rule: "rule";
|
|
61
61
|
card: "card";
|
|
62
|
-
organization: "organization";
|
|
63
62
|
transaction: "transaction";
|
|
64
63
|
settlement: "settlement";
|
|
64
|
+
organization: "organization";
|
|
65
65
|
user: "user";
|
|
66
66
|
log: "log";
|
|
67
67
|
operation: "operation";
|
|
@@ -6,7 +6,7 @@ export declare namespace Payload {
|
|
|
6
6
|
namespace Creatable {
|
|
7
7
|
const type: import("isly/dist/cjs/object").IslyObject<{
|
|
8
8
|
sub: string;
|
|
9
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
9
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
10
10
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
11
11
|
}, object>;
|
|
12
12
|
const typeZod: zod.ZodObject<{
|
|
@@ -14,9 +14,9 @@ export declare namespace Payload {
|
|
|
14
14
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
15
15
|
rule: "rule";
|
|
16
16
|
card: "card";
|
|
17
|
-
organization: "organization";
|
|
18
17
|
transaction: "transaction";
|
|
19
18
|
settlement: "settlement";
|
|
19
|
+
organization: "organization";
|
|
20
20
|
user: "user";
|
|
21
21
|
log: "log";
|
|
22
22
|
operation: "operation";
|
|
@@ -43,7 +43,7 @@ export declare namespace Payload {
|
|
|
43
43
|
iat: number;
|
|
44
44
|
iss: string;
|
|
45
45
|
sub: string;
|
|
46
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
46
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
47
47
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
48
48
|
token?: string | undefined;
|
|
49
49
|
}, object>;
|
|
@@ -55,9 +55,9 @@ export declare namespace Payload {
|
|
|
55
55
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
56
56
|
rule: "rule";
|
|
57
57
|
card: "card";
|
|
58
|
-
organization: "organization";
|
|
59
58
|
transaction: "transaction";
|
|
60
59
|
settlement: "settlement";
|
|
60
|
+
organization: "organization";
|
|
61
61
|
user: "user";
|
|
62
62
|
log: "log";
|
|
63
63
|
operation: "operation";
|
|
@@ -85,7 +85,7 @@ export declare namespace Payload {
|
|
|
85
85
|
iat: number;
|
|
86
86
|
iss: string;
|
|
87
87
|
sub: string;
|
|
88
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
88
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
89
89
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
90
90
|
id: string;
|
|
91
91
|
token?: string | undefined;
|
|
@@ -94,7 +94,7 @@ export declare namespace Payload {
|
|
|
94
94
|
iat: number;
|
|
95
95
|
iss: string;
|
|
96
96
|
sub: string;
|
|
97
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
97
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
98
98
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
99
99
|
token?: string | undefined;
|
|
100
100
|
}>;
|
|
@@ -106,9 +106,9 @@ export declare namespace Payload {
|
|
|
106
106
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
107
107
|
rule: "rule";
|
|
108
108
|
card: "card";
|
|
109
|
-
organization: "organization";
|
|
110
109
|
transaction: "transaction";
|
|
111
110
|
settlement: "settlement";
|
|
111
|
+
organization: "organization";
|
|
112
112
|
user: "user";
|
|
113
113
|
log: "log";
|
|
114
114
|
operation: "operation";
|
|
@@ -137,7 +137,7 @@ export declare namespace Payload {
|
|
|
137
137
|
iat: number;
|
|
138
138
|
iss: string;
|
|
139
139
|
sub: string;
|
|
140
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
140
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
141
141
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
142
142
|
exp: number;
|
|
143
143
|
token?: string | undefined;
|
|
@@ -146,7 +146,7 @@ export declare namespace Payload {
|
|
|
146
146
|
iat: number;
|
|
147
147
|
iss: string;
|
|
148
148
|
sub: string;
|
|
149
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
149
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
150
150
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
151
151
|
token?: string | undefined;
|
|
152
152
|
}>;
|
|
@@ -158,9 +158,9 @@ export declare namespace Payload {
|
|
|
158
158
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
159
159
|
rule: "rule";
|
|
160
160
|
card: "card";
|
|
161
|
-
organization: "organization";
|
|
162
161
|
transaction: "transaction";
|
|
163
162
|
settlement: "settlement";
|
|
163
|
+
organization: "organization";
|
|
164
164
|
user: "user";
|
|
165
165
|
log: "log";
|
|
166
166
|
operation: "operation";
|
|
@@ -195,9 +195,9 @@ export declare namespace Payload {
|
|
|
195
195
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
196
196
|
rule: "rule";
|
|
197
197
|
card: "card";
|
|
198
|
-
organization: "organization";
|
|
199
198
|
transaction: "transaction";
|
|
200
199
|
settlement: "settlement";
|
|
200
|
+
organization: "organization";
|
|
201
201
|
user: "user";
|
|
202
202
|
log: "log";
|
|
203
203
|
operation: "operation";
|
|
@@ -225,9 +225,9 @@ export declare namespace Payload {
|
|
|
225
225
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
226
226
|
rule: "rule";
|
|
227
227
|
card: "card";
|
|
228
|
-
organization: "organization";
|
|
229
228
|
transaction: "transaction";
|
|
230
229
|
settlement: "settlement";
|
|
230
|
+
organization: "organization";
|
|
231
231
|
user: "user";
|
|
232
232
|
log: "log";
|
|
233
233
|
operation: "operation";
|
package/dist/cjs/User/index.d.ts
CHANGED
|
@@ -54,9 +54,9 @@ export declare namespace User {
|
|
|
54
54
|
uk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
55
55
|
rule: "rule";
|
|
56
56
|
card: "card";
|
|
57
|
-
organization: "organization";
|
|
58
57
|
transaction: "transaction";
|
|
59
58
|
settlement: "settlement";
|
|
59
|
+
organization: "organization";
|
|
60
60
|
user: "user";
|
|
61
61
|
log: "log";
|
|
62
62
|
operation: "operation";
|
|
@@ -71,9 +71,9 @@ export declare namespace User {
|
|
|
71
71
|
uguk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
72
72
|
rule: "rule";
|
|
73
73
|
card: "card";
|
|
74
|
-
organization: "organization";
|
|
75
74
|
transaction: "transaction";
|
|
76
75
|
settlement: "settlement";
|
|
76
|
+
organization: "organization";
|
|
77
77
|
user: "user";
|
|
78
78
|
log: "log";
|
|
79
79
|
operation: "operation";
|
|
@@ -88,9 +88,9 @@ export declare namespace User {
|
|
|
88
88
|
eea: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
89
89
|
rule: "rule";
|
|
90
90
|
card: "card";
|
|
91
|
-
organization: "organization";
|
|
92
91
|
transaction: "transaction";
|
|
93
92
|
settlement: "settlement";
|
|
93
|
+
organization: "organization";
|
|
94
94
|
user: "user";
|
|
95
95
|
log: "log";
|
|
96
96
|
operation: "operation";
|
|
@@ -105,9 +105,9 @@ export declare namespace User {
|
|
|
105
105
|
test: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
106
106
|
rule: "rule";
|
|
107
107
|
card: "card";
|
|
108
|
-
organization: "organization";
|
|
109
108
|
transaction: "transaction";
|
|
110
109
|
settlement: "settlement";
|
|
110
|
+
organization: "organization";
|
|
111
111
|
user: "user";
|
|
112
112
|
log: "log";
|
|
113
113
|
operation: "operation";
|
|
@@ -132,10 +132,10 @@ export declare namespace User {
|
|
|
132
132
|
const type: import("isly/dist/cjs/object").IslyObject<{
|
|
133
133
|
email: string;
|
|
134
134
|
access: {
|
|
135
|
-
uk?: Partial<Record<"rule" | "card" | "
|
|
136
|
-
uguk?: Partial<Record<"rule" | "card" | "
|
|
137
|
-
eea?: Partial<Record<"rule" | "card" | "
|
|
138
|
-
test?: Partial<Record<"rule" | "card" | "
|
|
135
|
+
uk?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
136
|
+
uguk?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
137
|
+
eea?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
138
|
+
test?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
139
139
|
"*"?: {
|
|
140
140
|
user?: "developer" | "read" | "write" | "admin" | undefined;
|
|
141
141
|
} | undefined;
|
package/dist/mjs/Audit.d.ts
CHANGED
|
@@ -20,6 +20,6 @@ export declare namespace Audit {
|
|
|
20
20
|
readonly clearbank: readonly ["assessmentFailed", "validationFailed"];
|
|
21
21
|
};
|
|
22
22
|
const keys: (keyof typeof value)[];
|
|
23
|
-
const type: isly.Type<"clearbank" | "rule" | "
|
|
23
|
+
const type: isly.Type<"clearbank" | "rule" | "account" | "transaction" | "organization" | "user" | "settlements" | "marqeta" | "label" | "route">;
|
|
24
24
|
}
|
|
25
25
|
}
|
|
@@ -50,8 +50,8 @@ export declare namespace Transactions {
|
|
|
50
50
|
end: string | undefined;
|
|
51
51
|
currency: string | undefined;
|
|
52
52
|
organization: string | undefined;
|
|
53
|
-
rail: "paxgiro" | "mastercard" | "diners" | "visa" | "paxgiro-credit" | "
|
|
54
|
-
type: "
|
|
53
|
+
rail: "paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "transfer" | "fasterpayments" | "chaps" | "bacs" | "credit" | undefined;
|
|
54
|
+
type: "internal" | "card" | "external" | "system" | undefined;
|
|
55
55
|
}>;
|
|
56
56
|
function parse(query: string | http.Request["search"]): Query;
|
|
57
57
|
}
|
|
@@ -2,5 +2,5 @@ import { isly } from "isly";
|
|
|
2
2
|
export type Status = typeof Status.values[number];
|
|
3
3
|
export declare namespace Status {
|
|
4
4
|
const values: readonly ["pending", "success", "failed"];
|
|
5
|
-
const type: isly.Type<"
|
|
5
|
+
const type: isly.Type<"pending" | "success" | "failed">;
|
|
6
6
|
}
|
package/dist/mjs/Rail/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { Address as RailAddress } from "./Address";
|
|
|
4
4
|
export type Rail = typeof Rail.rails[number];
|
|
5
5
|
export declare namespace Rail {
|
|
6
6
|
const rails: readonly ["internal", "paxgiro", "paxgiro-credit", "mastercard", "diners", "visa", "fasterpayments", "chaps", "bacs", "transfer", "credit"];
|
|
7
|
-
const type: isly.Type<"paxgiro" | "mastercard" | "diners" | "visa" | "paxgiro-credit" | "
|
|
8
|
-
const type2: isly2.String<"paxgiro" | "mastercard" | "diners" | "visa" | "paxgiro-credit" | "
|
|
7
|
+
const type: isly.Type<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "transfer" | "fasterpayments" | "chaps" | "bacs" | "credit">;
|
|
8
|
+
const type2: isly2.String<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "transfer" | "fasterpayments" | "chaps" | "bacs" | "credit">;
|
|
9
9
|
export import Address = RailAddress;
|
|
10
10
|
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { isoly } from "isoly";
|
|
2
2
|
import { Card } from "../../../Card";
|
|
3
|
-
import { Rail } from "../../../Rail";
|
|
4
|
-
import { PreTransaction } from "../../PreTransaction";
|
|
5
3
|
export interface Charge {
|
|
6
4
|
merchant?: Charge.Merchant;
|
|
7
5
|
fx?: Charge.Fx;
|
|
@@ -27,13 +25,6 @@ export declare namespace Charge {
|
|
|
27
25
|
namespace Merchant {
|
|
28
26
|
const type: import("isly/dist/cjs/object").IslyObject<Merchant, object>;
|
|
29
27
|
}
|
|
30
|
-
type ChargeTransaction = PreTransaction.Incoming & {
|
|
31
|
-
account: Rail.Address.Internal;
|
|
32
|
-
};
|
|
33
28
|
function total(currency: isoly.Currency, charges: Charge): number;
|
|
34
|
-
function toTransactions(charge: Charge, account: string, id: string, currency: isoly.Currency, fxCollectAccount: string): {
|
|
35
|
-
merchant: ChargeTransaction | undefined;
|
|
36
|
-
fx: ChargeTransaction | undefined;
|
|
37
|
-
};
|
|
38
29
|
const type: import("isly/dist/cjs/object").IslyObject<Charge, object>;
|
|
39
30
|
}
|
|
@@ -27,26 +27,6 @@ export var Charge;
|
|
|
27
27
|
return isoly.Currency.add(currency, charges.fx?.amount ?? 0, charges.merchant?.amount ?? 0);
|
|
28
28
|
}
|
|
29
29
|
Charge.total = total;
|
|
30
|
-
function toTransactions(charge, account, id, currency, fxCollectAccount) {
|
|
31
|
-
const merchant = charge.merchant && toTransaction(charge.merchant, account, id, currency, fxCollectAccount, "merchant");
|
|
32
|
-
const fx = charge.fx && toTransaction(charge.fx, account, id, currency, fxCollectAccount, "fx");
|
|
33
|
-
return { merchant, fx };
|
|
34
|
-
}
|
|
35
|
-
Charge.toTransactions = toTransactions;
|
|
36
|
-
function toTransaction(charge, account, id, currency, fxCollectAccount, type) {
|
|
37
|
-
const accountId = Merchant.type.is(charge) ? charge.destination.account : fxCollectAccount;
|
|
38
|
-
return {
|
|
39
|
-
type: "incoming",
|
|
40
|
-
account: { type: "internal", identifier: accountId },
|
|
41
|
-
counterpart: { type: "internal", identifier: account },
|
|
42
|
-
currency: currency,
|
|
43
|
-
amount: charge.amount,
|
|
44
|
-
description: `${type} charge for transaction ${id}`,
|
|
45
|
-
posted: isoly.DateTime.now(),
|
|
46
|
-
rail: "internal",
|
|
47
|
-
reference: { reference: id, returnId: id },
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
30
|
Charge.type = isly.object({
|
|
51
31
|
merchant: Charge.Merchant.type.optional(),
|
|
52
32
|
fx: Charge.Fx.type.optional(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../Transaction/Amount/Charge/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,OAAO,CAAA;AAC7B,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;AAC3B,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../Transaction/Amount/Charge/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,OAAO,CAAA;AAC7B,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;AAC3B,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;AAMpC,MAAM,KAAW,MAAM,CAsCtB;AAtCD,WAAiB,MAAM;IAMtB,IAAiB,EAAE,CAMlB;IAND,WAAiB,EAAE;QACL,OAAI,GAAG,IAAI,CAAC,MAAM,CAAK;YACnC,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE;YACrB,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE;YACnB,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;SAC5D,CAAC,CAAA;IACH,CAAC,EANgB,EAAE,GAAF,SAAE,KAAF,SAAE,QAMlB;IAQD,IAAiB,QAAQ,CAUxB;IAVD,WAAiB,QAAQ;QACX,aAAI,GAAG,IAAI,CAAC,MAAM,CAAW;YACzC,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE;YACrB,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE;YACnB,QAAQ,EAAE,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,IAAI;YACxC,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;YAC5D,WAAW,EAAE,IAAI,CAAC,MAAM,CAAC;gBACxB,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE;aACtB,CAAC;SACF,CAAC,CAAA;IACH,CAAC,EAVgB,QAAQ,GAAR,eAAQ,KAAR,eAAQ,QAUxB;IACD,SAAgB,KAAK,CAAC,QAAwB,EAAE,OAAe;QAC9D,OAAO,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,QAAQ,EAAE,OAAO,CAAC,EAAE,EAAE,MAAM,IAAI,CAAC,EAAE,OAAO,CAAC,QAAQ,EAAE,MAAM,IAAI,CAAC,CAAC,CAAA;IAC5F,CAAC;IAFe,YAAK,QAEpB,CAAA;IACY,WAAI,GAAG,IAAI,CAAC,MAAM,CAAS;QACvC,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,EAAE;QACzC,EAAE,EAAE,MAAM,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE;KAC7B,CAAC,CAAA;AACH,CAAC,EAtCgB,MAAM,KAAN,MAAM,QAsCtB"}
|
|
@@ -142,6 +142,6 @@ export declare namespace Transaction {
|
|
|
142
142
|
counterpart: Extract<Transaction["counterpart"], Rail.Address.Card.Counterpart>;
|
|
143
143
|
};
|
|
144
144
|
namespace CardTransaction {
|
|
145
|
-
const type: import("isly/dist/cjs/object").IslyObject<CardTransaction, Omit<Transaction, "
|
|
145
|
+
const type: import("isly/dist/cjs/object").IslyObject<CardTransaction, Omit<Transaction, "account" | "counterpart">>;
|
|
146
146
|
}
|
|
147
147
|
}
|
|
@@ -32,24 +32,24 @@ export declare namespace Permission {
|
|
|
32
32
|
const typeZod: zod.ZodEnum<{
|
|
33
33
|
rule: "rule";
|
|
34
34
|
card: "card";
|
|
35
|
-
organization: "organization";
|
|
36
35
|
transaction: "transaction";
|
|
37
36
|
settlement: "settlement";
|
|
37
|
+
organization: "organization";
|
|
38
38
|
user: "user";
|
|
39
39
|
log: "log";
|
|
40
40
|
operation: "operation";
|
|
41
41
|
"*": "*";
|
|
42
42
|
treasury: "treasury";
|
|
43
43
|
}>;
|
|
44
|
-
const type: isly.Type<"rule" | "card" | "
|
|
44
|
+
const type: isly.Type<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury">;
|
|
45
45
|
}
|
|
46
|
-
const type: isly.Type<Partial<Record<"rule" | "card" | "
|
|
46
|
+
const type: isly.Type<Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>>;
|
|
47
47
|
const typeZod: zod.ZodRecord<zod.ZodEnum<{
|
|
48
48
|
rule: "rule";
|
|
49
49
|
card: "card";
|
|
50
|
-
organization: "organization";
|
|
51
50
|
transaction: "transaction";
|
|
52
51
|
settlement: "settlement";
|
|
52
|
+
organization: "organization";
|
|
53
53
|
user: "user";
|
|
54
54
|
log: "log";
|
|
55
55
|
operation: "operation";
|
|
@@ -8,9 +8,9 @@ export declare namespace Access {
|
|
|
8
8
|
uk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
9
9
|
rule: "rule";
|
|
10
10
|
card: "card";
|
|
11
|
-
organization: "organization";
|
|
12
11
|
transaction: "transaction";
|
|
13
12
|
settlement: "settlement";
|
|
13
|
+
organization: "organization";
|
|
14
14
|
user: "user";
|
|
15
15
|
log: "log";
|
|
16
16
|
operation: "operation";
|
|
@@ -25,9 +25,9 @@ export declare namespace Access {
|
|
|
25
25
|
uguk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
26
26
|
rule: "rule";
|
|
27
27
|
card: "card";
|
|
28
|
-
organization: "organization";
|
|
29
28
|
transaction: "transaction";
|
|
30
29
|
settlement: "settlement";
|
|
30
|
+
organization: "organization";
|
|
31
31
|
user: "user";
|
|
32
32
|
log: "log";
|
|
33
33
|
operation: "operation";
|
|
@@ -42,9 +42,9 @@ export declare namespace Access {
|
|
|
42
42
|
eea: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
43
43
|
rule: "rule";
|
|
44
44
|
card: "card";
|
|
45
|
-
organization: "organization";
|
|
46
45
|
transaction: "transaction";
|
|
47
46
|
settlement: "settlement";
|
|
47
|
+
organization: "organization";
|
|
48
48
|
user: "user";
|
|
49
49
|
log: "log";
|
|
50
50
|
operation: "operation";
|
|
@@ -59,9 +59,9 @@ export declare namespace Access {
|
|
|
59
59
|
test: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
60
60
|
rule: "rule";
|
|
61
61
|
card: "card";
|
|
62
|
-
organization: "organization";
|
|
63
62
|
transaction: "transaction";
|
|
64
63
|
settlement: "settlement";
|
|
64
|
+
organization: "organization";
|
|
65
65
|
user: "user";
|
|
66
66
|
log: "log";
|
|
67
67
|
operation: "operation";
|
|
@@ -6,7 +6,7 @@ export declare namespace Payload {
|
|
|
6
6
|
namespace Creatable {
|
|
7
7
|
const type: import("isly/dist/cjs/object").IslyObject<{
|
|
8
8
|
sub: string;
|
|
9
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
9
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
10
10
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
11
11
|
}, object>;
|
|
12
12
|
const typeZod: zod.ZodObject<{
|
|
@@ -14,9 +14,9 @@ export declare namespace Payload {
|
|
|
14
14
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
15
15
|
rule: "rule";
|
|
16
16
|
card: "card";
|
|
17
|
-
organization: "organization";
|
|
18
17
|
transaction: "transaction";
|
|
19
18
|
settlement: "settlement";
|
|
19
|
+
organization: "organization";
|
|
20
20
|
user: "user";
|
|
21
21
|
log: "log";
|
|
22
22
|
operation: "operation";
|
|
@@ -43,7 +43,7 @@ export declare namespace Payload {
|
|
|
43
43
|
iat: number;
|
|
44
44
|
iss: string;
|
|
45
45
|
sub: string;
|
|
46
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
46
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
47
47
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
48
48
|
token?: string | undefined;
|
|
49
49
|
}, object>;
|
|
@@ -55,9 +55,9 @@ export declare namespace Payload {
|
|
|
55
55
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
56
56
|
rule: "rule";
|
|
57
57
|
card: "card";
|
|
58
|
-
organization: "organization";
|
|
59
58
|
transaction: "transaction";
|
|
60
59
|
settlement: "settlement";
|
|
60
|
+
organization: "organization";
|
|
61
61
|
user: "user";
|
|
62
62
|
log: "log";
|
|
63
63
|
operation: "operation";
|
|
@@ -85,7 +85,7 @@ export declare namespace Payload {
|
|
|
85
85
|
iat: number;
|
|
86
86
|
iss: string;
|
|
87
87
|
sub: string;
|
|
88
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
88
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
89
89
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
90
90
|
id: string;
|
|
91
91
|
token?: string | undefined;
|
|
@@ -94,7 +94,7 @@ export declare namespace Payload {
|
|
|
94
94
|
iat: number;
|
|
95
95
|
iss: string;
|
|
96
96
|
sub: string;
|
|
97
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
97
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
98
98
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
99
99
|
token?: string | undefined;
|
|
100
100
|
}>;
|
|
@@ -106,9 +106,9 @@ export declare namespace Payload {
|
|
|
106
106
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
107
107
|
rule: "rule";
|
|
108
108
|
card: "card";
|
|
109
|
-
organization: "organization";
|
|
110
109
|
transaction: "transaction";
|
|
111
110
|
settlement: "settlement";
|
|
111
|
+
organization: "organization";
|
|
112
112
|
user: "user";
|
|
113
113
|
log: "log";
|
|
114
114
|
operation: "operation";
|
|
@@ -137,7 +137,7 @@ export declare namespace Payload {
|
|
|
137
137
|
iat: number;
|
|
138
138
|
iss: string;
|
|
139
139
|
sub: string;
|
|
140
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
140
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
141
141
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
142
142
|
exp: number;
|
|
143
143
|
token?: string | undefined;
|
|
@@ -146,7 +146,7 @@ export declare namespace Payload {
|
|
|
146
146
|
iat: number;
|
|
147
147
|
iss: string;
|
|
148
148
|
sub: string;
|
|
149
|
-
permission: Partial<Record<"rule" | "card" | "
|
|
149
|
+
permission: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">>;
|
|
150
150
|
realm: "test" | "uk" | "uguk" | "eea";
|
|
151
151
|
token?: string | undefined;
|
|
152
152
|
}>;
|
|
@@ -158,9 +158,9 @@ export declare namespace Payload {
|
|
|
158
158
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
159
159
|
rule: "rule";
|
|
160
160
|
card: "card";
|
|
161
|
-
organization: "organization";
|
|
162
161
|
transaction: "transaction";
|
|
163
162
|
settlement: "settlement";
|
|
163
|
+
organization: "organization";
|
|
164
164
|
user: "user";
|
|
165
165
|
log: "log";
|
|
166
166
|
operation: "operation";
|
|
@@ -195,9 +195,9 @@ export declare namespace Payload {
|
|
|
195
195
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
196
196
|
rule: "rule";
|
|
197
197
|
card: "card";
|
|
198
|
-
organization: "organization";
|
|
199
198
|
transaction: "transaction";
|
|
200
199
|
settlement: "settlement";
|
|
200
|
+
organization: "organization";
|
|
201
201
|
user: "user";
|
|
202
202
|
log: "log";
|
|
203
203
|
operation: "operation";
|
|
@@ -225,9 +225,9 @@ export declare namespace Payload {
|
|
|
225
225
|
permission: zod.ZodRecord<zod.ZodEnum<{
|
|
226
226
|
rule: "rule";
|
|
227
227
|
card: "card";
|
|
228
|
-
organization: "organization";
|
|
229
228
|
transaction: "transaction";
|
|
230
229
|
settlement: "settlement";
|
|
230
|
+
organization: "organization";
|
|
231
231
|
user: "user";
|
|
232
232
|
log: "log";
|
|
233
233
|
operation: "operation";
|
package/dist/mjs/User/index.d.ts
CHANGED
|
@@ -54,9 +54,9 @@ export declare namespace User {
|
|
|
54
54
|
uk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
55
55
|
rule: "rule";
|
|
56
56
|
card: "card";
|
|
57
|
-
organization: "organization";
|
|
58
57
|
transaction: "transaction";
|
|
59
58
|
settlement: "settlement";
|
|
59
|
+
organization: "organization";
|
|
60
60
|
user: "user";
|
|
61
61
|
log: "log";
|
|
62
62
|
operation: "operation";
|
|
@@ -71,9 +71,9 @@ export declare namespace User {
|
|
|
71
71
|
uguk: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
72
72
|
rule: "rule";
|
|
73
73
|
card: "card";
|
|
74
|
-
organization: "organization";
|
|
75
74
|
transaction: "transaction";
|
|
76
75
|
settlement: "settlement";
|
|
76
|
+
organization: "organization";
|
|
77
77
|
user: "user";
|
|
78
78
|
log: "log";
|
|
79
79
|
operation: "operation";
|
|
@@ -88,9 +88,9 @@ export declare namespace User {
|
|
|
88
88
|
eea: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
89
89
|
rule: "rule";
|
|
90
90
|
card: "card";
|
|
91
|
-
organization: "organization";
|
|
92
91
|
transaction: "transaction";
|
|
93
92
|
settlement: "settlement";
|
|
93
|
+
organization: "organization";
|
|
94
94
|
user: "user";
|
|
95
95
|
log: "log";
|
|
96
96
|
operation: "operation";
|
|
@@ -105,9 +105,9 @@ export declare namespace User {
|
|
|
105
105
|
test: zod.ZodOptional<zod.ZodRecord<zod.ZodEnum<{
|
|
106
106
|
rule: "rule";
|
|
107
107
|
card: "card";
|
|
108
|
-
organization: "organization";
|
|
109
108
|
transaction: "transaction";
|
|
110
109
|
settlement: "settlement";
|
|
110
|
+
organization: "organization";
|
|
111
111
|
user: "user";
|
|
112
112
|
log: "log";
|
|
113
113
|
operation: "operation";
|
|
@@ -132,10 +132,10 @@ export declare namespace User {
|
|
|
132
132
|
const type: import("isly/dist/cjs/object").IslyObject<{
|
|
133
133
|
email: string;
|
|
134
134
|
access: {
|
|
135
|
-
uk?: Partial<Record<"rule" | "card" | "
|
|
136
|
-
uguk?: Partial<Record<"rule" | "card" | "
|
|
137
|
-
eea?: Partial<Record<"rule" | "card" | "
|
|
138
|
-
test?: Partial<Record<"rule" | "card" | "
|
|
135
|
+
uk?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
136
|
+
uguk?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
137
|
+
eea?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
138
|
+
test?: Partial<Record<"rule" | "card" | "transaction" | "settlement" | "organization" | "user" | "log" | "operation" | "*" | "treasury", "developer" | "read" | "write" | "admin">> | undefined;
|
|
139
139
|
"*"?: {
|
|
140
140
|
user?: "developer" | "read" | "write" | "admin" | undefined;
|
|
141
141
|
} | undefined;
|