@mbanq/core-sdk-js 0.26.0 → 0.28.0

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,5 +1,5 @@
1
1
  import z$1, { z } from 'zod';
2
- import { a as Command, G as GraphQLRequest } from '../config.d-BSoFrdxi.js';
2
+ import { a as Command, G as GraphQLRequest } from '../config.d-BvqzFkbH.js';
3
3
  import * as buffer from 'buffer';
4
4
  import { e as ProcessOutput, G as GetTransferInput, T as Transfer, b as CreateTransferInput, ai as CreateTransferOutput, P as Payment, aj as PaymentFilters, a as PaymentResponse, C as CreatePaymentInput, ak as ProcessOutput$1, U as UpdatePaymentInput, u as SavingAccount, al as ListAccountsOfClientRequest, y as UpdateAccountRequest, am as CreateAndActivateAccountRequest, an as CreateAndActivateAccountResponse, ao as CloseAccountRequest, ap as CloseAccountResponse, aq as BlockAccountRequest, ar as BlockAccountResponse, as as HoldAmountRequest, at as HoldAmountResponse, au as UpdateRecipientRequest, R as Recipient, g as CreateRecipientRequest, h as RecipientRequest, av as Recipients, B as UserDetail, aw as EnableSelfServiceAccessRequest, ax as EnableSelfServiceAccessResponse, ay as UpdateSelfServiceUserRequest, az as UpdateSelfServiceUserResponse, aA as DeleteSelfServiceUserResponse } from '../recipient-i5k7edaA.js';
5
5
  import 'graphql';
@@ -9040,6 +9040,70 @@ type CardSettlement = z.infer<typeof CardSettlementSchema>;
9040
9040
  type GetCardSettlementsRequest = z.infer<typeof GetCardSettlementsRequestSchema>;
9041
9041
  type GetCardSettlementsResponse = z.infer<typeof GetCardSettlementsResponseSchema>;
9042
9042
  type GetCardSettlementByIdRequest = z.infer<typeof GetCardSettlementByIdRequestSchema>;
