@yuno-payments/dashboard-api-mfe 0.36.51-beta.3 → 0.36.53-RC.2

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.
@@ -120,6 +120,15 @@ export declare class Api extends HttpClient {
120
120
  deleteWebhookV2<T>(code: string, accountCode: string): Promise<AxiosResponse<T>>;
121
121
  updateWebhookV2<T>(code: string, payload: any, accountCode: string): Promise<AxiosResponse<T>>;
122
122
  getMenu<T>(): Promise<AxiosResponse<T>>;
123
+ postWebhookLogs<T>({ payload: { account_code, ...rest }, }: {
124
+ payload: Audit.AuditWebhooksParams;
125
+ }): Promise<AxiosResponse<T>>;
126
+ postResendWebhooks<T>({ codes, }: Audit.AuditWebhooksResendParams): Promise<AxiosResponse<T>>;
127
+ postExportApiLogs<T>(payload: Audit.ExportApiLogsRequest): Promise<AxiosResponse<T>>;
128
+ postApiLogs<T>({ payload: { account_code, ...rest }, }: {
129
+ payload: Audit.AuditApiLogsParams;
130
+ }): Promise<AxiosResponse<T>>;
131
+ getWebhooksDetailByPaymentCode<T>(paymentCode: string): Promise<AxiosResponse<T>>;
123
132
  useGetPaymentStatusesStyles<T>(): Promise<AxiosResponse<T, any>>;
124
133
  useGetTransactionStatusesStyles<T>(): Promise<AxiosResponse<T, any>>;
125
134
  useGetReconciliationTransactionStatusesStyles<T>(): Promise<AxiosResponse<T, any>>;
@@ -0,0 +1,5 @@
1
+ import { UseMutationResult } from '@tanstack/react-query';
2
+ import { Audit, Reports } from '../../types';
3
+ import { BFFErrorResponse } from '../smart-routing';
4
+ export declare function useResendWebhooks(): UseMutationResult<void, BFFErrorResponse, Audit.AuditWebhooksResendParams>;
5
+ export declare function useExportApiLogs(): UseMutationResult<Reports.ICreateReportsResponse, BFFErrorResponse, Audit.ExportApiLogsRequest>;
@@ -1 +1,2 @@
1
1
  export * from './audit.mutation';
2
+ export * from './audit-api.mutation';
@@ -21,6 +21,7 @@ export * from './scheduled-reports';
21
21
  export * from './velocity-rules';
22
22
  export * from './developers';
23
23
  export * from './audit';
24
+ export * from './audit/audit-api.mutation';
24
25
  export * from './reconciliations';
25
26
  export * from './insights';
26
27
  export * from './saml-config';
@@ -1,5 +1,11 @@
1
1
  import { UseQueryResult } from '@tanstack/react-query';
2
2
  import { AxiosError } from 'axios';
3
3
  import type { Audit } from '../../types';
4
+ import { BFFErrorResponse } from '../../mutations';
4
5
  export declare function useGetAuditEvents(params: Audit.AuditEventsParams): UseQueryResult<Audit.AuditEvents, AxiosError>;
5
6
  export declare function useGetAuditMonitorEventDetail(id: number | null): UseQueryResult<Audit.AuditMonitorDetail, AxiosError>;
7
+ export declare function usePostApiLogs(params: Audit.AuditApiLogsParams): UseQueryResult<Audit.AuditApiLogsResponse, BFFErrorResponse>;
8
+ export declare function usePostWebhookLogs({ params, }: {
9
+ params: Audit.AuditWebhooksParams;
10
+ }): UseQueryResult<Audit.AuditWebhooksResponse, BFFErrorResponse>;
11
+ export declare function useGetWebhooksDetailByPaymentCode(code: string): UseQueryResult<unknown, BFFErrorResponse>;
@@ -107,4 +107,84 @@ export declare namespace Audit {
107
107
  type: string;
108
108
  percentage: number;
109
109
  }
110
+ interface ExportApiLogsRequest {
111
+ report_name: string;
112
+ account_code: string[];
113
+ start_date: string;
114
+ end_date: string;
115
+ time_zone: string;
116
+ method?: string[];
117
+ }
118
+ interface AuditApiJSON {
119
+ [key: string]: string;
120
+ }
121
+ interface AuditApiLogs {
122
+ code: string;
123
+ url: string;
124
+ method: string;
125
+ source: string;
126
+ headers: AuditApiJSON;
127
+ request: AuditApiJSON;
128
+ response: AuditApiJSON;
129
+ account_name: string;
130
+ account_code: string;
131
+ status_code: number;
132
+ trace_id: string;
133
+ created_at: string;
134
+ }
135
+ interface AuditApiLogsResponse {
136
+ data: AuditApiLogs[];
137
+ page: number;
138
+ size: number;
139
+ total_rows: number;
140
+ total_pages: number;
141
+ }
142
+ interface AuditApiLogsParams {
143
+ page: number;
144
+ size: number;
145
+ periodicity?: string;
146
+ account_code?: string[];
147
+ organizationCode?: string;
148
+ status_codes?: string[];
149
+ methods?: string[];
150
+ }
151
+ interface AuditWebhooksParams {
152
+ page: number;
153
+ size: number;
154
+ organizationCode: string;
155
+ periodicity?: string;
156
+ account_code?: string[];
157
+ status_codes?: string[];
158
+ methods?: string[];
159
+ }
160
+ interface AuditWebhooks {
161
+ id: number;
162
+ organization_code: string;
163
+ account_code: string;
164
+ type: string;
165
+ created_at: string;
166
+ updated_at: string;
167
+ time: number;
168
+ http_method: string;
169
+ url: string;
170
+ request: string;
171
+ response: string;
172
+ response_status: number;
173
+ connect_timeout: number;
174
+ read_timeout: number;
175
+ exception: string;
176
+ headers: string;
177
+ trace_id: string;
178
+ origin_id: string;
179
+ }
180
+ interface AuditWebhooksResponse {
181
+ data: AuditWebhooks[];
182
+ page: number;
183
+ size: number;
184
+ total_rows: number;
185
+ total_pages: number;
186
+ }
187
+ interface AuditWebhooksResendParams {
188
+ codes: string[];
189
+ }
110
190
  }
