@t-0/provider-starter-ts 1.1.10 → 1.1.12
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@t-0/provider-starter-ts",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.12",
|
|
4
4
|
"description": "CLI tool to scaffold a Node.js t-0 Network integration service",
|
|
5
5
|
"main": "dist/create.js",
|
|
6
6
|
"bin": {
|
|
@@ -39,6 +39,6 @@
|
|
|
39
39
|
"@types/fs-extra": "^11.0.4",
|
|
40
40
|
"@types/inquirer": "^9.0.9",
|
|
41
41
|
"@types/node": "^25.4.0",
|
|
42
|
-
"typescript": "^
|
|
42
|
+
"typescript": "^6.0.2"
|
|
43
43
|
}
|
|
44
44
|
}
|
package/template/package.json
CHANGED
|
@@ -17,6 +17,8 @@ export default async function publishQuotes(networkClient: Client<typeof Network
|
|
|
17
17
|
rate: toProtoDecimal(873, -3), // rate 0.873
|
|
18
18
|
maxAmount: toProtoDecimal(25000, 0), // maximum amount in USD, could be 1000,5000,10000 or 25000
|
|
19
19
|
clientQuoteId: randomUUID(),
|
|
20
|
+
// optional: set fix to charge a fixed fee per transfer (e.g. wire fees)
|
|
21
|
+
// fix: toProtoDecimal(5, 0), // $5 fixed charge
|
|
20
22
|
}],
|
|
21
23
|
currency: 'EUR',
|
|
22
24
|
expiration: timestampFromDate(new Date(Date.now() + 30 * 1000)), // expiration time (30 seconds from now)
|
package/template/src/service.ts
CHANGED
|
@@ -48,6 +48,7 @@ const CreateProviderService = (networkClient: Client<typeof NetworkService>) =>
|
|
|
48
48
|
}
|
|
49
49
|
})
|
|
50
50
|
}, 2000);
|
|
51
|
+
// optional: if your provider has multiple legal entities, set beneficiaryProviderLegalEntityId
|
|
51
52
|
return {
|
|
52
53
|
result: {
|
|
53
54
|
case: "accepted",
|
|
@@ -70,6 +71,8 @@ const CreateProviderService = (networkClient: Client<typeof NetworkService>) =>
|
|
|
70
71
|
|
|
71
72
|
async approvePaymentQuote(req: ApprovePaymentQuoteRequest, _: HandlerContext) {
|
|
72
73
|
// TODO: when the payment goes through the Manual AML Check on the pay-out provider side, the provider submitted the payment will have a last look to approve final quote
|
|
74
|
+
// The request includes payOutFix — the fixed charge in USD for this payout.
|
|
75
|
+
// Consider it alongside payOutRate and payOutAmount when deciding to accept.
|
|
73
76
|
console.log(`Received approve payment quote request for ${req.paymentId}`)
|
|
74
77
|
return {
|
|
75
78
|
result: {
|