@yuno-payments/dashboard-api-mfe 2.0.4 → 2.0.5

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.
@@ -1,7 +1,7 @@
1
1
  import { AxiosError, AxiosRequestConfig, AxiosResponse } from 'axios';
2
2
  import { HttpClient } from '../lib/http-client';
3
3
  import { GetPaymentsParams, GetReconciliationMetricParams, FirebaseUserSubscribe, PathNotification, TimeZoneCatalog, GetTransactionDetailsV2Params, MfaUserSubscribe, UserInviteMultiaccountPayload, GetTransactionsParams, PaymentsSettings, GetPayoutDetail, GetPayoutTransactionDetail, PinnedSections, ThemeSettings, ListSubscriptionsParams } from './api.types';
4
- import { Audit, OperationTransaction, Organization, OrganizationConfig, SmartRouting, User, Webhook, Reports, ReportType, TemplateType, OrganizationSettings, IListScheduledReportsResponse, DataReport, Reconciliation, Checkout, ReconciliationReportType, SendPaymentNotification, ReconciliationAlerts, ReconciliationAgenda, ReconciliationSales, ReconciliationAdvancements, ReconciliationFees, ReconciliationInsights, Payment, AddToRiskListRequest, InsightsFraudParams, InsightsFraudBody, AI, PaymentFiltersSection, Installments, Connection, TemplateReporting, GetUserFullResponse, Team, ConciergeAlerts, Playground } from '../types';
4
+ import { Audit, OperationTransaction, Organization, OrganizationConfig, SmartRouting, User, Webhook, Reports, ReportType, TemplateType, OrganizationSettings, IListScheduledReportsResponse, DataReport, Reconciliation, Checkout, ReconciliationReportType, SendPaymentNotification, ReconciliationAlerts, ReconciliationAgenda, ReconciliationSales, ReconciliationAdvancements, ReconciliationFees, ReconciliationInsights, Payment, AddToRiskListRequest, InsightsFraudParams, InsightsFraudBody, AI, PaymentFiltersSection, Installments, Connection, TemplateReporting, GetUserFullResponse, Team, ConciergeAccess, ConciergeAccessRequest, Playground } from '../types';
5
5
  import { ConversionRateParams, ConversionRateBody, ConversionRateOverview, ConversionRateOverviewFraud3ds } from '../types/data-report/conversion-rate.types';
6
6
  import { RoutingMonitors } from '../types/routing-monitors';
7
7
  import { ChangePaymentsWebhook } from '../mutations';
