MFASettings
- Table
- Protobuf
Description:
note
The protobuf file is the authoritative source of documentation. Please refer to the Protobuf tab when in doubt about field definitions, validation rules, or type specifications.
| Field | Type | Description | Required | Validation |
|---|---|---|---|---|
enabled_for_methods | string[] | No description available | No | None |
syntax = "proto3";
package meshtrade.iam.user.v1;
import "buf/validate/validate.proto";
option go_package = "github.com/meshtrade/api/go/iam/user/v1;user_v1";
option java_package = "co.meshtrade.api.iam.user.v1";
/*
A user in the IAM service.
Each User belongs to a specific group and has
defined roles that determine their permissions within that group.
*/
message User {
/*
The unique resource name for the user.
Format: users/{ULIDv2}.
This field is system-generated and immutable upon creation.
Any value provided on creation is ignored.
*/
string name = 1 [(buf.validate.field) = {
cel: {
id: "name.format.optional"
message: "name must be empty or in the format users/{ULIDv2}"
expression: "size(this) == 0 || this.matches('^users/[0123456789ABCDEFGHJKMNPQRSTVWXYZ]{26}$')"
}
}];
/*
The resource name of the parent group that owns this user.
This field is required on creation and establishes the direct ownership link.
Format: groups/{ULIDv2}.
*/
string owner = 2 [(buf.validate.field) = {
required: true
string: {
len: 33
pattern: "^groups/[0123456789ABCDEFGHJKMNPQRSTVWXYZ]{26}$"
}
}];
/*
Ownership hiearchy of groups that have access to this resource in the format groups/{group_id}.
System set on creation.
*/
repeated string owners = 3 [(buf.validate.field) = {
repeated: {
items: {
string: {
len: 33
pattern: "^groups/[0123456789ABCDEFGHJKMNPQRSTVWXYZ]{26}$"
}
}
}
}];
/*
The unique email address of this user.
This field is required on creation and must be a valid email format.
*/
string email = 4 [(buf.validate.field) = {
required: true
string: {email: true}
}];
/*
The mobile phone number of this user.
Used for multi-factor authentication, notifications, and contact purposes.
Format and validation defined by meshtrade.type.v1.MobileNumber.
*/
MobileNumber mobile_number = 5;
/*
Roles is a list of standard roles assigned to this user,
prepended by the name of the group in which they have been assigned that role.
e.g. groups/{ULIDv2}/roles/{role}, where role is a value of the meshtrade.iam.role.v1.Role enum.
*/
repeated string roles = 6 [(buf.validate.field) = {
repeated: {
items: {
string: {
min_len: 47
max_len: 48
pattern: "^groups/[0123456789ABCDEFGHJKMNPQRSTVWXYZ]{26}/roles/[1-9][0-9]{6,7}$"
}
}
}
}];
MFASettings mfa_settings = 7;
}
/*
The mobile phone number of this user.
Used for multi-factor authentication, notifications, and contact purposes.
*/
message MobileNumber {
/*
This is the actual Mobile Number that has been verified by the user
*/
string value = 1;
/*
This is set to true when the user has verified their number through the use of an OTP
*/
bool verified = 2;
/*
This is the reason a number for a user was reset
*/
string reset_reason = 3;
}
message MFASettings {
repeated string enabled_for_methods = 3;
}