@veruna/api-contracts 1.0.32 → 1.0.33
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/build/rest-api.d.ts +2 -1
- package/build/rest-api.js +2 -1
- package/build/routes/users.routes.d.ts +0 -1
- package/build/routes/users.routes.js +0 -1
- package/build/routes/verification.routes.d.ts +2 -0
- package/build/routes/verification.routes.js +2 -0
- package/build/v1/users/queries/index.d.ts +0 -1
- package/build/v1/users/queries/index.js +0 -1
- package/build/v1/verification/commands/cancel-verification.command.d.ts +15 -0
- package/build/v1/verification/commands/cancel-verification.command.js +18 -0
- package/build/v1/verification/commands/index.d.ts +1 -0
- package/build/v1/verification/commands/index.js +1 -0
- package/build/v1/verification/index.d.ts +1 -0
- package/build/v1/verification/index.js +1 -0
- package/build/v1/{users → verification}/queries/get-active-verifications.query.d.ts +6 -6
- package/build/v1/verification/queries/get-active-verifications.query.js +16 -0
- package/build/v1/verification/queries/index.d.ts +1 -0
- package/build/v1/verification/queries/index.js +17 -0
- package/package.json +1 -1
- package/build/v1/users/queries/get-active-verifications.query.js +0 -16
package/build/rest-api.d.ts
CHANGED
|
@@ -36,7 +36,6 @@ export declare const REST_API: {
|
|
|
36
36
|
readonly STATUS: "/api/v1/users/me/password/change/status";
|
|
37
37
|
readonly COMPLETE: "/api/v1/users/me/password/change/complete";
|
|
38
38
|
};
|
|
39
|
-
readonly VERIFICATIONS_ACTIVE: "/api/v1/users/me/verifications/active";
|
|
40
39
|
};
|
|
41
40
|
readonly UNREG: {
|
|
42
41
|
readonly AUTHENTICATE: "/api/v1/unreg/";
|
|
@@ -136,6 +135,8 @@ export declare const REST_API: {
|
|
|
136
135
|
};
|
|
137
136
|
readonly VERIFICATION: {
|
|
138
137
|
readonly RESEND: "/api/v1/verification/resend";
|
|
138
|
+
readonly ACTIVE: "/api/v1/verification/active";
|
|
139
|
+
readonly CANCEL: (requestId: string) => string;
|
|
139
140
|
};
|
|
140
141
|
};
|
|
141
142
|
};
|
package/build/rest-api.js
CHANGED
|
@@ -43,7 +43,6 @@ exports.REST_API = {
|
|
|
43
43
|
STATUS: `${exports.ROOT}/${controllers_1.USERS_CONTROLLER}/${routes_1.USERS_ROUTES.PASSWORD_CHANGE_STATUS}`,
|
|
44
44
|
COMPLETE: `${exports.ROOT}/${controllers_1.USERS_CONTROLLER}/${routes_1.USERS_ROUTES.PASSWORD_CHANGE_COMPLETE}`,
|
|
45
45
|
},
|
|
46
|
-
VERIFICATIONS_ACTIVE: `${exports.ROOT}/${controllers_1.USERS_CONTROLLER}/${routes_1.USERS_ROUTES.VERIFICATIONS_ACTIVE}`,
|
|
47
46
|
},
|
|
48
47
|
// Unregistered Users
|
|
49
48
|
UNREG: {
|
|
@@ -153,6 +152,8 @@ exports.REST_API = {
|
|
|
153
152
|
},
|
|
154
153
|
VERIFICATION: {
|
|
155
154
|
RESEND: `${exports.ROOT}/${controllers_1.VERIFICATION_CONTROLLER}/${routes_1.VERIFICATION_ROUTES.RESEND}`,
|
|
155
|
+
ACTIVE: `${exports.ROOT}/${controllers_1.VERIFICATION_CONTROLLER}/${routes_1.VERIFICATION_ROUTES.ACTIVE}`,
|
|
156
|
+
CANCEL: (requestId) => `${exports.ROOT}/${controllers_1.VERIFICATION_CONTROLLER}/${requestId}/cancel`,
|
|
156
157
|
},
|
|
157
158
|
},
|
|
158
159
|
};
|
|
@@ -18,5 +18,4 @@ export declare const USERS_ROUTES: {
|
|
|
18
18
|
readonly PASSWORD_CHANGE_VERIFY: "me/password/change/verify";
|
|
19
19
|
readonly PASSWORD_CHANGE_STATUS: "me/password/change/status";
|
|
20
20
|
readonly PASSWORD_CHANGE_COMPLETE: "me/password/change/complete";
|
|
21
|
-
readonly VERIFICATIONS_ACTIVE: "me/verifications/active";
|
|
22
21
|
};
|
|
@@ -18,4 +18,3 @@ __exportStar(require("./get-current-user.query"), exports);
|
|
|
18
18
|
__exportStar(require("./email-change-status.query"), exports);
|
|
19
19
|
__exportStar(require("./delete-account-status.query"), exports);
|
|
20
20
|
__exportStar(require("./password-change-status.query"), exports);
|
|
21
|
-
__exportStar(require("./get-active-verifications.query"), exports);
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { HttpMethod } from '../../../shared/http-method';
|
|
3
|
+
export declare namespace CancelVerificationCommand {
|
|
4
|
+
const Request: z.ZodObject<{
|
|
5
|
+
requestId: z.ZodString;
|
|
6
|
+
}, z.core.$strip>;
|
|
7
|
+
const Response: z.ZodObject<{
|
|
8
|
+
requestId: z.ZodString;
|
|
9
|
+
cancelled: z.ZodBoolean;
|
|
10
|
+
}, z.core.$strip>;
|
|
11
|
+
const URL: (requestId: string) => string;
|
|
12
|
+
const METHOD = HttpMethod.POST;
|
|
13
|
+
type RequestType = z.infer<typeof Request>;
|
|
14
|
+
type ResponseType = z.infer<typeof Response>;
|
|
15
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CancelVerificationCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const http_method_1 = require("../../../shared/http-method");
|
|
6
|
+
const rest_api_1 = require("../../../rest-api");
|
|
7
|
+
var CancelVerificationCommand;
|
|
8
|
+
(function (CancelVerificationCommand) {
|
|
9
|
+
CancelVerificationCommand.Request = zod_1.z.object({
|
|
10
|
+
requestId: zod_1.z.string().uuid(),
|
|
11
|
+
});
|
|
12
|
+
CancelVerificationCommand.Response = zod_1.z.object({
|
|
13
|
+
requestId: zod_1.z.string(),
|
|
14
|
+
cancelled: zod_1.z.boolean(),
|
|
15
|
+
});
|
|
16
|
+
CancelVerificationCommand.URL = rest_api_1.REST_API.V1.VERIFICATION.CANCEL;
|
|
17
|
+
CancelVerificationCommand.METHOD = http_method_1.HttpMethod.POST;
|
|
18
|
+
})(CancelVerificationCommand || (exports.CancelVerificationCommand = CancelVerificationCommand = {}));
|
|
@@ -16,4 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
__exportStar(require("./verification.errors"), exports);
|
|
18
18
|
__exportStar(require("./commands"), exports);
|
|
19
|
+
__exportStar(require("./queries"), exports);
|
|
19
20
|
__exportStar(require("./schemas"), exports);
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { HttpMethod } from '../../../shared/http-method';
|
|
3
|
-
export declare namespace
|
|
3
|
+
export declare namespace GetActiveVerificationsQuery {
|
|
4
4
|
const Request: z.ZodObject<{}, z.core.$strip>;
|
|
5
5
|
const Response: z.ZodObject<{
|
|
6
6
|
verifications: z.ZodArray<z.ZodObject<{
|
|
7
7
|
requestId: z.ZodString;
|
|
8
|
-
type: z.ZodEnum<typeof import("
|
|
9
|
-
status: z.ZodEnum<typeof import("
|
|
8
|
+
type: z.ZodEnum<typeof import("..").VerificationType>;
|
|
9
|
+
status: z.ZodEnum<typeof import("..").VerificationRequestStatus>;
|
|
10
10
|
steps: z.ZodArray<z.ZodObject<{
|
|
11
11
|
stepId: z.ZodString;
|
|
12
|
-
channel: z.ZodEnum<typeof import("
|
|
12
|
+
channel: z.ZodEnum<typeof import("..").VerificationChannel>;
|
|
13
13
|
address: z.ZodString;
|
|
14
|
-
status: z.ZodEnum<typeof import("
|
|
14
|
+
status: z.ZodEnum<typeof import("..").VerificationStepStatus>;
|
|
15
15
|
}, z.core.$strip>>;
|
|
16
16
|
}, z.core.$strip>>;
|
|
17
17
|
}, z.core.$strip>;
|
|
18
|
-
const URL: "/api/v1/
|
|
18
|
+
const URL: "/api/v1/verification/active";
|
|
19
19
|
const METHOD = HttpMethod.GET;
|
|
20
20
|
type RequestType = z.infer<typeof Request>;
|
|
21
21
|
type ResponseType = z.infer<typeof Response>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.GetActiveVerificationsQuery = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const verification_status_response_schema_1 = require("../schemas/verification-status-response.schema");
|
|
6
|
+
const rest_api_1 = require("../../../rest-api");
|
|
7
|
+
const http_method_1 = require("../../../shared/http-method");
|
|
8
|
+
var GetActiveVerificationsQuery;
|
|
9
|
+
(function (GetActiveVerificationsQuery) {
|
|
10
|
+
GetActiveVerificationsQuery.Request = zod_1.z.object({});
|
|
11
|
+
GetActiveVerificationsQuery.Response = zod_1.z.object({
|
|
12
|
+
verifications: zod_1.z.array(verification_status_response_schema_1.VerificationStatusResponseSchema),
|
|
13
|
+
});
|
|
14
|
+
GetActiveVerificationsQuery.URL = rest_api_1.REST_API.V1.VERIFICATION.ACTIVE;
|
|
15
|
+
GetActiveVerificationsQuery.METHOD = http_method_1.HttpMethod.GET;
|
|
16
|
+
})(GetActiveVerificationsQuery || (exports.GetActiveVerificationsQuery = GetActiveVerificationsQuery = {}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './get-active-verifications.query';
|
|
@@ -0,0 +1,17 @@
|
|
|
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("./get-active-verifications.query"), exports);
|
package/package.json
CHANGED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UserGetActiveVerificationsQuery = void 0;
|
|
4
|
-
const zod_1 = require("zod");
|
|
5
|
-
const verification_status_response_schema_1 = require("../../verification/schemas/verification-status-response.schema");
|
|
6
|
-
const rest_api_1 = require("../../../rest-api");
|
|
7
|
-
const http_method_1 = require("../../../shared/http-method");
|
|
8
|
-
var UserGetActiveVerificationsQuery;
|
|
9
|
-
(function (UserGetActiveVerificationsQuery) {
|
|
10
|
-
UserGetActiveVerificationsQuery.Request = zod_1.z.object({});
|
|
11
|
-
UserGetActiveVerificationsQuery.Response = zod_1.z.object({
|
|
12
|
-
verifications: zod_1.z.array(verification_status_response_schema_1.VerificationStatusResponseSchema),
|
|
13
|
-
});
|
|
14
|
-
UserGetActiveVerificationsQuery.URL = rest_api_1.REST_API.V1.USERS.VERIFICATIONS_ACTIVE;
|
|
15
|
-
UserGetActiveVerificationsQuery.METHOD = http_method_1.HttpMethod.GET;
|
|
16
|
-
})(UserGetActiveVerificationsQuery || (exports.UserGetActiveVerificationsQuery = UserGetActiveVerificationsQuery = {}));
|