9043
+ declare const AcquiredCard: z.ZodObject<{
9044
+ id: z.ZodNumber;
9045
+ lastDigits: z.ZodString;
9046
+ expiryDate: z.ZodString;
9047
+ network: z.ZodString;
9048
+ pushEnabled: z.ZodBoolean;
9049
+ pullEnabled: z.ZodBoolean;
9050
+ isRegulated: z.ZodBoolean;
9051
+ avsVerified: z.ZodBoolean;
9052
+ pushFundAvailability: z.ZodString;
9053
+ countryCode: z.ZodString;
9054
+ currencyCode: z.ZodString;
9055
+ cardType: z.ZodString;
9056
+ fullName: z.ZodString;
9057
+ referenceId: z.ZodString;
9058
+ externalId: z.ZodString;
9059
+ deleted: z.ZodBoolean;
9060
+ status: z.ZodString;
9061
+ financialInstitution: z.ZodString;
9062
+ createdAt: z.ZodString;
9063
+ updatedAt: z.ZodString;
9064
+ }, "strip", z.ZodTypeAny, {
9065
+ status: string;
9066
+ id: number;
9067
+ externalId: string;
9068
+ createdAt: string;
9069
+ countryCode: string;
9070
+ financialInstitution: string;
9071
+ network: string;
9072
+ cardType: string;
9073
+ expiryDate: string;
9074
+ lastDigits: string;
9075
+ pushEnabled: boolean;
9076
+ pullEnabled: boolean;
9077
+ isRegulated: boolean;
9078
+ avsVerified: boolean;
9079
+ pushFundAvailability: string;
9080
+ currencyCode: string;
9081
+ fullName: string;
9082
+ referenceId: string;
9083
+ deleted: boolean;
9084
+ updatedAt: string;
9085
+ }, {
9086
+ status: string;
9087
+ id: number;
9088
+ externalId: string;
9089
+ createdAt: string;
9090
+ countryCode: string;
9091
+ financialInstitution: string;
9092
+ network: string;
9093
+ cardType: string;
9094
+ expiryDate: string;
9095
+ lastDigits: string;
9096
+ pushEnabled: boolean;
9097
+ pullEnabled: boolean;
9098
+ isRegulated: boolean;
9099
+ avsVerified: boolean;
9100
+ pushFundAvailability: string;
9101
+ currencyCode: string;
9102
+ fullName: string;
9103
+ referenceId: string;
9104
+ deleted: boolean;
9105
+ updatedAt: string;
9106
+ }>;
9043
9107
  declare const AcquiredCardsList: z.ZodArray<z.ZodObject<{
9044
9108
  id: z.ZodNumber;
9045
9109
  lastDigits: z.ZodString;
@@ -9104,6 +9168,7 @@ declare const AcquiredCardsList: z.ZodArray<z.ZodObject<{
9104
9168
  deleted: boolean;
9105
9169
  updatedAt: string;
9106
9170
  }>, "many">;
9171
+ type AcquiredCardResponse = z.infer<typeof AcquiredCard>;
9107
9172
  type AcquiredCardsResponse = z.infer<typeof AcquiredCardsList>;
9108
9173
 
9109
9174
  declare const CreatePrepaidCardRequestSchema: z.ZodObject<{
@@ -11494,6 +11559,22 @@ declare const GetCardSettlements: (params: GetCardSettlementsRequest) => Command
11494
11559
  declare const GetCardSettlementById: (params: GetCardSettlementByIdRequest) => Command<{
11495
11560
  params: GetCardSettlementByIdRequest;
11496
11561
  }, CardSettlement>;
11562
+ /**
11563
+ * Terminate a card
11564
+ *
11565
+ * Permanently terminates a card, making it unusable for any transactions.
11566
+ * This action is irreversible and the card cannot be reactivated after termination.
11567
+ * Use this when a card should be completely removed from service.
11568
+ *
11569
+ * @param cardId - The unique identifier of the card to terminate
11570
+ * @returns Command object that executes the API request and returns termination details
11571
+ *
11572
+ * @example
11573
+ * ```typescript
11574
+ * const command = TerminateCard(67890);
11575
+ * const result = await client.request(command);
11576
+ * ```
11577
+ */
11497
11578
  declare const TerminateCard: (cardId: number) => Command<{
11498
11579
  cardId: number;
11499
11580
  command: string;
@@ -11503,6 +11584,22 @@ declare const TerminateCard: (cardId: number) => Command<{
11503
11584
  clientId: number;
11504
11585
  cardToken: string;
11505
11586
  }>;
11587
+ /**
11588
+ * Suspend a card
11589
+ *
11590
+ * Temporarily suspends a card, preventing it from being used for transactions.
11591
+ * The card can be reactivated later using ReactivateCard or ActivateCard.
11592
+ * Use this for temporary card holds or when investigating suspicious activity.
11593
+ *
11594
+ * @param cardId - The unique identifier of the card to suspend
11595
+ * @returns Command object that executes the API request and returns suspension details
11596
+ *
11597
+ * @example
11598
+ * ```typescript
11599
+ * const command = SuspendCard(67890);
11600
+ * const result = await client.request(command);
11601
+ * ```
11602
+ */
11506
11603
  declare const SuspendCard: (cardId: number) => Command<{
11507
11604
  cardId: number;
11508
11605
  command: string;
@@ -11512,6 +11609,22 @@ declare const SuspendCard: (cardId: number) => Command<{
11512
11609
  clientId: number;
11513
11610
  cardToken: string;
11514
11611
  }>;
11612
+ /**
11613
+ * Activate a card
11614
+ *
11615
+ * Activates a card that has been issued but not yet activated.
11616
+ * This is typically required for new cards or cards that were previously suspended.
11617
+ * Activation enables the card for transactions according to its configured features.
11618
+ *
11619
+ * @param cardId - The unique identifier of the card to activate
11620
+ * @returns Command object that executes the API request and returns activation details
11621
+ *
11622
+ * @example
11623
+ * ```typescript
11624
+ * const command = ActivateCard(67890);
11625
+ * const result = await client.request(command);
11626
+ * ```
11627
+ */
11515
11628
  declare const ActivateCard: (cardId: number) => Command<{
11516
11629
  cardId: number;
11517
11630
  command: string;
@@ -11521,6 +11634,23 @@ declare const ActivateCard: (cardId: number) => Command<{
11521
11634
  clientId: number;
11522
11635
  cardToken: string;
11523
11636
  }>;
11637
+ /**
11638
+ * Reactivate a suspended card
11639
+ *
11640
+ * Reactivates a card that was previously suspended. This restores the card's
11641
+ * ability to process transactions according to its configuration.
11642
+ * Use this to restore a suspended card back to active status.
11643
+ *
11644
+ * @param cardId - The unique identifier of the card to reactivate
11645
+ * @returns Command object that executes the API request and returns reactivation details
11646
+ *
11647
+ * @example
11648
+ * ```typescript
11649
+ * const command = ReactivateCard(67890);
11650
+ * const result = await client.request(command);
11651
+ * console.log(`Card ${result.id} has been reactivated`);
11652
+ * ```
11653
+ */
11524
11654
  declare const ReactivateCard: (cardId: number) => Command<{
11525
11655
  cardId: number;
11526
11656
  command: string;
@@ -11530,6 +11660,24 @@ declare const ReactivateCard: (cardId: number) => Command<{
11530
11660
  clientId: number;
11531
11661
  cardToken: string;
11532
11662
  }>;
11663
+ /**
11664
+ * Replace a card
11665
+ *
11666
+ * Requests a replacement for an existing card due to loss, theft, damage, or non-receipt.
11667
+ * This action terminates the current card and issues a new card with a new number and details.
11668
+ * The replacement card will inherit the same configuration and features as the original card.
11669
+ *
11670
+ * @param cardId - The unique identifier of the card to replace
11671
+ * @param reason - The reason for replacement (LOST, STOLEN, DAMAGED, or CARD_NOT_RECEIVED)
11672
+ * @returns Command object that executes the API request and returns replacement card details
11673
+ *
11674
+ * @example
11675
+ * ```typescript
11676
+ * // Replace a lost card
11677
+ * const command = ReplaceCard(67890, 'LOST');
11678
+ * const result = await client.request(command);
11679
+ * ```
11680
+ */
11533
11681
  declare const ReplaceCard: (cardId: number, reason: "LOST" | "STOLEN" | "DAMAGED" | "CARD_NOT_RECEIVED") => Command<{
11534
11682
  cardId: number;
11535
11683
  reason: string;
@@ -11538,6 +11686,25 @@ declare const ReplaceCard: (cardId: number, reason: "LOST" | "STOLEN" | "DAMAGED
11538
11686
  resourceId: number;
11539
11687
  clientId: number;
11540
11688
  }>;
11689
+ /**
11690
+ * Renew a card
11691
+ *
11692
+ * Renews an expiring card by issuing a new card with the same product type.
11693
+ * This is typically used when a card is approaching its expiration date and needs
11694
+ * to be renewed with a new expiration date. The new card will maintain the same
11695
+ * product configuration and features as the original card.
11696
+ *
11697
+ * @param cardId - The unique identifier of the card to renew
11698
+ * @param productId - The product ID for the renewed card (can be the same or different from original)
11699
+ * @returns Command object that executes the API request and returns renewed card details
11700
+ *
11701
+ * @example
11702
+ * ```typescript
11703
+ * // Renew a card with the same product
11704
+ * const command = RenewCard(67890, 12345);
11705
+ * const result = await client.request(command);
11706
+ * ```
11707
+ */
11541
11708
  declare const RenewCard: (cardId: number, productId: number) => Command<{
11542
11709
  cardId: number;
11543
11710
  productId: number;
@@ -11546,9 +11713,75 @@ declare const RenewCard: (cardId: number, productId: number) => Command<{
11546
11713
  resourceId: number;
11547
11714
  clientId: number;
11548
11715
  }>;
11716
+ /**
11717
+ * Get all acquired cards for a client
11718
+ *
11719
+ * Retrieves a list of all acquired/external cards associated with a specific client ID.
11720
+ * Acquired cards are cards that were obtained from external sources or integrated systems.
11721
+ * Returns comprehensive card details including status, type, network, and configuration.
11722
+ *
11723
+ * @param clientId - The unique identifier of the client
11724
+ * @returns Command object that executes the API request and returns list of acquired cards
11725
+ *
11726
+ * @example
11727
+ * ```typescript
11728
+ * const command = GetAcquiredCards(12345);
11729
+ * const acquiredCards = await client.request(command);
11730
+ * ```
11731
+ */
11549
11732
  declare const GetAcquiredCards: (clientId: number) => Command<{
11550
11733
  clientId: number;
11551
11734
  }, AcquiredCardsResponse>;
11735
+ /**
11736
+ * Get acquired card by ID
11737
+ *
11738
+ * Retrieves detailed information for a specific acquired/external card using its unique identifier.
11739
+ * This endpoint allows you to fetch specific information related to an acquired card based on the
11740
+ * card ID, including all card details such as network, type, status, and configuration settings.
11741
+ *
11742
+ * @param clientId - The unique identifier of the client who owns the acquired card
11743
+ * @param acquiredCardId - The unique identifier of the acquired card to retrieve
11744
+ * @returns Command object that executes the API request and returns acquired card details
11745
+ *
11746
+ * @example
11747
+ * ```typescript
11748
+ * const command = getAcquiredCardById(12345, 67890);
11749
+ * const acquiredCard = await client.request(command);
11750
+ * ```
11751
+ */
11752
+ declare const getAcquiredCardById: (clientId: number, acquiredCardId: number) => Command<{
11753
+ clientId: number;
11754
+ acquiredCardId: number;
11755
+ }, AcquiredCardResponse>;
11756
+ /**
11757
+ * Adds an acquired card to a client
11758
+ *
11759
+ * Adds an acquired card to a client by storing the card information in the client's
11760
+ * external cards list. This endpoint allows you to add a card that was obtained from an
11761
+ * external source or integrated system to a client's list of acquired cards.
11762
+ *
11763
+ * @param clientId - The unique identifier of the client
11764
+ * @param params - Object containing the card data to add
11765
+ * @returns Command object that executes the API request and returns the added acquired card details
11766
+ * ```typescript
11767
+ * const command = AddAcquiredCard(12345, {
11768
+ * cardData: 'cardData'
11769
+ * });
11770
+ * ```
11771
+ */
11772
+ declare const AddAcquiredCard: (clientId: number, params: {
11773
+ cardData: string;
11774
+ }) => Command<{
11775
+ clientId: number;
11776
+ params: {
11777
+ cardData: string;
11778
+ };
11779
+ }, {
11780
+ id: number;
11781
+ officeId: number;
11782
+ clientId: number;
11783
+ resourceId: number;
11784
+ }>;
11552
11785
 
11553
11786
  /**
11554
11787
  * Create Prepaid Card
@@ -17031,4 +17264,4 @@ declare const DeleteFixedDepositAccount: (accountId: number) => Command<{
17031
17264
  accountId: number;
17032
17265
  }, DeleteFixedDepositAccountResponse>;
17033
17266
 
17034
- export { ActivateCard, ActivatePhysicalCard, AddCardToMobileWallet, ApproveRejectClientDocument, BlockAccount, ChangeCardType, CloseAccount, CreateAccountProduct, CreateAndActivateAccount, CreateCard, CreateCardProduct, CreateClient, CreateClientAddress, CreateClientIdentifier, CreateFixedDepositAccount, CreatePayment, CreatePrepaidCard, CreateRecipient, CreateTransfer, CustomCreate, CustomGet, CustomUpdate, DeactivatePrepaidCard, DeleteAccount, DeleteClient, DeleteClientDocument, DeleteFixedDepositAccount, DeletePayment, DeleteRecipient, DeleteSelfServiceUser, DownloadAccountStatement, EnableDisableConfiguration, EnableSelfServiceAccess, GenerateAccountStatement, GetAccount, GetAccountDocumentsDetails, GetAccountProductById, GetAccountsOfClient, GetAcquiredCards, GetAllAccountProducts, GetBankDetailsFromRoutingCode, GetCardAuthorizationById, GetCardAuthorizations, GetCardById, GetCardImageUrl, GetCardProduct, GetCardSettlementById, GetCardSettlements, GetCards, GetClient, GetClientAddress, GetClientClassification, GetClients, GetCompletedTransactions, GetConfigurationByName, GetConfigurations, GetFixedDepositAccount, GetPayment, GetPayments, GetPendingTransactions, GetPermittedDocumentTypes, GetPrepaidCardById, GetPrepaidCardsByAccountId, GetRecentTransactions, GetRecipient, GetRecipients, GetStatusOfVerifyClient, GetTransactionById, GetTransfer, GetTransfers, GetUserDetail, GraphQL, HoldAmount, ListCardProduct, ListClientDocument, OrderPhysicalCard, ReactivateCard, RenewCard, ReplaceCard, ScheduleAccountClosure, SetClientAddressStatus, SetPIN, SuspendCard, SwitchClientClassification, TerminateCard, UpdateAccount, UpdateAccountProduct, UpdateCardFeature, UpdateCardLimit, UpdateCardProduct, UpdateClient, UpdateClientAddress, UpdateClientIdentifier, UpdateFixedDepositAccount, UpdatePayment, UpdateRecipientGQL as UpdateRecipient, UpdateSelfServiceUser, UploadClientIdentifierDocument, VerifyWithActivateClients };
17267
+ export { ActivateCard, ActivatePhysicalCard, AddAcquiredCard, AddCardToMobileWallet, ApproveRejectClientDocument, BlockAccount, ChangeCardType, CloseAccount, CreateAccountProduct, CreateAndActivateAccount, CreateCard, CreateCardProduct, CreateClient, CreateClientAddress, CreateClientIdentifier, CreateFixedDepositAccount, CreatePayment, CreatePrepaidCard, CreateRecipient, CreateTransfer, CustomCreate, CustomGet, CustomUpdate, DeactivatePrepaidCard, DeleteAccount, DeleteClient, DeleteClientDocument, DeleteFixedDepositAccount, DeletePayment, DeleteRecipient, DeleteSelfServiceUser, DownloadAccountStatement, EnableDisableConfiguration, EnableSelfServiceAccess, GenerateAccountStatement, GetAccount, GetAccountDocumentsDetails, GetAccountProductById, GetAccountsOfClient, GetAcquiredCards, GetAllAccountProducts, GetBankDetailsFromRoutingCode, GetCardAuthorizationById, GetCardAuthorizations, GetCardById, GetCardImageUrl, GetCardProduct, GetCardSettlementById, GetCardSettlements, GetCards, GetClient, GetClientAddress, GetClientClassification, GetClients, GetCompletedTransactions, GetConfigurationByName, GetConfigurations, GetFixedDepositAccount, GetPayment, GetPayments, GetPendingTransactions, GetPermittedDocumentTypes, GetPrepaidCardById, GetPrepaidCardsByAccountId, GetRecentTransactions, GetRecipient, GetRecipients, GetStatusOfVerifyClient, GetTransactionById, GetTransfer, GetTransfers, GetUserDetail, GraphQL, HoldAmount, ListCardProduct, ListClientDocument, OrderPhysicalCard, ReactivateCard, RenewCard, ReplaceCard, ScheduleAccountClosure, SetClientAddressStatus, SetPIN, SuspendCard, SwitchClientClassification, TerminateCard, UpdateAccount, UpdateAccountProduct, UpdateCardFeature, UpdateCardLimit, UpdateCardProduct, UpdateClient, UpdateClientAddress, UpdateClientIdentifier, UpdateFixedDepositAccount, UpdatePayment, UpdateRecipientGQL as UpdateRecipient, UpdateSelfServiceUser, UploadClientIdentifierDocument, VerifyWithActivateClients, getAcquiredCardById };