@@ -223,12 +223,6 @@ export declare namespace SmartRouting {
223
223
  export type AvailableActions = 'END' | 'DECLINE' | 'CAPTURE' | 'CANCEL' | 'REVERT' | 'RETRY';
224
224
  export type OutputType = 'SUCCESS' | 'ERROR' | 'WARNING';
225
225
  export type StatusTransaction = 'SUCCEEDED' | 'PENDING' | 'PROCEED' | 'ERROR' | 'DECLINED' | 'DECLINE_GROUP';
226
- export enum StepType {
227
- FRAUD = "FRAUD",
228
- PAYMENT = "PAYMENT",
229
- THREE_D_SECURE = "THREE_D_SECURE",
230
- CYBERSOURCE_3DS = "CYBERSOURCE_3DS"
231
- }
232
226
  export interface TransactionStatuses {
233
227
  condition_actions: ConditionActions[];
234
228
  transaction_statuses: {
@@ -246,16 +240,14 @@ export declare namespace SmartRouting {
246
240
  export type DeclineTypes = {
247
241
  label: string;
248
242
  name: string;
249
- group?: DeclineGroupType;
250
243
  is_used: boolean;
251
- step_type?: StepType;
244
+ step_type?: 'PAYMENT' | 'THREE_D_SECURE';
252
245
  }[];
253
246
  export interface DeclineGroup {
254
247
  id?: number;
255
248
  name: string;
256
249
  account_code: string;
257
250
  decline_types: string[];
258
- group_type?: DeclineGroupType;
259
251
  }
260
252
  export interface PaymentRoute {
261
253
  index: number;
@@ -273,10 +265,6 @@ export declare namespace SmartRouting {
273
265
  available_provider: number;
274
266
  unavailable_provider: number;
275
267
  }
276
- export enum DeclineGroupType {
277
- PROVIDER_STATUS = "PROVIDER_STATUS",
278
- MAC_CODE = "MAC_CODE"
279
- }
280
268
  interface ApprovalRateOpsgenie {
281
269
  opsgenie_service_name: string;
282
270
  opsgenie_api_keys: string;
@@ -314,7 +302,6 @@ export declare namespace SmartRouting {
314
302
  name: string;
315
303
  types: string[];
316
304
  account_codes: string[];
317
- group?: DeclineGroupType;
318
305
  }
319
306
  export interface PayloadAIWorkflowCreate {
320
307
  payment_method: string;