@@ -717,11 +717,13 @@ export declare class Api extends HttpClient {
717
717
  updateOnboarding<T>(organizationCode: string, recipientId: string, onboardingId: string, payload: UpdateOnboardingPayload): Promise<AxiosResponse<T, any>>;
718
718
  blockOnboarding<T>(organizationCode: string, recipientId: string, onboardingId: string): Promise<AxiosResponse<T, any>>;
719
719
  unblockOnboarding<T>(organizationCode: string, recipientId: string, onboardingId: string): Promise<AxiosResponse<T, any>>;
720
- getConciergeAlerts<T>(): Promise<AxiosResponse<T>>;
721
- getConciergeAlertById<T>(alertId: string): Promise<AxiosResponse<T>>;
722
- createConciergeAlert<T>(payload: ConciergeAlerts.CreateAlertPayload): Promise<AxiosResponse<T>>;
723
- deleteConciergeAlert<T>(alertId: string): Promise<AxiosResponse<T>>;
724
- enableConciergeAlert<T>(alertId: string, payload: ConciergeAlerts.EnableAlertPayload): Promise<AxiosResponse<T>>;
720
+ getConciergeAccess<T>(): Promise<AxiosResponse<T>>;
721
+ updateConciergeAccess<T>(payload: ConciergeAccess.UpdatePayload): Promise<AxiosResponse<T>>;
722
+ createConciergeBrief<T>(payload: ConciergeAccess.CreateBriefPayload): Promise<AxiosResponse<T>>;
723
+ updateConciergeBrief<T>(briefId: string, payload: ConciergeAccess.UpdateBriefPayload): Promise<AxiosResponse<T>>;
724
+ deleteConciergeBrief<T>(briefId: string): Promise<AxiosResponse<T>>;
725
+ createConciergeAccessRequest<T>(payload: ConciergeAccessRequest.CreatePayload): Promise<AxiosResponse<T>>;
726
+ getConciergeAccessRequestStatus<T>(): Promise<AxiosResponse<T>>;
725
727
  postPlaygroundExecuteFlow<T>(payload: Playground.ExecuteFlowPayload): Promise<AxiosResponse<T, unknown>>;
726
728
  postApiLogsListV2<T>(payload: Audit.ApiLogsListParams): Promise<AxiosResponse<T>>;
727
729
  getApiLogsByPaymentId<T>(paymentId: string, accountCode: string, createdAtFrom?: string): Promise<AxiosResponse<T>>;
@@ -1,8 +1,10 @@
1
1
  import { UseMutationResult } from '@tanstack/react-query';
2
- import { ConciergeAlerts } from '../../types';
3
- export declare function useCreateConciergeAlert(): UseMutationResult<ConciergeAlerts.CreateAlertResponse, ConciergeAlerts.Error, ConciergeAlerts.CreateAlertPayload>;
4
- export declare function useDeleteConciergeAlert(): UseMutationResult<ConciergeAlerts.DeleteAlertResponse, ConciergeAlerts.Error, string>;
5
- export declare function useEnableConciergeAlert(): UseMutationResult<ConciergeAlerts.EnableAlertResponse, ConciergeAlerts.Error, {
6
- alertId: string;
7
- payload: ConciergeAlerts.EnableAlertPayload;
2
+ import { ConciergeAccess, ConciergeAccessRequest } from '../../types';
3
+ export declare function useUpdateConciergeAccess(): UseMutationResult<ConciergeAccess.UpdateResponse, ConciergeAccess.Error, ConciergeAccess.UpdatePayload>;
4
+ export declare function useCreateConciergeBrief(): UseMutationResult<ConciergeAccess.CreateBriefResponse, ConciergeAccess.Error, ConciergeAccess.CreateBriefPayload>;
5
+ export declare function useUpdateConciergeBrief(): UseMutationResult<ConciergeAccess.UpdateBriefResponse, ConciergeAccess.Error, {
6
+ briefId: string;
7
+ payload: ConciergeAccess.UpdateBriefPayload;
8
8
  }>;
9
+ export declare function useRequestConciergeAccess(): UseMutationResult<ConciergeAccessRequest.CreateResponse, ConciergeAccessRequest.Error, ConciergeAccessRequest.CreatePayload>;
10
+ export declare function useDeleteConciergeBrief(): UseMutationResult<void, ConciergeAccess.Error, string>;
@@ -1,6 +1,6 @@
1
1
  import { UseQueryResult } from '@tanstack/react-query';
2
- import { ConciergeAlerts } from '../../types';
3
- export declare const CONCIERGE_ALERTS_QUERY_KEY = "GET/concierge/alerts";
4
- export declare const CONCIERGE_ALERT_BY_ID_QUERY_KEY = "GET/concierge/alerts/by-id";
5
- export declare function useGetConciergeAlerts(): UseQueryResult<ConciergeAlerts.Alert[], ConciergeAlerts.Error>;
6
- export declare function useGetConciergeAlertById(alertId: string): UseQueryResult<ConciergeAlerts.Alert, ConciergeAlerts.Error>;
2
+ import { ConciergeAccess, ConciergeAccessRequest } from '../../types';
3
+ export declare const CONCIERGE_ACCESS_QUERY_KEY = "GET/concierge/access";
4
+ export declare const CONCIERGE_ACCESS_REQUEST_STATUS_QUERY_KEY = "GET/concierge/access-requests/me";
5
+ export declare function useGetConciergeAccess(): UseQueryResult<ConciergeAccess.GetResponse, ConciergeAccess.Error>;
6
+ export declare function useGetConciergeAccessRequestStatus(): UseQueryResult<ConciergeAccessRequest.StatusResponse, ConciergeAccessRequest.Error>;
@@ -0,0 +1,36 @@
1
+ export declare namespace ConciergeAccessRequest {
2
+ type Channel = 'slack' | 'whatsapp' | 'telegram';
3
+ type SlackSetup = 'add_existing' | 'create_new';
4
+ type Status = 'pending' | 'in_review' | 'approved' | 'active' | 'rejected';
5
+ interface Item {
6
+ id: string;
7
+ organization_code: string;
8
+ merchant_name: string | null;
9
+ merchant_first_name: string | null;
10
+ kam_email: string | null;
11
+ tam_email: string | null;
12
+ agent_email: string | null;
13
+ requester_email: string;
14
+ status: Status;
15
+ channel: Channel | null;
16
+ slack_setup: SlackSetup | null;
17
+ group_name: string | null;
18
+ link: string | null;
19
+ activation_date: string | null;
20
+ brief_language: string | null;
21
+ created_at: string;
22
+ updated_at: string;
23
+ }
24
+ interface CreatePayload {
25
+ channel: Channel;
26
+ slack_setup?: SlackSetup | null;
27
+ group_name: string;
28
+ activation_date: string;
29
+ }
30
+ type CreateResponse = Item;
31
+ type StatusResponse = Item | null;
32
+ type Error = {
33
+ code?: string;
34
+ name?: string;
35
+ };
36
+ }
@@ -0,0 +1,50 @@
1
+ export declare namespace ConciergeAccess {
2
+ interface SlackChannels {
3
+ channel_ids: string[];
4
+ dm_user_ids: string[];
5
+ }
6
+ interface WhatsappChannels {
7
+ group_ids: string[];
8
+ dm_phones: string[];
9
+ }
10
+ interface TelegramChannels {
11
+ chat_ids: string[];
12
+ dm_usernames: string[];
13
+ }
14
+ interface ChannelsConfig {
15
+ slack?: SlackChannels;
16
+ whatsapp?: WhatsappChannels;
17
+ telegram?: TelegramChannels;
18
+ }
19
+ interface Brief {
20
+ id: string;
21
+ name: string;
22
+ enabled: boolean;
23
+ frequency: string;
24
+ day_of_week: string;
25
+ day_of_month: string;
26
+ delivery_time: string;
27
+ content: string;
28
+ }
29
+ interface HeartbeatConfig {
30
+ merchant_id: string;
31
+ preferred_language: string;
32
+ heartbeat_channel_id: string;
33
+ heartbeat_channel_name: string;
34
+ timezone: string;
35
+ briefs: Brief[];
36
+ channels: ChannelsConfig;
37
+ updated_at: string;
38
+ }
39
+ type GetResponse = HeartbeatConfig;
40
+ type UpdatePayload = ChannelsConfig;
41
+ type UpdateResponse = ChannelsConfig;
42
+ type CreateBriefPayload = Omit<Brief, 'id'>;
43
+ type CreateBriefResponse = Brief;
44
+ type UpdateBriefPayload = Omit<Brief, 'id'>;
45
+ type UpdateBriefResponse = Brief;
46
+ type Error = {
47
+ code?: string;
48
+ name?: string;
49
+ };
50
+ }
@@ -1 +1,2 @@
1
- export * from './concierge-alerts';
1
+ export * from './concierge-access';
2
+ export * from './concierge-access-request';