tychat-contracts 1.0.54 → 1.0.55

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.
package/dist/index.d.ts CHANGED
@@ -11,4 +11,5 @@ export * from './billing';
11
11
  export * from './ai';
12
12
  export * from './storage';
13
13
  export * from './notifications';
14
+ export * from './tenants';
14
15
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,MAAM,CAAC;AACrB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,MAAM,CAAC;AACrB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC"}
package/dist/index.js CHANGED
@@ -27,3 +27,4 @@ __exportStar(require("./billing"), exports);
27
27
  __exportStar(require("./ai"), exports);
28
28
  __exportStar(require("./storage"), exports);
29
29
  __exportStar(require("./notifications"), exports);
30
+ __exportStar(require("./tenants"), exports);
@@ -1 +1,2 @@
1
+ export * from './update-tenant-environment-url.dto';
1
2
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tenants/index.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tenants/index.ts"],"names":[],"mappings":"AAAA,cAAc,qCAAqC,CAAC"}
@@ -1,2 +1,17 @@
1
1
  "use strict";
2
- // DTOs de tenants foram movidos para o próprio microserviço tychat-tenant-service
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("./update-tenant-environment-url.dto"), exports);
@@ -0,0 +1,8 @@
1
+ /**
2
+ * PATCH /tenants/:id/environment-urls/:service — set or reset custom hostname for Dokploy.
3
+ * Send `null` or empty string to revert to default (slug-based) host.
4
+ */
5
+ export declare class UpdateTenantEnvironmentUrlDto {
6
+ host?: string | null;
7
+ }
8
+ //# sourceMappingURL=update-tenant-environment-url.dto.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-tenant-environment-url.dto.d.ts","sourceRoot":"","sources":["../../src/tenants/update-tenant-environment-url.dto.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,qBAAa,6BAA6B;IAYxC,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACtB"}
@@ -0,0 +1,35 @@
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.UpdateTenantEnvironmentUrlDto = void 0;
13
+ const swagger_1 = require("@nestjs/swagger");
14
+ const class_validator_1 = require("class-validator");
15
+ /**
16
+ * PATCH /tenants/:id/environment-urls/:service — set or reset custom hostname for Dokploy.
17
+ * Send `null` or empty string to revert to default (slug-based) host.
18
+ */
19
+ class UpdateTenantEnvironmentUrlDto {
20
+ host;
21
+ }
22
+ exports.UpdateTenantEnvironmentUrlDto = UpdateTenantEnvironmentUrlDto;
23
+ __decorate([
24
+ (0, swagger_1.ApiPropertyOptional)({
25
+ description: 'Hostname or full URL (e.g. clinic.example.com or https://clinic.example.com). Omit or send null to reset to default slug-based domain.',
26
+ nullable: true,
27
+ example: 'acme.custom.com',
28
+ maxLength: 255,
29
+ }),
30
+ (0, class_validator_1.IsOptional)(),
31
+ (0, class_validator_1.ValidateIf)((_, v) => v !== null && v !== undefined),
32
+ (0, class_validator_1.IsString)(),
33
+ (0, class_validator_1.MaxLength)(255),
34
+ __metadata("design:type", Object)
35
+ ], UpdateTenantEnvironmentUrlDto.prototype, "host", void 0);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tychat-contracts",
3
- "version": "1.0.54",
3
+ "version": "1.0.55",
4
4
  "description": "DTOs compartilhados com class-validator (API e microserviços)",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/src/index.ts CHANGED
@@ -11,3 +11,4 @@ export * from './billing';
11
11
  export * from './ai';
12
12
  export * from './storage';
13
13
  export * from './notifications';
14
+ export * from './tenants';
@@ -1 +1 @@
1
- // DTOs de tenants foram movidos para o próprio microserviço tychat-tenant-service
1
+ export * from './update-tenant-environment-url.dto';
@@ -0,0 +1,21 @@
1
+ import { ApiPropertyOptional } from '@nestjs/swagger';
2
+ import { IsOptional, IsString, MaxLength, ValidateIf } from 'class-validator';
3
+
4
+ /**
5
+ * PATCH /tenants/:id/environment-urls/:service — set or reset custom hostname for Dokploy.
6
+ * Send `null` or empty string to revert to default (slug-based) host.
7
+ */
8
+ export class UpdateTenantEnvironmentUrlDto {
9
+ @ApiPropertyOptional({
10
+ description:
11
+ 'Hostname or full URL (e.g. clinic.example.com or https://clinic.example.com). Omit or send null to reset to default slug-based domain.',
12
+ nullable: true,
13
+ example: 'acme.custom.com',
14
+ maxLength: 255,
15
+ })
16
+ @IsOptional()
17
+ @ValidateIf((_, v) => v !== null && v !== undefined)
18
+ @IsString()
19
+ @MaxLength(255)
20
+ host?: string | null;
21
+ }