@fiado/type-kit 3.354.0 → 3.355.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.
- package/_test_/unit/webhookBusiness/WebhookEventEnvelope.test.ts +147 -0
- package/_test_/unit/webhookBusiness/webhookEvents.test.ts +197 -0
- package/_test_/unit/webhookBusiness/webhookSubscriptionRequests.test.ts +60 -0
- package/bin/index.d.ts +1 -0
- package/bin/index.js +5 -1
- package/bin/productCatalog/enums/ProductSubtypeEnum.d.ts +1 -1
- package/bin/productCatalog/enums/ProductSubtypeEnum.js +2 -2
- package/bin/productCatalog/enums/ProductTypeEnum.d.ts +4 -4
- package/bin/productCatalog/enums/ProductTypeEnum.js +4 -4
- package/bin/transactionProcessor/dtos/{AuthorizeWelcomeBonusRequest.d.ts → AuthorizeBonusRequest.d.ts} +3 -3
- package/bin/transactionProcessor/dtos/{AuthorizeWelcomeBonusRequest.js → AuthorizeBonusRequest.js} +10 -10
- package/bin/transactionProcessor/index.d.ts +1 -1
- package/bin/transactionProcessor/index.js +1 -1
- package/bin/webhookBusiness/constants/CaseRefPattern.d.ts +8 -0
- package/bin/webhookBusiness/constants/CaseRefPattern.js +11 -0
- package/bin/webhookBusiness/constants/WebhookFieldLimits.d.ts +6 -0
- package/bin/webhookBusiness/constants/WebhookFieldLimits.js +9 -0
- package/bin/webhookBusiness/dtos/WebhookDeliveryView.d.ts +28 -0
- package/bin/webhookBusiness/dtos/WebhookDeliveryView.js +2 -0
- package/bin/webhookBusiness/dtos/WebhookEventEnvelope.d.ts +27 -0
- package/bin/webhookBusiness/dtos/WebhookEventEnvelope.js +62 -0
- package/bin/webhookBusiness/dtos/WebhookOutboundMessage.d.ts +10 -0
- package/bin/webhookBusiness/dtos/WebhookOutboundMessage.js +2 -0
- package/bin/webhookBusiness/dtos/WebhookSubscriptionView.d.ts +23 -0
- package/bin/webhookBusiness/dtos/WebhookSubscriptionView.js +2 -0
- package/bin/webhookBusiness/dtos/requests/DeactivateWebhookSubscriptionRequest.d.ts +11 -0
- package/bin/webhookBusiness/dtos/requests/DeactivateWebhookSubscriptionRequest.js +42 -0
- package/bin/webhookBusiness/dtos/requests/GetWebhookSubscriptionRequest.d.ts +9 -0
- package/bin/webhookBusiness/dtos/requests/GetWebhookSubscriptionRequest.js +35 -0
- package/bin/webhookBusiness/dtos/requests/ListWebhookDeliveriesRequest.d.ts +9 -0
- package/bin/webhookBusiness/dtos/requests/ListWebhookDeliveriesRequest.js +35 -0
- package/bin/webhookBusiness/dtos/requests/RedeliverWebhookEventRequest.d.ts +11 -0
- package/bin/webhookBusiness/dtos/requests/RedeliverWebhookEventRequest.js +43 -0
- package/bin/webhookBusiness/dtos/requests/UpsertWebhookSubscriptionRequest.d.ts +22 -0
- package/bin/webhookBusiness/dtos/requests/UpsertWebhookSubscriptionRequest.js +89 -0
- package/bin/webhookBusiness/dtos/responses/DeactivateWebhookSubscriptionResponse.d.ts +5 -0
- package/bin/webhookBusiness/dtos/responses/DeactivateWebhookSubscriptionResponse.js +2 -0
- package/bin/webhookBusiness/dtos/responses/GetWebhookSubscriptionResponse.d.ts +5 -0
- package/bin/webhookBusiness/dtos/responses/GetWebhookSubscriptionResponse.js +2 -0
- package/bin/webhookBusiness/dtos/responses/ListWebhookDeliveriesResponse.d.ts +10 -0
- package/bin/webhookBusiness/dtos/responses/ListWebhookDeliveriesResponse.js +2 -0
- package/bin/webhookBusiness/dtos/responses/ListWebhookSubscriptionsResponse.d.ts +10 -0
- package/bin/webhookBusiness/dtos/responses/ListWebhookSubscriptionsResponse.js +2 -0
- package/bin/webhookBusiness/dtos/responses/RedeliverWebhookEventResponse.d.ts +11 -0
- package/bin/webhookBusiness/dtos/responses/RedeliverWebhookEventResponse.js +2 -0
- package/bin/webhookBusiness/dtos/responses/UpsertWebhookSubscriptionResponse.d.ts +7 -0
- package/bin/webhookBusiness/dtos/responses/UpsertWebhookSubscriptionResponse.js +2 -0
- package/bin/webhookBusiness/enums/ComplianceDecisionEnum.d.ts +11 -0
- package/bin/webhookBusiness/enums/ComplianceDecisionEnum.js +15 -0
- package/bin/webhookBusiness/enums/DeliveryOutcomeEnum.d.ts +15 -0
- package/bin/webhookBusiness/enums/DeliveryOutcomeEnum.js +19 -0
- package/bin/webhookBusiness/enums/SubscriptionStatusEnum.d.ts +5 -0
- package/bin/webhookBusiness/enums/SubscriptionStatusEnum.js +9 -0
- package/bin/webhookBusiness/enums/SubscriptionVisibilityEnum.d.ts +10 -0
- package/bin/webhookBusiness/enums/SubscriptionVisibilityEnum.js +14 -0
- package/bin/webhookBusiness/enums/WebhookEventType.d.ts +10 -0
- package/bin/webhookBusiness/enums/WebhookEventType.js +14 -0
- package/bin/webhookBusiness/events/AccountIssuanceCompletedV1.d.ts +19 -0
- package/bin/webhookBusiness/events/AccountIssuanceCompletedV1.js +47 -0
- package/bin/webhookBusiness/events/ComplianceDecisionV1.d.ts +25 -0
- package/bin/webhookBusiness/events/ComplianceDecisionV1.js +51 -0
- package/bin/webhookBusiness/index.d.ts +24 -0
- package/bin/webhookBusiness/index.js +47 -0
- package/package.json +1 -1
- package/src/index.ts +4 -0
- package/src/productCatalog/enums/ProductSubtypeEnum.ts +2 -2
- package/src/productCatalog/enums/ProductTypeEnum.ts +4 -4
- package/src/transactionProcessor/dtos/{AuthorizeWelcomeBonusRequest.ts → AuthorizeBonusRequest.ts} +3 -3
- package/src/transactionProcessor/index.ts +1 -1
- package/src/webhookBusiness/constants/CaseRefPattern.ts +9 -0
- package/src/webhookBusiness/constants/WebhookFieldLimits.ts +8 -0
- package/src/webhookBusiness/dtos/WebhookDeliveryView.ts +29 -0
- package/src/webhookBusiness/dtos/WebhookEventEnvelope.ts +42 -0
- package/src/webhookBusiness/dtos/WebhookOutboundMessage.ts +18 -0
- package/src/webhookBusiness/dtos/WebhookSubscriptionView.ts +24 -0
- package/src/webhookBusiness/dtos/requests/DeactivateWebhookSubscriptionRequest.ts +27 -0
- package/src/webhookBusiness/dtos/requests/GetWebhookSubscriptionRequest.ts +20 -0
- package/src/webhookBusiness/dtos/requests/ListWebhookDeliveriesRequest.ts +21 -0
- package/src/webhookBusiness/dtos/requests/RedeliverWebhookEventRequest.ts +28 -0
- package/src/webhookBusiness/dtos/requests/UpsertWebhookSubscriptionRequest.ts +69 -0
- package/src/webhookBusiness/dtos/responses/DeactivateWebhookSubscriptionResponse.ts +6 -0
- package/src/webhookBusiness/dtos/responses/GetWebhookSubscriptionResponse.ts +6 -0
- package/src/webhookBusiness/dtos/responses/ListWebhookDeliveriesResponse.ts +11 -0
- package/src/webhookBusiness/dtos/responses/ListWebhookSubscriptionsResponse.ts +11 -0
- package/src/webhookBusiness/dtos/responses/RedeliverWebhookEventResponse.ts +12 -0
- package/src/webhookBusiness/dtos/responses/UpsertWebhookSubscriptionResponse.ts +8 -0
- package/src/webhookBusiness/enums/ComplianceDecisionEnum.ts +11 -0
- package/src/webhookBusiness/enums/DeliveryOutcomeEnum.ts +15 -0
- package/src/webhookBusiness/enums/SubscriptionStatusEnum.ts +5 -0
- package/src/webhookBusiness/enums/SubscriptionVisibilityEnum.ts +10 -0
- package/src/webhookBusiness/enums/WebhookEventType.ts +10 -0
- package/src/webhookBusiness/events/AccountIssuanceCompletedV1.ts +30 -0
- package/src/webhookBusiness/events/ComplianceDecisionV1.ts +36 -0
- package/src/webhookBusiness/index.ts +37 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { WebhookEventType } from '../enums/WebhookEventType';
|
|
2
|
+
/**
|
|
3
|
+
* Sobre común de todo lo que sale por `webhook-business`. El receptor rutea por `eventType` y recién
|
|
4
|
+
* ahí valida el `payload` contra la clase concreta que le corresponde.
|
|
5
|
+
*
|
|
6
|
+
* `TEventType` deja fijar el miembro del catálogo que acompaña a `TPayload`, para que el par
|
|
7
|
+
* `(eventType, payload)` quede amarrado en `WebhookOutboundMessage`.
|
|
8
|
+
*/
|
|
9
|
+
export declare class WebhookEventEnvelope<TPayload, TEventType extends WebhookEventType = WebhookEventType> {
|
|
10
|
+
/** Idempotencia del receptor: reprocesar el mismo `eventId` no debe duplicar efectos. */
|
|
11
|
+
eventId: string;
|
|
12
|
+
eventType: TEventType;
|
|
13
|
+
/** Lambda que lo produjo. Para soporte y para la bitácora de entregas. */
|
|
14
|
+
source: string;
|
|
15
|
+
/**
|
|
16
|
+
* La llave de enrutamiento: con esto `webhook-business` resuelve los tags `wh:*` y decide a
|
|
17
|
+
* quién le toca. Obligatorio en TODO evento — sin él no hay destinatario posible.
|
|
18
|
+
*/
|
|
19
|
+
directoryId: string;
|
|
20
|
+
/** ISO-8601. Resuelve el reordenamiento; la cola es estándar y no garantiza orden. */
|
|
21
|
+
occurredAt: string;
|
|
22
|
+
/**
|
|
23
|
+
* El evento concreto, sin transformar. Se valida como objeto presente y nada más: la clase real
|
|
24
|
+
* la elige el receptor por `eventType`, y un `@Type()` genérico aquí dejaría el payload vacío.
|
|
25
|
+
*/
|
|
26
|
+
payload: TPayload;
|
|
27
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
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.WebhookEventEnvelope = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const WebhookEventType_1 = require("../enums/WebhookEventType");
|
|
16
|
+
const WebhookFieldLimits_1 = require("../constants/WebhookFieldLimits");
|
|
17
|
+
/**
|
|
18
|
+
* Sobre común de todo lo que sale por `webhook-business`. El receptor rutea por `eventType` y recién
|
|
19
|
+
* ahí valida el `payload` contra la clase concreta que le corresponde.
|
|
20
|
+
*
|
|
21
|
+
* `TEventType` deja fijar el miembro del catálogo que acompaña a `TPayload`, para que el par
|
|
22
|
+
* `(eventType, payload)` quede amarrado en `WebhookOutboundMessage`.
|
|
23
|
+
*/
|
|
24
|
+
class WebhookEventEnvelope {
|
|
25
|
+
}
|
|
26
|
+
exports.WebhookEventEnvelope = WebhookEventEnvelope;
|
|
27
|
+
__decorate([
|
|
28
|
+
(0, class_transformer_1.Expose)(),
|
|
29
|
+
(0, class_validator_1.IsString)(),
|
|
30
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
31
|
+
(0, class_validator_1.MaxLength)(WebhookFieldLimits_1.WEBHOOK_EVENT_ID_MAX_LENGTH),
|
|
32
|
+
__metadata("design:type", String)
|
|
33
|
+
], WebhookEventEnvelope.prototype, "eventId", void 0);
|
|
34
|
+
__decorate([
|
|
35
|
+
(0, class_transformer_1.Expose)(),
|
|
36
|
+
(0, class_validator_1.IsEnum)(WebhookEventType_1.WebhookEventType),
|
|
37
|
+
__metadata("design:type", String)
|
|
38
|
+
], WebhookEventEnvelope.prototype, "eventType", void 0);
|
|
39
|
+
__decorate([
|
|
40
|
+
(0, class_transformer_1.Expose)(),
|
|
41
|
+
(0, class_validator_1.IsString)(),
|
|
42
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
43
|
+
__metadata("design:type", String)
|
|
44
|
+
], WebhookEventEnvelope.prototype, "source", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, class_transformer_1.Expose)(),
|
|
47
|
+
(0, class_validator_1.IsString)(),
|
|
48
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
49
|
+
__metadata("design:type", String)
|
|
50
|
+
], WebhookEventEnvelope.prototype, "directoryId", void 0);
|
|
51
|
+
__decorate([
|
|
52
|
+
(0, class_transformer_1.Expose)(),
|
|
53
|
+
(0, class_validator_1.IsString)(),
|
|
54
|
+
(0, class_validator_1.IsISO8601)(),
|
|
55
|
+
__metadata("design:type", String)
|
|
56
|
+
], WebhookEventEnvelope.prototype, "occurredAt", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, class_transformer_1.Expose)(),
|
|
59
|
+
(0, class_validator_1.IsObject)(),
|
|
60
|
+
(0, class_validator_1.IsNotEmptyObject)(),
|
|
61
|
+
__metadata("design:type", Object)
|
|
62
|
+
], WebhookEventEnvelope.prototype, "payload", void 0);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { WebhookEventEnvelope } from './WebhookEventEnvelope';
|
|
2
|
+
import { WebhookEventType } from '../enums/WebhookEventType';
|
|
3
|
+
import { AccountIssuanceCompletedV1 } from '../events/AccountIssuanceCompletedV1';
|
|
4
|
+
import { ComplianceDecisionV1 } from '../events/ComplianceDecisionV1';
|
|
5
|
+
/**
|
|
6
|
+
* Unión cerrada de todo lo que la cola de `webhook-business` transporta hacia suscriptores externos
|
|
7
|
+
* (corte 1). Cada variante amarra el par `(eventType, payload)`: un sobre que declara un tipo de
|
|
8
|
+
* evento y lleva el payload de otro no compila.
|
|
9
|
+
*/
|
|
10
|
+
export type WebhookOutboundMessage = WebhookEventEnvelope<AccountIssuanceCompletedV1, WebhookEventType.AccountIssuanceCompleted> | WebhookEventEnvelope<ComplianceDecisionV1, WebhookEventType.ComplianceDecision>;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { WebhookEventType } from '../enums/WebhookEventType';
|
|
2
|
+
import type { SubscriptionStatusEnum } from '../enums/SubscriptionStatusEnum';
|
|
3
|
+
import type { SubscriptionVisibilityEnum } from '../enums/SubscriptionVisibilityEnum';
|
|
4
|
+
/**
|
|
5
|
+
* Una fila del padrón de suscriptores tal como sale por la API de administración.
|
|
6
|
+
* Expone el par `(tag, eventType)` en vez de las llaves crudas: `TAG#`/`EVT#` son detalle de DynamoDB.
|
|
7
|
+
*/
|
|
8
|
+
export interface WebhookSubscriptionView {
|
|
9
|
+
tag: string;
|
|
10
|
+
eventType: WebhookEventType;
|
|
11
|
+
subscriberName: string;
|
|
12
|
+
url: string;
|
|
13
|
+
visibility: SubscriptionVisibilityEnum;
|
|
14
|
+
status: SubscriptionStatusEnum;
|
|
15
|
+
/** Vínculo informativo con el padrón de socios M2M de RBAC. Todavía no gobierna la entrega. */
|
|
16
|
+
integrationId?: string;
|
|
17
|
+
timeoutMs?: number;
|
|
18
|
+
maxRetries?: number;
|
|
19
|
+
createdAt?: number;
|
|
20
|
+
updatedAt?: number;
|
|
21
|
+
createdBy?: string;
|
|
22
|
+
updatedBy?: string;
|
|
23
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { WebhookEventType } from '../../enums/WebhookEventType';
|
|
2
|
+
/**
|
|
3
|
+
* Body de `POST /private/webhook-subscriptions/deactivate` — baja lógica del destino.
|
|
4
|
+
* La fila no se borra: la bitácora referencia tags que tienen que seguir siendo explicables.
|
|
5
|
+
*/
|
|
6
|
+
export declare class DeactivateWebhookSubscriptionRequest {
|
|
7
|
+
tag: string;
|
|
8
|
+
eventType: WebhookEventType;
|
|
9
|
+
/** Quién dispara la baja. Sin él la auditoría queda en `system`. */
|
|
10
|
+
actor?: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
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.DeactivateWebhookSubscriptionRequest = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const WebhookEventType_1 = require("../../enums/WebhookEventType");
|
|
16
|
+
const WebhookFieldLimits_1 = require("../../constants/WebhookFieldLimits");
|
|
17
|
+
/**
|
|
18
|
+
* Body de `POST /private/webhook-subscriptions/deactivate` — baja lógica del destino.
|
|
19
|
+
* La fila no se borra: la bitácora referencia tags que tienen que seguir siendo explicables.
|
|
20
|
+
*/
|
|
21
|
+
class DeactivateWebhookSubscriptionRequest {
|
|
22
|
+
}
|
|
23
|
+
exports.DeactivateWebhookSubscriptionRequest = DeactivateWebhookSubscriptionRequest;
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_transformer_1.Expose)(),
|
|
26
|
+
(0, class_validator_1.IsString)(),
|
|
27
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
28
|
+
(0, class_validator_1.MaxLength)(WebhookFieldLimits_1.WEBHOOK_TAG_MAX_LENGTH),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], DeactivateWebhookSubscriptionRequest.prototype, "tag", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, class_transformer_1.Expose)(),
|
|
33
|
+
(0, class_validator_1.IsEnum)(WebhookEventType_1.WebhookEventType),
|
|
34
|
+
__metadata("design:type", String)
|
|
35
|
+
], DeactivateWebhookSubscriptionRequest.prototype, "eventType", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, class_transformer_1.Expose)(),
|
|
38
|
+
(0, class_validator_1.IsOptional)(),
|
|
39
|
+
(0, class_validator_1.IsString)(),
|
|
40
|
+
(0, class_validator_1.MaxLength)(128),
|
|
41
|
+
__metadata("design:type", String)
|
|
42
|
+
], DeactivateWebhookSubscriptionRequest.prototype, "actor", void 0);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { WebhookEventType } from '../../enums/WebhookEventType';
|
|
2
|
+
/**
|
|
3
|
+
* Query de `GET /private/webhook-subscriptions/lookup`. El par viaja en el query string y no en el
|
|
4
|
+
* path porque el tag lleva `:` reservado, y un path param con dos puntos depende del cliente.
|
|
5
|
+
*/
|
|
6
|
+
export declare class GetWebhookSubscriptionRequest {
|
|
7
|
+
tag: string;
|
|
8
|
+
eventType: WebhookEventType;
|
|
9
|
+
}
|
|
@@ -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.GetWebhookSubscriptionRequest = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const WebhookEventType_1 = require("../../enums/WebhookEventType");
|
|
16
|
+
const WebhookFieldLimits_1 = require("../../constants/WebhookFieldLimits");
|
|
17
|
+
/**
|
|
18
|
+
* Query de `GET /private/webhook-subscriptions/lookup`. El par viaja en el query string y no en el
|
|
19
|
+
* path porque el tag lleva `:` reservado, y un path param con dos puntos depende del cliente.
|
|
20
|
+
*/
|
|
21
|
+
class GetWebhookSubscriptionRequest {
|
|
22
|
+
}
|
|
23
|
+
exports.GetWebhookSubscriptionRequest = GetWebhookSubscriptionRequest;
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_transformer_1.Expose)(),
|
|
26
|
+
(0, class_validator_1.IsString)(),
|
|
27
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
28
|
+
(0, class_validator_1.MaxLength)(WebhookFieldLimits_1.WEBHOOK_TAG_MAX_LENGTH),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], GetWebhookSubscriptionRequest.prototype, "tag", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, class_transformer_1.Expose)(),
|
|
33
|
+
(0, class_validator_1.IsEnum)(WebhookEventType_1.WebhookEventType),
|
|
34
|
+
__metadata("design:type", String)
|
|
35
|
+
], GetWebhookSubscriptionRequest.prototype, "eventType", void 0);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Query de `GET /private/webhook-deliveries` — la bitácora de un comprador, la consulta que
|
|
3
|
+
* contesta "por qué el suscriptor no se enteró de esto". Va contra el GSI `directoryId-createdAt-index`.
|
|
4
|
+
*/
|
|
5
|
+
export declare class ListWebhookDeliveriesRequest {
|
|
6
|
+
directoryId: string;
|
|
7
|
+
/** Tope de asientos a devolver. El manager lo recorta a su máximo. */
|
|
8
|
+
limit?: number;
|
|
9
|
+
}
|
|
@@ -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.ListWebhookDeliveriesRequest = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
/**
|
|
16
|
+
* Query de `GET /private/webhook-deliveries` — la bitácora de un comprador, la consulta que
|
|
17
|
+
* contesta "por qué el suscriptor no se enteró de esto". Va contra el GSI `directoryId-createdAt-index`.
|
|
18
|
+
*/
|
|
19
|
+
class ListWebhookDeliveriesRequest {
|
|
20
|
+
}
|
|
21
|
+
exports.ListWebhookDeliveriesRequest = ListWebhookDeliveriesRequest;
|
|
22
|
+
__decorate([
|
|
23
|
+
(0, class_transformer_1.Expose)(),
|
|
24
|
+
(0, class_validator_1.IsString)(),
|
|
25
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
26
|
+
__metadata("design:type", String)
|
|
27
|
+
], ListWebhookDeliveriesRequest.prototype, "directoryId", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_transformer_1.Expose)(),
|
|
30
|
+
(0, class_validator_1.IsOptional)(),
|
|
31
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
32
|
+
(0, class_validator_1.IsInt)(),
|
|
33
|
+
(0, class_validator_1.IsPositive)(),
|
|
34
|
+
__metadata("design:type", Number)
|
|
35
|
+
], ListWebhookDeliveriesRequest.prototype, "limit", void 0);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Body de `POST /private/webhook-deliveries/redeliver` — reposición manual de un evento.
|
|
3
|
+
* El `payload` viaja en el request porque la bitácora guarda el desenlace, nunca el evento: de la
|
|
4
|
+
* fila salen el tipo, el origen y el destinatario; el contenido lo repone quien lo produjo.
|
|
5
|
+
*/
|
|
6
|
+
export declare class RedeliverWebhookEventRequest {
|
|
7
|
+
eventId: string;
|
|
8
|
+
payload: unknown;
|
|
9
|
+
/** Quién dispara el reenvío, para el log de la reposición. */
|
|
10
|
+
actor?: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
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.RedeliverWebhookEventRequest = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const WebhookFieldLimits_1 = require("../../constants/WebhookFieldLimits");
|
|
16
|
+
/**
|
|
17
|
+
* Body de `POST /private/webhook-deliveries/redeliver` — reposición manual de un evento.
|
|
18
|
+
* El `payload` viaja en el request porque la bitácora guarda el desenlace, nunca el evento: de la
|
|
19
|
+
* fila salen el tipo, el origen y el destinatario; el contenido lo repone quien lo produjo.
|
|
20
|
+
*/
|
|
21
|
+
class RedeliverWebhookEventRequest {
|
|
22
|
+
}
|
|
23
|
+
exports.RedeliverWebhookEventRequest = RedeliverWebhookEventRequest;
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_transformer_1.Expose)(),
|
|
26
|
+
(0, class_validator_1.IsString)(),
|
|
27
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
28
|
+
(0, class_validator_1.MaxLength)(WebhookFieldLimits_1.WEBHOOK_EVENT_ID_MAX_LENGTH),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], RedeliverWebhookEventRequest.prototype, "eventId", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, class_transformer_1.Expose)(),
|
|
33
|
+
(0, class_validator_1.IsObject)(),
|
|
34
|
+
(0, class_validator_1.IsNotEmptyObject)(),
|
|
35
|
+
__metadata("design:type", Object)
|
|
36
|
+
], RedeliverWebhookEventRequest.prototype, "payload", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, class_transformer_1.Expose)(),
|
|
39
|
+
(0, class_validator_1.IsOptional)(),
|
|
40
|
+
(0, class_validator_1.IsString)(),
|
|
41
|
+
(0, class_validator_1.MaxLength)(128),
|
|
42
|
+
__metadata("design:type", String)
|
|
43
|
+
], RedeliverWebhookEventRequest.prototype, "actor", void 0);
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { WebhookEventType } from '../../enums/WebhookEventType';
|
|
2
|
+
import { SubscriptionStatusEnum } from '../../enums/SubscriptionStatusEnum';
|
|
3
|
+
import { SubscriptionVisibilityEnum } from '../../enums/SubscriptionVisibilityEnum';
|
|
4
|
+
/**
|
|
5
|
+
* Body de `PUT /private/webhook-subscriptions` — alta o actualización de una fila del padrón.
|
|
6
|
+
* Es idempotente: el par `(tag, eventType)` es la llave, así que reenviar el mismo body no duplica.
|
|
7
|
+
*/
|
|
8
|
+
export declare class UpsertWebhookSubscriptionRequest {
|
|
9
|
+
/** Tag de enrutamiento. El prefijo reservado lo verifica el manager, no el DTO. */
|
|
10
|
+
tag: string;
|
|
11
|
+
eventType: WebhookEventType;
|
|
12
|
+
subscriberName: string;
|
|
13
|
+
/** Absoluta en los dos modos de visibilidad: el dispatcher hace POST contra ella tal cual. */
|
|
14
|
+
url: string;
|
|
15
|
+
visibility: SubscriptionVisibilityEnum;
|
|
16
|
+
status: SubscriptionStatusEnum;
|
|
17
|
+
integrationId?: string;
|
|
18
|
+
timeoutMs?: number;
|
|
19
|
+
maxRetries?: number;
|
|
20
|
+
/** Quién dispara el alta. Sin él la auditoría queda en `system`, que es el actor de los procesos. */
|
|
21
|
+
actor?: string;
|
|
22
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
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.UpsertWebhookSubscriptionRequest = void 0;
|
|
13
|
+
const class_transformer_1 = require("class-transformer");
|
|
14
|
+
const class_validator_1 = require("class-validator");
|
|
15
|
+
const WebhookEventType_1 = require("../../enums/WebhookEventType");
|
|
16
|
+
const SubscriptionStatusEnum_1 = require("../../enums/SubscriptionStatusEnum");
|
|
17
|
+
const SubscriptionVisibilityEnum_1 = require("../../enums/SubscriptionVisibilityEnum");
|
|
18
|
+
const WebhookFieldLimits_1 = require("../../constants/WebhookFieldLimits");
|
|
19
|
+
/**
|
|
20
|
+
* Body de `PUT /private/webhook-subscriptions` — alta o actualización de una fila del padrón.
|
|
21
|
+
* Es idempotente: el par `(tag, eventType)` es la llave, así que reenviar el mismo body no duplica.
|
|
22
|
+
*/
|
|
23
|
+
class UpsertWebhookSubscriptionRequest {
|
|
24
|
+
}
|
|
25
|
+
exports.UpsertWebhookSubscriptionRequest = UpsertWebhookSubscriptionRequest;
|
|
26
|
+
__decorate([
|
|
27
|
+
(0, class_transformer_1.Expose)(),
|
|
28
|
+
(0, class_validator_1.IsString)(),
|
|
29
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
30
|
+
(0, class_validator_1.MaxLength)(WebhookFieldLimits_1.WEBHOOK_TAG_MAX_LENGTH),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], UpsertWebhookSubscriptionRequest.prototype, "tag", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, class_transformer_1.Expose)(),
|
|
35
|
+
(0, class_validator_1.IsEnum)(WebhookEventType_1.WebhookEventType),
|
|
36
|
+
__metadata("design:type", String)
|
|
37
|
+
], UpsertWebhookSubscriptionRequest.prototype, "eventType", void 0);
|
|
38
|
+
__decorate([
|
|
39
|
+
(0, class_transformer_1.Expose)(),
|
|
40
|
+
(0, class_validator_1.IsString)(),
|
|
41
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
42
|
+
(0, class_validator_1.MaxLength)(128),
|
|
43
|
+
__metadata("design:type", String)
|
|
44
|
+
], UpsertWebhookSubscriptionRequest.prototype, "subscriberName", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, class_transformer_1.Expose)(),
|
|
47
|
+
(0, class_validator_1.IsUrl)({ require_tld: false, require_protocol: true, protocols: ['http', 'https'] }),
|
|
48
|
+
__metadata("design:type", String)
|
|
49
|
+
], UpsertWebhookSubscriptionRequest.prototype, "url", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
(0, class_transformer_1.Expose)(),
|
|
52
|
+
(0, class_validator_1.IsEnum)(SubscriptionVisibilityEnum_1.SubscriptionVisibilityEnum),
|
|
53
|
+
__metadata("design:type", String)
|
|
54
|
+
], UpsertWebhookSubscriptionRequest.prototype, "visibility", void 0);
|
|
55
|
+
__decorate([
|
|
56
|
+
(0, class_transformer_1.Expose)(),
|
|
57
|
+
(0, class_validator_1.IsEnum)(SubscriptionStatusEnum_1.SubscriptionStatusEnum),
|
|
58
|
+
__metadata("design:type", String)
|
|
59
|
+
], UpsertWebhookSubscriptionRequest.prototype, "status", void 0);
|
|
60
|
+
__decorate([
|
|
61
|
+
(0, class_transformer_1.Expose)(),
|
|
62
|
+
(0, class_validator_1.IsOptional)(),
|
|
63
|
+
(0, class_validator_1.IsString)(),
|
|
64
|
+
(0, class_validator_1.MaxLength)(128),
|
|
65
|
+
__metadata("design:type", String)
|
|
66
|
+
], UpsertWebhookSubscriptionRequest.prototype, "integrationId", void 0);
|
|
67
|
+
__decorate([
|
|
68
|
+
(0, class_transformer_1.Expose)(),
|
|
69
|
+
(0, class_validator_1.IsOptional)(),
|
|
70
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
71
|
+
(0, class_validator_1.IsInt)(),
|
|
72
|
+
(0, class_validator_1.IsPositive)(),
|
|
73
|
+
__metadata("design:type", Number)
|
|
74
|
+
], UpsertWebhookSubscriptionRequest.prototype, "timeoutMs", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
(0, class_transformer_1.Expose)(),
|
|
77
|
+
(0, class_validator_1.IsOptional)(),
|
|
78
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
79
|
+
(0, class_validator_1.IsInt)(),
|
|
80
|
+
(0, class_validator_1.IsPositive)(),
|
|
81
|
+
__metadata("design:type", Number)
|
|
82
|
+
], UpsertWebhookSubscriptionRequest.prototype, "maxRetries", void 0);
|
|
83
|
+
__decorate([
|
|
84
|
+
(0, class_transformer_1.Expose)(),
|
|
85
|
+
(0, class_validator_1.IsOptional)(),
|
|
86
|
+
(0, class_validator_1.IsString)(),
|
|
87
|
+
(0, class_validator_1.MaxLength)(128),
|
|
88
|
+
__metadata("design:type", String)
|
|
89
|
+
], UpsertWebhookSubscriptionRequest.prototype, "actor", void 0);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { WebhookDeliveryView } from '../WebhookDeliveryView';
|
|
2
|
+
/**
|
|
3
|
+
* Respuesta de `GET /private/webhook-deliveries`. Un comprador sin asientos devuelve la lista
|
|
4
|
+
* vacía y no un 404: que nunca le haya salido un evento es un estado válido.
|
|
5
|
+
*/
|
|
6
|
+
export interface ListWebhookDeliveriesResponse {
|
|
7
|
+
directoryId: string;
|
|
8
|
+
deliveries: WebhookDeliveryView[];
|
|
9
|
+
count: number;
|
|
10
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { WebhookSubscriptionView } from '../WebhookSubscriptionView';
|
|
2
|
+
/**
|
|
3
|
+
* Respuesta de `GET /private/webhook-subscriptions` — el padrón completo.
|
|
4
|
+
* `truncated` avisa que se alcanzó el tope de la lectura y quedaron filas afuera.
|
|
5
|
+
*/
|
|
6
|
+
export interface ListWebhookSubscriptionsResponse {
|
|
7
|
+
subscriptions: WebhookSubscriptionView[];
|
|
8
|
+
count: number;
|
|
9
|
+
truncated: boolean;
|
|
10
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { WebhookEventType } from '../../enums/WebhookEventType';
|
|
2
|
+
/**
|
|
3
|
+
* Respuesta de `POST /private/webhook-deliveries/redeliver`. Devuelve qué se repuso, no cómo
|
|
4
|
+
* terminó cada destino: eso queda en la bitácora, que es la fuente de los desenlaces.
|
|
5
|
+
*/
|
|
6
|
+
export interface RedeliverWebhookEventResponse {
|
|
7
|
+
eventId: string;
|
|
8
|
+
eventType: WebhookEventType;
|
|
9
|
+
directoryId: string;
|
|
10
|
+
redeliveredAt: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { WebhookSubscriptionView } from '../WebhookSubscriptionView';
|
|
2
|
+
/** Respuesta de `PUT /private/webhook-subscriptions`. */
|
|
3
|
+
export interface UpsertWebhookSubscriptionResponse {
|
|
4
|
+
/** `true` cuando el par `(tag, eventType)` no existía y se dio de alta. */
|
|
5
|
+
created: boolean;
|
|
6
|
+
subscription: WebhookSubscriptionView;
|
|
7
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Desenlace del dictamen del oficial de cumplimiento, en los únicos dos términos accionables.
|
|
3
|
+
* Deliberadamente NO existe un valor que insinúe sobre qué se dictaminó: avisar de una coincidencia
|
|
4
|
+
* en listas es delito, y este enum viaja a un externo.
|
|
5
|
+
*/
|
|
6
|
+
export declare enum ComplianceDecisionEnum {
|
|
7
|
+
/** Se liberó el caso: el siguiente intento de abrir la cuenta puede pasar. */
|
|
8
|
+
CLEARED = "CLEARED",
|
|
9
|
+
/** Terminal: la cuenta no se abre y la venta no continúa. Nadie lo va a destrabar. */
|
|
10
|
+
REJECTED = "REJECTED"
|
|
11
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ComplianceDecisionEnum = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Desenlace del dictamen del oficial de cumplimiento, en los únicos dos términos accionables.
|
|
6
|
+
* Deliberadamente NO existe un valor que insinúe sobre qué se dictaminó: avisar de una coincidencia
|
|
7
|
+
* en listas es delito, y este enum viaja a un externo.
|
|
8
|
+
*/
|
|
9
|
+
var ComplianceDecisionEnum;
|
|
10
|
+
(function (ComplianceDecisionEnum) {
|
|
11
|
+
/** Se liberó el caso: el siguiente intento de abrir la cuenta puede pasar. */
|
|
12
|
+
ComplianceDecisionEnum["CLEARED"] = "CLEARED";
|
|
13
|
+
/** Terminal: la cuenta no se abre y la venta no continúa. Nadie lo va a destrabar. */
|
|
14
|
+
ComplianceDecisionEnum["REJECTED"] = "REJECTED";
|
|
15
|
+
})(ComplianceDecisionEnum || (exports.ComplianceDecisionEnum = ComplianceDecisionEnum = {}));
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/** Desenlace de un evento frente a un destinatario, tal como queda asentado en la bitácora. */
|
|
2
|
+
export declare enum DeliveryOutcomeEnum {
|
|
3
|
+
/** El suscriptor aceptó el evento. */
|
|
4
|
+
DELIVERED = "DELIVERED",
|
|
5
|
+
/** El suscriptor rechazó la entrega o no respondió. El mensaje vuelve a la cola. */
|
|
6
|
+
FAILED = "FAILED",
|
|
7
|
+
/** Se agotaron los intentos que el destino admite. No se vuelve a intentar. */
|
|
8
|
+
EXHAUSTED = "EXHAUSTED",
|
|
9
|
+
/** El directoryId no traía ningún tag `wh:*`: el evento se descarta sin reintento. */
|
|
10
|
+
NO_RECIPIENT = "NO_RECIPIENT",
|
|
11
|
+
/** El tag existe pero nadie declaró un destino para ese eventType. */
|
|
12
|
+
NO_SUBSCRIPTION = "NO_SUBSCRIPTION",
|
|
13
|
+
/** El destino está dado de baja: es un no-op registrado, no un error. */
|
|
14
|
+
SKIPPED_INACTIVE = "SKIPPED_INACTIVE"
|
|
15
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DeliveryOutcomeEnum = void 0;
|
|
4
|
+
/** Desenlace de un evento frente a un destinatario, tal como queda asentado en la bitácora. */
|
|
5
|
+
var DeliveryOutcomeEnum;
|
|
6
|
+
(function (DeliveryOutcomeEnum) {
|
|
7
|
+
/** El suscriptor aceptó el evento. */
|
|
8
|
+
DeliveryOutcomeEnum["DELIVERED"] = "DELIVERED";
|
|
9
|
+
/** El suscriptor rechazó la entrega o no respondió. El mensaje vuelve a la cola. */
|
|
10
|
+
DeliveryOutcomeEnum["FAILED"] = "FAILED";
|
|
11
|
+
/** Se agotaron los intentos que el destino admite. No se vuelve a intentar. */
|
|
12
|
+
DeliveryOutcomeEnum["EXHAUSTED"] = "EXHAUSTED";
|
|
13
|
+
/** El directoryId no traía ningún tag `wh:*`: el evento se descarta sin reintento. */
|
|
14
|
+
DeliveryOutcomeEnum["NO_RECIPIENT"] = "NO_RECIPIENT";
|
|
15
|
+
/** El tag existe pero nadie declaró un destino para ese eventType. */
|
|
16
|
+
DeliveryOutcomeEnum["NO_SUBSCRIPTION"] = "NO_SUBSCRIPTION";
|
|
17
|
+
/** El destino está dado de baja: es un no-op registrado, no un error. */
|
|
18
|
+
DeliveryOutcomeEnum["SKIPPED_INACTIVE"] = "SKIPPED_INACTIVE";
|
|
19
|
+
})(DeliveryOutcomeEnum || (exports.DeliveryOutcomeEnum = DeliveryOutcomeEnum = {}));
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SubscriptionStatusEnum = void 0;
|
|
4
|
+
/** Permite apagar un destino sin borrar su fila del padrón. */
|
|
5
|
+
var SubscriptionStatusEnum;
|
|
6
|
+
(function (SubscriptionStatusEnum) {
|
|
7
|
+
SubscriptionStatusEnum["ACTIVE"] = "ACTIVE";
|
|
8
|
+
SubscriptionStatusEnum["INACTIVE"] = "INACTIVE";
|
|
9
|
+
})(SubscriptionStatusEnum || (exports.SubscriptionStatusEnum = SubscriptionStatusEnum = {}));
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Qué cliente y qué credenciales lleva la entrega. No es "dentro o fuera de la VPC".
|
|
3
|
+
* Es enum y no un booleano para poder sumar un tercer modo (firma, mTLS, bearer) sin migrar la tabla.
|
|
4
|
+
*/
|
|
5
|
+
export declare enum SubscriptionVisibilityEnum {
|
|
6
|
+
/** Receptor dentro de la VPC: la baseUrl se resuelve por destino y se pasa por llamada. */
|
|
7
|
+
PRIVATE = "PRIVATE",
|
|
8
|
+
/** Receptor fuera de la VPC: HTTP plano contra la URL absoluta, sin token ni headers propios. */
|
|
9
|
+
PUBLIC = "PUBLIC"
|
|
10
|
+
}
|