You've already forked npm-core-sdk
Latest generation
This commit is contained in:
208
user.ts
208
user.ts
@@ -151,6 +151,10 @@ export interface SendVerificationMailAsRequest {
|
||||
* @generated from protobuf field: string ProjectID = 4
|
||||
*/
|
||||
ProjectID: string; // The project ID the user is invited to, if any.
|
||||
/**
|
||||
* @generated from protobuf field: string SiteID = 5
|
||||
*/
|
||||
SiteID: string; // The site ID the user is invited to, if any.
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.EnrollUserProjectRequest
|
||||
@@ -177,6 +181,31 @@ export interface EnrollUserProjectRequest {
|
||||
*/
|
||||
ForceTwoFA: boolean;
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.EnrollUserSiteRequest
|
||||
*/
|
||||
export interface EnrollUserSiteRequest {
|
||||
/**
|
||||
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
||||
*/
|
||||
Header?: RequestSiteHeader;
|
||||
/**
|
||||
* @generated from protobuf field: string Mail = 2
|
||||
*/
|
||||
Mail: string;
|
||||
/**
|
||||
* The locale the user will be enrolled with following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
*
|
||||
* @generated from protobuf field: string locale = 3
|
||||
*/
|
||||
locale: string;
|
||||
/**
|
||||
* @generated from protobuf field: bool ForceTwoFA = 4
|
||||
*/
|
||||
ForceTwoFA: boolean;
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.SendVerificationMailProjectRequest
|
||||
*/
|
||||
@@ -884,6 +913,31 @@ export interface EnrollUserProjectWithoutMailRequest {
|
||||
*/
|
||||
ForceTwoFA: boolean;
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.EnrollUserSiteWithoutMailRequest
|
||||
*/
|
||||
export interface EnrollUserSiteWithoutMailRequest {
|
||||
/**
|
||||
* @generated from protobuf field: api.RequestSiteHeader Header = 1
|
||||
*/
|
||||
Header?: RequestSiteHeader;
|
||||
/**
|
||||
* @generated from protobuf field: string Mail = 2
|
||||
*/
|
||||
Mail: string;
|
||||
/**
|
||||
* The locale the user will be enrolled with following the specification defined at
|
||||
* http://www.rfc-editor.org/rfc/bcp/bcp47.txt.
|
||||
* Examples are: "en-US", "fr-CH", "es-MX"
|
||||
*
|
||||
* @generated from protobuf field: string locale = 3
|
||||
*/
|
||||
locale: string;
|
||||
/**
|
||||
* @generated from protobuf field: bool ForceTwoFA = 4
|
||||
*/
|
||||
ForceTwoFA: boolean;
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.UpdateTwoFAPlatformRequest
|
||||
*/
|
||||
@@ -1573,7 +1627,8 @@ class SendVerificationMailAsRequest$Type extends MessageType<SendVerificationMai
|
||||
{ no: 1, name: "SenderMail", kind: "scalar", localName: "SenderMail", jsonName: "SenderMail", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
||||
{ no: 2, name: "UserID", kind: "scalar", localName: "UserID", jsonName: "UserID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
||||
{ no: 3, name: "OrganisationID", kind: "scalar", localName: "OrganisationID", jsonName: "OrganisationID", T: 9 /*ScalarType.STRING*/ },
|
||||
{ no: 4, name: "ProjectID", kind: "scalar", localName: "ProjectID", jsonName: "ProjectID", T: 9 /*ScalarType.STRING*/ }
|
||||
{ no: 4, name: "ProjectID", kind: "scalar", localName: "ProjectID", jsonName: "ProjectID", T: 9 /*ScalarType.STRING*/ },
|
||||
{ no: 5, name: "SiteID", kind: "scalar", localName: "SiteID", jsonName: "SiteID", T: 9 /*ScalarType.STRING*/ }
|
||||
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["SenderMail", "UserID"] } } });
|
||||
}
|
||||
create(value?: PartialMessage<SendVerificationMailAsRequest>): SendVerificationMailAsRequest {
|
||||
@@ -1582,6 +1637,7 @@ class SendVerificationMailAsRequest$Type extends MessageType<SendVerificationMai
|
||||
message.UserID = "";
|
||||
message.OrganisationID = "";
|
||||
message.ProjectID = "";
|
||||
message.SiteID = "";
|
||||
if (value !== undefined)
|
||||
reflectionMergePartial<SendVerificationMailAsRequest>(this, message, value);
|
||||
return message;
|
||||
@@ -1603,6 +1659,9 @@ class SendVerificationMailAsRequest$Type extends MessageType<SendVerificationMai
|
||||
case /* string ProjectID */ 4:
|
||||
message.ProjectID = reader.string();
|
||||
break;
|
||||
case /* string SiteID */ 5:
|
||||
message.SiteID = reader.string();
|
||||
break;
|
||||
default:
|
||||
let u = options.readUnknownField;
|
||||
if (u === "throw")
|
||||
@@ -1627,6 +1686,9 @@ class SendVerificationMailAsRequest$Type extends MessageType<SendVerificationMai
|
||||
/* string ProjectID = 4; */
|
||||
if (message.ProjectID !== "")
|
||||
writer.tag(4, WireType.LengthDelimited).string(message.ProjectID);
|
||||
/* string SiteID = 5; */
|
||||
if (message.SiteID !== "")
|
||||
writer.tag(5, WireType.LengthDelimited).string(message.SiteID);
|
||||
let u = options.writeUnknownFields;
|
||||
if (u !== false)
|
||||
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
||||
@@ -1708,6 +1770,76 @@ class EnrollUserProjectRequest$Type extends MessageType<EnrollUserProjectRequest
|
||||
*/
|
||||
export const EnrollUserProjectRequest = new EnrollUserProjectRequest$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class EnrollUserSiteRequest$Type extends MessageType<EnrollUserSiteRequest> {
|
||||
constructor() {
|
||||
super("api.EnrollUserSiteRequest", [
|
||||
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } },
|
||||
{ no: 2, name: "Mail", kind: "scalar", localName: "Mail", jsonName: "Mail", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
||||
{ no: 3, name: "locale", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
||||
{ no: 4, name: "ForceTwoFA", kind: "scalar", localName: "ForceTwoFA", jsonName: "ForceTwoFA", T: 8 /*ScalarType.BOOL*/ }
|
||||
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "Mail"] } } });
|
||||
}
|
||||
create(value?: PartialMessage<EnrollUserSiteRequest>): EnrollUserSiteRequest {
|
||||
const message = globalThis.Object.create((this.messagePrototype!));
|
||||
message.Mail = "";
|
||||
message.locale = "";
|
||||
message.ForceTwoFA = false;
|
||||
if (value !== undefined)
|
||||
reflectionMergePartial<EnrollUserSiteRequest>(this, message, value);
|
||||
return message;
|
||||
}
|
||||
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: EnrollUserSiteRequest): EnrollUserSiteRequest {
|
||||
let message = target ?? this.create(), end = reader.pos + length;
|
||||
while (reader.pos < end) {
|
||||
let [fieldNo, wireType] = reader.tag();
|
||||
switch (fieldNo) {
|
||||
case /* api.RequestSiteHeader Header */ 1:
|
||||
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
||||
break;
|
||||
case /* string Mail */ 2:
|
||||
message.Mail = reader.string();
|
||||
break;
|
||||
case /* string locale */ 3:
|
||||
message.locale = reader.string();
|
||||
break;
|
||||
case /* bool ForceTwoFA */ 4:
|
||||
message.ForceTwoFA = reader.bool();
|
||||
break;
|
||||
default:
|
||||
let u = options.readUnknownField;
|
||||
if (u === "throw")
|
||||
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
||||
let d = reader.skip(wireType);
|
||||
if (u !== false)
|
||||
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
||||
}
|
||||
}
|
||||
return message;
|
||||
}
|
||||
internalBinaryWrite(message: EnrollUserSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
||||
/* api.RequestSiteHeader Header = 1; */
|
||||
if (message.Header)
|
||||
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
||||
/* string Mail = 2; */
|
||||
if (message.Mail !== "")
|
||||
writer.tag(2, WireType.LengthDelimited).string(message.Mail);
|
||||
/* string locale = 3; */
|
||||
if (message.locale !== "")
|
||||
writer.tag(3, WireType.LengthDelimited).string(message.locale);
|
||||
/* bool ForceTwoFA = 4; */
|
||||
if (message.ForceTwoFA !== false)
|
||||
writer.tag(4, WireType.Varint).bool(message.ForceTwoFA);
|
||||
let u = options.writeUnknownFields;
|
||||
if (u !== false)
|
||||
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
||||
return writer;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @generated MessageType for protobuf message api.EnrollUserSiteRequest
|
||||
*/
|
||||
export const EnrollUserSiteRequest = new EnrollUserSiteRequest$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class SendVerificationMailProjectRequest$Type extends MessageType<SendVerificationMailProjectRequest> {
|
||||
constructor() {
|
||||
super("api.SendVerificationMailProjectRequest", [
|
||||
@@ -4887,6 +5019,76 @@ class EnrollUserProjectWithoutMailRequest$Type extends MessageType<EnrollUserPro
|
||||
*/
|
||||
export const EnrollUserProjectWithoutMailRequest = new EnrollUserProjectWithoutMailRequest$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class EnrollUserSiteWithoutMailRequest$Type extends MessageType<EnrollUserSiteWithoutMailRequest> {
|
||||
constructor() {
|
||||
super("api.EnrollUserSiteWithoutMailRequest", [
|
||||
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } },
|
||||
{ no: 2, name: "Mail", kind: "scalar", localName: "Mail", jsonName: "Mail", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } },
|
||||
{ no: 3, name: "locale", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
||||
{ no: 4, name: "ForceTwoFA", kind: "scalar", localName: "ForceTwoFA", jsonName: "ForceTwoFA", T: 8 /*ScalarType.BOOL*/ }
|
||||
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "Mail"] } } });
|
||||
}
|
||||
create(value?: PartialMessage<EnrollUserSiteWithoutMailRequest>): EnrollUserSiteWithoutMailRequest {
|
||||
const message = globalThis.Object.create((this.messagePrototype!));
|
||||
message.Mail = "";
|
||||
message.locale = "";
|
||||
message.ForceTwoFA = false;
|
||||
if (value !== undefined)
|
||||
reflectionMergePartial<EnrollUserSiteWithoutMailRequest>(this, message, value);
|
||||
return message;
|
||||
}
|
||||
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: EnrollUserSiteWithoutMailRequest): EnrollUserSiteWithoutMailRequest {
|
||||
let message = target ?? this.create(), end = reader.pos + length;
|
||||
while (reader.pos < end) {
|
||||
let [fieldNo, wireType] = reader.tag();
|
||||
switch (fieldNo) {
|
||||
case /* api.RequestSiteHeader Header */ 1:
|
||||
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
||||
break;
|
||||
case /* string Mail */ 2:
|
||||
message.Mail = reader.string();
|
||||
break;
|
||||
case /* string locale */ 3:
|
||||
message.locale = reader.string();
|
||||
break;
|
||||
case /* bool ForceTwoFA */ 4:
|
||||
message.ForceTwoFA = reader.bool();
|
||||
break;
|
||||
default:
|
||||
let u = options.readUnknownField;
|
||||
if (u === "throw")
|
||||
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
||||
let d = reader.skip(wireType);
|
||||
if (u !== false)
|
||||
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
||||
}
|
||||
}
|
||||
return message;
|
||||
}
|
||||
internalBinaryWrite(message: EnrollUserSiteWithoutMailRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
||||
/* api.RequestSiteHeader Header = 1; */
|
||||
if (message.Header)
|
||||
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
||||
/* string Mail = 2; */
|
||||
if (message.Mail !== "")
|
||||
writer.tag(2, WireType.LengthDelimited).string(message.Mail);
|
||||
/* string locale = 3; */
|
||||
if (message.locale !== "")
|
||||
writer.tag(3, WireType.LengthDelimited).string(message.locale);
|
||||
/* bool ForceTwoFA = 4; */
|
||||
if (message.ForceTwoFA !== false)
|
||||
writer.tag(4, WireType.Varint).bool(message.ForceTwoFA);
|
||||
let u = options.writeUnknownFields;
|
||||
if (u !== false)
|
||||
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
||||
return writer;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @generated MessageType for protobuf message api.EnrollUserSiteWithoutMailRequest
|
||||
*/
|
||||
export const EnrollUserSiteWithoutMailRequest = new EnrollUserSiteWithoutMailRequest$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class UpdateTwoFAPlatformRequest$Type extends MessageType<UpdateTwoFAPlatformRequest> {
|
||||
constructor() {
|
||||
super("api.UpdateTwoFAPlatformRequest", [
|
||||
@@ -6055,6 +6257,8 @@ export const UserService = new ServiceType("api.UserService", [
|
||||
{ name: "SendVerificationMailAs", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Sends a verification mail to a user on the platform as another user" }, "api.rscType": "Platform", "api.roles": "Platform.Organisation-User", "google.api.method_visibility": { restriction: "INTERNAL" } }, I: SendVerificationMailAsRequest, O: SendVerificationMailResult },
|
||||
{ name: "EnrollProjectUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Enroll user on the platform" }, "api.rscType": "Project", "api.roles": "Platform.Project-User", "google.api.method_visibility": { restriction: "SDK" } }, I: EnrollUserProjectRequest, O: EnrollUserResult },
|
||||
{ name: "EnrollProjectUserWithoutMail", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Enroll user on the platform but do not send invitation email" }, "api.rscType": "Project", "api.roles": "Platform.Project-User", "google.api.method_visibility": { restriction: "SDK" } }, I: EnrollUserProjectWithoutMailRequest, O: EnrollUserResult },
|
||||
{ name: "EnrollSiteUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Enroll user on the platform" }, "api.rscType": "Site", "api.roles": "Platform.Site-User", "google.api.method_visibility": { restriction: "SDK" } }, I: EnrollUserSiteRequest, O: EnrollUserResult },
|
||||
{ name: "EnrollSiteUserWithoutMail", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Enroll user on the platform but do not send invitation email" }, "api.rscType": "Site", "api.roles": "Platform.Site-User", "google.api.method_visibility": { restriction: "SDK" } }, I: EnrollUserSiteWithoutMailRequest, O: EnrollUserResult },
|
||||
{ name: "SendVerificationMailProject", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Sends a verification mail to a user on the platform" }, "api.rscType": "Project", "api.roles": "Platform.Project-User", "google.api.method_visibility": { restriction: "SDK" } }, I: SendVerificationMailProjectRequest, O: SendVerificationMailResult },
|
||||
{ name: "RemoveUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Remove user from the platform" }, "api.rscType": "Platform", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: RemoveUserRequest, O: RemoveUserResult },
|
||||
{ name: "CreateSA", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Create Service Account on the platform" }, "api.rscType": "Organisation", "api.roles": "Platform.Organisation-User", "google.api.method_visibility": { restriction: "SDK" } }, I: CreateSARequest, O: CreateSAResult },
|
||||
@@ -6082,7 +6286,7 @@ export const UserService = new ServiceType("api.UserService", [
|
||||
{ name: "GetPlatformUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Get user details. The user must have at least a platform role." }, "api.rscType": "Platform", "api.roles": "Platform.User", "google.api.method_visibility": { restriction: "SDK" } }, I: GetPlatformUserRequest, O: GetPlatformUserResult },
|
||||
{ name: "GetOrganisationUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Get user details. The user must have at least an organisation role." }, "api.rscType": "Organisation", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: GetOrganisationUserRequest, O: GetOrganisationUserResult },
|
||||
{ name: "GetProjectUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Get user details. The user must have at least a project role." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: GetProjectUserRequest, O: GetProjectUserResult },
|
||||
{ name: "GetSiteUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Get user details. The user must have at least a Site role." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: GetSiteUserRequest, O: GetProjectUserResult },
|
||||
{ name: "GetSiteUser", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "Get user details. The user must have at least a Site role." }, "api.rscType": "Site", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: GetSiteUserRequest, O: GetSiteUserResult },
|
||||
{ name: "ListPlatformRoles", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "List Platform Roles of a user" }, "api.rscType": "Platform", "api.roles": "Platform.Platform-User", "google.api.method_visibility": { restriction: "SDK" } }, I: ListUserPlatformRolesRequest, O: ListUserPlatformRolesResult },
|
||||
{ name: "ListOrganisationRoles", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "List Organisation Roles of a user" }, "api.rscType": "Organisation", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: ListUserOrganisationRolesRequest, O: ListUserOrganisationRolesResult },
|
||||
{ name: "ListProjectRoles", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Admin User"], description: "List Project Roles of a user" }, "api.rscType": "Project", "api.roles": "Platform.Project-Role", "google.api.method_visibility": { restriction: "SDK" } }, I: ListUserProjectRolesRequest, O: ListUserProjectRolesResult },
|
||||
|
||||
Reference in New Issue
Block a user