@spritz-finance/service-client 0.2.76 → 0.2.78
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/lib/config.js
CHANGED
|
@@ -45,6 +45,7 @@ const envConfigs = {
|
|
|
45
45
|
exchangeRatesServiceEndpoint: 'https://api-staging.spritz.finance/exchange-rates',
|
|
46
46
|
web3ServiceEndpoint: 'https://api-staging.spritz.finance/web3',
|
|
47
47
|
unblockServiceEndpoint: 'https://api-staging.spritz.finance/unblock',
|
|
48
|
+
onrampServiceEndpoint: 'https://api-staging.spritz.finance/bridge',
|
|
48
49
|
},
|
|
49
50
|
production: {
|
|
50
51
|
authEndpoint: 'https://auth.spritz.finance/oauth2/token',
|
|
@@ -17,6 +17,11 @@ export type IntegratorWebhook = {
|
|
|
17
17
|
url: string;
|
|
18
18
|
createdAt: string;
|
|
19
19
|
};
|
|
20
|
+
export type Integrator = {
|
|
21
|
+
id: string;
|
|
22
|
+
name: string;
|
|
23
|
+
email: number;
|
|
24
|
+
};
|
|
20
25
|
export declare class UsersServiceClient {
|
|
21
26
|
client: AxiosInstance;
|
|
22
27
|
constructor();
|
|
@@ -25,4 +30,5 @@ export declare class UsersServiceClient {
|
|
|
25
30
|
findOrInitialize(email: string): Promise<User>;
|
|
26
31
|
findByEmail(email: string): Promise<User>;
|
|
27
32
|
getIntegratorWebhooks(integratorId: string): Promise<IntegratorWebhook[]>;
|
|
33
|
+
getIntegrator(integratorId: string): Promise<Integrator>;
|
|
28
34
|
}
|
|
@@ -36,5 +36,10 @@ class UsersServiceClient {
|
|
|
36
36
|
.get(`/integrators/service/webhooks/${integratorId}`)
|
|
37
37
|
.then((res) => res.data);
|
|
38
38
|
}
|
|
39
|
+
async getIntegrator(integratorId) {
|
|
40
|
+
return this.client
|
|
41
|
+
.get(`/integrators/integrator/${integratorId}`)
|
|
42
|
+
.then((res) => res.data);
|
|
43
|
+
}
|
|
39
44
|
}
|
|
40
45
|
exports.UsersServiceClient = UsersServiceClient;
|