@fiado/type-kit 1.0.1 → 1.0.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.
@@ -0,0 +1,11 @@
1
+ import { CountryId } from '../../country/enums/CountryId';
2
+ export declare class ShippingAddressDto {
3
+ municipality: string;
4
+ neighborhood: string;
5
+ postalCode: string;
6
+ street: string;
7
+ subRegion: string;
8
+ addressNumber: string;
9
+ internalNumber?: string;
10
+ countryId: CountryId;
11
+ }
@@ -0,0 +1 @@
1
+ export * from './dtos/AddressShippingDto';
@@ -0,0 +1,4 @@
1
+ export declare class CardActivateDto {
2
+ countryId: number;
3
+ panOrCode: string;
4
+ }
@@ -0,0 +1,6 @@
1
+ import { ShippingAddressDto } from '../../address/dtos/AddressShippingDto';
2
+ export declare class CardRequest {
3
+ countryId: number;
4
+ type: string;
5
+ address: ShippingAddressDto;
6
+ }
@@ -0,0 +1,34 @@
1
+ import { CountryId } from '../../country/enums/CountryId';
2
+ import { ShippingAddressDto } from '../../address/dtos/AddressShippingDto';
3
+ import { CardType } from '../enums/CardType';
4
+ import { Brand } from '../enums/Brand';
5
+ import { OwnershipType } from '../enums/OwnershipType';
6
+ import { Status } from '../enums/Status';
7
+ export declare class CreateCardDto {
8
+ id?: string;
9
+ accountId?: string;
10
+ activationDate?: string;
11
+ countryId: CountryId;
12
+ type: CardType;
13
+ directoryId?: string;
14
+ externalCardId: string;
15
+ externalUserId: string;
16
+ externalShipmentId: string;
17
+ shipmentProvider: string;
18
+ externalShipmentTrackingId: string;
19
+ externalShipmentTrackingUrl: string;
20
+ holderName: string;
21
+ holderLastName: string;
22
+ imageUrl?: string;
23
+ brand: Brand;
24
+ ownershipType: OwnershipType;
25
+ lastFour: string;
26
+ providerName?: string;
27
+ status: Status;
28
+ statusUpdateDate?: string;
29
+ tenantId?: string;
30
+ spendLimitByTransaction?: number;
31
+ spendLimitByDay?: number;
32
+ spendLimitByMonth?: number;
33
+ shippedAddress?: ShippingAddressDto;
34
+ }
@@ -0,0 +1,8 @@
1
+ export declare enum Brand {
2
+ VISA = "VISA",
3
+ MASTERCARD = "MASTERCARD",
4
+ AMERICAN_EXPRESS = "AMERICAN_EXPRESS",
5
+ DISCOVER = "DISCOVER",
6
+ DINERS_CLUB = "DINERS_CLUB",
7
+ JCB = "JCB"
8
+ }
@@ -0,0 +1,5 @@
1
+ export declare enum CardType {
2
+ CREDIT = "CREDIT",
3
+ DEBIT = "DEBIT",
4
+ PREPAID = "PREPAID"
5
+ }
@@ -0,0 +1,4 @@
1
+ export declare enum CardUpdateKey {
2
+ CHANGE_STATUS = "CHANGE_STATUS",
3
+ CHANGE_PIN = "CHANGE_PIN"
4
+ }
@@ -0,0 +1,4 @@
1
+ export declare enum IssuanceType {
2
+ VIRTUAL = "VIRTUAL",
3
+ PHYSICAL = "PHYSICAL"
4
+ }
@@ -0,0 +1,4 @@
1
+ export declare enum OwnershipType {
2
+ NOMINATE = "NOMINATE",
3
+ INNOMINATE = "INNOMINATE"
4
+ }
@@ -0,0 +1,5 @@
1
+ export declare enum Status {
2
+ ACTIVE = "ACTIVE",
3
+ PENDING = "PENDING",
4
+ PAUSED = "PAUSED"
5
+ }
@@ -0,0 +1,4 @@
1
+ export declare enum CountryId {
2
+ MEX = "484",
3
+ USA = "840"
4
+ }
@@ -0,0 +1 @@
1
+ export * from './enums/CountryId';
@@ -0,0 +1,6 @@
1
+ export declare class ValidationUtils {
2
+ static validateUuidV4(value: any): boolean;
3
+ static validateStringLength(minLength: number, maxLength: number): (value: string) => boolean;
4
+ static validateIso8601(value: string): boolean;
5
+ static validateNumberRange(minValue: number, maxValue: number): (value: number | null) => boolean;
6
+ }
@@ -0,0 +1,2 @@
1
+ export declare const regexUuidV4: RegExp;
2
+ export declare const regexIso8601: RegExp;
package/bin/index.d.ts ADDED
@@ -0,0 +1,9 @@
1
+ export * from './card/dtos/CardActivateDto';
2
+ export * from './card/dtos/CardRequestDto';
3
+ export * from './card/dtos/CreateCardDto';
4
+ export * from './card/enums/CardType';
5
+ export * from './card/enums/CardUpdateKey';
6
+ export * from './card/enums/IssuanceType';
7
+ export * from './card/enums/Status';
8
+ export * from './card/enums/IssuanceType';
9
+ export * from './card/enums/OwnershipType';
package/bin/index.js ADDED
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./card/dtos/CardActivateDto"), exports);
18
+ __exportStar(require("./card/dtos/CardRequestDto"), exports);
19
+ __exportStar(require("./card/dtos/CreateCardDto"), exports);
20
+ __exportStar(require("./card/enums/CardType"), exports);
21
+ __exportStar(require("./card/enums/CardUpdateKey"), exports);
22
+ __exportStar(require("./card/enums/IssuanceType"), exports);
23
+ __exportStar(require("./card/enums/Status"), exports);
24
+ __exportStar(require("./card/enums/IssuanceType"), exports);
25
+ __exportStar(require("./card/enums/OwnershipType"), exports);
@@ -0,0 +1,4 @@
1
+ export declare enum Provider {
2
+ TERN = "TERN",
3
+ POMELO = "POMELO"
4
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fiado/type-kit",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "",
5
5
  "main": "bin/index.js",
6
6
  "types": "bin/index.d.ts",
package/src/index.ts ADDED
@@ -0,0 +1,13 @@
1
+ export * from './card/dtos/CardActivateDto';
2
+ export * from './card/dtos/CardRequestDto';
3
+ export * from './card/dtos/CreateCardDto';
4
+
5
+ export * from './card/enums/CardType';
6
+ export * from './card/enums/CardUpdateKey';
7
+ export * from './card/enums/IssuanceType';
8
+ export * from './card/enums/Status';
9
+ export * from './card/enums/IssuanceType';
10
+ export * from './card/enums/OwnershipType';
11
+
12
+
13
+
package/src/card/index.ts DELETED
@@ -1,13 +0,0 @@
1
- export * from './dtos/CardActivateDto';
2
- export * from './dtos/CardRequestDto';
3
- export * from './dtos/CreateCardDto';
4
-
5
- export * from './enums/CardType';
6
- export * from './enums/CardUpdateKey';
7
- export * from './enums/IssuanceType';
8
- export * from './enums/Status';
9
- export * from './enums/IssuanceType';
10
- export * from './enums/OwnershipType';
11
-
12
-
13
-