@fiado/type-kit 3.48.0 → 3.50.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/cognitoBackofficeConnector/dtos/Introspect.test.ts +30 -30
- package/_test_/unit/platformRbac/auth/dtos.test.ts +42 -42
- package/_test_/unit/platformRbac/dtos/AuthorizeRequest.test.ts +30 -30
- package/_test_/unit/platformRbac/dtos/AuthorizeResponse.test.ts +25 -25
- package/bin/platformRbac/mfa/VerifyTotpEnrollmentRequest.d.ts +6 -0
- package/bin/platformRbac/mfa/VerifyTotpEnrollmentRequest.js +4 -0
- package/bin/provider/enums/Provider.d.ts +2 -1
- package/bin/provider/enums/Provider.js +1 -0
- package/bin/remittance/dtos/RemittancePayRequest.d.ts +20 -0
- package/bin/remittance/dtos/RemittancePayRequest.js +43 -0
- package/bin/remittance/dtos/RemittancePayResponse.d.ts +23 -0
- package/bin/remittance/dtos/RemittancePayResponse.js +14 -0
- package/bin/remittance/dtos/index.d.ts +2 -0
- package/bin/remittance/dtos/index.js +2 -0
- package/package.json +1 -1
- package/src/cognitoBackofficeConnector/dtos/InitiateAuthRequest.ts +12 -12
- package/src/cognitoBackofficeConnector/dtos/IntrospectRequest.ts +10 -10
- package/src/cognitoBackofficeConnector/dtos/IntrospectResponse.ts +10 -10
- package/src/cognitoBackofficeConnector/dtos/VerifyPasswordRequest.ts +15 -15
- package/src/cognitoBackofficeConnector/dtos/VerifyPasswordResponse.ts +6 -6
- package/src/cognitoBackofficeConnector/enums/CognitoChallengeType.ts +24 -24
- package/src/cognitoBackofficeConnector/enums/IntrospectFailReason.ts +11 -11
- package/src/mdm/README.md +78 -78
- package/src/mdm/dtos/DeviceArchiveRequest.ts +14 -14
- package/src/mdm/dtos/DeviceArchiveResponse.ts +10 -10
- package/src/mdm/dtos/DeviceAutoLockScheduleRequest.ts +18 -18
- package/src/mdm/dtos/DeviceAutoLockScheduleResponse.ts +10 -10
- package/src/mdm/dtos/DeviceEnrollInitiateResponse.ts +9 -9
- package/src/mdm/dtos/DeviceEnrollRequest.ts +38 -38
- package/src/mdm/dtos/DeviceEnrollStatusRequest.ts +14 -14
- package/src/mdm/dtos/DeviceEnrollStatusResponse.ts +15 -15
- package/src/mdm/dtos/DeviceEnrollmentCompletedEvent.ts +8 -8
- package/src/mdm/dtos/DeviceLastSeenRequest.ts +9 -9
- package/src/mdm/dtos/DeviceLastSeenResponse.ts +9 -9
- package/src/mdm/dtos/DeviceLockRequest.ts +46 -46
- package/src/mdm/dtos/DeviceLockResponse.ts +12 -12
- package/src/mdm/dtos/DeviceLockScreenMessage.ts +14 -14
- package/src/mdm/dtos/DeviceLogEntry.ts +5 -5
- package/src/mdm/dtos/DeviceLogRequest.ts +19 -19
- package/src/mdm/dtos/DeviceLogResponse.ts +10 -10
- package/src/mdm/dtos/DeviceNotifyRequest.ts +47 -47
- package/src/mdm/dtos/DeviceNotifyResponse.ts +10 -10
- package/src/mdm/dtos/DevicePinUnlockRequest.ts +19 -19
- package/src/mdm/dtos/DevicePinUnlockResponse.ts +12 -12
- package/src/mdm/dtos/DeviceReleaseCompletedEvent.ts +6 -6
- package/src/mdm/dtos/DeviceReleaseInitiateResponse.ts +10 -10
- package/src/mdm/dtos/DeviceReleaseRequest.ts +24 -24
- package/src/mdm/dtos/DeviceReleaseStatusRequest.ts +14 -14
- package/src/mdm/dtos/DeviceReleaseStatusResponse.ts +10 -10
- package/src/mdm/dtos/DeviceRestrictAppsRequest.ts +19 -19
- package/src/mdm/dtos/DeviceRestrictAppsResponse.ts +10 -10
- package/src/mdm/dtos/DeviceServiceDeactivateInitiateResponse.ts +9 -9
- package/src/mdm/dtos/DeviceServiceDeactivateRequest.ts +19 -19
- package/src/mdm/dtos/DeviceServiceDeactivateStatusRequest.ts +14 -14
- package/src/mdm/dtos/DeviceServiceDeactivateStatusResponse.ts +10 -10
- package/src/mdm/dtos/DeviceStatusRequest.ts +9 -9
- package/src/mdm/dtos/DeviceStatusResponse.ts +16 -16
- package/src/mdm/dtos/DeviceUnlockRequest.ts +14 -14
- package/src/mdm/dtos/DeviceUnlockResponse.ts +10 -10
- package/src/mdm/dtos/MdmError.ts +7 -7
- package/src/mdm/enums/DeviceEnrollmentModeEnum.ts +4 -4
- package/src/mdm/enums/DeviceLockModeEnum.ts +4 -4
- package/src/mdm/enums/DeviceNotifyIntensityEnum.ts +4 -4
- package/src/mdm/enums/DeviceReleaseReasonEnum.ts +5 -5
- package/src/mdm/enums/DeviceServiceDeactivateReasonEnum.ts +5 -5
- package/src/mdm/enums/MdmDeviceStatusEnum.ts +10 -10
- package/src/mdm/enums/MdmErrorCodeEnum.ts +17 -17
- package/src/mdm/enums/MdmOperationStatusEnum.ts +5 -5
- package/src/mdm/enums/MdmOperationTypeEnum.ts +15 -15
- package/src/mdm/enums/MdmProviderEnum.ts +4 -4
- package/src/mdm/index.ts +60 -60
- package/src/messagesConnector/dtos/MessagesByDestinationResponse.ts +5 -5
- package/src/messagesConnector/dtos/NotificationQueueMessageRequestV2.ts +54 -54
- package/src/messagesConnector/dtos/NotificationResponse.ts +19 -19
- package/src/messagesConnector/dtos/NotificationsCursorResponse.ts +6 -6
- package/src/messagesConnector/dtos/NotificationsPageResponse.ts +10 -10
- package/src/messagesConnector/dtos/NotificationsV3Response.ts +5 -5
- package/src/messagesConnector/dtos/OtpValidatedResponse.ts +9 -9
- package/src/messagesConnector/dtos/SendMessageResponse.ts +10 -10
- package/src/messagesConnector/dtos/TemplateMessageCreateRequest.ts +51 -51
- package/src/messagesConnector/dtos/TemplateMessageListFiltersRequest.ts +47 -47
- package/src/messagesConnector/dtos/TemplateMessageListResponse.ts +16 -16
- package/src/messagesConnector/dtos/TemplateMessageResponse.ts +52 -52
- package/src/messagesConnector/dtos/TemplateMessageUpdateRequest.ts +39 -39
- package/src/messagesConnector/dtos/VerifyOtpResponse.ts +5 -5
- package/src/messagesConnector/enums/DeliveryChannelExtendedEnum.ts +5 -5
- package/src/messagesConnector/validators/IsStringValueRecord.ts +12 -12
- package/src/messagesConnector/validators/IsTemplatePlaceholders.ts +45 -45
- package/src/messaging/dtos/MessageDeliveryRequest.ts +29 -29
- package/src/messaging/dtos/MessageDeliveryResponse.ts +6 -6
- package/src/messaging/enums/ContentTypeEnum.ts +4 -4
- package/src/messaging/enums/DeliveryChannelEnum.ts +4 -4
- package/src/messaging/index.ts +6 -6
- package/src/messaging/validators/IsDestinationByChannel.ts +61 -61
- package/src/messaging/validators/IsNotBlank.ts +31 -31
- package/src/platformRbac/auth/DefineNextChallengeRequest.ts +25 -25
- package/src/platformRbac/auth/DefineNextChallengeResponse.ts +14 -14
- package/src/platformRbac/auth/NewPasswordRequest.ts +10 -10
- package/src/platformRbac/auth/PrepareChallengeRequest.ts +13 -13
- package/src/platformRbac/auth/PrepareChallengeResponse.ts +9 -9
- package/src/platformRbac/auth/ResetPasswordRequest.ts +14 -14
- package/src/platformRbac/auth/VerifyChallengeRequest.ts +16 -16
- package/src/platformRbac/auth/VerifyChallengeResponse.ts +6 -6
- package/src/platformRbac/dtos/AuthorizeRequest.ts +14 -14
- package/src/platformRbac/dtos/AuthorizeResponse.ts +16 -16
- package/src/platformRbac/enums/AuthorizeDenyReason.ts +10 -10
- package/src/platformRbac/enums/ChallengeNameEnum.ts +7 -7
- package/src/platformRbac/enums/MfaMethodEnum.ts +4 -4
- package/src/platformRbac/mfa/ChangeMfaMethodRequest.ts +10 -10
- package/src/platformRbac/mfa/EnrollTotpResponse.ts +12 -12
- package/src/platformRbac/mfa/MfaStatusResponse.ts +14 -14
- package/src/platformRbac/mfa/VerifyTotpEnrollmentRequest.ts +15 -7
- package/src/provider/enums/Provider.ts +2 -1
- package/src/remittance/dtos/RemittancePayRequest.ts +30 -0
- package/src/remittance/dtos/RemittancePayResponse.ts +24 -0
- package/src/remittance/dtos/index.ts +2 -0
package/src/mdm/README.md
CHANGED
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
# Dominio MDM — DTOs prototipo
|
|
2
|
-
|
|
3
|
-
> ⚠️ **TEMPORAL.** Estos archivos están aquí como prototipo. **Antes de usarlos en producción** deben moverse a `fiado-type-kit/src/mdm/` para no violar el anti-pattern `DTO_LOCAL` (los DTOs son contrato entre microservicios y no deben vivir locales al lambda).
|
|
4
|
-
|
|
5
|
-
## Qué es esto
|
|
6
|
-
|
|
7
|
-
DTOs y enums para el servicio MDM (Mobile Device Management) de SureKeep. Son agnósticos al proveedor — la misma forma sirve para Trustonic, Datacultr o cualquier otro proveedor que se integre en el futuro.
|
|
8
|
-
|
|
9
|
-
## Convenciones
|
|
10
|
-
|
|
11
|
-
Sigue el estándar `@fiado/type-kit`:
|
|
12
|
-
|
|
13
|
-
- **Idioma:** inglés (CamelCase para clases, camelCase para propiedades, UPPER_SNAKE_CASE para enums).
|
|
14
|
-
- **Forma:** clases, no `type` ni `interface`.
|
|
15
|
-
- **Request DTOs:** decoradores `@Expose()` de `class-transformer` + decoradores de `class-validator` (`@IsString`, `@IsEnum`, `@IsOptional`, etc.).
|
|
16
|
-
- **Response DTOs:** sin decoradores (los genera el backend).
|
|
17
|
-
- **Enums:** valores en `UPPER_SNAKE_CASE`.
|
|
18
|
-
|
|
19
|
-
## Estructura
|
|
20
|
-
|
|
21
|
-
```
|
|
22
|
-
mdm/
|
|
23
|
-
├── dtos/
|
|
24
|
-
│ ├── DeviceLockRequest.ts ← Request DTO con validación
|
|
25
|
-
│ ├── DeviceLockResponse.ts ← Response DTO sin validación
|
|
26
|
-
│ ├── DeviceLockScreenMessage.ts ← DTO compartido (nested)
|
|
27
|
-
│ ├── MdmError.ts ← Error tipado compartido
|
|
28
|
-
│ └── ...
|
|
29
|
-
├── enums/
|
|
30
|
-
│ ├── DeviceLockModeEnum.ts
|
|
31
|
-
│ ├── MdmDeviceStatusEnum.ts
|
|
32
|
-
│ └── ...
|
|
33
|
-
└── index.ts ← barrel export
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
## Uso temporal
|
|
37
|
-
|
|
38
|
-
```typescript
|
|
39
|
-
import { DeviceLockRequest } from "./mdm";
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
## Uso definitivo (cuando esté en el type-kit)
|
|
43
|
-
|
|
44
|
-
```typescript
|
|
45
|
-
import { DeviceLockRequest } from "@fiado/type-kit/bin/mdm";
|
|
46
|
-
// o como namespace:
|
|
47
|
-
import { Mdm } from "@fiado/type-kit";
|
|
48
|
-
```
|
|
49
|
-
|
|
50
|
-
## Acciones soportadas
|
|
51
|
-
|
|
52
|
-
| Acción | Trustonic | Datacultr |
|
|
53
|
-
|---|---|---|
|
|
54
|
-
| DeviceNotify | HEADSUP / FULLSCREEN | Notification (con `notification_code`) |
|
|
55
|
-
| DeviceRestrictApps | ⚠️ Por confirmar configuración | Nudge (App Block) |
|
|
56
|
-
| DeviceLock (FIRM) | Lock LOCK | Bulk Lock |
|
|
57
|
-
| DeviceLock (TEMPORARY) | Lock DIMISSABLE | ❌ Error: no soporta |
|
|
58
|
-
| DeviceUnlock | Unlock | Unlock |
|
|
59
|
-
| DevicePinUnlock | PIN Unlock | get_device_passcode |
|
|
60
|
-
| DeviceStatus | Device Info | Device Status by IMEI |
|
|
61
|
-
| DeviceEnroll | Upload + Activate (síncrono) | Registra y espera webhook |
|
|
62
|
-
| DeviceRelease | Release | Release |
|
|
63
|
-
| DeviceServiceDeactivate | Deactivate Service | ❌ Error: no soporta |
|
|
64
|
-
| DeviceArchive | Archive | ❌ Error: no soporta |
|
|
65
|
-
| DeviceAutoLockSchedule | ❌ Error: no soporta postpaid | Adhoc Auto Lock |
|
|
66
|
-
| DeviceLastSeen | (incluido en Device Info) | Device Last Seen |
|
|
67
|
-
| DeviceLog | ❌ Error: no expone | Device Log |
|
|
68
|
-
|
|
69
|
-
## Eventos entrantes (solo Datacultr)
|
|
70
|
-
|
|
71
|
-
- `DeviceEnrollmentCompletedEvent` — Enrollment Webhook
|
|
72
|
-
- `DeviceReleaseCompletedEvent` — Release Webhook
|
|
73
|
-
|
|
74
|
-
Trustonic no emite webhooks (según el PDF oficial v2.0.1). Para Trustonic se debe pollear `Upload Status` y `Device Info`.
|
|
75
|
-
|
|
76
|
-
---
|
|
77
|
-
|
|
78
|
-
*Mantenido en este repo solo como prototipo. Subir al `fiado-type-kit` antes de producción.*
|
|
1
|
+
# Dominio MDM — DTOs prototipo
|
|
2
|
+
|
|
3
|
+
> ⚠️ **TEMPORAL.** Estos archivos están aquí como prototipo. **Antes de usarlos en producción** deben moverse a `fiado-type-kit/src/mdm/` para no violar el anti-pattern `DTO_LOCAL` (los DTOs son contrato entre microservicios y no deben vivir locales al lambda).
|
|
4
|
+
|
|
5
|
+
## Qué es esto
|
|
6
|
+
|
|
7
|
+
DTOs y enums para el servicio MDM (Mobile Device Management) de SureKeep. Son agnósticos al proveedor — la misma forma sirve para Trustonic, Datacultr o cualquier otro proveedor que se integre en el futuro.
|
|
8
|
+
|
|
9
|
+
## Convenciones
|
|
10
|
+
|
|
11
|
+
Sigue el estándar `@fiado/type-kit`:
|
|
12
|
+
|
|
13
|
+
- **Idioma:** inglés (CamelCase para clases, camelCase para propiedades, UPPER_SNAKE_CASE para enums).
|
|
14
|
+
- **Forma:** clases, no `type` ni `interface`.
|
|
15
|
+
- **Request DTOs:** decoradores `@Expose()` de `class-transformer` + decoradores de `class-validator` (`@IsString`, `@IsEnum`, `@IsOptional`, etc.).
|
|
16
|
+
- **Response DTOs:** sin decoradores (los genera el backend).
|
|
17
|
+
- **Enums:** valores en `UPPER_SNAKE_CASE`.
|
|
18
|
+
|
|
19
|
+
## Estructura
|
|
20
|
+
|
|
21
|
+
```
|
|
22
|
+
mdm/
|
|
23
|
+
├── dtos/
|
|
24
|
+
│ ├── DeviceLockRequest.ts ← Request DTO con validación
|
|
25
|
+
│ ├── DeviceLockResponse.ts ← Response DTO sin validación
|
|
26
|
+
│ ├── DeviceLockScreenMessage.ts ← DTO compartido (nested)
|
|
27
|
+
│ ├── MdmError.ts ← Error tipado compartido
|
|
28
|
+
│ └── ...
|
|
29
|
+
├── enums/
|
|
30
|
+
│ ├── DeviceLockModeEnum.ts
|
|
31
|
+
│ ├── MdmDeviceStatusEnum.ts
|
|
32
|
+
│ └── ...
|
|
33
|
+
└── index.ts ← barrel export
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## Uso temporal
|
|
37
|
+
|
|
38
|
+
```typescript
|
|
39
|
+
import { DeviceLockRequest } from "./mdm";
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Uso definitivo (cuando esté en el type-kit)
|
|
43
|
+
|
|
44
|
+
```typescript
|
|
45
|
+
import { DeviceLockRequest } from "@fiado/type-kit/bin/mdm";
|
|
46
|
+
// o como namespace:
|
|
47
|
+
import { Mdm } from "@fiado/type-kit";
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## Acciones soportadas
|
|
51
|
+
|
|
52
|
+
| Acción | Trustonic | Datacultr |
|
|
53
|
+
|---|---|---|
|
|
54
|
+
| DeviceNotify | HEADSUP / FULLSCREEN | Notification (con `notification_code`) |
|
|
55
|
+
| DeviceRestrictApps | ⚠️ Por confirmar configuración | Nudge (App Block) |
|
|
56
|
+
| DeviceLock (FIRM) | Lock LOCK | Bulk Lock |
|
|
57
|
+
| DeviceLock (TEMPORARY) | Lock DIMISSABLE | ❌ Error: no soporta |
|
|
58
|
+
| DeviceUnlock | Unlock | Unlock |
|
|
59
|
+
| DevicePinUnlock | PIN Unlock | get_device_passcode |
|
|
60
|
+
| DeviceStatus | Device Info | Device Status by IMEI |
|
|
61
|
+
| DeviceEnroll | Upload + Activate (síncrono) | Registra y espera webhook |
|
|
62
|
+
| DeviceRelease | Release | Release |
|
|
63
|
+
| DeviceServiceDeactivate | Deactivate Service | ❌ Error: no soporta |
|
|
64
|
+
| DeviceArchive | Archive | ❌ Error: no soporta |
|
|
65
|
+
| DeviceAutoLockSchedule | ❌ Error: no soporta postpaid | Adhoc Auto Lock |
|
|
66
|
+
| DeviceLastSeen | (incluido en Device Info) | Device Last Seen |
|
|
67
|
+
| DeviceLog | ❌ Error: no expone | Device Log |
|
|
68
|
+
|
|
69
|
+
## Eventos entrantes (solo Datacultr)
|
|
70
|
+
|
|
71
|
+
- `DeviceEnrollmentCompletedEvent` — Enrollment Webhook
|
|
72
|
+
- `DeviceReleaseCompletedEvent` — Release Webhook
|
|
73
|
+
|
|
74
|
+
Trustonic no emite webhooks (según el PDF oficial v2.0.1). Para Trustonic se debe pollear `Upload Status` y `Device Info`.
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
*Mantenido en este repo solo como prototipo. Subir al `fiado-type-kit` antes de producción.*
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Expose } from "class-transformer";
|
|
2
|
-
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
-
|
|
4
|
-
export class DeviceArchiveRequest {
|
|
5
|
-
@Expose()
|
|
6
|
-
@IsString()
|
|
7
|
-
@IsNotEmpty()
|
|
8
|
-
imei: string;
|
|
9
|
-
|
|
10
|
-
@Expose()
|
|
11
|
-
@IsString()
|
|
12
|
-
@IsNotEmpty()
|
|
13
|
-
operationReference: string;
|
|
14
|
-
}
|
|
1
|
+
import { Expose } from "class-transformer";
|
|
2
|
+
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
+
|
|
4
|
+
export class DeviceArchiveRequest {
|
|
5
|
+
@Expose()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
imei: string;
|
|
9
|
+
|
|
10
|
+
@Expose()
|
|
11
|
+
@IsString()
|
|
12
|
+
@IsNotEmpty()
|
|
13
|
+
operationReference: string;
|
|
14
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
-
import { MdmError } from "./MdmError";
|
|
3
|
-
|
|
4
|
-
export class DeviceArchiveResponse {
|
|
5
|
-
imei: string;
|
|
6
|
-
operationReference: string;
|
|
7
|
-
status: MdmOperationStatusEnum;
|
|
8
|
-
archivedAt?: string;
|
|
9
|
-
error?: MdmError;
|
|
10
|
-
}
|
|
1
|
+
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
+
import { MdmError } from "./MdmError";
|
|
3
|
+
|
|
4
|
+
export class DeviceArchiveResponse {
|
|
5
|
+
imei: string;
|
|
6
|
+
operationReference: string;
|
|
7
|
+
status: MdmOperationStatusEnum;
|
|
8
|
+
archivedAt?: string;
|
|
9
|
+
error?: MdmError;
|
|
10
|
+
}
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { Expose } from "class-transformer";
|
|
2
|
-
import { IsString, IsNotEmpty, IsISO8601 } from "class-validator";
|
|
3
|
-
|
|
4
|
-
export class DeviceAutoLockScheduleRequest {
|
|
5
|
-
@Expose()
|
|
6
|
-
@IsString()
|
|
7
|
-
@IsNotEmpty()
|
|
8
|
-
imei: string;
|
|
9
|
-
|
|
10
|
-
@Expose()
|
|
11
|
-
@IsISO8601()
|
|
12
|
-
lockAt: string;
|
|
13
|
-
|
|
14
|
-
@Expose()
|
|
15
|
-
@IsString()
|
|
16
|
-
@IsNotEmpty()
|
|
17
|
-
operationReference: string;
|
|
18
|
-
}
|
|
1
|
+
import { Expose } from "class-transformer";
|
|
2
|
+
import { IsString, IsNotEmpty, IsISO8601 } from "class-validator";
|
|
3
|
+
|
|
4
|
+
export class DeviceAutoLockScheduleRequest {
|
|
5
|
+
@Expose()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
imei: string;
|
|
9
|
+
|
|
10
|
+
@Expose()
|
|
11
|
+
@IsISO8601()
|
|
12
|
+
lockAt: string;
|
|
13
|
+
|
|
14
|
+
@Expose()
|
|
15
|
+
@IsString()
|
|
16
|
+
@IsNotEmpty()
|
|
17
|
+
operationReference: string;
|
|
18
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
-
import { MdmError } from "./MdmError";
|
|
3
|
-
|
|
4
|
-
export class DeviceAutoLockScheduleResponse {
|
|
5
|
-
imei: string;
|
|
6
|
-
operationReference: string;
|
|
7
|
-
status: MdmOperationStatusEnum;
|
|
8
|
-
scheduledFor?: string;
|
|
9
|
-
error?: MdmError;
|
|
10
|
-
}
|
|
1
|
+
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
+
import { MdmError } from "./MdmError";
|
|
3
|
+
|
|
4
|
+
export class DeviceAutoLockScheduleResponse {
|
|
5
|
+
imei: string;
|
|
6
|
+
operationReference: string;
|
|
7
|
+
status: MdmOperationStatusEnum;
|
|
8
|
+
scheduledFor?: string;
|
|
9
|
+
error?: MdmError;
|
|
10
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
-
import { MdmError } from "./MdmError";
|
|
3
|
-
|
|
4
|
-
export class DeviceEnrollInitiateResponse {
|
|
5
|
-
imei: string;
|
|
6
|
-
operationReference: string;
|
|
7
|
-
status: MdmOperationStatusEnum;
|
|
8
|
-
error?: MdmError;
|
|
9
|
-
}
|
|
1
|
+
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
+
import { MdmError } from "./MdmError";
|
|
3
|
+
|
|
4
|
+
export class DeviceEnrollInitiateResponse {
|
|
5
|
+
imei: string;
|
|
6
|
+
operationReference: string;
|
|
7
|
+
status: MdmOperationStatusEnum;
|
|
8
|
+
error?: MdmError;
|
|
9
|
+
}
|
|
@@ -1,38 +1,38 @@
|
|
|
1
|
-
import { Expose } from "class-transformer";
|
|
2
|
-
import { IsString, IsNotEmpty, IsOptional, IsNumber, IsPositive, IsUUID } from "class-validator";
|
|
3
|
-
|
|
4
|
-
export class DeviceEnrollRequest {
|
|
5
|
-
@Expose()
|
|
6
|
-
@IsString()
|
|
7
|
-
@IsNotEmpty()
|
|
8
|
-
imei: string;
|
|
9
|
-
|
|
10
|
-
@Expose()
|
|
11
|
-
@IsString()
|
|
12
|
-
@IsOptional()
|
|
13
|
-
imei2?: string;
|
|
14
|
-
|
|
15
|
-
@Expose()
|
|
16
|
-
@IsString()
|
|
17
|
-
@IsOptional()
|
|
18
|
-
brand?: string;
|
|
19
|
-
|
|
20
|
-
@Expose()
|
|
21
|
-
@IsString()
|
|
22
|
-
@IsOptional()
|
|
23
|
-
model?: string;
|
|
24
|
-
|
|
25
|
-
@Expose()
|
|
26
|
-
@IsUUID()
|
|
27
|
-
creditId: string;
|
|
28
|
-
|
|
29
|
-
@Expose()
|
|
30
|
-
@IsNumber()
|
|
31
|
-
@IsPositive()
|
|
32
|
-
termMonths: number;
|
|
33
|
-
|
|
34
|
-
@Expose()
|
|
35
|
-
@IsString()
|
|
36
|
-
@IsNotEmpty()
|
|
37
|
-
operationReference: string;
|
|
38
|
-
}
|
|
1
|
+
import { Expose } from "class-transformer";
|
|
2
|
+
import { IsString, IsNotEmpty, IsOptional, IsNumber, IsPositive, IsUUID } from "class-validator";
|
|
3
|
+
|
|
4
|
+
export class DeviceEnrollRequest {
|
|
5
|
+
@Expose()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
imei: string;
|
|
9
|
+
|
|
10
|
+
@Expose()
|
|
11
|
+
@IsString()
|
|
12
|
+
@IsOptional()
|
|
13
|
+
imei2?: string;
|
|
14
|
+
|
|
15
|
+
@Expose()
|
|
16
|
+
@IsString()
|
|
17
|
+
@IsOptional()
|
|
18
|
+
brand?: string;
|
|
19
|
+
|
|
20
|
+
@Expose()
|
|
21
|
+
@IsString()
|
|
22
|
+
@IsOptional()
|
|
23
|
+
model?: string;
|
|
24
|
+
|
|
25
|
+
@Expose()
|
|
26
|
+
@IsUUID()
|
|
27
|
+
creditId: string;
|
|
28
|
+
|
|
29
|
+
@Expose()
|
|
30
|
+
@IsNumber()
|
|
31
|
+
@IsPositive()
|
|
32
|
+
termMonths: number;
|
|
33
|
+
|
|
34
|
+
@Expose()
|
|
35
|
+
@IsString()
|
|
36
|
+
@IsNotEmpty()
|
|
37
|
+
operationReference: string;
|
|
38
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Expose } from "class-transformer";
|
|
2
|
-
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
-
|
|
4
|
-
export class DeviceEnrollStatusRequest {
|
|
5
|
-
@Expose()
|
|
6
|
-
@IsString()
|
|
7
|
-
@IsNotEmpty()
|
|
8
|
-
imei: string;
|
|
9
|
-
|
|
10
|
-
@Expose()
|
|
11
|
-
@IsString()
|
|
12
|
-
@IsNotEmpty()
|
|
13
|
-
operationReference: string;
|
|
14
|
-
}
|
|
1
|
+
import { Expose } from "class-transformer";
|
|
2
|
+
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
+
|
|
4
|
+
export class DeviceEnrollStatusRequest {
|
|
5
|
+
@Expose()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
imei: string;
|
|
9
|
+
|
|
10
|
+
@Expose()
|
|
11
|
+
@IsString()
|
|
12
|
+
@IsNotEmpty()
|
|
13
|
+
operationReference: string;
|
|
14
|
+
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
-
import { DeviceEnrollmentModeEnum } from "../enums/DeviceEnrollmentModeEnum";
|
|
3
|
-
import { MdmError } from "./MdmError";
|
|
4
|
-
|
|
5
|
-
export class DeviceEnrollStatusResponse {
|
|
6
|
-
imei: string;
|
|
7
|
-
operationReference: string;
|
|
8
|
-
status: MdmOperationStatusEnum;
|
|
9
|
-
enrolledAt?: string;
|
|
10
|
-
enrollmentMode?: DeviceEnrollmentModeEnum;
|
|
11
|
-
enrollmentId?: string;
|
|
12
|
-
brand?: string;
|
|
13
|
-
model?: string;
|
|
14
|
-
error?: MdmError;
|
|
15
|
-
}
|
|
1
|
+
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
+
import { DeviceEnrollmentModeEnum } from "../enums/DeviceEnrollmentModeEnum";
|
|
3
|
+
import { MdmError } from "./MdmError";
|
|
4
|
+
|
|
5
|
+
export class DeviceEnrollStatusResponse {
|
|
6
|
+
imei: string;
|
|
7
|
+
operationReference: string;
|
|
8
|
+
status: MdmOperationStatusEnum;
|
|
9
|
+
enrolledAt?: string;
|
|
10
|
+
enrollmentMode?: DeviceEnrollmentModeEnum;
|
|
11
|
+
enrollmentId?: string;
|
|
12
|
+
brand?: string;
|
|
13
|
+
model?: string;
|
|
14
|
+
error?: MdmError;
|
|
15
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export class DeviceEnrollmentCompletedEvent {
|
|
2
|
-
imei: string;
|
|
3
|
-
brand?: string;
|
|
4
|
-
model?: string;
|
|
5
|
-
enrolledAt: string;
|
|
6
|
-
successful: boolean;
|
|
7
|
-
provider: string;
|
|
8
|
-
}
|
|
1
|
+
export class DeviceEnrollmentCompletedEvent {
|
|
2
|
+
imei: string;
|
|
3
|
+
brand?: string;
|
|
4
|
+
model?: string;
|
|
5
|
+
enrolledAt: string;
|
|
6
|
+
successful: boolean;
|
|
7
|
+
provider: string;
|
|
8
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Expose } from "class-transformer";
|
|
2
|
-
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
-
|
|
4
|
-
export class DeviceLastSeenRequest {
|
|
5
|
-
@Expose()
|
|
6
|
-
@IsString()
|
|
7
|
-
@IsNotEmpty()
|
|
8
|
-
imei: string;
|
|
9
|
-
}
|
|
1
|
+
import { Expose } from "class-transformer";
|
|
2
|
+
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
+
|
|
4
|
+
export class DeviceLastSeenRequest {
|
|
5
|
+
@Expose()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
imei: string;
|
|
9
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
-
import { MdmError } from "./MdmError";
|
|
3
|
-
|
|
4
|
-
export class DeviceLastSeenResponse {
|
|
5
|
-
imei: string;
|
|
6
|
-
status: MdmOperationStatusEnum;
|
|
7
|
-
lastSeenAt?: string;
|
|
8
|
-
error?: MdmError;
|
|
9
|
-
}
|
|
1
|
+
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
2
|
+
import { MdmError } from "./MdmError";
|
|
3
|
+
|
|
4
|
+
export class DeviceLastSeenResponse {
|
|
5
|
+
imei: string;
|
|
6
|
+
status: MdmOperationStatusEnum;
|
|
7
|
+
lastSeenAt?: string;
|
|
8
|
+
error?: MdmError;
|
|
9
|
+
}
|
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
import { Expose, Type } from "class-transformer";
|
|
2
|
-
import {
|
|
3
|
-
IsString,
|
|
4
|
-
IsNotEmpty,
|
|
5
|
-
IsEnum,
|
|
6
|
-
IsOptional,
|
|
7
|
-
IsNumber,
|
|
8
|
-
IsPositive,
|
|
9
|
-
ValidateNested,
|
|
10
|
-
IsUrl
|
|
11
|
-
} from "class-validator";
|
|
12
|
-
import { DeviceLockModeEnum } from "../enums/DeviceLockModeEnum";
|
|
13
|
-
import { DeviceLockScreenMessage } from "./DeviceLockScreenMessage";
|
|
14
|
-
|
|
15
|
-
export class DeviceLockRequest {
|
|
16
|
-
@Expose()
|
|
17
|
-
@IsString()
|
|
18
|
-
@IsNotEmpty()
|
|
19
|
-
imei: string;
|
|
20
|
-
|
|
21
|
-
@Expose()
|
|
22
|
-
@IsEnum(DeviceLockModeEnum)
|
|
23
|
-
mode: DeviceLockModeEnum;
|
|
24
|
-
|
|
25
|
-
@Expose()
|
|
26
|
-
@IsNumber()
|
|
27
|
-
@IsPositive()
|
|
28
|
-
@IsOptional()
|
|
29
|
-
durationSeconds?: number;
|
|
30
|
-
|
|
31
|
-
@Expose()
|
|
32
|
-
@IsOptional()
|
|
33
|
-
@ValidateNested()
|
|
34
|
-
@Type(() => DeviceLockScreenMessage)
|
|
35
|
-
screenMessage?: DeviceLockScreenMessage;
|
|
36
|
-
|
|
37
|
-
@Expose()
|
|
38
|
-
@IsUrl()
|
|
39
|
-
@IsOptional()
|
|
40
|
-
paymentLink?: string;
|
|
41
|
-
|
|
42
|
-
@Expose()
|
|
43
|
-
@IsString()
|
|
44
|
-
@IsNotEmpty()
|
|
45
|
-
operationReference: string;
|
|
46
|
-
}
|
|
1
|
+
import { Expose, Type } from "class-transformer";
|
|
2
|
+
import {
|
|
3
|
+
IsString,
|
|
4
|
+
IsNotEmpty,
|
|
5
|
+
IsEnum,
|
|
6
|
+
IsOptional,
|
|
7
|
+
IsNumber,
|
|
8
|
+
IsPositive,
|
|
9
|
+
ValidateNested,
|
|
10
|
+
IsUrl
|
|
11
|
+
} from "class-validator";
|
|
12
|
+
import { DeviceLockModeEnum } from "../enums/DeviceLockModeEnum";
|
|
13
|
+
import { DeviceLockScreenMessage } from "./DeviceLockScreenMessage";
|
|
14
|
+
|
|
15
|
+
export class DeviceLockRequest {
|
|
16
|
+
@Expose()
|
|
17
|
+
@IsString()
|
|
18
|
+
@IsNotEmpty()
|
|
19
|
+
imei: string;
|
|
20
|
+
|
|
21
|
+
@Expose()
|
|
22
|
+
@IsEnum(DeviceLockModeEnum)
|
|
23
|
+
mode: DeviceLockModeEnum;
|
|
24
|
+
|
|
25
|
+
@Expose()
|
|
26
|
+
@IsNumber()
|
|
27
|
+
@IsPositive()
|
|
28
|
+
@IsOptional()
|
|
29
|
+
durationSeconds?: number;
|
|
30
|
+
|
|
31
|
+
@Expose()
|
|
32
|
+
@IsOptional()
|
|
33
|
+
@ValidateNested()
|
|
34
|
+
@Type(() => DeviceLockScreenMessage)
|
|
35
|
+
screenMessage?: DeviceLockScreenMessage;
|
|
36
|
+
|
|
37
|
+
@Expose()
|
|
38
|
+
@IsUrl()
|
|
39
|
+
@IsOptional()
|
|
40
|
+
paymentLink?: string;
|
|
41
|
+
|
|
42
|
+
@Expose()
|
|
43
|
+
@IsString()
|
|
44
|
+
@IsNotEmpty()
|
|
45
|
+
operationReference: string;
|
|
46
|
+
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { DeviceLockModeEnum } from "../enums/DeviceLockModeEnum";
|
|
2
|
-
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
3
|
-
import { MdmError } from "./MdmError";
|
|
4
|
-
|
|
5
|
-
export class DeviceLockResponse {
|
|
6
|
-
imei: string;
|
|
7
|
-
operationReference: string;
|
|
8
|
-
status: MdmOperationStatusEnum;
|
|
9
|
-
lockedAt?: string;
|
|
10
|
-
appliedMode?: DeviceLockModeEnum;
|
|
11
|
-
error?: MdmError;
|
|
12
|
-
}
|
|
1
|
+
import { DeviceLockModeEnum } from "../enums/DeviceLockModeEnum";
|
|
2
|
+
import { MdmOperationStatusEnum } from "../enums/MdmOperationStatusEnum";
|
|
3
|
+
import { MdmError } from "./MdmError";
|
|
4
|
+
|
|
5
|
+
export class DeviceLockResponse {
|
|
6
|
+
imei: string;
|
|
7
|
+
operationReference: string;
|
|
8
|
+
status: MdmOperationStatusEnum;
|
|
9
|
+
lockedAt?: string;
|
|
10
|
+
appliedMode?: DeviceLockModeEnum;
|
|
11
|
+
error?: MdmError;
|
|
12
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Expose } from "class-transformer";
|
|
2
|
-
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
-
|
|
4
|
-
export class DeviceLockScreenMessage {
|
|
5
|
-
@Expose()
|
|
6
|
-
@IsString()
|
|
7
|
-
@IsNotEmpty()
|
|
8
|
-
title: string;
|
|
9
|
-
|
|
10
|
-
@Expose()
|
|
11
|
-
@IsString()
|
|
12
|
-
@IsNotEmpty()
|
|
13
|
-
content: string;
|
|
14
|
-
}
|
|
1
|
+
import { Expose } from "class-transformer";
|
|
2
|
+
import { IsString, IsNotEmpty } from "class-validator";
|
|
3
|
+
|
|
4
|
+
export class DeviceLockScreenMessage {
|
|
5
|
+
@Expose()
|
|
6
|
+
@IsString()
|
|
7
|
+
@IsNotEmpty()
|
|
8
|
+
title: string;
|
|
9
|
+
|
|
10
|
+
@Expose()
|
|
11
|
+
@IsString()
|
|
12
|
+
@IsNotEmpty()
|
|
13
|
+
content: string;
|
|
14
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export class DeviceLogEntry {
|
|
2
|
-
occurredAt: string;
|
|
3
|
-
action: string;
|
|
4
|
-
state: string;
|
|
5
|
-
}
|
|
1
|
+
export class DeviceLogEntry {
|
|
2
|
+
occurredAt: string;
|
|
3
|
+
action: string;
|
|
4
|
+
state: string;
|
|
5
|
+
}
|