@pax2pay/model-banking 0.1.466 → 0.1.468
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/Accounts/History.ts +2 -5
- package/Client/Accounts/Rails.ts +2 -5
- package/Client/Accounts/index.ts +2 -5
- package/Client/Cards.ts +2 -5
- package/Client/Exchanges.ts +2 -5
- package/Client/Operations.ts +2 -5
- package/Client/Organizations/Groups.ts +2 -5
- package/Client/Organizations/index.ts +2 -5
- package/Client/Processor/Tpl.ts +22 -0
- package/Client/Processor/index.ts +9 -0
- package/Client/Reports.ts +2 -5
- package/Client/Transactions/Notes.ts +2 -5
- package/Client/Transactions/index.ts +2 -5
- package/Client/Version.ts +2 -6
- package/Client/index.ts +40 -31
- package/dist/Client/Accounts/History.d.ts +2 -2
- package/dist/Client/Accounts/History.js +2 -3
- package/dist/Client/Accounts/History.js.map +1 -1
- package/dist/Client/Accounts/Rails.d.ts +2 -2
- package/dist/Client/Accounts/Rails.js +2 -3
- package/dist/Client/Accounts/Rails.js.map +1 -1
- package/dist/Client/Accounts/index.d.ts +2 -2
- package/dist/Client/Accounts/index.js +2 -3
- package/dist/Client/Accounts/index.js.map +1 -1
- package/dist/Client/Cards.d.ts +2 -2
- package/dist/Client/Cards.js +2 -3
- package/dist/Client/Cards.js.map +1 -1
- package/dist/Client/Exchanges.d.ts +2 -2
- package/dist/Client/Exchanges.js +2 -3
- package/dist/Client/Exchanges.js.map +1 -1
- package/dist/Client/Operations.d.ts +2 -2
- package/dist/Client/Operations.js +2 -3
- package/dist/Client/Operations.js.map +1 -1
- package/dist/Client/Organizations/Groups.d.ts +2 -2
- package/dist/Client/Organizations/Groups.js +2 -3
- package/dist/Client/Organizations/Groups.js.map +1 -1
- package/dist/Client/Organizations/index.d.ts +2 -2
- package/dist/Client/Organizations/index.js +2 -3
- package/dist/Client/Organizations/index.js.map +1 -1
- package/dist/Client/Processor/Tpl.d.ts +12 -0
- package/dist/Client/Processor/Tpl.js +10 -0
- package/dist/Client/Processor/Tpl.js.map +1 -0
- package/dist/Client/Processor/index.d.ts +7 -0
- package/dist/Client/Processor/index.js +8 -0
- package/dist/Client/Processor/index.js.map +1 -0
- package/dist/Client/Reports.d.ts +2 -2
- package/dist/Client/Reports.js +2 -3
- package/dist/Client/Reports.js.map +1 -1
- package/dist/Client/Transactions/Notes.d.ts +2 -2
- package/dist/Client/Transactions/Notes.js +2 -3
- package/dist/Client/Transactions/Notes.js.map +1 -1
- package/dist/Client/Transactions/index.d.ts +2 -2
- package/dist/Client/Transactions/index.js +2 -3
- package/dist/Client/Transactions/index.js.map +1 -1
- package/dist/Client/Version.d.ts +2 -3
- package/dist/Client/Version.js +2 -3
- package/dist/Client/Version.js.map +1 -1
- package/dist/Client/index.d.ts +11 -7
- package/dist/Client/index.js +22 -10
- package/dist/Client/index.js.map +1 -1
- package/dist/reports/visa/Data/Country.d.ts +1 -0
- package/dist/reports/visa/Data/Country.js +13 -0
- package/dist/reports/visa/Data/Country.js.map +1 -1
- package/dist/reports/visa/Data/Monthly.d.ts +2 -0
- package/dist/reports/visa/Data/Monthly.js +17 -5
- package/dist/reports/visa/Data/Monthly.js.map +1 -1
- package/dist/reports/visa/Data/NonMonthly.d.ts +2 -1
- package/dist/reports/visa/Data/NonMonthly.js +18 -7
- package/dist/reports/visa/Data/NonMonthly.js.map +1 -1
- package/dist/reports/visa/Data/Regional.d.ts +1 -0
- package/dist/reports/visa/Data/Regional.js +7 -0
- package/dist/reports/visa/Data/Regional.js.map +1 -1
- package/dist/reports/visa/Data/index.d.ts +3 -2
- package/dist/reports/visa/Data/index.js +10 -1
- package/dist/reports/visa/Data/index.js.map +1 -1
- package/package.json +1 -5
- package/reports/visa/Data/Country.ts +12 -0
- package/reports/visa/Data/Monthly.ts +20 -5
- package/reports/visa/Data/NonMonthly.ts +15 -6
- package/reports/visa/Data/Regional.ts +6 -0
- package/reports/visa/Data/index.ts +10 -2
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Account } from "../../Account"
|
|
5
4
|
|
|
6
|
-
export class History
|
|
7
|
-
constructor(client: http.Client) {
|
|
8
|
-
super(client)
|
|
9
|
-
}
|
|
5
|
+
export class History {
|
|
6
|
+
constructor(private readonly client: http.Client) {}
|
|
10
7
|
async list(account: string): Promise<Account.History[] | gracely.Error> {
|
|
11
8
|
return this.client.get<Account.History[]>(`/account/${account}/history`)
|
|
12
9
|
}
|
package/Client/Accounts/Rails.ts
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Rail } from "../../Rail"
|
|
5
4
|
import { Supplier } from "../../Supplier"
|
|
6
5
|
|
|
7
|
-
export class Rails
|
|
8
|
-
constructor(client: http.Client) {
|
|
9
|
-
super(client)
|
|
10
|
-
}
|
|
6
|
+
export class Rails {
|
|
7
|
+
constructor(private readonly client: http.Client) {}
|
|
11
8
|
async create(account: string, supplier: Supplier): Promise<Rail | gracely.Error> {
|
|
12
9
|
return this.client.post<Rail>(`/account/${account}/rail`, supplier)
|
|
13
10
|
}
|
package/Client/Accounts/index.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Account } from "../../Account"
|
|
5
4
|
import { Buffer } from "./Buffer"
|
|
6
5
|
import { Counterparts } from "./Counterparts"
|
|
@@ -9,7 +8,7 @@ import { Rails } from "./Rails"
|
|
|
9
8
|
import { Rules } from "./Rules"
|
|
10
9
|
import { Status } from "./Status"
|
|
11
10
|
|
|
12
|
-
export class Accounts
|
|
11
|
+
export class Accounts {
|
|
13
12
|
readonly buffer = new Buffer(this.client)
|
|
14
13
|
readonly Rails = new Rails(this.client)
|
|
15
14
|
readonly rules = new Rules(this.client)
|
|
@@ -17,9 +16,7 @@ export class Accounts extends rest.Collection<gracely.Error> {
|
|
|
17
16
|
readonly counterparts = new Counterparts(this.client)
|
|
18
17
|
readonly history = new History(this.client)
|
|
19
18
|
|
|
20
|
-
constructor(client: http.Client) {
|
|
21
|
-
super(client)
|
|
22
|
-
}
|
|
19
|
+
constructor(private readonly client: http.Client) {}
|
|
23
20
|
async create(account: Account.Creatable): Promise<Account | gracely.Error> {
|
|
24
21
|
return this.client.post<Account>("/account", account)
|
|
25
22
|
}
|
package/Client/Cards.ts
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { isoly } from "isoly"
|
|
3
3
|
import { http } from "cloudly-http"
|
|
4
|
-
import * as rest from "cloudly-rest"
|
|
5
4
|
import { Card } from "../Card"
|
|
6
5
|
|
|
7
|
-
export class Cards
|
|
8
|
-
constructor(client: http.Client) {
|
|
9
|
-
super(client)
|
|
10
|
-
}
|
|
6
|
+
export class Cards {
|
|
7
|
+
constructor(private readonly client: http.Client) {}
|
|
11
8
|
|
|
12
9
|
async fetch(card: string): Promise<Card | gracely.Error> {
|
|
13
10
|
// I mean it's supposed to return Card.Storable
|
package/Client/Exchanges.ts
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { isoly } from "isoly"
|
|
3
3
|
import { http } from "cloudly-http"
|
|
4
|
-
import * as rest from "cloudly-rest"
|
|
5
4
|
import { Exchange } from "../Exchange"
|
|
6
5
|
|
|
7
|
-
export class Exchanges
|
|
8
|
-
constructor(client: http.Client) {
|
|
9
|
-
super(client)
|
|
10
|
-
}
|
|
6
|
+
export class Exchanges {
|
|
7
|
+
constructor(private readonly client: http.Client) {}
|
|
11
8
|
async fetch(currency: isoly.Currency): Promise<Exchange.Rates | gracely.Error> {
|
|
12
9
|
return this.client.get<Exchange.Rates>(`/exchange?currencies=${currency}`)
|
|
13
10
|
}
|
package/Client/Operations.ts
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Operation } from "../Operation"
|
|
5
4
|
|
|
6
|
-
export class Operations
|
|
7
|
-
constructor(client: http.Client) {
|
|
8
|
-
super(client)
|
|
9
|
-
}
|
|
5
|
+
export class Operations {
|
|
6
|
+
constructor(private readonly client: http.Client) {}
|
|
10
7
|
async list(options?: {
|
|
11
8
|
start?: string
|
|
12
9
|
end?: string
|
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Organization } from "../../Organization"
|
|
5
4
|
|
|
6
|
-
export class Groups
|
|
7
|
-
constructor(client: http.Client) {
|
|
8
|
-
super(client)
|
|
9
|
-
}
|
|
5
|
+
export class Groups {
|
|
6
|
+
constructor(private readonly client: http.Client) {}
|
|
10
7
|
async replace(organization: string, groups: string[]): Promise<Organization | gracely.Error> {
|
|
11
8
|
return this.client.put<Organization>(`/organization/group`, groups, {
|
|
12
9
|
organization,
|
|
@@ -1,17 +1,14 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Organization } from "../../Organization"
|
|
5
4
|
import { Groups } from "./Groups"
|
|
6
5
|
import { Rules } from "./Rules"
|
|
7
6
|
|
|
8
|
-
export class Organizations
|
|
7
|
+
export class Organizations {
|
|
9
8
|
readonly Rules = new Rules(this.client)
|
|
10
9
|
readonly groups = new Groups(this.client)
|
|
11
10
|
|
|
12
|
-
constructor(client: http.Client) {
|
|
13
|
-
super(client)
|
|
14
|
-
}
|
|
11
|
+
constructor(private readonly client: http.Client) {}
|
|
15
12
|
async list(options?: {
|
|
16
13
|
limit?: string
|
|
17
14
|
cursor?: string
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { gracely } from "gracely"
|
|
2
|
+
import { http } from "cloudly-http"
|
|
3
|
+
import { storage } from "cloudly-storage"
|
|
4
|
+
import { Card } from "../../Card"
|
|
5
|
+
import { reports } from "../../reports"
|
|
6
|
+
|
|
7
|
+
export class Tpl {
|
|
8
|
+
constructor(private readonly client: http.Client) {}
|
|
9
|
+
|
|
10
|
+
async getQuarterly(
|
|
11
|
+
stack: Card.Stack,
|
|
12
|
+
[start, end]: NonNullable<storage.KeyValueStore.ListOptions["range"]>,
|
|
13
|
+
cursor?: string,
|
|
14
|
+
limit?: number
|
|
15
|
+
): Promise<(reports.visa.Data & { cursor?: string }) | gracely.Error> {
|
|
16
|
+
const search =
|
|
17
|
+
`?start=${start}&end=${end}` + `${cursor ? `&cursor=${cursor}` : ""}` + `${limit ? `&limit=${limit}` : ""}`
|
|
18
|
+
return await this.client.get<reports.visa.Data & { cursor?: string }>(
|
|
19
|
+
`/processor/${stack}/report/quarterly${search}`
|
|
20
|
+
)
|
|
21
|
+
}
|
|
22
|
+
}
|
package/Client/Reports.ts
CHANGED
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Card } from "../Card"
|
|
5
4
|
|
|
6
|
-
export class Reports
|
|
7
|
-
constructor(client: http.Client) {
|
|
8
|
-
super(client)
|
|
9
|
-
}
|
|
5
|
+
export class Reports {
|
|
6
|
+
constructor(private readonly client: http.Client) {}
|
|
10
7
|
async fetchT140(stack: Card.Stack, id: string): Promise<string | gracely.Error> {
|
|
11
8
|
return this.client.get<string>(`/processor/${stack}/t140/${id}?decrypt`)
|
|
12
9
|
}
|
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
3
|
import { Transaction } from "../../Transaction"
|
|
5
4
|
|
|
6
|
-
export class Notes
|
|
7
|
-
constructor(client: http.Client) {
|
|
8
|
-
super(client)
|
|
9
|
-
}
|
|
5
|
+
export class Notes {
|
|
6
|
+
constructor(private readonly client: http.Client) {}
|
|
10
7
|
async create(
|
|
11
8
|
organization: string,
|
|
12
9
|
account: string,
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { isoly } from "isoly"
|
|
3
3
|
import { http } from "cloudly-http"
|
|
4
|
-
import * as rest from "cloudly-rest"
|
|
5
4
|
import { Card } from "../../Card"
|
|
6
5
|
import { Operation } from "../../Operation"
|
|
7
6
|
import { Rule } from "../../Rule"
|
|
@@ -9,11 +8,9 @@ import { Supplier } from "../../Supplier"
|
|
|
9
8
|
import { Transaction } from "../../Transaction"
|
|
10
9
|
import { Notes } from "./Notes"
|
|
11
10
|
|
|
12
|
-
export class Transactions
|
|
11
|
+
export class Transactions {
|
|
13
12
|
readonly Notes = new Notes(this.client)
|
|
14
|
-
constructor(client: http.Client) {
|
|
15
|
-
super(client)
|
|
16
|
-
}
|
|
13
|
+
constructor(private readonly client: http.Client) {}
|
|
17
14
|
async create(account: string, transaction: Transaction.Creatable): Promise<Transaction | gracely.Error> {
|
|
18
15
|
return this.client.post<Transaction>(`/account/${account}/transaction`, transaction)
|
|
19
16
|
}
|
package/Client/Version.ts
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
import { gracely } from "gracely"
|
|
2
1
|
import { http } from "cloudly-http"
|
|
3
|
-
import * as rest from "cloudly-rest"
|
|
4
2
|
|
|
5
|
-
export class Version
|
|
6
|
-
constructor(client: http.Client) {
|
|
7
|
-
super(client)
|
|
8
|
-
}
|
|
3
|
+
export class Version {
|
|
4
|
+
constructor(private readonly client: http.Client) {}
|
|
9
5
|
async fetch() {
|
|
10
6
|
return this.client.get<any>("/version")
|
|
11
7
|
}
|
package/Client/index.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { gracely } from "gracely"
|
|
2
2
|
import { userwidgets } from "@userwidgets/model"
|
|
3
3
|
import { http } from "cloudly-http"
|
|
4
|
-
import { rest } from "cloudly-rest"
|
|
5
4
|
import { Accounts } from "./Accounts"
|
|
6
5
|
import { Audit } from "./Audit"
|
|
7
6
|
import { Cards } from "./Cards"
|
|
@@ -10,6 +9,7 @@ import { Labels } from "./Labels"
|
|
|
10
9
|
import { Logs } from "./Logs"
|
|
11
10
|
import { Operations } from "./Operations"
|
|
12
11
|
import { Organizations } from "./Organizations"
|
|
12
|
+
import { Processor } from "./Processor"
|
|
13
13
|
import { Reports } from "./Reports"
|
|
14
14
|
import { Rules } from "./Rules"
|
|
15
15
|
import { Settlements } from "./Settlements"
|
|
@@ -17,7 +17,7 @@ import { Transactions } from "./Transactions"
|
|
|
17
17
|
import { Treasury } from "./Treasury"
|
|
18
18
|
import { Version } from "./Version"
|
|
19
19
|
|
|
20
|
-
export class Client
|
|
20
|
+
export class Client {
|
|
21
21
|
realm?: string
|
|
22
22
|
organization?: string
|
|
23
23
|
readonly accounts = new Accounts(this.client)
|
|
@@ -36,35 +36,44 @@ export class Client extends rest.Client<gracely.Error> {
|
|
|
36
36
|
readonly groups = new Labels(this.client, "group")
|
|
37
37
|
readonly userwidgets = (server: string, application: string) =>
|
|
38
38
|
new userwidgets.ClientCollection(new http.Client(server), { application })
|
|
39
|
+
readonly processors = new Processor(this.client)
|
|
39
40
|
readonly version = new Version(this.client)
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
41
|
+
onUnauthorized?: (client: Client) => Promise<boolean>
|
|
42
|
+
private constructor(private readonly client: http.Client<gracely.Error>) {
|
|
43
|
+
this.client.onUnauthorized = async () => this.onUnauthorized != undefined && (await this.onUnauthorized(this))
|
|
44
|
+
}
|
|
45
|
+
set key(value: string | undefined) {
|
|
46
|
+
this.client.key = value
|
|
47
|
+
}
|
|
48
|
+
get key(): string | undefined {
|
|
49
|
+
return this.client.key
|
|
50
|
+
}
|
|
51
|
+
set onError(value: ((request: http.Request, response: http.Response) => Promise<boolean>) | undefined) {
|
|
52
|
+
this.client.onError = value
|
|
53
|
+
}
|
|
54
|
+
get onError(): ((request: http.Request, response: http.Response) => Promise<boolean>) | undefined {
|
|
55
|
+
return this.client.onError
|
|
56
|
+
}
|
|
57
|
+
static create(server: string, key?: string): Client {
|
|
58
|
+
const httpClient: http.Client<gracely.Error> = new http.Client<gracely.Error>(server, key, {
|
|
59
|
+
appendHeader: request => ({
|
|
60
|
+
...request.header,
|
|
61
|
+
realm: result.realm,
|
|
62
|
+
organization: request.header.organization ?? result.organization,
|
|
63
|
+
}),
|
|
64
|
+
postprocess: async response => {
|
|
65
|
+
let result = response
|
|
66
|
+
const body = await response.body
|
|
67
|
+
if (Array.isArray(body))
|
|
68
|
+
result = http.Response.create(
|
|
69
|
+
Object.defineProperty(body, "cursor", {
|
|
70
|
+
value: response.header.cursor ?? response.header.link?.split?.(",")[0],
|
|
71
|
+
})
|
|
72
|
+
)
|
|
73
|
+
return result
|
|
74
|
+
},
|
|
75
|
+
})
|
|
76
|
+
const result: Client = new Client(httpClient)
|
|
77
|
+
return result
|
|
66
78
|
}
|
|
67
|
-
}
|
|
68
|
-
export namespace Client {
|
|
69
|
-
export type Unauthorized = (client: rest.Client<never>) => Promise<boolean>
|
|
70
79
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { http } from "cloudly-http";
|
|
3
|
-
import * as rest from "cloudly-rest";
|
|
4
3
|
import { Account } from "../../Account";
|
|
5
|
-
export declare class History
|
|
4
|
+
export declare class History {
|
|
5
|
+
private readonly client;
|
|
6
6
|
constructor(client: http.Client);
|
|
7
7
|
list(account: string): Promise<Account.History[] | gracely.Error>;
|
|
8
8
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"History.js","sourceRoot":"../","sources":["Client/Accounts/History.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"History.js","sourceRoot":"../","sources":["Client/Accounts/History.ts"],"names":[],"mappings":"AAIA,MAAM,OAAO,OAAO;IACnB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IACpD,KAAK,CAAC,IAAI,CAAC,OAAe;QACzB,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAoB,YAAY,OAAO,UAAU,CAAC,CAAA;IACzE,CAAC;CACD"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { http } from "cloudly-http";
|
|
3
|
-
import * as rest from "cloudly-rest";
|
|
4
3
|
import { Rail } from "../../Rail";
|
|
5
4
|
import { Supplier } from "../../Supplier";
|
|
6
|
-
export declare class Rails
|
|
5
|
+
export declare class Rails {
|
|
6
|
+
private readonly client;
|
|
7
7
|
constructor(client: http.Client);
|
|
8
8
|
create(account: string, supplier: Supplier): Promise<Rail | gracely.Error>;
|
|
9
9
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
export class Rails extends rest.Collection {
|
|
1
|
+
export class Rails {
|
|
3
2
|
constructor(client) {
|
|
4
|
-
|
|
3
|
+
this.client = client;
|
|
5
4
|
}
|
|
6
5
|
async create(account, supplier) {
|
|
7
6
|
return this.client.post(`/account/${account}/rail`, supplier);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Rails.js","sourceRoot":"../","sources":["Client/Accounts/Rails.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Rails.js","sourceRoot":"../","sources":["Client/Accounts/Rails.ts"],"names":[],"mappings":"AAKA,MAAM,OAAO,KAAK;IACjB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IACpD,KAAK,CAAC,MAAM,CAAC,OAAe,EAAE,QAAkB;QAC/C,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAO,YAAY,OAAO,OAAO,EAAE,QAAQ,CAAC,CAAA;IACpE,CAAC;CACD"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { http } from "cloudly-http";
|
|
3
|
-
import * as rest from "cloudly-rest";
|
|
4
3
|
import { Account } from "../../Account";
|
|
5
4
|
import { Buffer } from "./Buffer";
|
|
6
5
|
import { Counterparts } from "./Counterparts";
|
|
@@ -8,7 +7,8 @@ import { History } from "./History";
|
|
|
8
7
|
import { Rails } from "./Rails";
|
|
9
8
|
import { Rules } from "./Rules";
|
|
10
9
|
import { Status } from "./Status";
|
|
11
|
-
export declare class Accounts
|
|
10
|
+
export declare class Accounts {
|
|
11
|
+
private readonly client;
|
|
12
12
|
readonly buffer: Buffer;
|
|
13
13
|
readonly Rails: Rails;
|
|
14
14
|
readonly rules: Rules;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import * as rest from "cloudly-rest";
|
|
2
1
|
import { Buffer } from "./Buffer";
|
|
3
2
|
import { Counterparts } from "./Counterparts";
|
|
4
3
|
import { History } from "./History";
|
|
5
4
|
import { Rails } from "./Rails";
|
|
6
5
|
import { Rules } from "./Rules";
|
|
7
6
|
import { Status } from "./Status";
|
|
8
|
-
export class Accounts
|
|
7
|
+
export class Accounts {
|
|
9
8
|
constructor(client) {
|
|
10
|
-
|
|
9
|
+
this.client = client;
|
|
11
10
|
this.buffer = new Buffer(this.client);
|
|
12
11
|
this.Rails = new Rails(this.client);
|
|
13
12
|
this.rules = new Rules(this.client);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"../","sources":["Client/Accounts/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../","sources":["Client/Accounts/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACnC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAC/B,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AAEjC,MAAM,OAAO,QAAQ;IAQpB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;QAPvC,WAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAChC,UAAK,GAAG,IAAI,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAC9B,UAAK,GAAG,IAAI,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAC9B,WAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAChC,iBAAY,GAAG,IAAI,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAC5C,YAAO,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IAEQ,CAAC;IACpD,KAAK,CAAC,MAAM,CAAC,OAA0B;QACtC,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAU,UAAU,EAAE,OAAO,CAAC,CAAA;IACtD,CAAC;IACD,KAAK,CAAC,GAAG,CAAC,OAAe;QACxB,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAU,YAAY,OAAO,EAAE,CAAC,CAAA;IACvD,CAAC;IACD,KAAK,CAAC,IAAI,CAAC,OAIV;QACA,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAA8C,UAAU,EAAE,OAAO,CAAC,CAAA;IACzF,CAAC;CACD"}
|
package/dist/Client/Cards.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { isoly } from "isoly";
|
|
3
3
|
import { http } from "cloudly-http";
|
|
4
|
-
import * as rest from "cloudly-rest";
|
|
5
4
|
import { Card } from "../Card";
|
|
6
|
-
export declare class Cards
|
|
5
|
+
export declare class Cards {
|
|
6
|
+
private readonly client;
|
|
7
7
|
constructor(client: http.Client);
|
|
8
8
|
fetch(card: string): Promise<Card | gracely.Error>;
|
|
9
9
|
create(card: Card.Creatable): Promise<Card | gracely.Error>;
|
package/dist/Client/Cards.js
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { http } from "cloudly-http";
|
|
2
|
-
|
|
3
|
-
export class Cards extends rest.Collection {
|
|
2
|
+
export class Cards {
|
|
4
3
|
constructor(client) {
|
|
5
|
-
|
|
4
|
+
this.client = client;
|
|
6
5
|
}
|
|
7
6
|
async fetch(card) {
|
|
8
7
|
return this.client.get(`/card/${card}`);
|
package/dist/Client/Cards.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Cards.js","sourceRoot":"../","sources":["Client/Cards.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;
|
|
1
|
+
{"version":3,"file":"Cards.js","sourceRoot":"../","sources":["Client/Cards.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAGnC,MAAM,OAAO,KAAK;IACjB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IAEpD,KAAK,CAAC,KAAK,CAAC,IAAY;QAEvB,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAO,SAAS,IAAI,EAAE,CAAC,CAAA;IAC9C,CAAC;IACD,KAAK,CAAC,MAAM,CAAC,IAAoB;QAChC,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAO,OAAO,EAAE,IAAI,CAAC,CAAA;IAC7C,CAAC;IACD,KAAK,CAAC,IAAI,CAAC,OAMV;QAEA,MAAM,MAAM,GACX,OAAO,EAAE,KAAK,IAAI,OAAO,EAAE,GAAG;YAC7B,CAAC,CAAC,UAAU,OAAO,EAAE,KAAK,QAAQ,OAAO,EAAE,GAAG,EAAE;YAChD,CAAC,CAAC,OAAO,EAAE,KAAK;gBAChB,CAAC,CAAC,UAAU,OAAO,EAAE,KAAK,EAAE;gBAC5B,CAAC,CAAC,OAAO,EAAE,GAAG;oBACd,CAAC,CAAC,QAAQ,OAAO,EAAE,GAAG,EAAE;oBACxB,CAAC,CAAC,EAAE,CAAA;QACN,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CACrB,QAAQ,MAAM,EAAE,EAChB,OAAO,IAAI,CAAC,CAAC,EAAE,KAAK,EAAE,GAAG,EAAE,GAAG,OAAO,EAAE,EAAE,EAAE,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,CAC7D,CAAA;IACF,CAAC;IACD,KAAK,CAAC,MAAM,CAAC,EAAU,EAAE,IAAqB;QAC7C,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAO,SAAS,EAAE,EAAE,EAAE,IAAI,CAAC,CAAA;IACpD,CAAC;IACD,KAAK,CAAC,UAAU,CACf,MAAmB,EACnB,KAAsB,EACtB,OAA6C;QAE7C,MAAM,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,EAAE,GAAG,OAAO,EAAE,GAAG,KAAK,EAAE,CAAC,CAAA;QAC/D,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CACrB,oBAAoB,MAAM,IAAI,OAAO,EAAE,CACvC,CAAA;IACF,CAAC;CACD"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { isoly } from "isoly";
|
|
3
3
|
import { http } from "cloudly-http";
|
|
4
|
-
import * as rest from "cloudly-rest";
|
|
5
4
|
import { Exchange } from "../Exchange";
|
|
6
|
-
export declare class Exchanges
|
|
5
|
+
export declare class Exchanges {
|
|
6
|
+
private readonly client;
|
|
7
7
|
constructor(client: http.Client);
|
|
8
8
|
fetch(currency: isoly.Currency): Promise<Exchange.Rates | gracely.Error>;
|
|
9
9
|
}
|
package/dist/Client/Exchanges.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
export class Exchanges extends rest.Collection {
|
|
1
|
+
export class Exchanges {
|
|
3
2
|
constructor(client) {
|
|
4
|
-
|
|
3
|
+
this.client = client;
|
|
5
4
|
}
|
|
6
5
|
async fetch(currency) {
|
|
7
6
|
return this.client.get(`/exchange?currencies=${currency}`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Exchanges.js","sourceRoot":"../","sources":["Client/Exchanges.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Exchanges.js","sourceRoot":"../","sources":["Client/Exchanges.ts"],"names":[],"mappings":"AAKA,MAAM,OAAO,SAAS;IACrB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IACpD,KAAK,CAAC,KAAK,CAAC,QAAwB;QACnC,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAiB,wBAAwB,QAAQ,EAAE,CAAC,CAAA;IAC3E,CAAC;CACD"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { http } from "cloudly-http";
|
|
3
|
-
import * as rest from "cloudly-rest";
|
|
4
3
|
import { Operation } from "../Operation";
|
|
5
|
-
export declare class Operations
|
|
4
|
+
export declare class Operations {
|
|
5
|
+
private readonly client;
|
|
6
6
|
constructor(client: http.Client);
|
|
7
7
|
list(options?: {
|
|
8
8
|
start?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Operations.js","sourceRoot":"../","sources":["Client/Operations.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Operations.js","sourceRoot":"../","sources":["Client/Operations.ts"],"names":[],"mappings":"AAIA,MAAM,OAAO,UAAU;IACtB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IACpD,KAAK,CAAC,IAAI,CAAC,OAMV;QACA,MAAM,MAAM,GACX,OAAO,EAAE,KAAK,IAAI,OAAO,EAAE,GAAG;YAC7B,CAAC,CAAC,UAAU,OAAO,EAAE,KAAK,QAAQ,OAAO,EAAE,GAAG,EAAE;YAChD,CAAC,CAAC,OAAO,EAAE,KAAK;gBAChB,CAAC,CAAC,UAAU,OAAO,EAAE,KAAK,EAAE;gBAC5B,CAAC,CAAC,OAAO,EAAE,GAAG;oBACd,CAAC,CAAC,QAAQ,OAAO,EAAE,GAAG,EAAE;oBACxB,CAAC,CAAC,EAAE,CAAA;QACN,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CACrB,aAAa,MAAM,EAAE,EACrB,OAAO,IAAI,CAAC,CAAC,EAAE,KAAK,EAAE,GAAG,EAAE,GAAG,OAAO,EAAE,EAAE,EAAE,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,CAC7D,CAAA;IACF,CAAC;CACD"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { http } from "cloudly-http";
|
|
3
|
-
import * as rest from "cloudly-rest";
|
|
4
3
|
import { Organization } from "../../Organization";
|
|
5
|
-
export declare class Groups
|
|
4
|
+
export declare class Groups {
|
|
5
|
+
private readonly client;
|
|
6
6
|
constructor(client: http.Client);
|
|
7
7
|
replace(organization: string, groups: string[]): Promise<Organization | gracely.Error>;
|
|
8
8
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
export class Groups extends rest.Collection {
|
|
1
|
+
export class Groups {
|
|
3
2
|
constructor(client) {
|
|
4
|
-
|
|
3
|
+
this.client = client;
|
|
5
4
|
}
|
|
6
5
|
async replace(organization, groups) {
|
|
7
6
|
return this.client.put(`/organization/group`, groups, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Groups.js","sourceRoot":"../","sources":["Client/Organizations/Groups.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Groups.js","sourceRoot":"../","sources":["Client/Organizations/Groups.ts"],"names":[],"mappings":"AAIA,MAAM,OAAO,MAAM;IAClB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;IAAG,CAAC;IACpD,KAAK,CAAC,OAAO,CAAC,YAAoB,EAAE,MAAgB;QACnD,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAe,qBAAqB,EAAE,MAAM,EAAE;YACnE,YAAY;SACZ,CAAC,CAAA;IACH,CAAC;CACD"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { gracely } from "gracely";
|
|
2
2
|
import { http } from "cloudly-http";
|
|
3
|
-
import * as rest from "cloudly-rest";
|
|
4
3
|
import { Organization } from "../../Organization";
|
|
5
4
|
import { Groups } from "./Groups";
|
|
6
5
|
import { Rules } from "./Rules";
|
|
7
|
-
export declare class Organizations
|
|
6
|
+
export declare class Organizations {
|
|
7
|
+
private readonly client;
|
|
8
8
|
readonly Rules: Rules;
|
|
9
9
|
readonly groups: Groups;
|
|
10
10
|
constructor(client: http.Client);
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import * as rest from "cloudly-rest";
|
|
2
1
|
import { Groups } from "./Groups";
|
|
3
2
|
import { Rules } from "./Rules";
|
|
4
|
-
export class Organizations
|
|
3
|
+
export class Organizations {
|
|
5
4
|
constructor(client) {
|
|
6
|
-
|
|
5
|
+
this.client = client;
|
|
7
6
|
this.Rules = new Rules(this.client);
|
|
8
7
|
this.groups = new Groups(this.client);
|
|
9
8
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"../","sources":["Client/Organizations/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../","sources":["Client/Organizations/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AACjC,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAA;AAE/B,MAAM,OAAO,aAAa;IAIzB,YAA6B,MAAmB;QAAnB,WAAM,GAAN,MAAM,CAAa;QAHvC,UAAK,GAAG,IAAI,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;QAC9B,WAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;IAEU,CAAC;IACpD,KAAK,CAAC,IAAI,CAAC,OAGV;QACA,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAmD,eAAe,EAAE,OAAO,CAAC,CAAA;IACnG,CAAC;IACD,KAAK,CAAC,MAAM,CAAC,YAA0B;QACtC,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAe,eAAe,EAAE,YAAY,CAAC,CAAA;IACrE,CAAC;IACD,KAAK,CAAC,MAAM,CAAC,EAAU,EAAE,UAAmC;QAC3D,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAe,iBAAiB,EAAE,EAAE,EAAE,UAAU,CAAC,CAAA;IAC1E,CAAC;CACD"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { gracely } from "gracely";
|
|
2
|
+
import { http } from "cloudly-http";
|
|
3
|
+
import { storage } from "cloudly-storage";
|
|
4
|
+
import { Card } from "../../Card";
|
|
5
|
+
import { reports } from "../../reports";
|
|
6
|
+
export declare class Tpl {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: http.Client);
|
|
9
|
+
getQuarterly(stack: Card.Stack, [start, end]: NonNullable<storage.KeyValueStore.ListOptions["range"]>, cursor?: string, limit?: number): Promise<(reports.visa.Data & {
|
|
10
|
+
cursor?: string;
|
|
11
|
+
}) | gracely.Error>;
|
|
12
|
+
}
|