resurgence-data 1.1.0 → 1.1.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,4 @@
1
+ export declare class BillerKeyUpdateDto {
2
+ billerId: string;
3
+ environment: string;
4
+ }
@@ -1 +1,30 @@
1
1
  "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.BillerKeyUpdateDto = void 0;
13
+ const swagger_1 = require("@nestjs/swagger");
14
+ const class_validator_1 = require("class-validator");
15
+ const biller_type_1 = require("../types/biller.type");
16
+ class BillerKeyUpdateDto {
17
+ }
18
+ exports.BillerKeyUpdateDto = BillerKeyUpdateDto;
19
+ __decorate([
20
+ (0, swagger_1.ApiProperty)({ description: "Biller id" }),
21
+ (0, class_validator_1.IsUUID)(4, { message: "Please select a valid biller id" }),
22
+ (0, class_validator_1.IsNotEmpty)({ message: "Please provide a valid biller id" }),
23
+ __metadata("design:type", String)
24
+ ], BillerKeyUpdateDto.prototype, "billerId", void 0);
25
+ __decorate([
26
+ (0, swagger_1.ApiProperty)({ description: "Environment" }),
27
+ (0, class_validator_1.IsIn)(biller_type_1.environments, { message: "Please select a valid environment" }),
28
+ (0, class_validator_1.IsNotEmpty)({ message: "Please provide an environment for the key update" }),
29
+ __metadata("design:type", String)
30
+ ], BillerKeyUpdateDto.prototype, "environment", void 0);
@@ -1 +1,2 @@
1
1
  export * from "./api-key.data";
2
+ export * from "./api-key.dto";
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./api-key.data"), exports);
18
+ __exportStar(require("./api-key.dto"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "resurgence-data",
3
- "version": "1.1.0",
3
+ "version": "1.1.2",
4
4
  "description": "DTOs and shareable resources",
5
5
  "module": "dist/index.js",
6
6
  "main": "dist/index.js",
@@ -0,0 +1,14 @@
1
+ import { ApiProperty } from "@nestjs/swagger";
2
+ import { IsIn, IsNotEmpty, IsUUID } from "class-validator";
3
+ import { environments } from "../types/biller.type";
4
+
5
+ export class BillerKeyUpdateDto {
6
+ @ApiProperty({ description: "Biller id" })
7
+ @IsUUID(4, { message: "Please select a valid biller id" })
8
+ @IsNotEmpty({ message: "Please provide a valid biller id" })
9
+ billerId: string;
10
+ @ApiProperty({ description: "Environment" })
11
+ @IsIn(environments, { message: "Please select a valid environment" })
12
+ @IsNotEmpty({ message: "Please provide an environment for the key update" })
13
+ environment: string;
14
+ }
@@ -1 +1,2 @@
1
1
  export * from "./api-key.data";
2
+ export * from "./api-key.dto";