@pax2pay/model-banking 0.1.507 → 0.1.508
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/Client/Transactions/index.ts +33 -15
- package/Client/index.ts +6 -3
- package/Rail/index.ts +2 -0
- package/dist/cjs/Client/Transactions/index.d.ts +29 -11
- package/dist/cjs/Client/Transactions/index.js +25 -0
- package/dist/cjs/Client/Transactions/index.js.map +1 -1
- package/dist/cjs/Client/index.d.ts +5 -2
- package/dist/cjs/Client/index.js +3 -0
- package/dist/cjs/Client/index.js.map +1 -1
- package/dist/cjs/Rail/index.d.ts +2 -0
- package/dist/cjs/Rail/index.js +2 -0
- package/dist/cjs/Rail/index.js.map +1 -1
- package/dist/mjs/Client/Transactions/index.d.ts +29 -11
- package/dist/mjs/Client/Transactions/index.js +25 -0
- package/dist/mjs/Client/Transactions/index.js.map +1 -1
- package/dist/mjs/Client/index.d.ts +5 -2
- package/dist/mjs/Client/index.js +5 -2
- package/dist/mjs/Client/index.js.map +1 -1
- package/dist/mjs/Rail/index.d.ts +2 -0
- package/dist/mjs/Rail/index.js +2 -0
- package/dist/mjs/Rail/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { isoly } from "isoly"
|
|
3
3
|
import { http } from "cloudly-http"
|
|
4
|
+
import { isly } from "isly2"
|
|
4
5
|
import { Card } from "../../Card"
|
|
5
6
|
import { Operation } from "../../Operation"
|
|
6
7
|
import { Rail } from "../../Rail"
|
|
@@ -18,21 +19,7 @@ export class Transactions {
|
|
|
18
19
|
async create(account: string, transaction: Transaction.Creatable): Promise<Transaction | gracely.Error> {
|
|
19
20
|
return this.client.post<Transaction>(`/account/${account}/transaction`, transaction)
|
|
20
21
|
}
|
|
21
|
-
async list(
|
|
22
|
-
options?:
|
|
23
|
-
| {
|
|
24
|
-
account?: string
|
|
25
|
-
limit?: number
|
|
26
|
-
cursor?: string
|
|
27
|
-
start?: isoly.DateTime
|
|
28
|
-
end?: isoly.DateTime
|
|
29
|
-
currency?: string
|
|
30
|
-
organization?: string
|
|
31
|
-
rail?: Rail
|
|
32
|
-
type?: Transaction.Types
|
|
33
|
-
}
|
|
34
|
-
| string
|
|
35
|
-
): Promise<(Transaction[] & { cursor?: string | undefined }) | gracely.Error> {
|
|
22
|
+
async list(options?: string | Transactions.Query): Promise<(Transaction[] & { cursor?: string }) | gracely.Error> {
|
|
36
23
|
const query = !options ? undefined : typeof options == "string" ? options : http.Search.stringify({ ...options })
|
|
37
24
|
return await this.client.get<Transaction[] & { cursor?: string | undefined }>(
|
|
38
25
|
"/transaction" + (query ? "?" + query : "")
|
|
@@ -57,3 +44,34 @@ export class Transactions {
|
|
|
57
44
|
return this.client.get<Transaction.Statistics>(`/transaction/statistics${query}`)
|
|
58
45
|
}
|
|
59
46
|
}
|
|
47
|
+
export namespace Transactions {
|
|
48
|
+
export interface Query {
|
|
49
|
+
account?: string
|
|
50
|
+
limit?: number
|
|
51
|
+
cursor?: string
|
|
52
|
+
start?: isoly.DateTime
|
|
53
|
+
end?: isoly.DateTime
|
|
54
|
+
currency?: string
|
|
55
|
+
organization?: string
|
|
56
|
+
rail?: Rail
|
|
57
|
+
type?: Transaction.Types
|
|
58
|
+
}
|
|
59
|
+
export namespace Query {
|
|
60
|
+
export const type = isly.object({
|
|
61
|
+
account: isly.string().optional(),
|
|
62
|
+
limit: isly.number().optional(),
|
|
63
|
+
cursor: isly.string().optional(),
|
|
64
|
+
start: isly.string().optional(),
|
|
65
|
+
end: isly.string().optional(),
|
|
66
|
+
currency: isly.string().optional(),
|
|
67
|
+
organization: isly.string().optional(),
|
|
68
|
+
rail: Rail.type2.optional(),
|
|
69
|
+
type: isly.string("value", ...Transaction.types).optional(),
|
|
70
|
+
})
|
|
71
|
+
export function parse(query: string | http.Request["search"]): Query {
|
|
72
|
+
if (typeof query == "string")
|
|
73
|
+
query = query ? http.Search.parse(query.replace("?", "")) : {} // search.parse does not support empty string
|
|
74
|
+
return type.prune(query) ?? {}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
package/Client/index.ts
CHANGED
|
@@ -13,7 +13,7 @@ import { Processor } from "./Processor"
|
|
|
13
13
|
import { Reports } from "./Reports"
|
|
14
14
|
import { Rules } from "./Rules"
|
|
15
15
|
import { Settlements } from "./Settlements"
|
|
16
|
-
import { Transactions } from "./Transactions"
|
|
16
|
+
import { Transactions as ClientTransactions } from "./Transactions"
|
|
17
17
|
import { Treasury } from "./Treasury"
|
|
18
18
|
import { Version } from "./Version"
|
|
19
19
|
|
|
@@ -30,7 +30,7 @@ export class Client {
|
|
|
30
30
|
readonly logs: Logs
|
|
31
31
|
readonly rules: Rules
|
|
32
32
|
readonly settlements: Settlements
|
|
33
|
-
readonly transactions:
|
|
33
|
+
readonly transactions: ClientTransactions
|
|
34
34
|
readonly treasury: Treasury
|
|
35
35
|
readonly flags: Labels
|
|
36
36
|
readonly groups: Labels
|
|
@@ -60,7 +60,7 @@ export class Client {
|
|
|
60
60
|
this.logs = new Logs(this.client)
|
|
61
61
|
this.rules = new Rules(this.client)
|
|
62
62
|
this.settlements = new Settlements(this.client)
|
|
63
|
-
this.transactions = new
|
|
63
|
+
this.transactions = new ClientTransactions(this.client)
|
|
64
64
|
this.treasury = new Treasury(this.client)
|
|
65
65
|
this.flags = new Labels(this.client, "flag")
|
|
66
66
|
this.groups = new Labels(this.client, "group")
|
|
@@ -96,3 +96,6 @@ export class Client {
|
|
|
96
96
|
return result
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
|
+
export namespace Client {
|
|
100
|
+
export import Transactions = ClientTransactions
|
|
101
|
+
}
|
package/Rail/index.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { isly } from "isly"
|
|
2
|
+
import { isly as isly2 } from "isly2"
|
|
2
3
|
import { Address as RailAddress } from "./Address"
|
|
3
4
|
|
|
4
5
|
export type Rail = typeof Rail.rails[number]
|
|
@@ -17,5 +18,6 @@ export namespace Rail {
|
|
|
17
18
|
"credit",
|
|
18
19
|
] as const
|
|
19
20
|
export const type = isly.string<Rail>(rails)
|
|
21
|
+
export const type2 = isly2.string<Rail>("value", ...rails)
|
|
20
22
|
export import Address = RailAddress
|
|
21
23
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { isoly } from "isoly";
|
|
3
3
|
import { http } from "cloudly-http";
|
|
4
|
+
import { isly } from "isly2";
|
|
4
5
|
import { Card } from "../../Card";
|
|
5
6
|
import { Operation } from "../../Operation";
|
|
6
7
|
import { Rail } from "../../Rail";
|
|
@@ -13,18 +14,8 @@ export declare class Transactions {
|
|
|
13
14
|
readonly Notes: Notes;
|
|
14
15
|
constructor(client: http.Client);
|
|
15
16
|
create(account: string, transaction: Transaction.Creatable): Promise<Transaction | gracely.Error>;
|
|
16
|
-
list(options?: {
|
|
17
|
-
account?: string;
|
|
18
|
-
limit?: number;
|
|
17
|
+
list(options?: string | Transactions.Query): Promise<(Transaction[] & {
|
|
19
18
|
cursor?: string;
|
|
20
|
-
start?: isoly.DateTime;
|
|
21
|
-
end?: isoly.DateTime;
|
|
22
|
-
currency?: string;
|
|
23
|
-
organization?: string;
|
|
24
|
-
rail?: Rail;
|
|
25
|
-
type?: Transaction.Types;
|
|
26
|
-
} | string): Promise<(Transaction[] & {
|
|
27
|
-
cursor?: string | undefined;
|
|
28
19
|
}) | gracely.Error>;
|
|
29
20
|
fetch(transaction: string, account?: string): Promise<Transaction | gracely.Error>;
|
|
30
21
|
getOperations(transactionId: string): Promise<Operation[] | gracely.Error>;
|
|
@@ -36,3 +27,30 @@ export declare class Transactions {
|
|
|
36
27
|
limit?: number;
|
|
37
28
|
}): Promise<Transaction.Statistics | gracely.Error>;
|
|
38
29
|
}
|
|
30
|
+
export declare namespace Transactions {
|
|
31
|
+
interface Query {
|
|
32
|
+
account?: string;
|
|
33
|
+
limit?: number;
|
|
34
|
+
cursor?: string;
|
|
35
|
+
start?: isoly.DateTime;
|
|
36
|
+
end?: isoly.DateTime;
|
|
37
|
+
currency?: string;
|
|
38
|
+
organization?: string;
|
|
39
|
+
rail?: Rail;
|
|
40
|
+
type?: Transaction.Types;
|
|
41
|
+
}
|
|
42
|
+
namespace Query {
|
|
43
|
+
const type: isly.Object<{
|
|
44
|
+
account: string | undefined;
|
|
45
|
+
limit: number | undefined;
|
|
46
|
+
cursor: string | undefined;
|
|
47
|
+
start: string | undefined;
|
|
48
|
+
end: string | undefined;
|
|
49
|
+
currency: string | undefined;
|
|
50
|
+
organization: string | undefined;
|
|
51
|
+
rail: "paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "fasterpayments" | "chaps" | "bacs" | "transfer" | "credit" | undefined;
|
|
52
|
+
type: "internal" | "card" | "external" | "system" | undefined;
|
|
53
|
+
}>;
|
|
54
|
+
function parse(query: string | http.Request["search"]): Query;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Transactions = void 0;
|
|
4
4
|
const cloudly_http_1 = require("cloudly-http");
|
|
5
|
+
const isly2_1 = require("isly2");
|
|
6
|
+
const Rail_1 = require("../../Rail");
|
|
7
|
+
const Transaction_1 = require("../../Transaction");
|
|
5
8
|
const Notes_1 = require("./Notes");
|
|
6
9
|
class Transactions {
|
|
7
10
|
client;
|
|
@@ -32,4 +35,26 @@ class Transactions {
|
|
|
32
35
|
}
|
|
33
36
|
}
|
|
34
37
|
exports.Transactions = Transactions;
|
|
38
|
+
(function (Transactions) {
|
|
39
|
+
let Query;
|
|
40
|
+
(function (Query) {
|
|
41
|
+
Query.type = isly2_1.isly.object({
|
|
42
|
+
account: isly2_1.isly.string().optional(),
|
|
43
|
+
limit: isly2_1.isly.number().optional(),
|
|
44
|
+
cursor: isly2_1.isly.string().optional(),
|
|
45
|
+
start: isly2_1.isly.string().optional(),
|
|
46
|
+
end: isly2_1.isly.string().optional(),
|
|
47
|
+
currency: isly2_1.isly.string().optional(),
|
|
48
|
+
organization: isly2_1.isly.string().optional(),
|
|
49
|
+
rail: Rail_1.Rail.type2.optional(),
|
|
50
|
+
type: isly2_1.isly.string("value", ...Transaction_1.Transaction.types).optional(),
|
|
51
|
+
});
|
|
52
|
+
function parse(query) {
|
|
53
|
+
if (typeof query == "string")
|
|
54
|
+
query = query ? cloudly_http_1.http.Search.parse(query.replace("?", "")) : {};
|
|
55
|
+
return Query.type.prune(query) ?? {};
|
|
56
|
+
}
|
|
57
|
+
Query.parse = parse;
|
|
58
|
+
})(Query = Transactions.Query || (Transactions.Query = {}));
|
|
59
|
+
})(Transactions || (exports.Transactions = Transactions = {}));
|
|
35
60
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../Client/Transactions/index.ts"],"names":[],"mappings":";;;AAEA,+CAAmC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../Client/Transactions/index.ts"],"names":[],"mappings":";;;AAEA,+CAAmC;AACnC,iCAA4B;AAG5B,qCAAiC;AAGjC,mDAA+C;AAC/C,mCAA+B;AAE/B,MAAa,YAAY;IAEK;IADpB,KAAK,CAAO;IACrB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;QAC/C,IAAI,CAAC,KAAK,GAAG,IAAI,aAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IACpC,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAAe,EAAE,WAAkC;QAC/D,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAc,YAAY,OAAO,cAAc,EAAE,WAAW,CAAC,CAAA;IACrF,CAAC;IACD,KAAK,CAAC,IAAI,CAAC,OAAqC;QAC/C,MAAM,KAAK,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,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AAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YACjC,KAAK,EAAE,YAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YAC/B,MAAM,EAAE,YAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YAChC,KAAK,EAAE,YAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YAC/B,GAAG,EAAE,YAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YAC7B,QAAQ,EAAE,YAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YAClC,YAAY,EAAE,YAAI,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;YACtC,IAAI,EAAE,WAAI,CAAC,KAAK,CAAC,QAAQ,EAAE;YAC3B,IAAI,EAAE,YAAI,CAAC,MAAM,CAAC,OAAO,EAAE,GAAG,yBAAW,CAAC,KAAK,CAAC,CAAC,QAAQ,EAAE;SAC3D,CAAC,CAAA;QACF,SAAgB,KAAK,CAAC,KAAsC;YAC3D,IAAI,OAAO,KAAK,IAAI,QAAQ;gBAC3B,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,mBAAI,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAA;YAC/D,OAAO,MAAA,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,EAAE,CAAA;QAC/B,CAAC;QAJe,WAAK,QAIpB,CAAA;IACF,CAAC,EAjBgB,KAAK,GAAL,kBAAK,KAAL,kBAAK,QAiBrB;AACF,CAAC,EA9BgB,YAAY,4BAAZ,YAAY,QA8B5B"}
|
|
@@ -12,7 +12,7 @@ import { Processor } from "./Processor";
|
|
|
12
12
|
import { Reports } from "./Reports";
|
|
13
13
|
import { Rules } from "./Rules";
|
|
14
14
|
import { Settlements } from "./Settlements";
|
|
15
|
-
import { Transactions } from "./Transactions";
|
|
15
|
+
import { Transactions as ClientTransactions } from "./Transactions";
|
|
16
16
|
import { Treasury } from "./Treasury";
|
|
17
17
|
import { Version } from "./Version";
|
|
18
18
|
export declare class Client {
|
|
@@ -29,7 +29,7 @@ export declare class Client {
|
|
|
29
29
|
readonly logs: Logs;
|
|
30
30
|
readonly rules: Rules;
|
|
31
31
|
readonly settlements: Settlements;
|
|
32
|
-
readonly transactions:
|
|
32
|
+
readonly transactions: ClientTransactions;
|
|
33
33
|
readonly treasury: Treasury;
|
|
34
34
|
readonly flags: Labels;
|
|
35
35
|
readonly groups: Labels;
|
|
@@ -44,3 +44,6 @@ export declare class Client {
|
|
|
44
44
|
onUnauthorized?: (client: Client) => Promise<boolean>;
|
|
45
45
|
static create(server: string, key?: string): Client;
|
|
46
46
|
}
|
|
47
|
+
export declare namespace Client {
|
|
48
|
+
export import Transactions = ClientTransactions;
|
|
49
|
+
}
|
package/dist/cjs/Client/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Client/index.ts"],"names":[],"mappings":";;;AACA,8CAAgD;AAChD,+CAAmC;AACnC,yCAAqC;AACrC,mCAA+B;AAC/B,mCAA+B;AAC/B,2CAAuC;AACvC,qCAAiC;AACjC,iCAA6B;AAC7B,6CAAyC;AACzC,mDAA+C;AAC/C,2CAAuC;AACvC,uCAAmC;AACnC,mCAA+B;AAC/B,+CAA2C;AAC3C,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Client/index.ts"],"names":[],"mappings":";;;AACA,8CAAgD;AAChD,+CAAmC;AACnC,yCAAqC;AACrC,mCAA+B;AAC/B,mCAA+B;AAC/B,2CAAuC;AACvC,qCAAiC;AACjC,iCAA6B;AAC7B,6CAAyC;AACzC,mDAA+C;AAC/C,2CAAuC;AACvC,uCAAmC;AACnC,mCAA+B;AAC/B,+CAA2C;AAC3C,iDAAmE;AACnE,yCAAqC;AACrC,uCAAmC;AAEnC,MAAa,MAAM;IA+BmB;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isly2 } from "isly2";
|
|
2
3
|
import { Address as RailAddress } from "./Address";
|
|
3
4
|
export type Rail = typeof Rail.rails[number];
|
|
4
5
|
export declare namespace Rail {
|
|
5
6
|
const rails: readonly ["internal", "paxgiro", "paxgiro-credit", "mastercard", "diners", "visa", "fasterpayments", "chaps", "bacs", "transfer", "credit"];
|
|
6
7
|
const type: isly.Type<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "fasterpayments" | "chaps" | "bacs" | "transfer" | "credit">;
|
|
8
|
+
const type2: isly2.String<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "fasterpayments" | "chaps" | "bacs" | "transfer" | "credit">;
|
|
7
9
|
export import Address = RailAddress;
|
|
8
10
|
}
|
package/dist/cjs/Rail/index.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Rail = void 0;
|
|
4
4
|
const isly_1 = require("isly");
|
|
5
|
+
const isly2_1 = require("isly2");
|
|
5
6
|
const Address_1 = require("./Address");
|
|
6
7
|
var Rail;
|
|
7
8
|
(function (Rail) {
|
|
@@ -19,6 +20,7 @@ var Rail;
|
|
|
19
20
|
"credit",
|
|
20
21
|
];
|
|
21
22
|
Rail.type = isly_1.isly.string(Rail.rails);
|
|
23
|
+
Rail.type2 = isly2_1.isly.string("value", ...Rail.rails);
|
|
22
24
|
Rail.Address = Address_1.Address;
|
|
23
25
|
})(Rail || (exports.Rail = Rail = {}));
|
|
24
26
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Rail/index.ts"],"names":[],"mappings":";;;AAAA,+BAA2B;AAC3B,uCAAkD;AAGlD,IAAiB,IAAI,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Rail/index.ts"],"names":[],"mappings":";;;AAAA,+BAA2B;AAC3B,iCAAqC;AACrC,uCAAkD;AAGlD,IAAiB,IAAI,CAiBpB;AAjBD,WAAiB,IAAI;IACP,UAAK,GAAG;QACpB,UAAU;QACV,SAAS;QACT,gBAAgB;QAChB,YAAY;QACZ,QAAQ;QACR,MAAM;QACN,gBAAgB;QAChB,OAAO;QACP,MAAM;QACN,UAAU;QACV,QAAQ;KACC,CAAA;IACG,SAAI,GAAG,WAAI,CAAC,MAAM,CAAO,KAAA,KAAK,CAAC,CAAA;IAC/B,UAAK,GAAG,YAAK,CAAC,MAAM,CAAO,OAAO,EAAE,GAAG,KAAA,KAAK,CAAC,CAAA;IAC5C,YAAO,GAAG,iBAAW,CAAA;AACpC,CAAC,EAjBgB,IAAI,oBAAJ,IAAI,QAiBpB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { isoly } from "isoly";
|
|
3
3
|
import { http } from "cloudly-http";
|
|
4
|
+
import { isly } from "isly2";
|
|
4
5
|
import { Card } from "../../Card";
|
|
5
6
|
import { Operation } from "../../Operation";
|
|
6
7
|
import { Rail } from "../../Rail";
|
|
@@ -13,18 +14,8 @@ export declare class Transactions {
|
|
|
13
14
|
readonly Notes: Notes;
|
|
14
15
|
constructor(client: http.Client);
|
|
15
16
|
create(account: string, transaction: Transaction.Creatable): Promise<Transaction | gracely.Error>;
|
|
16
|
-
list(options?: {
|
|
17
|
-
account?: string;
|
|
18
|
-
limit?: number;
|
|
17
|
+
list(options?: string | Transactions.Query): Promise<(Transaction[] & {
|
|
19
18
|
cursor?: string;
|
|
20
|
-
start?: isoly.DateTime;
|
|
21
|
-
end?: isoly.DateTime;
|
|
22
|
-
currency?: string;
|
|
23
|
-
organization?: string;
|
|
24
|
-
rail?: Rail;
|
|
25
|
-
type?: Transaction.Types;
|
|
26
|
-
} | string): Promise<(Transaction[] & {
|
|
27
|
-
cursor?: string | undefined;
|
|
28
19
|
}) | gracely.Error>;
|
|
29
20
|
fetch(transaction: string, account?: string): Promise<Transaction | gracely.Error>;
|
|
30
21
|
getOperations(transactionId: string): Promise<Operation[] | gracely.Error>;
|
|
@@ -36,3 +27,30 @@ export declare class Transactions {
|
|
|
36
27
|
limit?: number;
|
|
37
28
|
}): Promise<Transaction.Statistics | gracely.Error>;
|
|
38
29
|
}
|
|
30
|
+
export declare namespace Transactions {
|
|
31
|
+
interface Query {
|
|
32
|
+
account?: string;
|
|
33
|
+
limit?: number;
|
|
34
|
+
cursor?: string;
|
|
35
|
+
start?: isoly.DateTime;
|
|
36
|
+
end?: isoly.DateTime;
|
|
37
|
+
currency?: string;
|
|
38
|
+
organization?: string;
|
|
39
|
+
rail?: Rail;
|
|
40
|
+
type?: Transaction.Types;
|
|
41
|
+
}
|
|
42
|
+
namespace Query {
|
|
43
|
+
const type: isly.Object<{
|
|
44
|
+
account: string | undefined;
|
|
45
|
+
limit: number | undefined;
|
|
46
|
+
cursor: string | undefined;
|
|
47
|
+
start: string | undefined;
|
|
48
|
+
end: string | undefined;
|
|
49
|
+
currency: string | undefined;
|
|
50
|
+
organization: string | undefined;
|
|
51
|
+
rail: "paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "fasterpayments" | "chaps" | "bacs" | "transfer" | "credit" | undefined;
|
|
52
|
+
type: "internal" | "card" | "external" | "system" | undefined;
|
|
53
|
+
}>;
|
|
54
|
+
function parse(query: string | http.Request["search"]): Query;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { http } from "cloudly-http";
|
|
2
|
+
import { isly } from "isly2";
|
|
3
|
+
import { Rail } from "../../Rail";
|
|
4
|
+
import { Transaction } from "../../Transaction";
|
|
2
5
|
import { Notes } from "./Notes";
|
|
3
6
|
export class Transactions {
|
|
4
7
|
client;
|
|
@@ -28,4 +31,26 @@ export class Transactions {
|
|
|
28
31
|
return this.client.get(`/transaction/statistics${query}`);
|
|
29
32
|
}
|
|
30
33
|
}
|
|
34
|
+
(function (Transactions) {
|
|
35
|
+
let Query;
|
|
36
|
+
(function (Query) {
|
|
37
|
+
Query.type = isly.object({
|
|
38
|
+
account: isly.string().optional(),
|
|
39
|
+
limit: isly.number().optional(),
|
|
40
|
+
cursor: isly.string().optional(),
|
|
41
|
+
start: isly.string().optional(),
|
|
42
|
+
end: isly.string().optional(),
|
|
43
|
+
currency: isly.string().optional(),
|
|
44
|
+
organization: isly.string().optional(),
|
|
45
|
+
rail: Rail.type2.optional(),
|
|
46
|
+
type: isly.string("value", ...Transaction.types).optional(),
|
|
47
|
+
});
|
|
48
|
+
function parse(query) {
|
|
49
|
+
if (typeof query == "string")
|
|
50
|
+
query = query ? http.Search.parse(query.replace("?", "")) : {};
|
|
51
|
+
return Query.type.prune(query) ?? {};
|
|
52
|
+
}
|
|
53
|
+
Query.parse = parse;
|
|
54
|
+
})(Query = Transactions.Query || (Transactions.Query = {}));
|
|
55
|
+
})(Transactions || (Transactions = {}));
|
|
31
56
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../Client/Transactions/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../Client/Transactions/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AACnC,OAAO,EAAE,IAAI,EAAE,MAAM,OAAO,CAAA;AAG5B,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAA;AAGjC,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAE/B,MAAM,OAAO,YAAY;IAEK;IADpB,KAAK,CAAO;IACrB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;QAC/C,IAAI,CAAC,KAAK,GAAG,IAAI,KAAK,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,KAAK,GAAL,kBAAK,KAAL,kBAAK,QAiBrB;AACF,CAAC,EA9BgB,YAAY,KAAZ,YAAY,QA8B5B"}
|
|
@@ -12,7 +12,7 @@ import { Processor } from "./Processor";
|
|
|
12
12
|
import { Reports } from "./Reports";
|
|
13
13
|
import { Rules } from "./Rules";
|
|
14
14
|
import { Settlements } from "./Settlements";
|
|
15
|
-
import { Transactions } from "./Transactions";
|
|
15
|
+
import { Transactions as ClientTransactions } from "./Transactions";
|
|
16
16
|
import { Treasury } from "./Treasury";
|
|
17
17
|
import { Version } from "./Version";
|
|
18
18
|
export declare class Client {
|
|
@@ -29,7 +29,7 @@ export declare class Client {
|
|
|
29
29
|
readonly logs: Logs;
|
|
30
30
|
readonly rules: Rules;
|
|
31
31
|
readonly settlements: Settlements;
|
|
32
|
-
readonly transactions:
|
|
32
|
+
readonly transactions: ClientTransactions;
|
|
33
33
|
readonly treasury: Treasury;
|
|
34
34
|
readonly flags: Labels;
|
|
35
35
|
readonly groups: Labels;
|
|
@@ -44,3 +44,6 @@ export declare class Client {
|
|
|
44
44
|
onUnauthorized?: (client: Client) => Promise<boolean>;
|
|
45
45
|
static create(server: string, key?: string): Client;
|
|
46
46
|
}
|
|
47
|
+
export declare namespace Client {
|
|
48
|
+
export import Transactions = ClientTransactions;
|
|
49
|
+
}
|
package/dist/mjs/Client/index.js
CHANGED
|
@@ -12,7 +12,7 @@ import { Processor } from "./Processor";
|
|
|
12
12
|
import { Reports } from "./Reports";
|
|
13
13
|
import { Rules } from "./Rules";
|
|
14
14
|
import { Settlements } from "./Settlements";
|
|
15
|
-
import { Transactions } from "./Transactions";
|
|
15
|
+
import { Transactions as ClientTransactions } from "./Transactions";
|
|
16
16
|
import { Treasury } from "./Treasury";
|
|
17
17
|
import { Version } from "./Version";
|
|
18
18
|
export class Client {
|
|
@@ -60,7 +60,7 @@ export class Client {
|
|
|
60
60
|
this.logs = new Logs(this.client);
|
|
61
61
|
this.rules = new Rules(this.client);
|
|
62
62
|
this.settlements = new Settlements(this.client);
|
|
63
|
-
this.transactions = new
|
|
63
|
+
this.transactions = new ClientTransactions(this.client);
|
|
64
64
|
this.treasury = new Treasury(this.client);
|
|
65
65
|
this.flags = new Labels(this.client, "flag");
|
|
66
66
|
this.groups = new Labels(this.client, "group");
|
|
@@ -92,4 +92,7 @@ export class Client {
|
|
|
92
92
|
return result;
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
|
+
(function (Client) {
|
|
96
|
+
Client.Transactions = ClientTransactions;
|
|
97
|
+
})(Client || (Client = {}));
|
|
95
98
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Client/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAA;AAChD,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AACnC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAA;AACrC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AACjC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAA;AAC7B,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAC/C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACnC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAA;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.js","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AAY,IAAI,MAAM,CAAC,YAAY,EAAE;oBACtE,CAAC,CAAC,EAAE,CAAC;aACN,CAAC;YACF,WAAW,EAAE,KAAK,EAAC,QAAQ,EAAC,EAAE;gBAC7B,IAAI,MAAM,GAAG,QAAQ,CAAA;gBACrB,MAAM,IAAI,GAAG,MAAM,QAAQ,CAAC,IAAI,CAAA;gBAChC,IAAI,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC;oBACtB,MAAM,GAAG,IAAI,CAAC,QAAQ,CAAC,MAAM,CAC5B,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,QAAQ,EAAE;wBACrC,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,IAAI,QAAQ,CAAC,MAAM,CAAC,IAAI,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;qBACtE,CAAC,CACF,CAAA;gBACF,OAAO,MAAM,CAAA;YACd,CAAC;SACD,CAAC,CAAA;QACF,MAAM,MAAM,GAAW,IAAI,MAAM,CAAC,UAAU,CAAC,CAAA;QAC7C,OAAO,MAAM,CAAA;IACd,CAAC;CACD;AACD,WAAiB,MAAM;IACR,mBAAY,GAAG,kBAAkB,CAAA;AAChD,CAAC,EAFgB,MAAM,KAAN,MAAM,QAEtB"}
|
package/dist/mjs/Rail/index.d.ts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { isly } from "isly";
|
|
2
|
+
import { isly as isly2 } from "isly2";
|
|
2
3
|
import { Address as RailAddress } from "./Address";
|
|
3
4
|
export type Rail = typeof Rail.rails[number];
|
|
4
5
|
export declare namespace Rail {
|
|
5
6
|
const rails: readonly ["internal", "paxgiro", "paxgiro-credit", "mastercard", "diners", "visa", "fasterpayments", "chaps", "bacs", "transfer", "credit"];
|
|
6
7
|
const type: isly.Type<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "fasterpayments" | "chaps" | "bacs" | "transfer" | "credit">;
|
|
8
|
+
const type2: isly2.String<"paxgiro" | "mastercard" | "diners" | "visa" | "internal" | "paxgiro-credit" | "fasterpayments" | "chaps" | "bacs" | "transfer" | "credit">;
|
|
7
9
|
export import Address = RailAddress;
|
|
8
10
|
}
|
package/dist/mjs/Rail/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { isly } from "isly";
|
|
2
|
+
import { isly as isly2 } from "isly2";
|
|
2
3
|
import { Address as RailAddress } from "./Address";
|
|
3
4
|
export var Rail;
|
|
4
5
|
(function (Rail) {
|
|
@@ -16,6 +17,7 @@ export var Rail;
|
|
|
16
17
|
"credit",
|
|
17
18
|
];
|
|
18
19
|
Rail.type = isly.string(Rail.rails);
|
|
20
|
+
Rail.type2 = isly2.string("value", ...Rail.rails);
|
|
19
21
|
Rail.Address = RailAddress;
|
|
20
22
|
})(Rail || (Rail = {}));
|
|
21
23
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Rail/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;AAC3B,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,WAAW,CAAA;AAGlD,MAAM,KAAW,IAAI,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../Rail/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;AAC3B,OAAO,EAAE,IAAI,IAAI,KAAK,EAAE,MAAM,OAAO,CAAA;AACrC,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,WAAW,CAAA;AAGlD,MAAM,KAAW,IAAI,CAiBpB;AAjBD,WAAiB,IAAI;IACP,UAAK,GAAG;QACpB,UAAU;QACV,SAAS;QACT,gBAAgB;QAChB,YAAY;QACZ,QAAQ;QACR,MAAM;QACN,gBAAgB;QAChB,OAAO;QACP,MAAM;QACN,UAAU;QACV,QAAQ;KACC,CAAA;IACG,SAAI,GAAG,IAAI,CAAC,MAAM,CAAO,KAAA,KAAK,CAAC,CAAA;IAC/B,UAAK,GAAG,KAAK,CAAC,MAAM,CAAO,OAAO,EAAE,GAAG,KAAA,KAAK,CAAC,CAAA;IAC5C,YAAO,GAAG,WAAW,CAAA;AACpC,CAAC,EAjBgB,IAAI,KAAJ,IAAI,QAiBpB"}
|