diff --git a/protogen/docs/CONFIGURATION.tmpl b/protogen/docs/CONFIGURATION.tmpl new file mode 100644 index 0000000000..c180d7a56f --- /dev/null +++ b/protogen/docs/CONFIGURATION.tmpl @@ -0,0 +1,78 @@ +--- +title: "Configuration" +date: "{{ date "2006-01-02T15:04:05-0700" now }}" +weight: 20 +geekdocRepo: https://github.com/owncloud/ocis +geekdocEditPath: edit/master/accounts/templates +geekdocFilePath: CONFIGURATION.tmpl +--- +{{- define "options"}} +{{ $fnNames := (last . ).Flags -}} +{{ range $opt := first . }} +{{ range $fnName := $fnNames }}{{ with list $fnName $opt -}} +{{ $o := last . -}} +{{ if eq $o.FnName $fnName -}} +-{{ $o.Name }} | {{ range $i, $e := $o.Env }} {{ if $i }}, {{ end }}${{ $e }}{{ end }} +: {{ $o.Usage }}. {{- if $o.Default }} Default: `{{ $o.Default }}`.{{ end }} + +{{ end -}} +{{ end -}} +{{ end -}} +{{ end -}} +{{ end }} + +{{`{{< toc >}}`}} + +## Configuration + +### Configuration using config files + +Out of the box extensions will attempt to read configuration details from: + +```console +/etc/ocis +$HOME/.ocis +./config +``` + +For this configuration to be picked up, have a look at your extension `root` command and look for which default config name it has assigned. *i.e: ocis-accounts reads `accounts.json | yaml | toml ...`*. + +So far we support the file formats `JSON` and `YAML`, if you want to get a full example configuration just take a look at [our repository](https://github.com/owncloud/ocis/tree/master/accounts/config), there you can always see the latest configuration format. These example configurations include all available options and the default values. The configuration file will be automatically loaded if it's placed at `/etc/ocis/ocis.yml`, `${HOME}/.ocis/ocis.yml` or `$(pwd)/config/ocis.yml`. + +### Environment variables + +If you prefer to configure the service with environment variables you can see the available variables below. + +If multiple variables are listed for one option, they are in order of precedence. This means the leftmost variable will always win if given. + +### Command-line flags + +If you prefer to configure the service with command-line flags you can see the available variables below. Command line flags are only working when calling the subcommand directly. + +{{ $options := .Options -}} +{{ range $com := .Commands }}{{ with (list $options $com) -}} +{{ $c := last . -}} +{{ if eq $c.Name "accounts" -}} +## Root Command + +{{ $c.Usage }} + +Usage: `accounts [global options] command [command options] [arguments...]` +{{ template "options" . -}} +## Sub Commands + +{{ end -}} +{{ end -}} +{{ end -}} +{{- range $com := .Commands }}{{ with (list $options $com) -}} +{{- $c := last . }} +{{- if ne $c.Name "accounts" -}} +### accounts {{ $c.Name }} + +{{ $c.Usage }} + +Usage: `accounts {{ $c.Name }} [command options] [arguments...]` +{{ template "options" . }} +{{- end -}} +{{- end -}} +{{- end -}} diff --git a/protogen/docs/GRPC.tmpl b/protogen/docs/GRPC.tmpl new file mode 100644 index 0000000000..ca038092b7 --- /dev/null +++ b/protogen/docs/GRPC.tmpl @@ -0,0 +1,95 @@ +--- +title: "GRPC API" +date: 2018-05-02T00:00:00+00:00 +weight: 50 +geekdocRepo: https://github.com/owncloud/ocis-thumbnails +geekdocEditPath: edit/master/docs +geekdocFilePath: grpc.md +--- + +{{`{{< toc >}}`}} + +{{ range .Files -}} +{{ $filename := .Name }} +{{ $filenameParts := splitList "/" $filename }} +## {{ .Name }} + +{{ .Description }} +{{- range .Messages -}} +{{- /* remove newline */}}### {{ .LongName }} + +{{ .Description }} + +{{ if .HasFields -}} +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +{{ range .Fields -}} +{{- $loca := printf "#%s" (.LongType | lower | replace "." "") -}} +{{- if and (hasPrefix "ocis." .LongType) (ge (len $filenameParts) 3) -}} + {{- $rep := regexReplaceAll "[^/]+" (slice $filenameParts 1 (sub (len $filenameParts) 1) | join "/") ".." -}} + {{- $fieldDir := dir (.LongType | lower | replace "." "/") -}} + {{- $loca = printf "%s/%s/grpc.md#%s" $rep (substr 5 (len $fieldDir) $fieldDir) (.Type | lower | replace "." "") -}} +{{- end -}} +| {{.Name}} | [{{.LongType}}]({{ $loca }}) | {{.Label}} | {{nobr .Description}}{{if .DefaultValue}} Default: {{.DefaultValue}}{{end }} | +{{ end -}} +{{ end }} +{{ if .HasExtensions -}} +| Extension | Type | Base | Number | Description | +| --------- | ---- | ---- | ------ | ----------- | +{{ range .Extensions -}} +| {{.Name}} | {{.LongType}} | {{.ContainingLongType}} | {{.Number}} | {{nobr .Description}}{{if .DefaultValue}} Default: {{.DefaultValue}}{{end}} | +{{ end -}} +{{ end -}} +{{ end -}} +{{- range .Enums -}} +### {{ .LongName }} + +{{ .Description }} + +| Name | Number | Description | +| ---- | ------ | ----------- | +{{range .Values -}} +| {{.Name}} | {{.Number}} | {{nobr .Description}} | +{{ end -}} +{{ end -}} + +{{ if .HasExtensions }} + +### File-level Extensions +| Extension | Type | Base | Number | Description | +| --------- | ---- | ---- | ------ | ----------- | +{{ range .Extensions -}} +| {{.Name}} | {{.LongType}} | {{.ContainingLongType}} | {{.Number}} | {{nobr .Description}}{{if .DefaultValue}} Default: `{{.DefaultValue}}`{{end}} | +{{ end -}} +{{ end -}} +{{- range .Services }} +### {{ .Name }} + +{{ .Description }} + +| Method Name | Request Type | Response Type | Description | +| ----------- | ------------ | ------------- | ------------| +{{ range .Methods -}} +{{- $reqLoca := printf "#%s" (.RequestLongType | lower | replace "." "") -}} +{{- $respLoca := printf "#%s" (.ResponseLongType | lower | replace "." "") -}} +{{- if and (hasPrefix ".ocis." .RequestLongType) (ge (len $filenameParts) 3) }} + {{- $rep := regexReplaceAll "[^/]+" (slice $filenameParts 1 (sub (len $filenameParts) 1) | join "/") ".." -}} + {{- $reqDir := dir (.RequestLongType | lower | replace "." "/") -}} + {{- $reqLoca = printf "%s/%s/grpc.md#%s" $rep (substr 6 (len $reqDir) $reqDir) (.RequestType | lower | replace "." "") -}} +{{- end -}} +{{- if and (hasPrefix ".ocis." .ResponseLongType) (ge (len $filenameParts) 3) }} + {{- $rep := regexReplaceAll "[^/]+" (slice $filenameParts 1 (sub (len $filenameParts) 1) | join "/") ".." -}} + {{- $respDir := dir (.ResponseLongType | lower | replace "." "/") -}} + {{- $respLoca = printf "%s/%s/grpc.md#%s" $rep (substr 6 (len $respDir) $respDir) (.ResponseType | lower | replace "." "") -}} +{{- end -}} +| {{.Name}} | [{{.RequestLongType}}]({{ $reqLoca }}){{if .RequestStreaming}} stream{{end}} | [{{.ResponseLongType}}]({{ $respLoca }}){{if .ResponseStreaming}} stream{{end}} | {{nobr .Description}} | +{{ end -}} +{{ end -}} +{{ end }} +## Scalar Value Types + +| .proto Type | Notes | C++ | Java | +| ----------- | ----- | --- | ---- | +{{ range .Scalars -}} +| {{`{{< div id="`}}{{.ProtoType}}{{`" content="`}}{{.ProtoType}}{{`" >}}`}} | {{.Notes}} | {{.CppType}} | {{.JavaType}} | +{{ end }} diff --git a/protogen/docs/extensions/ocis/messages/accounts/v1/grpc.md b/protogen/docs/extensions/ocis/messages/accounts/v1/grpc.md new file mode 100644 index 0000000000..17b96362e7 --- /dev/null +++ b/protogen/docs/extensions/ocis/messages/accounts/v1/grpc.md @@ -0,0 +1,139 @@ +--- +title: "GRPC API" +date: 2018-05-02T00:00:00+00:00 +weight: 50 +geekdocRepo: https://github.com/owncloud/ocis-thumbnails +geekdocEditPath: edit/master/docs +geekdocFilePath: grpc.md +--- + +{{< toc >}} + + + +## ocis/messages/accounts/v1/accounts.proto + +### Account + +Account follows the properties of the ms graph api user resource. +See https://docs.microsoft.com/en-us/graph/api/resources/user?view=graph-rest-1.0#properties + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| id | [string](#string) | | The unique identifier for the user. Key. Not nullable. Non reassignable. Read-only. | +| account_enabled | [bool](#bool) | | true* if the account is enabled; otherwise, *false*. This property is required when a user is created. Supports $filter. | +| is_resource_account | [bool](#bool) | | A resource account is also known as a /disabled user object/ in Azure AD, and can be used to represent resources in general. In Exchange it might be used to represent conference rooms, for example, and allow them to have a phone number. You could give printers or machines with a sync client resource accounts as well. A resource account can be homed in Microsoft 365 or on premises using Skype for Business Server 2019. *true* if the user is a resource account; otherwise, *false*. Null value should be considered false. | +| creation_type | [string](#string) | | Indicates whether the account was created as - a regular school or work account ("" / emptystring), - a local account, fully managed by oCIS (LocalAccount), includes synced accounts or - an external account (Invitation), - self-service sign-up using email verification (EmailVerified). Read-only. | +| identities | [Identities](#identities) | repeated | Represents the identities that can be used to sign in to this account. An identity can be provided by oCIS (also known as a local account), by organizations, or by social identity providers such as Facebook, Google, and Microsoft, and is tied to an account. May contain multiple items with the same signInType value. Supports $filter. | +| display_name | [string](#string) | | The name displayed in the address book for the account. This is usually the combination of the user's first name, middle initial and last name. This property is required when a user is created and it cannot be cleared during updates. Supports $filter and $orderby. posixaccount MUST cn | +| preferred_name | [string](#string) | | The username posixaccount MUST uid | +| uid_number | [int64](#int64) | | TODO rename to on_premise_? or move to extension? see https://docs.microsoft.com/en-us/graph/extensibility-open-users used for exposing the user using ldap posixaccount MUST uidnumber | +| gid_number | [int64](#int64) | | used for exposing the user using ldap posixaccount MUST gidnumber | +| mail | [string](#string) | | The SMTP address for the user, for example, "jeff@contoso.onmicrosoft.com". Read-Only. Supports $filter. inetorgperson MAY mail | +| description | [string](#string) | | A description, useful for resource accounts posixaccount MAY description | +| password_profile | [PasswordProfile](#passwordprofile) | | Specifies the password profile for the user. The profile contains the user’s password. This property is required when a user is created. The password in the profile must satisfy minimum requirements as specified by the passwordPolicies property. By default, a strong password is required. posixaccount MAY authPassword | +| memberOf | [Group](#group) | repeated | The groups, directory roles and administrative units that the user is a member of. Read-only. Nullable. should we only respond with repeated strings of ids? no clients should a proper filter mask! | +| created_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | The created date of the account object. | +| deleted_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | The date and time the user was deleted. Returned only on $select. | +| on_premises_sync_enabled | [bool](#bool) | | true* if this object is synced from an on-premises directory; *false* if this object was originally synced from an on-premises directory but is no longer synced; null if this object has never been synced from an on-premises directory (default). Read-only | +| on_premises_immutable_id | [string](#string) | | This property is used to associate an on-premises LDAP user to the oCIS account object. This property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property. Important: The $ and _ characters cannot be used when specifying this property. Supports $filter. | +| on_premises_security_identifier | [string](#string) | | Contains the on-premises security identifier (SID) for the user that was synchronized from on-premises to the cloud. Read-only. | +| on_premises_distinguished_name | [string](#string) | | Contains the on-premises LDAP `distinguished name` or `DN`. The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. | +| on_premises_sam_account_name | [string](#string) | | Contains the on-premises `samAccountName` synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. | +| on_premises_domain_name | [string](#string) | | Contains the on-premises `domainFQDN`, also called `dnsDomainName` synchronized from the on-premises directory The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. | +| on_premises_user_principal_name | [string](#string) | | Contains the on-premises userPrincipalName synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. | +| on_premises_last_sync_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | Indicates the last time at which the object was synced with the on-premises directory; Read-only. | +| on_premises_provisioning_errors | [OnPremisesProvisioningError](#onpremisesprovisioningerror) | repeated | Errors when using synchronization during provisioning. | +| external_user_state | [string](#string) | | For an external user invited to the tenant using the invitation API, this property represents the invited user's invitation status. For invited users, the state can be `PendingAcceptance` or `Accepted`, or "" / emptystring for all other users. Returned only on $select. Supports $filter with the supported values. For example: $filter=externalUserState eq 'PendingAcceptance'. | +| external_user_state_change_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | Shows the timestamp for the latest change to the externalUserState property. Returned only on $select. | +| refresh_tokens_valid_from_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get an error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph). If this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint. Returned only on $select. Read-only. Use invalidateAllRefreshTokens to reset. | +| sign_in_sessions_valid_from_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get an error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph). If this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint. Read-only. Use revokeSignInSessions to reset. | + +### Group + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| id | [string](#string) | | The unique identifier for the group. Returned by default. Inherited from directoryObject. Key. Not nullable. Read-only. | +| display_name | [string](#string) | | The display name for the group. This property is required when a group is created and cannot be cleared during updates. Returned by default. Supports $filter and $orderby. groupofnames MUST cn + +groupofnames MUST/MAY member | +| members | [Account](#account) | repeated | Users, contacts, and groups that are members of this group. HTTP Methods: GET (supported for all groups), POST (supported for security groups and mail-enabled security groups), DELETE (supported only for security groups) Read-only. Nullable. TODO accounts (users) only for now, we can add groups with the dedicated message using oneof construct later | +| owners | [Account](#account) | repeated | groupofnames MAY businessCategory groupofnames MAY o groupofnames MAY ou groupofnames MAY owner, SINGLE-VALUE but there might be multiple owners | +| description | [string](#string) | | An optional description for the group. Returned by default. groupofnames MAY description | +| gid_number | [int64](#int64) | | used for exposing the user using ldap posixgroup MUST gidnumber + +posixgroup MAY authPassword posixgroup MAY userPassword posixgroup MAY memberUid -> groupofnames member posixgroup MAY description -> groupofnames | +| created_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | Timestamp of when the group was created. The value cannot be modified and is automatically populated when the group is created Returned by default. Read-only. | +| deleted_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | For some Azure Active Directory objects (user, group, application), if the object is deleted, it is first logically deleted, and this property is updated with the date and time when the object was deleted. Otherwise this property is null. If the object is restored, this property is updated to null. Returned by default. Read-only. | +| expiration_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | Timestamp of when the group is set to expire. The value cannot be modified and is automatically populated when the group is created. Returned by default. Read-only. | +| hide_from_address_lists | [bool](#bool) | | True if the group is not displayed in certain parts of the Outlook user interface: in the Address Book, in address lists for selecting message recipients, and in the Browse Groups dialog for searching groups; false otherwise. Default value is false. Returned only on $select. | +| visibility | [string](#string) | | Specifies the visibility of an Office 365 group. Possible values are: Private, Public, or Hiddenmembership; blank values are treated as public. See group visibility options to learn more. Visibility can be set only when a group is created; it is not editable. Returned by default. | +| on_premises_sync_enabled | [bool](#bool) | | true* if this group is synced from an on-premises directory; *false* if this group was originally synced from an on-premises directory but is no longer synced; null if this object has never been synced from an on-premises directory (default). Returned by default. Read-only. Supports $filter. | +| on_premises_immutable_id | [string](#string) | | This property is used to associate an on-premises LDAP user to the oCIS account object. This property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property. Important: The $ and _ characters cannot be used when specifying this property. Supports $filter. | +| on_premises_security_identifier | [string](#string) | | Contains the on-premises security identifier (SID) for the group that was synchronized from on-premises to the cloud. Returned by default. Read-only. | +| on_premises_distinguished_name | [string](#string) | | Contains the on-premises LDAP `distinguished name` or `DN`. The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. | +| on_premises_sam_account_name | [string](#string) | | Contains the on-premises `samAccountName` synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Returned by default. Read-only. | +| on_premises_domain_name | [string](#string) | | Contains the on-premises domain FQDN, also called dnsDomainName synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect. Returned by default. Read-only. | +| on_premises_net_bios_name | [string](#string) | | Contains the on-premises netBios name synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect. Returned by default. Read-only. | +| on_premises_last_sync_date_time | [string](#string) | | Indicates the last time at which the group was synced with the on-premises directory. Returned by default. Read-only. Supports $filter. | +| on_premises_provisioning_errors | [OnPremisesProvisioningError](#onpremisesprovisioningerror) | repeated | Errors when using synchronization during provisioning. | + +### Identities + +Identities Represents an identity used to sign in to a user account. +An identity can be provided by oCIS, by organizations, or by social identity providers such as Facebook, Google, or Microsoft, that are tied to a user account. +This enables the user to sign in to the user account with any of those associated identities. +They are also used to keep a history of old usernames. + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| sign_in_type | [string](#string) | | Specifies the user sign-in types in your directory, such as `emailAddress`, `userName` or `federated`. Here, federated represents a unique identifier for a user from an issuer, that can be in any format chosen by the issuer. Additional validation is enforced on *issuer_assigned_id* when the sign-in type is set to `emailAddress` or `userName`. This property can also be set to any custom string. | +| issuer | [string](#string) | | Specifies the issuer of the identity, for example facebook.com. For local accounts (where signInType is not federated), this property is the local B2C tenant default domain name, for example contoso.onmicrosoft.com. For external users from other Azure AD organization, this will be the domain of the federated organization, for example contoso.com. Supports $filter. 512 character limit. | +| issuer_assigned_id | [string](#string) | | Specifies the unique identifier assigned to the user by the issuer. The combination of *issuer* and *issuerAssignedId* must be unique within the organization. Represents the sign-in name for the user, when signInType is set to emailAddress or userName (also known as local accounts). When *signInType* is set to: * `emailAddress`, (or starts with `emailAddress` like `emailAddress1`) *issuerAssignedId* must be a valid email address * `userName`, issuer_assigned_id must be a valid local part of an email address Supports $filter. 512 character limit. | + +### OnPremisesProvisioningError + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| category | [string](#string) | | Category of the provisioning error. Note: Currently, there is only one possible value. Possible value: PropertyConflict - indicates a property value is not unique. Other objects contain the same value for the property. | +| occurred_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | The date and time at which the error occurred. | +| property_causing_error | [string](#string) | | Name of the directory property causing the error. Current possible values: UserPrincipalName or ProxyAddress | +| value | [string](#string) | | Value of the property causing the error. | + +### PasswordProfile + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| password | [string](#string) | | The password for the user. This property is required when a user is created. It can be updated, but the user will be required to change the password on the next login. The password must satisfy minimum requirements as specified by the user’s passwordPolicies property. By default, a strong password is required. | +| last_password_change_date_time | [google.protobuf.Timestamp](#googleprotobuftimestamp) | | The time when this account last changed their password. | +| password_policies | [string](#string) | repeated | Specifies password policies for the user. This value is an enumeration with one possible value being “DisableStrongPassword”, which allows weaker passwords than the default policy to be specified. “DisablePasswordExpiration” can also be specified. | +| force_change_password_next_sign_in | [bool](#bool) | | true* if the user must change her password on the next login; otherwise false. | +| force_change_password_next_sign_in_with_mfa | [bool](#bool) | | If *true*, at next sign-in, the user must perform a multi-factor authentication (MFA) before being forced to change their password. The behavior is identical to forceChangePasswordNextSignIn except that the user is required to first perform a multi-factor authentication before password change. After a password change, this property will be automatically reset to false. If not set, default is false. | + + +## Scalar Value Types + +| .proto Type | Notes | C++ | Java | +| ----------- | ----- | --- | ---- | +| {{< div id="double" content="double" >}} | | double | double | +| {{< div id="float" content="float" >}} | | float | float | +| {{< div id="int32" content="int32" >}} | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. | int32 | int | +| {{< div id="int64" content="int64" >}} | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. | int64 | long | +| {{< div id="uint32" content="uint32" >}} | Uses variable-length encoding. | uint32 | int | +| {{< div id="uint64" content="uint64" >}} | Uses variable-length encoding. | uint64 | long | +| {{< div id="sint32" content="sint32" >}} | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. | int32 | int | +| {{< div id="sint64" content="sint64" >}} | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. | int64 | long | +| {{< div id="fixed32" content="fixed32" >}} | Always four bytes. More efficient than uint32 if values are often greater than 2^28. | uint32 | int | +| {{< div id="fixed64" content="fixed64" >}} | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. | uint64 | long | +| {{< div id="sfixed32" content="sfixed32" >}} | Always four bytes. | int32 | int | +| {{< div id="sfixed64" content="sfixed64" >}} | Always eight bytes. | int64 | long | +| {{< div id="bool" content="bool" >}} | | bool | boolean | +| {{< div id="string" content="string" >}} | A string must always contain UTF-8 encoded or 7-bit ASCII text. | string | String | +| {{< div id="bytes" content="bytes" >}} | May contain any arbitrary sequence of bytes. | string | ByteString | + diff --git a/protogen/docs/extensions/ocis/services/accounts/v1/grpc.md b/protogen/docs/extensions/ocis/services/accounts/v1/grpc.md new file mode 100644 index 0000000000..45a66887e6 --- /dev/null +++ b/protogen/docs/extensions/ocis/services/accounts/v1/grpc.md @@ -0,0 +1,252 @@ +--- +title: "GRPC API" +date: 2018-05-02T00:00:00+00:00 +weight: 50 +geekdocRepo: https://github.com/owncloud/ocis-thumbnails +geekdocEditPath: edit/master/docs +geekdocFilePath: grpc.md +--- + +{{< toc >}} + + + +## ocis/services/accounts/v1/accounts.proto + +### AddMemberRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| group_id | [string](#string) | | The id of the group to add a member to | +| account_id | [string](#string) | | The account id to add | + +### CreateAccountRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| account | [ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | | The account resource to create | + +### CreateGroupRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| group | [ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | | The account resource to create | + +### DeleteAccountRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| id | [string](#string) | | | + +### DeleteGroupRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| id | [string](#string) | | | + +### GetAccountRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| id | [string](#string) | | | + +### GetGroupRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| id | [string](#string) | | | + +### ListAccountsRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| page_size | [int32](#int32) | | Optional. The maximum number of accounts to return in the response | +| page_token | [string](#string) | | Optional. A pagination token returned from a previous call to `Get` that indicates from where search should continue | +| field_mask | [google.protobuf.FieldMask](#googleprotobuffieldmask) | | Optional. Used to specify a subset of fields that should be returned by a get operation or modified by an update operation. | +| query | [string](#string) | | Optional. Search criteria used to select the accounts to return. If no search criteria is specified then all accounts will be returned + +TODO update query language Query expressions can be used to restrict results based upon the account properties where the operators `=`, `NOT`, `AND` and `OR` can be used along with the suffix wildcard symbol `*`. + +The string properties in a query expression should use escaped quotes for values that include whitespace to prevent unexpected behavior. + +Some example queries are: + +* Query `display_name=Th*` returns accounts whose display_name starts with "Th" * Query `email=foo@example.com` returns accounts with `email` set to `foo@example.com` * Query `display_name=\\"Test String\\"` returns accounts with display names that include both "Test" and "String" | + +### ListAccountsResponse + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| accounts | [ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | repeated | The field name should match the noun "accounts" in the method name. There will be a maximum number of items returned based on the page_size field in the request | +| next_page_token | [string](#string) | | Token to retrieve the next page of results, or empty if there are no more results in the list | + +### ListGroupsRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| page_size | [int32](#int32) | | Optional. The maximum number of groups to return in the response | +| page_token | [string](#string) | | Optional. A pagination token returned from a previous call to `Get` that indicates from where search should continue | +| field_mask | [google.protobuf.FieldMask](#googleprotobuffieldmask) | | Optional. Used to specify a subset of fields that should be returned by a get operation or modified by an update operation. | +| query | [string](#string) | | Optional. Search criteria used to select the groups to return. If no search criteria is specified then all groups will be returned + +TODO update query language Query expressions can be used to restrict results based upon the account properties where the operators `=`, `NOT`, `AND` and `OR` can be used along with the suffix wildcard symbol `*`. + +The string properties in a query expression should use escaped quotes for values that include whitespace to prevent unexpected behavior. + +Some example queries are: + +* Query `display_name=Th*` returns accounts whose display_name starts with "Th" * Query `display_name=\\"Test String\\"` returns groups with display names that include both "Test" and "String" | + +### ListGroupsResponse + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| groups | [ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | repeated | The field name should match the noun "group" in the method name. There will be a maximum number of items returned based on the page_size field in the request | +| next_page_token | [string](#string) | | Token to retrieve the next page of results, or empty if there are no more results in the list | + +### ListMembersRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| page_size | [int32](#int32) | | | +| page_token | [string](#string) | | Optional. A pagination token returned from a previous call to `Get` that indicates from where search should continue | +| field_mask | [google.protobuf.FieldMask](#googleprotobuffieldmask) | | Optional. Used to specify a subset of fields that should be returned by a get operation or modified by an update operation. | +| query | [string](#string) | | Optional. Search criteria used to select the groups to return. If no search criteria is specified then all groups will be returned + +TODO update query language Query expressions can be used to restrict results based upon the account properties where the operators `=`, `NOT`, `AND` and `OR` can be used along with the suffix wildcard symbol `*`. + +The string properties in a query expression should use escaped quotes for values that include whitespace to prevent unexpected behavior. + +Some example queries are: + +* Query `display_name=Th*` returns accounts whose display_name starts with "Th" * Query `display_name=\\"Test String\\"` returns groups with display names that include both "Test" and "String" | +| id | [string](#string) | | The id of the group to list members from | + +### ListMembersResponse + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| members | [ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | repeated | The field name should match the noun "members" in the method name. There will be a maximum number of items returned based on the page_size field in the request | +| next_page_token | [string](#string) | | Token to retrieve the next page of results, or empty if there are no more results in the list | + +### RebuildIndexRequest + + + + +### RebuildIndexResponse + + + + +### RemoveMemberRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| group_id | [string](#string) | | The id of the group to remove a member from | +| account_id | [string](#string) | | The account id to remove | + +### UpdateAccountRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| account | [ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | | The account resource which replaces the resource on the server | +| update_mask | [google.protobuf.FieldMask](#googleprotobuffieldmask) | | The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask | + +### UpdateGroupRequest + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| group | [ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | | The group resource which replaces the resource on the server | +| update_mask | [google.protobuf.FieldMask](#googleprotobuffieldmask) | | The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask | + + +### AccountsService + +Follow recommended Methods for rpc APIs https://cloud.google.com/apis/design/resources?hl=de#methods +https://cloud.google.com/apis/design/standard_methods?hl=de#list +https://cloud.google.com/apis/design/naming_convention?hl=de + +| Method Name | Request Type | Response Type | Description | +| ----------- | ------------ | ------------- | ------------| +| ListAccounts | [ListAccountsRequest](#listaccountsrequest) | [ListAccountsResponse](#listaccountsresponse) | Lists accounts | +| GetAccount | [GetAccountRequest](#getaccountrequest) | [.ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | Gets an account rpc GetAccount(GetAccountRequest) returns (Account) { | +| CreateAccount | [CreateAccountRequest](#createaccountrequest) | [.ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | Creates an account rpc CreateAccount(CreateAccountRequest) returns (Account) { | +| UpdateAccount | [UpdateAccountRequest](#updateaccountrequest) | [.ocis.messages.accounts.v1.Account](../../../messages/accounts/v1/grpc.md#account) | Updates an account rpc UpdateAccount(UpdateAccountRequest) returns (Account) { | +| DeleteAccount | [DeleteAccountRequest](#deleteaccountrequest) | [.google.protobuf.Empty](#googleprotobufempty) | Deletes an account | + +### GroupsService + + + +| Method Name | Request Type | Response Type | Description | +| ----------- | ------------ | ------------- | ------------| +| ListGroups | [ListGroupsRequest](#listgroupsrequest) | [ListGroupsResponse](#listgroupsresponse) | Lists groups | +| GetGroup | [GetGroupRequest](#getgrouprequest) | [.ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | Gets an groups | +| CreateGroup | [CreateGroupRequest](#creategrouprequest) | [.ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | Creates a group | +| UpdateGroup | [UpdateGroupRequest](#updategrouprequest) | [.ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | Updates a group | +| DeleteGroup | [DeleteGroupRequest](#deletegrouprequest) | [.google.protobuf.Empty](#googleprotobufempty) | Deletes a group | +| AddMember | [AddMemberRequest](#addmemberrequest) | [.ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | group:addmember https://docs.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0&tabs=http | +| RemoveMember | [RemoveMemberRequest](#removememberrequest) | [.ocis.messages.accounts.v1.Group](../../../messages/accounts/v1/grpc.md#group) | group:removemember https://docs.microsoft.com/en-us/graph/api/group-delete-members?view=graph-rest-1.0 | +| ListMembers | [ListMembersRequest](#listmembersrequest) | [ListMembersResponse](#listmembersresponse) | group:listmembers https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0 | + +### IndexService + + + +| Method Name | Request Type | Response Type | Description | +| ----------- | ------------ | ------------- | ------------| +| RebuildIndex | [RebuildIndexRequest](#rebuildindexrequest) | [RebuildIndexResponse](#rebuildindexresponse) | | + +## Scalar Value Types + +| .proto Type | Notes | C++ | Java | +| ----------- | ----- | --- | ---- | +| {{< div id="double" content="double" >}} | | double | double | +| {{< div id="float" content="float" >}} | | float | float | +| {{< div id="int32" content="int32" >}} | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. | int32 | int | +| {{< div id="int64" content="int64" >}} | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. | int64 | long | +| {{< div id="uint32" content="uint32" >}} | Uses variable-length encoding. | uint32 | int | +| {{< div id="uint64" content="uint64" >}} | Uses variable-length encoding. | uint64 | long | +| {{< div id="sint32" content="sint32" >}} | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. | int32 | int | +| {{< div id="sint64" content="sint64" >}} | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. | int64 | long | +| {{< div id="fixed32" content="fixed32" >}} | Always four bytes. More efficient than uint32 if values are often greater than 2^28. | uint32 | int | +| {{< div id="fixed64" content="fixed64" >}} | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. | uint64 | long | +| {{< div id="sfixed32" content="sfixed32" >}} | Always four bytes. | int32 | int | +| {{< div id="sfixed64" content="sfixed64" >}} | Always eight bytes. | int64 | long | +| {{< div id="bool" content="bool" >}} | | bool | boolean | +| {{< div id="string" content="string" >}} | A string must always contain UTF-8 encoded or 7-bit ASCII text. | string | String | +| {{< div id="bytes" content="bytes" >}} | May contain any arbitrary sequence of bytes. | string | ByteString | + diff --git a/protogen/gen/ocis/messages/accounts/v1/accounts.pb.go b/protogen/gen/ocis/messages/accounts/v1/accounts.pb.go new file mode 100644 index 0000000000..d55cb8b773 --- /dev/null +++ b/protogen/gen/ocis/messages/accounts/v1/accounts.pb.go @@ -0,0 +1,1222 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.1 +// protoc v3.17.3 +// source: ocis/messages/accounts/v1/accounts.proto + +package v1 + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + timestamppb "google.golang.org/protobuf/types/known/timestamppb" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +// Account follows the properties of the ms graph api user resource. +// See https://docs.microsoft.com/en-us/graph/api/resources/user?view=graph-rest-1.0#properties +type Account struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The unique identifier for the user. Key. Not nullable. Non reassignable. Read-only. + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + // *true* if the account is enabled; otherwise, *false*. This property is required when a user is created. Supports $filter. + AccountEnabled bool `protobuf:"varint,2,opt,name=account_enabled,json=accountEnabled,proto3" json:"account_enabled,omitempty"` + // A resource account is also known as a /disabled user object/ in Azure AD, and can be used to represent resources in general. + // In Exchange it might be used to represent conference rooms, for example, and allow them to have a phone number. + // You could give printers or machines with a sync client resource accounts as well. + // A resource account can be homed in Microsoft 365 or on premises using Skype for Business Server 2019. + // *true* if the user is a resource account; otherwise, *false*. Null value should be considered false. + IsResourceAccount bool `protobuf:"varint,3,opt,name=is_resource_account,json=isResourceAccount,proto3" json:"is_resource_account,omitempty"` + // Indicates whether the account was created as + // - a regular school or work account ("" / emptystring), + // - a local account, fully managed by oCIS (LocalAccount), includes synced accounts or + // - an external account (Invitation), + // - self-service sign-up using email verification (EmailVerified). Read-only. + CreationType string `protobuf:"bytes,4,opt,name=creation_type,json=creationType,proto3" json:"creation_type,omitempty"` + // Represents the identities that can be used to sign in to this account. + // An identity can be provided by oCIS (also known as a local account), by organizations, or by social identity providers such as Facebook, Google, and Microsoft, and is tied to an account. + // May contain multiple items with the same signInType value. Supports $filter. + Identities []*Identities `protobuf:"bytes,5,rep,name=identities,proto3" json:"identities,omitempty"` + // The name displayed in the address book for the account. + // This is usually the combination of the user's first name, middle initial and last name. + // This property is required when a user is created and it cannot be cleared during updates. + // Supports $filter and $orderby. + // posixaccount MUST cn + DisplayName string `protobuf:"bytes,6,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"` + // The username + // posixaccount MUST uid + PreferredName string `protobuf:"bytes,7,opt,name=preferred_name,json=preferredName,proto3" json:"preferred_name,omitempty"` + // TODO rename to on_premise_? or move to extension? see https://docs.microsoft.com/en-us/graph/extensibility-open-users + // used for exposing the user using ldap + // posixaccount MUST uidnumber + UidNumber int64 `protobuf:"varint,8,opt,name=uid_number,json=uidNumber,proto3" json:"uid_number,omitempty"` + // used for exposing the user using ldap + // posixaccount MUST gidnumber + GidNumber int64 `protobuf:"varint,9,opt,name=gid_number,json=gidNumber,proto3" json:"gid_number,omitempty"` + // The SMTP address for the user, for example, "jeff@contoso.onmicrosoft.com". Read-Only. Supports $filter. + // inetorgperson MAY mail + Mail string `protobuf:"bytes,10,opt,name=mail,proto3" json:"mail,omitempty"` + // A description, useful for resource accounts + // posixaccount MAY description + Description string `protobuf:"bytes,11,opt,name=description,proto3" json:"description,omitempty"` + // Specifies the password profile for the user. + // The profile contains the user’s password. This property is required when a user is created. + // The password in the profile must satisfy minimum requirements as specified by the passwordPolicies property. + // By default, a strong password is required. + // posixaccount MAY authPassword + PasswordProfile *PasswordProfile `protobuf:"bytes,12,opt,name=password_profile,json=passwordProfile,proto3" json:"password_profile,omitempty"` + // The groups, directory roles and administrative units that the user is a member of. Read-only. Nullable. + // should we only respond with repeated strings of ids? no clients should a proper filter mask! + MemberOf []*Group `protobuf:"bytes,13,rep,name=memberOf,proto3" json:"memberOf,omitempty"` + // The created date of the account object. + CreatedDateTime *timestamppb.Timestamp `protobuf:"bytes,16,opt,name=created_date_time,json=createdDateTime,proto3" json:"created_date_time,omitempty"` + // The date and time the user was deleted. Returned only on $select. + DeletedDateTime *timestamppb.Timestamp `protobuf:"bytes,17,opt,name=deleted_date_time,json=deletedDateTime,proto3" json:"deleted_date_time,omitempty"` + // *true* if this object is synced from an on-premises directory; + // *false* if this object was originally synced from an on-premises directory but is no longer synced; + // null if this object has never been synced from an on-premises directory (default). Read-only + OnPremisesSyncEnabled bool `protobuf:"varint,20,opt,name=on_premises_sync_enabled,json=onPremisesSyncEnabled,proto3" json:"on_premises_sync_enabled,omitempty"` + // This property is used to associate an on-premises LDAP user to the oCIS account object. + // This property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property. + // Important: The $ and _ characters cannot be used when specifying this property. Supports $filter. + OnPremisesImmutableId string `protobuf:"bytes,21,opt,name=on_premises_immutable_id,json=onPremisesImmutableId,proto3" json:"on_premises_immutable_id,omitempty"` + // Contains the on-premises security identifier (SID) for the user that was synchronized from on-premises to the cloud. Read-only. + OnPremisesSecurityIdentifier string `protobuf:"bytes,22,opt,name=on_premises_security_identifier,json=onPremisesSecurityIdentifier,proto3" json:"on_premises_security_identifier,omitempty"` + // Contains the on-premises LDAP `distinguished name` or `DN`. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + OnPremisesDistinguishedName string `protobuf:"bytes,23,opt,name=on_premises_distinguished_name,json=onPremisesDistinguishedName,proto3" json:"on_premises_distinguished_name,omitempty"` + // Contains the on-premises `samAccountName` synchronized from the on-premises directory. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + OnPremisesSamAccountName string `protobuf:"bytes,24,opt,name=on_premises_sam_account_name,json=onPremisesSamAccountName,proto3" json:"on_premises_sam_account_name,omitempty"` + // Contains the on-premises `domainFQDN`, also called `dnsDomainName` synchronized from the on-premises directory + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + OnPremisesDomainName string `protobuf:"bytes,25,opt,name=on_premises_domain_name,json=onPremisesDomainName,proto3" json:"on_premises_domain_name,omitempty"` + // Contains the on-premises userPrincipalName synchronized from the on-premises directory. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + OnPremisesUserPrincipalName string `protobuf:"bytes,26,opt,name=on_premises_user_principal_name,json=onPremisesUserPrincipalName,proto3" json:"on_premises_user_principal_name,omitempty"` + // Indicates the last time at which the object was synced with the on-premises directory; Read-only. + OnPremisesLastSyncDateTime *timestamppb.Timestamp `protobuf:"bytes,28,opt,name=on_premises_last_sync_date_time,json=onPremisesLastSyncDateTime,proto3" json:"on_premises_last_sync_date_time,omitempty"` + // Errors when using synchronization during provisioning. + OnPremisesProvisioningErrors []*OnPremisesProvisioningError `protobuf:"bytes,29,rep,name=on_premises_provisioning_errors,json=onPremisesProvisioningErrors,proto3" json:"on_premises_provisioning_errors,omitempty"` + // For an external user invited to the tenant using the invitation API, this property represents the invited user's invitation status. + // For invited users, the state can be `PendingAcceptance` or `Accepted`, or "" / emptystring for all other users. + // Returned only on $select. Supports $filter with the supported values. For example: $filter=externalUserState eq 'PendingAcceptance'. + ExternalUserState string `protobuf:"bytes,40,opt,name=external_user_state,json=externalUserState,proto3" json:"external_user_state,omitempty"` + // Shows the timestamp for the latest change to the externalUserState property. Returned only on $select. + ExternalUserStateChangeDateTime *timestamppb.Timestamp `protobuf:"bytes,41,opt,name=external_user_state_change_date_time,json=externalUserStateChangeDateTime,proto3" json:"external_user_state_change_date_time,omitempty"` + // Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get + // an error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph). + // If this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint. + // Returned only on $select. Read-only. Use invalidateAllRefreshTokens to reset. + RefreshTokensValidFromDateTime *timestamppb.Timestamp `protobuf:"bytes,60,opt,name=refresh_tokens_valid_from_date_time,json=refreshTokensValidFromDateTime,proto3" json:"refresh_tokens_valid_from_date_time,omitempty"` + // Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get + // an error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph). + // If this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint. + // Read-only. Use revokeSignInSessions to reset. + SignInSessionsValidFromDateTime *timestamppb.Timestamp `protobuf:"bytes,61,opt,name=sign_in_sessions_valid_from_date_time,json=signInSessionsValidFromDateTime,proto3" json:"sign_in_sessions_valid_from_date_time,omitempty"` +} + +func (x *Account) Reset() { + *x = Account{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Account) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Account) ProtoMessage() {} + +func (x *Account) ProtoReflect() protoreflect.Message { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use Account.ProtoReflect.Descriptor instead. +func (*Account) Descriptor() ([]byte, []int) { + return file_ocis_messages_accounts_v1_accounts_proto_rawDescGZIP(), []int{0} +} + +func (x *Account) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +func (x *Account) GetAccountEnabled() bool { + if x != nil { + return x.AccountEnabled + } + return false +} + +func (x *Account) GetIsResourceAccount() bool { + if x != nil { + return x.IsResourceAccount + } + return false +} + +func (x *Account) GetCreationType() string { + if x != nil { + return x.CreationType + } + return "" +} + +func (x *Account) GetIdentities() []*Identities { + if x != nil { + return x.Identities + } + return nil +} + +func (x *Account) GetDisplayName() string { + if x != nil { + return x.DisplayName + } + return "" +} + +func (x *Account) GetPreferredName() string { + if x != nil { + return x.PreferredName + } + return "" +} + +func (x *Account) GetUidNumber() int64 { + if x != nil { + return x.UidNumber + } + return 0 +} + +func (x *Account) GetGidNumber() int64 { + if x != nil { + return x.GidNumber + } + return 0 +} + +func (x *Account) GetMail() string { + if x != nil { + return x.Mail + } + return "" +} + +func (x *Account) GetDescription() string { + if x != nil { + return x.Description + } + return "" +} + +func (x *Account) GetPasswordProfile() *PasswordProfile { + if x != nil { + return x.PasswordProfile + } + return nil +} + +func (x *Account) GetMemberOf() []*Group { + if x != nil { + return x.MemberOf + } + return nil +} + +func (x *Account) GetCreatedDateTime() *timestamppb.Timestamp { + if x != nil { + return x.CreatedDateTime + } + return nil +} + +func (x *Account) GetDeletedDateTime() *timestamppb.Timestamp { + if x != nil { + return x.DeletedDateTime + } + return nil +} + +func (x *Account) GetOnPremisesSyncEnabled() bool { + if x != nil { + return x.OnPremisesSyncEnabled + } + return false +} + +func (x *Account) GetOnPremisesImmutableId() string { + if x != nil { + return x.OnPremisesImmutableId + } + return "" +} + +func (x *Account) GetOnPremisesSecurityIdentifier() string { + if x != nil { + return x.OnPremisesSecurityIdentifier + } + return "" +} + +func (x *Account) GetOnPremisesDistinguishedName() string { + if x != nil { + return x.OnPremisesDistinguishedName + } + return "" +} + +func (x *Account) GetOnPremisesSamAccountName() string { + if x != nil { + return x.OnPremisesSamAccountName + } + return "" +} + +func (x *Account) GetOnPremisesDomainName() string { + if x != nil { + return x.OnPremisesDomainName + } + return "" +} + +func (x *Account) GetOnPremisesUserPrincipalName() string { + if x != nil { + return x.OnPremisesUserPrincipalName + } + return "" +} + +func (x *Account) GetOnPremisesLastSyncDateTime() *timestamppb.Timestamp { + if x != nil { + return x.OnPremisesLastSyncDateTime + } + return nil +} + +func (x *Account) GetOnPremisesProvisioningErrors() []*OnPremisesProvisioningError { + if x != nil { + return x.OnPremisesProvisioningErrors + } + return nil +} + +func (x *Account) GetExternalUserState() string { + if x != nil { + return x.ExternalUserState + } + return "" +} + +func (x *Account) GetExternalUserStateChangeDateTime() *timestamppb.Timestamp { + if x != nil { + return x.ExternalUserStateChangeDateTime + } + return nil +} + +func (x *Account) GetRefreshTokensValidFromDateTime() *timestamppb.Timestamp { + if x != nil { + return x.RefreshTokensValidFromDateTime + } + return nil +} + +func (x *Account) GetSignInSessionsValidFromDateTime() *timestamppb.Timestamp { + if x != nil { + return x.SignInSessionsValidFromDateTime + } + return nil +} + +// Identities Represents an identity used to sign in to a user account. +// An identity can be provided by oCIS, by organizations, or by social identity providers such as Facebook, Google, or Microsoft, that are tied to a user account. +// This enables the user to sign in to the user account with any of those associated identities. +// They are also used to keep a history of old usernames. +type Identities struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Specifies the user sign-in types in your directory, such as `emailAddress`, `userName` or `federated`. + // Here, federated represents a unique identifier for a user from an issuer, that can be in any format chosen by the issuer. + // Additional validation is enforced on *issuer_assigned_id* when the sign-in type is set to `emailAddress` or `userName`. + // This property can also be set to any custom string. + SignInType string `protobuf:"bytes,1,opt,name=sign_in_type,json=signInType,proto3" json:"sign_in_type,omitempty"` + // Specifies the issuer of the identity, for example facebook.com. + // For local accounts (where signInType is not federated), this property is + // the local B2C tenant default domain name, for example contoso.onmicrosoft.com. + // For external users from other Azure AD organization, this will be the domain of + // the federated organization, for example contoso.com. + // Supports $filter. 512 character limit. + Issuer string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"` + // Specifies the unique identifier assigned to the user by the issuer. The combination of *issuer* and *issuerAssignedId* must be unique within the organization. Represents the sign-in name for the user, when signInType is set to emailAddress or userName (also known as local accounts). + // When *signInType* is set to: + // * `emailAddress`, (or starts with `emailAddress` like `emailAddress1`) *issuerAssignedId* must be a valid email address + // * `userName`, issuer_assigned_id must be a valid local part of an email address + // Supports $filter. 512 character limit. + IssuerAssignedId string `protobuf:"bytes,3,opt,name=issuer_assigned_id,json=issuerAssignedId,proto3" json:"issuer_assigned_id,omitempty"` +} + +func (x *Identities) Reset() { + *x = Identities{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Identities) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Identities) ProtoMessage() {} + +func (x *Identities) ProtoReflect() protoreflect.Message { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use Identities.ProtoReflect.Descriptor instead. +func (*Identities) Descriptor() ([]byte, []int) { + return file_ocis_messages_accounts_v1_accounts_proto_rawDescGZIP(), []int{1} +} + +func (x *Identities) GetSignInType() string { + if x != nil { + return x.SignInType + } + return "" +} + +func (x *Identities) GetIssuer() string { + if x != nil { + return x.Issuer + } + return "" +} + +func (x *Identities) GetIssuerAssignedId() string { + if x != nil { + return x.IssuerAssignedId + } + return "" +} + +type PasswordProfile struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The password for the user. This property is required when a user is created. + // It can be updated, but the user will be required to change the password on the next login. + // The password must satisfy minimum requirements as specified by the user’s passwordPolicies property. By default, a strong password is required. + Password string `protobuf:"bytes,1,opt,name=password,proto3" json:"password,omitempty"` + // The time when this account last changed their password. + LastPasswordChangeDateTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=last_password_change_date_time,json=lastPasswordChangeDateTime,proto3" json:"last_password_change_date_time,omitempty"` + // Specifies password policies for the user. + //This value is an enumeration with one possible value being “DisableStrongPassword”, which allows weaker passwords than the default policy to be specified. + // “DisablePasswordExpiration” can also be specified. + PasswordPolicies []string `protobuf:"bytes,3,rep,name=password_policies,json=passwordPolicies,proto3" json:"password_policies,omitempty"` + // *true* if the user must change her password on the next login; otherwise false. + ForceChangePasswordNextSignIn bool `protobuf:"varint,4,opt,name=force_change_password_next_sign_in,json=forceChangePasswordNextSignIn,proto3" json:"force_change_password_next_sign_in,omitempty"` + // If *true*, at next sign-in, the user must perform a multi-factor authentication (MFA) before being forced to change their password. The behavior is identical to forceChangePasswordNextSignIn except that the user is required to first perform a multi-factor authentication before password change. After a password change, this property will be automatically reset to false. If not set, default is false. + ForceChangePasswordNextSignInWithMfa bool `protobuf:"varint,5,opt,name=force_change_password_next_sign_in_with_mfa,json=forceChangePasswordNextSignInWithMfa,proto3" json:"force_change_password_next_sign_in_with_mfa,omitempty"` +} + +func (x *PasswordProfile) Reset() { + *x = PasswordProfile{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PasswordProfile) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PasswordProfile) ProtoMessage() {} + +func (x *PasswordProfile) ProtoReflect() protoreflect.Message { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PasswordProfile.ProtoReflect.Descriptor instead. +func (*PasswordProfile) Descriptor() ([]byte, []int) { + return file_ocis_messages_accounts_v1_accounts_proto_rawDescGZIP(), []int{2} +} + +func (x *PasswordProfile) GetPassword() string { + if x != nil { + return x.Password + } + return "" +} + +func (x *PasswordProfile) GetLastPasswordChangeDateTime() *timestamppb.Timestamp { + if x != nil { + return x.LastPasswordChangeDateTime + } + return nil +} + +func (x *PasswordProfile) GetPasswordPolicies() []string { + if x != nil { + return x.PasswordPolicies + } + return nil +} + +func (x *PasswordProfile) GetForceChangePasswordNextSignIn() bool { + if x != nil { + return x.ForceChangePasswordNextSignIn + } + return false +} + +func (x *PasswordProfile) GetForceChangePasswordNextSignInWithMfa() bool { + if x != nil { + return x.ForceChangePasswordNextSignInWithMfa + } + return false +} + +type Group struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The unique identifier for the group. + // Returned by default. Inherited from directoryObject. Key. Not nullable. Read-only. + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + // The display name for the group. This property is required when a group is created and cannot be cleared during updates. + // Returned by default. Supports $filter and $orderby. + // groupofnames MUST cn + DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"` // groupofnames MUST/MAY member + // Users, contacts, and groups that are members of this group. HTTP Methods: GET (supported for all groups), POST (supported for security groups and mail-enabled security groups), DELETE (supported only for security groups) Read-only. Nullable. + // TODO accounts (users) only for now, we can add groups with the dedicated message using oneof construct later + Members []*Account `protobuf:"bytes,3,rep,name=members,proto3" json:"members,omitempty"` + // groupofnames MAY businessCategory + // groupofnames MAY o + // groupofnames MAY ou + // groupofnames MAY owner, SINGLE-VALUE but there might be multiple owners + Owners []*Account `protobuf:"bytes,4,rep,name=owners,proto3" json:"owners,omitempty"` + // An optional description for the group. Returned by default. + // groupofnames MAY description + Description string `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"` + // used for exposing the user using ldap + // posixgroup MUST gidnumber + GidNumber int64 `protobuf:"varint,6,opt,name=gid_number,json=gidNumber,proto3" json:"gid_number,omitempty"` + // Timestamp of when the group was created. The value cannot be modified and is automatically populated when the group is created + // Returned by default. Read-only. + CreatedDateTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=created_date_time,json=createdDateTime,proto3" json:"created_date_time,omitempty"` + // For some Azure Active Directory objects (user, group, application), if the object is deleted, it is first logically deleted, and this property is updated with the date and time when the object was deleted. Otherwise this property is null. If the object is restored, this property is updated to null. + // Returned by default. Read-only. + DeletedDateTime *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=deleted_date_time,json=deletedDateTime,proto3" json:"deleted_date_time,omitempty"` + // Timestamp of when the group is set to expire. The value cannot be modified and is automatically populated when the group is created. + // Returned by default. Read-only. + ExpirationDateTime *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=expiration_date_time,json=expirationDateTime,proto3" json:"expiration_date_time,omitempty"` + // True if the group is not displayed in certain parts of the Outlook user interface: + // in the Address Book, in address lists for selecting message recipients, and in the Browse Groups dialog for searching groups; false otherwise. Default value is false. + // Returned only on $select. + HideFromAddressLists bool `protobuf:"varint,10,opt,name=hide_from_address_lists,json=hideFromAddressLists,proto3" json:"hide_from_address_lists,omitempty"` + // Specifies the visibility of an Office 365 group. Possible values are: Private, Public, or Hiddenmembership; blank values are treated as public. See group visibility options to learn more. + // Visibility can be set only when a group is created; it is not editable. + // Returned by default. + Visibility string `protobuf:"bytes,11,opt,name=visibility,proto3" json:"visibility,omitempty"` + // *true* if this group is synced from an on-premises directory; + // *false* if this group was originally synced from an on-premises directory but is no longer synced; + // null if this object has never been synced from an on-premises directory (default). + // Returned by default. Read-only. Supports $filter. + OnPremisesSyncEnabled bool `protobuf:"varint,20,opt,name=on_premises_sync_enabled,json=onPremisesSyncEnabled,proto3" json:"on_premises_sync_enabled,omitempty"` + // This property is used to associate an on-premises LDAP user to the oCIS account object. + // This property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property. + // Important: The $ and _ characters cannot be used when specifying this property. Supports $filter. + OnPremisesImmutableId string `protobuf:"bytes,21,opt,name=on_premises_immutable_id,json=onPremisesImmutableId,proto3" json:"on_premises_immutable_id,omitempty"` + // Contains the on-premises security identifier (SID) for the group that was synchronized from on-premises to the cloud. Returned by default. Read-only. + OnPremisesSecurityIdentifier string `protobuf:"bytes,22,opt,name=on_premises_security_identifier,json=onPremisesSecurityIdentifier,proto3" json:"on_premises_security_identifier,omitempty"` + // Contains the on-premises LDAP `distinguished name` or `DN`. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + OnPremisesDistinguishedName string `protobuf:"bytes,23,opt,name=on_premises_distinguished_name,json=onPremisesDistinguishedName,proto3" json:"on_premises_distinguished_name,omitempty"` + // Contains the on-premises `samAccountName` synchronized from the on-premises directory. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Returned by default. Read-only. + OnPremisesSamAccountName string `protobuf:"bytes,24,opt,name=on_premises_sam_account_name,json=onPremisesSamAccountName,proto3" json:"on_premises_sam_account_name,omitempty"` + // Contains the on-premises domain FQDN, also called dnsDomainName synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect. + // Returned by default. Read-only. + OnPremisesDomainName string `protobuf:"bytes,25,opt,name=on_premises_domain_name,json=onPremisesDomainName,proto3" json:"on_premises_domain_name,omitempty"` + // Contains the on-premises netBios name synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect. + // Returned by default. Read-only. + OnPremisesNetBiosName string `protobuf:"bytes,26,opt,name=on_premises_net_bios_name,json=onPremisesNetBiosName,proto3" json:"on_premises_net_bios_name,omitempty"` + // Indicates the last time at which the group was synced with the on-premises directory. + // Returned by default. Read-only. Supports $filter. + OnPremisesLastSyncDateTime string `protobuf:"bytes,27,opt,name=on_premises_last_sync_date_time,json=onPremisesLastSyncDateTime,proto3" json:"on_premises_last_sync_date_time,omitempty"` + // Errors when using synchronization during provisioning. + OnPremisesProvisioningErrors []*OnPremisesProvisioningError `protobuf:"bytes,28,rep,name=on_premises_provisioning_errors,json=onPremisesProvisioningErrors,proto3" json:"on_premises_provisioning_errors,omitempty"` +} + +func (x *Group) Reset() { + *x = Group{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Group) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Group) ProtoMessage() {} + +func (x *Group) ProtoReflect() protoreflect.Message { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use Group.ProtoReflect.Descriptor instead. +func (*Group) Descriptor() ([]byte, []int) { + return file_ocis_messages_accounts_v1_accounts_proto_rawDescGZIP(), []int{3} +} + +func (x *Group) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +func (x *Group) GetDisplayName() string { + if x != nil { + return x.DisplayName + } + return "" +} + +func (x *Group) GetMembers() []*Account { + if x != nil { + return x.Members + } + return nil +} + +func (x *Group) GetOwners() []*Account { + if x != nil { + return x.Owners + } + return nil +} + +func (x *Group) GetDescription() string { + if x != nil { + return x.Description + } + return "" +} + +func (x *Group) GetGidNumber() int64 { + if x != nil { + return x.GidNumber + } + return 0 +} + +func (x *Group) GetCreatedDateTime() *timestamppb.Timestamp { + if x != nil { + return x.CreatedDateTime + } + return nil +} + +func (x *Group) GetDeletedDateTime() *timestamppb.Timestamp { + if x != nil { + return x.DeletedDateTime + } + return nil +} + +func (x *Group) GetExpirationDateTime() *timestamppb.Timestamp { + if x != nil { + return x.ExpirationDateTime + } + return nil +} + +func (x *Group) GetHideFromAddressLists() bool { + if x != nil { + return x.HideFromAddressLists + } + return false +} + +func (x *Group) GetVisibility() string { + if x != nil { + return x.Visibility + } + return "" +} + +func (x *Group) GetOnPremisesSyncEnabled() bool { + if x != nil { + return x.OnPremisesSyncEnabled + } + return false +} + +func (x *Group) GetOnPremisesImmutableId() string { + if x != nil { + return x.OnPremisesImmutableId + } + return "" +} + +func (x *Group) GetOnPremisesSecurityIdentifier() string { + if x != nil { + return x.OnPremisesSecurityIdentifier + } + return "" +} + +func (x *Group) GetOnPremisesDistinguishedName() string { + if x != nil { + return x.OnPremisesDistinguishedName + } + return "" +} + +func (x *Group) GetOnPremisesSamAccountName() string { + if x != nil { + return x.OnPremisesSamAccountName + } + return "" +} + +func (x *Group) GetOnPremisesDomainName() string { + if x != nil { + return x.OnPremisesDomainName + } + return "" +} + +func (x *Group) GetOnPremisesNetBiosName() string { + if x != nil { + return x.OnPremisesNetBiosName + } + return "" +} + +func (x *Group) GetOnPremisesLastSyncDateTime() string { + if x != nil { + return x.OnPremisesLastSyncDateTime + } + return "" +} + +func (x *Group) GetOnPremisesProvisioningErrors() []*OnPremisesProvisioningError { + if x != nil { + return x.OnPremisesProvisioningErrors + } + return nil +} + +type OnPremisesProvisioningError struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Category of the provisioning error. Note: Currently, there is only one possible value. Possible value: PropertyConflict - indicates a property value is not unique. Other objects contain the same value for the property. + Category string `protobuf:"bytes,1,opt,name=category,proto3" json:"category,omitempty"` + // The date and time at which the error occurred. + OccurredDateTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=occurred_date_time,json=occurredDateTime,proto3" json:"occurred_date_time,omitempty"` + // Name of the directory property causing the error. Current possible values: UserPrincipalName or ProxyAddress + PropertyCausingError string `protobuf:"bytes,3,opt,name=property_causing_error,json=propertyCausingError,proto3" json:"property_causing_error,omitempty"` + // Value of the property causing the error. + Value string `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"` +} + +func (x *OnPremisesProvisioningError) Reset() { + *x = OnPremisesProvisioningError{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *OnPremisesProvisioningError) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*OnPremisesProvisioningError) ProtoMessage() {} + +func (x *OnPremisesProvisioningError) ProtoReflect() protoreflect.Message { + mi := &file_ocis_messages_accounts_v1_accounts_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use OnPremisesProvisioningError.ProtoReflect.Descriptor instead. +func (*OnPremisesProvisioningError) Descriptor() ([]byte, []int) { + return file_ocis_messages_accounts_v1_accounts_proto_rawDescGZIP(), []int{4} +} + +func (x *OnPremisesProvisioningError) GetCategory() string { + if x != nil { + return x.Category + } + return "" +} + +func (x *OnPremisesProvisioningError) GetOccurredDateTime() *timestamppb.Timestamp { + if x != nil { + return x.OccurredDateTime + } + return nil +} + +func (x *OnPremisesProvisioningError) GetPropertyCausingError() string { + if x != nil { + return x.PropertyCausingError + } + return "" +} + +func (x *OnPremisesProvisioningError) GetValue() string { + if x != nil { + return x.Value + } + return "" +} + +var File_ocis_messages_accounts_v1_accounts_proto protoreflect.FileDescriptor + +var file_ocis_messages_accounts_v1_accounts_proto_rawDesc = []byte{ + 0x0a, 0x28, 0x6f, 0x63, 0x69, 0x73, 0x2f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2f, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x19, 0x6f, 0x63, 0x69, 0x73, + 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2e, 0x76, 0x31, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xcc, 0x0d, 0x0a, 0x07, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, + 0x69, 0x64, 0x12, 0x27, 0x0a, 0x0f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x65, 0x6e, + 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x2e, 0x0a, 0x13, 0x69, + 0x73, 0x5f, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x11, 0x69, 0x73, 0x52, 0x65, 0x73, 0x6f, + 0x75, 0x72, 0x63, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0c, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, + 0x12, 0x45, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x18, 0x05, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, + 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, + 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x52, 0x0a, 0x69, 0x64, 0x65, + 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x69, 0x73, 0x70, 0x6c, + 0x61, 0x79, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, + 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x70, 0x72, + 0x65, 0x66, 0x65, 0x72, 0x72, 0x65, 0x64, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0d, 0x70, 0x72, 0x65, 0x66, 0x65, 0x72, 0x72, 0x65, 0x64, 0x4e, 0x61, 0x6d, + 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x75, 0x69, 0x64, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x75, 0x69, 0x64, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x12, 0x1d, 0x0a, 0x0a, 0x67, 0x69, 0x64, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x67, 0x69, 0x64, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, + 0x12, 0x0a, 0x04, 0x6d, 0x61, 0x69, 0x6c, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, + 0x61, 0x69, 0x6c, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, + 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x55, 0x0a, 0x10, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, + 0x64, 0x5f, 0x70, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x2a, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x61, 0x73, 0x73, + 0x77, 0x6f, 0x72, 0x64, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x52, 0x0f, 0x70, 0x61, 0x73, + 0x73, 0x77, 0x6f, 0x72, 0x64, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x12, 0x3c, 0x0a, 0x08, + 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x66, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, + 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x52, 0x08, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x66, 0x12, 0x46, 0x0a, 0x11, 0x63, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, + 0x10, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x52, 0x0f, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, + 0x6d, 0x65, 0x12, 0x46, 0x0a, 0x11, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x64, 0x5f, 0x64, 0x61, + 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x0f, 0x64, 0x65, 0x6c, 0x65, 0x74, + 0x65, 0x64, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x37, 0x0a, 0x18, 0x6f, 0x6e, + 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x73, 0x79, 0x6e, 0x63, 0x5f, 0x65, + 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x14, 0x20, 0x01, 0x28, 0x08, 0x52, 0x15, 0x6f, 0x6e, + 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x53, 0x79, 0x6e, 0x63, 0x45, 0x6e, 0x61, 0x62, + 0x6c, 0x65, 0x64, 0x12, 0x37, 0x0a, 0x18, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, + 0x65, 0x73, 0x5f, 0x69, 0x6d, 0x6d, 0x75, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x69, 0x64, 0x18, + 0x15, 0x20, 0x01, 0x28, 0x09, 0x52, 0x15, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, + 0x73, 0x49, 0x6d, 0x6d, 0x75, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x49, 0x64, 0x12, 0x45, 0x0a, 0x1f, + 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x73, 0x65, 0x63, 0x75, + 0x72, 0x69, 0x74, 0x79, 0x5f, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x18, + 0x16, 0x20, 0x01, 0x28, 0x09, 0x52, 0x1c, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, + 0x73, 0x53, 0x65, 0x63, 0x75, 0x72, 0x69, 0x74, 0x79, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, + 0x69, 0x65, 0x72, 0x12, 0x43, 0x0a, 0x1e, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, + 0x65, 0x73, 0x5f, 0x64, 0x69, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x75, 0x69, 0x73, 0x68, 0x65, 0x64, + 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x17, 0x20, 0x01, 0x28, 0x09, 0x52, 0x1b, 0x6f, 0x6e, 0x50, + 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x44, 0x69, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x75, 0x69, + 0x73, 0x68, 0x65, 0x64, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x3e, 0x0a, 0x1c, 0x6f, 0x6e, 0x5f, 0x70, + 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x73, 0x61, 0x6d, 0x5f, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x18, 0x20, 0x01, 0x28, 0x09, 0x52, 0x18, + 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x53, 0x61, 0x6d, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x17, 0x6f, 0x6e, 0x5f, 0x70, + 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x5f, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x19, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x6f, 0x6e, 0x50, 0x72, 0x65, + 0x6d, 0x69, 0x73, 0x65, 0x73, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x44, 0x0a, 0x1f, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x75, + 0x73, 0x65, 0x72, 0x5f, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x5f, 0x6e, 0x61, + 0x6d, 0x65, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x1b, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, + 0x69, 0x73, 0x65, 0x73, 0x55, 0x73, 0x65, 0x72, 0x50, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, + 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x5f, 0x0a, 0x1f, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, + 0x69, 0x73, 0x65, 0x73, 0x5f, 0x6c, 0x61, 0x73, 0x74, 0x5f, 0x73, 0x79, 0x6e, 0x63, 0x5f, 0x64, + 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x1c, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, + 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, + 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x1a, 0x6f, 0x6e, 0x50, 0x72, + 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x4c, 0x61, 0x73, 0x74, 0x53, 0x79, 0x6e, 0x63, 0x44, 0x61, + 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x7d, 0x0a, 0x1f, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, + 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, + 0x6e, 0x67, 0x5f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x18, 0x1d, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x36, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x6e, 0x50, 0x72, + 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, + 0x6e, 0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x52, 0x1c, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, + 0x73, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, 0x6e, 0x67, 0x45, + 0x72, 0x72, 0x6f, 0x72, 0x73, 0x12, 0x2e, 0x0a, 0x13, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, + 0x6c, 0x5f, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x28, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x11, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x55, 0x73, 0x65, 0x72, + 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x69, 0x0a, 0x24, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, + 0x6c, 0x5f, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x63, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x29, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, + 0x1f, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x55, 0x73, 0x65, 0x72, 0x53, 0x74, 0x61, + 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, + 0x12, 0x67, 0x0a, 0x23, 0x72, 0x65, 0x66, 0x72, 0x65, 0x73, 0x68, 0x5f, 0x74, 0x6f, 0x6b, 0x65, + 0x6e, 0x73, 0x5f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x5f, 0x66, 0x72, 0x6f, 0x6d, 0x5f, 0x64, 0x61, + 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x3c, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x1e, 0x72, 0x65, 0x66, 0x72, 0x65, + 0x73, 0x68, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x46, 0x72, 0x6f, + 0x6d, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x6a, 0x0a, 0x25, 0x73, 0x69, 0x67, + 0x6e, 0x5f, 0x69, 0x6e, 0x5f, 0x73, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x76, 0x61, + 0x6c, 0x69, 0x64, 0x5f, 0x66, 0x72, 0x6f, 0x6d, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, + 0x6d, 0x65, 0x18, 0x3d, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x52, 0x1f, 0x73, 0x69, 0x67, 0x6e, 0x49, 0x6e, 0x53, 0x65, 0x73, 0x73, + 0x69, 0x6f, 0x6e, 0x73, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x46, 0x72, 0x6f, 0x6d, 0x44, 0x61, 0x74, + 0x65, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x74, 0x0a, 0x0a, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, + 0x69, 0x65, 0x73, 0x12, 0x20, 0x0a, 0x0c, 0x73, 0x69, 0x67, 0x6e, 0x5f, 0x69, 0x6e, 0x5f, 0x74, + 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x69, 0x67, 0x6e, 0x49, + 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x73, 0x75, 0x65, 0x72, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x69, 0x73, 0x73, 0x75, 0x65, 0x72, 0x12, 0x2c, 0x0a, + 0x12, 0x69, 0x73, 0x73, 0x75, 0x65, 0x72, 0x5f, 0x61, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, + 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x10, 0x69, 0x73, 0x73, 0x75, 0x65, + 0x72, 0x41, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x64, 0x49, 0x64, 0x22, 0xe0, 0x02, 0x0a, 0x0f, + 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x50, 0x72, 0x6f, 0x66, 0x69, 0x6c, 0x65, 0x12, + 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x5e, 0x0a, 0x1e, 0x6c, + 0x61, 0x73, 0x74, 0x5f, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x5f, 0x63, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, + 0x1a, 0x6c, 0x61, 0x73, 0x74, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x2b, 0x0a, 0x11, 0x70, + 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x69, 0x65, 0x73, + 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x10, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, + 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x69, 0x65, 0x73, 0x12, 0x49, 0x0a, 0x22, 0x66, 0x6f, 0x72, 0x63, + 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x5f, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, + 0x64, 0x5f, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x5f, 0x69, 0x6e, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x1d, 0x66, 0x6f, 0x72, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, + 0x65, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x4e, 0x65, 0x78, 0x74, 0x53, 0x69, 0x67, + 0x6e, 0x49, 0x6e, 0x12, 0x59, 0x0a, 0x2b, 0x66, 0x6f, 0x72, 0x63, 0x65, 0x5f, 0x63, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x5f, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x5f, 0x6e, 0x65, 0x78, + 0x74, 0x5f, 0x73, 0x69, 0x67, 0x6e, 0x5f, 0x69, 0x6e, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x5f, 0x6d, + 0x66, 0x61, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x24, 0x66, 0x6f, 0x72, 0x63, 0x65, 0x43, + 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x4e, 0x65, 0x78, + 0x74, 0x53, 0x69, 0x67, 0x6e, 0x49, 0x6e, 0x57, 0x69, 0x74, 0x68, 0x4d, 0x66, 0x61, 0x22, 0x9d, + 0x09, 0x0a, 0x05, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x69, 0x73, 0x70, + 0x6c, 0x61, 0x79, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, + 0x64, 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x3c, 0x0a, 0x07, 0x6d, + 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x6f, + 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x52, 0x07, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x3a, 0x0a, 0x06, 0x6f, 0x77, 0x6e, + 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x6f, 0x63, 0x69, 0x73, + 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x06, 0x6f, + 0x77, 0x6e, 0x65, 0x72, 0x73, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, + 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, 0x67, 0x69, 0x64, 0x5f, 0x6e, + 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x67, 0x69, 0x64, + 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x46, 0x0a, 0x11, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x0f, 0x63, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x46, + 0x0a, 0x11, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x64, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, + 0x69, 0x6d, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x0f, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x64, 0x44, 0x61, + 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x4c, 0x0a, 0x14, 0x65, 0x78, 0x70, 0x69, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, + 0x52, 0x12, 0x65, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x61, 0x74, 0x65, + 0x54, 0x69, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x17, 0x68, 0x69, 0x64, 0x65, 0x5f, 0x66, 0x72, 0x6f, + 0x6d, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x73, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x08, 0x52, 0x14, 0x68, 0x69, 0x64, 0x65, 0x46, 0x72, 0x6f, 0x6d, 0x41, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x4c, 0x69, 0x73, 0x74, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x76, + 0x69, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x74, 0x79, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x76, 0x69, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x74, 0x79, 0x12, 0x37, 0x0a, 0x18, 0x6f, + 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x73, 0x79, 0x6e, 0x63, 0x5f, + 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x14, 0x20, 0x01, 0x28, 0x08, 0x52, 0x15, 0x6f, + 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x53, 0x79, 0x6e, 0x63, 0x45, 0x6e, 0x61, + 0x62, 0x6c, 0x65, 0x64, 0x12, 0x37, 0x0a, 0x18, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, + 0x73, 0x65, 0x73, 0x5f, 0x69, 0x6d, 0x6d, 0x75, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x69, 0x64, + 0x18, 0x15, 0x20, 0x01, 0x28, 0x09, 0x52, 0x15, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, + 0x65, 0x73, 0x49, 0x6d, 0x6d, 0x75, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x49, 0x64, 0x12, 0x45, 0x0a, + 0x1f, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x73, 0x65, 0x63, + 0x75, 0x72, 0x69, 0x74, 0x79, 0x5f, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, + 0x18, 0x16, 0x20, 0x01, 0x28, 0x09, 0x52, 0x1c, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, + 0x65, 0x73, 0x53, 0x65, 0x63, 0x75, 0x72, 0x69, 0x74, 0x79, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, + 0x66, 0x69, 0x65, 0x72, 0x12, 0x43, 0x0a, 0x1e, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, + 0x73, 0x65, 0x73, 0x5f, 0x64, 0x69, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x75, 0x69, 0x73, 0x68, 0x65, + 0x64, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x17, 0x20, 0x01, 0x28, 0x09, 0x52, 0x1b, 0x6f, 0x6e, + 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x44, 0x69, 0x73, 0x74, 0x69, 0x6e, 0x67, 0x75, + 0x69, 0x73, 0x68, 0x65, 0x64, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x3e, 0x0a, 0x1c, 0x6f, 0x6e, 0x5f, + 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x73, 0x61, 0x6d, 0x5f, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x18, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x18, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x53, 0x61, 0x6d, 0x41, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x17, 0x6f, 0x6e, 0x5f, + 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x64, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x5f, + 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x19, 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x6f, 0x6e, 0x50, 0x72, + 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x44, 0x6f, 0x6d, 0x61, 0x69, 0x6e, 0x4e, 0x61, 0x6d, 0x65, + 0x12, 0x38, 0x0a, 0x19, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, + 0x6e, 0x65, 0x74, 0x5f, 0x62, 0x69, 0x6f, 0x73, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x1a, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x15, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x4e, + 0x65, 0x74, 0x42, 0x69, 0x6f, 0x73, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x43, 0x0a, 0x1f, 0x6f, 0x6e, + 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x6c, 0x61, 0x73, 0x74, 0x5f, 0x73, + 0x79, 0x6e, 0x63, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x1b, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x1a, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x4c, + 0x61, 0x73, 0x74, 0x53, 0x79, 0x6e, 0x63, 0x44, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, + 0x7d, 0x0a, 0x1f, 0x6f, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x5f, 0x70, + 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x65, 0x72, 0x72, 0x6f, + 0x72, 0x73, 0x18, 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x36, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x50, + 0x72, 0x6f, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, 0x6e, 0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, + 0x52, 0x1c, 0x6f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x76, + 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, 0x6e, 0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x22, 0xcf, + 0x01, 0x0a, 0x1b, 0x4f, 0x6e, 0x50, 0x72, 0x65, 0x6d, 0x69, 0x73, 0x65, 0x73, 0x50, 0x72, 0x6f, + 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x69, 0x6e, 0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x1a, + 0x0a, 0x08, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x08, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x48, 0x0a, 0x12, 0x6f, 0x63, + 0x63, 0x75, 0x72, 0x72, 0x65, 0x64, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x52, 0x10, 0x6f, 0x63, 0x63, 0x75, 0x72, 0x72, 0x65, 0x64, 0x44, 0x61, 0x74, 0x65, + 0x54, 0x69, 0x6d, 0x65, 0x12, 0x34, 0x0a, 0x16, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, + 0x5f, 0x63, 0x61, 0x75, 0x73, 0x69, 0x6e, 0x67, 0x5f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x14, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x43, 0x61, + 0x75, 0x73, 0x69, 0x6e, 0x67, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, + 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, + 0x42, 0x41, 0x5a, 0x3f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6f, + 0x77, 0x6e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2f, 0x6f, 0x63, 0x69, 0x73, 0x2f, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x67, 0x65, 0x6e, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x6f, 0x63, 0x69, 0x73, 0x2f, 0x6d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, + 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_ocis_messages_accounts_v1_accounts_proto_rawDescOnce sync.Once + file_ocis_messages_accounts_v1_accounts_proto_rawDescData = file_ocis_messages_accounts_v1_accounts_proto_rawDesc +) + +func file_ocis_messages_accounts_v1_accounts_proto_rawDescGZIP() []byte { + file_ocis_messages_accounts_v1_accounts_proto_rawDescOnce.Do(func() { + file_ocis_messages_accounts_v1_accounts_proto_rawDescData = protoimpl.X.CompressGZIP(file_ocis_messages_accounts_v1_accounts_proto_rawDescData) + }) + return file_ocis_messages_accounts_v1_accounts_proto_rawDescData +} + +var file_ocis_messages_accounts_v1_accounts_proto_msgTypes = make([]protoimpl.MessageInfo, 5) +var file_ocis_messages_accounts_v1_accounts_proto_goTypes = []interface{}{ + (*Account)(nil), // 0: ocis.messages.accounts.v1.Account + (*Identities)(nil), // 1: ocis.messages.accounts.v1.Identities + (*PasswordProfile)(nil), // 2: ocis.messages.accounts.v1.PasswordProfile + (*Group)(nil), // 3: ocis.messages.accounts.v1.Group + (*OnPremisesProvisioningError)(nil), // 4: ocis.messages.accounts.v1.OnPremisesProvisioningError + (*timestamppb.Timestamp)(nil), // 5: google.protobuf.Timestamp +} +var file_ocis_messages_accounts_v1_accounts_proto_depIdxs = []int32{ + 1, // 0: ocis.messages.accounts.v1.Account.identities:type_name -> ocis.messages.accounts.v1.Identities + 2, // 1: ocis.messages.accounts.v1.Account.password_profile:type_name -> ocis.messages.accounts.v1.PasswordProfile + 3, // 2: ocis.messages.accounts.v1.Account.memberOf:type_name -> ocis.messages.accounts.v1.Group + 5, // 3: ocis.messages.accounts.v1.Account.created_date_time:type_name -> google.protobuf.Timestamp + 5, // 4: ocis.messages.accounts.v1.Account.deleted_date_time:type_name -> google.protobuf.Timestamp + 5, // 5: ocis.messages.accounts.v1.Account.on_premises_last_sync_date_time:type_name -> google.protobuf.Timestamp + 4, // 6: ocis.messages.accounts.v1.Account.on_premises_provisioning_errors:type_name -> ocis.messages.accounts.v1.OnPremisesProvisioningError + 5, // 7: ocis.messages.accounts.v1.Account.external_user_state_change_date_time:type_name -> google.protobuf.Timestamp + 5, // 8: ocis.messages.accounts.v1.Account.refresh_tokens_valid_from_date_time:type_name -> google.protobuf.Timestamp + 5, // 9: ocis.messages.accounts.v1.Account.sign_in_sessions_valid_from_date_time:type_name -> google.protobuf.Timestamp + 5, // 10: ocis.messages.accounts.v1.PasswordProfile.last_password_change_date_time:type_name -> google.protobuf.Timestamp + 0, // 11: ocis.messages.accounts.v1.Group.members:type_name -> ocis.messages.accounts.v1.Account + 0, // 12: ocis.messages.accounts.v1.Group.owners:type_name -> ocis.messages.accounts.v1.Account + 5, // 13: ocis.messages.accounts.v1.Group.created_date_time:type_name -> google.protobuf.Timestamp + 5, // 14: ocis.messages.accounts.v1.Group.deleted_date_time:type_name -> google.protobuf.Timestamp + 5, // 15: ocis.messages.accounts.v1.Group.expiration_date_time:type_name -> google.protobuf.Timestamp + 4, // 16: ocis.messages.accounts.v1.Group.on_premises_provisioning_errors:type_name -> ocis.messages.accounts.v1.OnPremisesProvisioningError + 5, // 17: ocis.messages.accounts.v1.OnPremisesProvisioningError.occurred_date_time:type_name -> google.protobuf.Timestamp + 18, // [18:18] is the sub-list for method output_type + 18, // [18:18] is the sub-list for method input_type + 18, // [18:18] is the sub-list for extension type_name + 18, // [18:18] is the sub-list for extension extendee + 0, // [0:18] is the sub-list for field type_name +} + +func init() { file_ocis_messages_accounts_v1_accounts_proto_init() } +func file_ocis_messages_accounts_v1_accounts_proto_init() { + if File_ocis_messages_accounts_v1_accounts_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_ocis_messages_accounts_v1_accounts_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Account); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_messages_accounts_v1_accounts_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Identities); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_messages_accounts_v1_accounts_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PasswordProfile); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_messages_accounts_v1_accounts_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Group); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_messages_accounts_v1_accounts_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*OnPremisesProvisioningError); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_ocis_messages_accounts_v1_accounts_proto_rawDesc, + NumEnums: 0, + NumMessages: 5, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_ocis_messages_accounts_v1_accounts_proto_goTypes, + DependencyIndexes: file_ocis_messages_accounts_v1_accounts_proto_depIdxs, + MessageInfos: file_ocis_messages_accounts_v1_accounts_proto_msgTypes, + }.Build() + File_ocis_messages_accounts_v1_accounts_proto = out.File + file_ocis_messages_accounts_v1_accounts_proto_rawDesc = nil + file_ocis_messages_accounts_v1_accounts_proto_goTypes = nil + file_ocis_messages_accounts_v1_accounts_proto_depIdxs = nil +} diff --git a/protogen/gen/ocis/messages/accounts/v1/accounts.pb.micro.go b/protogen/gen/ocis/messages/accounts/v1/accounts.pb.micro.go new file mode 100644 index 0000000000..35dd36abe9 --- /dev/null +++ b/protogen/gen/ocis/messages/accounts/v1/accounts.pb.micro.go @@ -0,0 +1,16 @@ +// Code generated by protoc-gen-micro. DO NOT EDIT. +// source: ocis/messages/accounts/v1/accounts.proto + +package v1 + +import ( + fmt "fmt" + proto "google.golang.org/protobuf/proto" + _ "google.golang.org/protobuf/types/known/timestamppb" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf diff --git a/protogen/gen/ocis/messages/accounts/v1/accounts.pb.web.go b/protogen/gen/ocis/messages/accounts/v1/accounts.pb.web.go new file mode 100644 index 0000000000..936cee7237 --- /dev/null +++ b/protogen/gen/ocis/messages/accounts/v1/accounts.pb.web.go @@ -0,0 +1,191 @@ +// Code generated by protoc-gen-microweb. DO NOT EDIT. +// source: v1.proto + +package v1 + +import ( + "bytes" + "encoding/json" + + "github.com/golang/protobuf/jsonpb" +) + +// AccountJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of Account. This struct is safe to replace or modify but +// should not be done so concurrently. +var AccountJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *Account) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := AccountJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*Account)(nil) + +// AccountJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of Account. This struct is safe to replace or modify but +// should not be done so concurrently. +var AccountJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *Account) UnmarshalJSON(b []byte) error { + return AccountJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*Account)(nil) + +// IdentitiesJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of Identities. This struct is safe to replace or modify but +// should not be done so concurrently. +var IdentitiesJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *Identities) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := IdentitiesJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*Identities)(nil) + +// IdentitiesJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of Identities. This struct is safe to replace or modify but +// should not be done so concurrently. +var IdentitiesJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *Identities) UnmarshalJSON(b []byte) error { + return IdentitiesJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*Identities)(nil) + +// PasswordProfileJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of PasswordProfile. This struct is safe to replace or modify but +// should not be done so concurrently. +var PasswordProfileJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *PasswordProfile) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := PasswordProfileJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*PasswordProfile)(nil) + +// PasswordProfileJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of PasswordProfile. This struct is safe to replace or modify but +// should not be done so concurrently. +var PasswordProfileJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *PasswordProfile) UnmarshalJSON(b []byte) error { + return PasswordProfileJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*PasswordProfile)(nil) + +// GroupJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of Group. This struct is safe to replace or modify but +// should not be done so concurrently. +var GroupJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *Group) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := GroupJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*Group)(nil) + +// GroupJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of Group. This struct is safe to replace or modify but +// should not be done so concurrently. +var GroupJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *Group) UnmarshalJSON(b []byte) error { + return GroupJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*Group)(nil) + +// OnPremisesProvisioningErrorJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of OnPremisesProvisioningError. This struct is safe to replace or modify but +// should not be done so concurrently. +var OnPremisesProvisioningErrorJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *OnPremisesProvisioningError) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := OnPremisesProvisioningErrorJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*OnPremisesProvisioningError)(nil) + +// OnPremisesProvisioningErrorJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of OnPremisesProvisioningError. This struct is safe to replace or modify but +// should not be done so concurrently. +var OnPremisesProvisioningErrorJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *OnPremisesProvisioningError) UnmarshalJSON(b []byte) error { + return OnPremisesProvisioningErrorJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*OnPremisesProvisioningError)(nil) diff --git a/protogen/gen/ocis/messages/accounts/v1/accounts.swagger.json b/protogen/gen/ocis/messages/accounts/v1/accounts.swagger.json new file mode 100644 index 0000000000..2b36629592 --- /dev/null +++ b/protogen/gen/ocis/messages/accounts/v1/accounts.swagger.json @@ -0,0 +1,43 @@ +{ + "swagger": "2.0", + "info": { + "title": "ocis/messages/accounts/v1/accounts.proto", + "version": "version not set" + }, + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": {}, + "definitions": { + "protobufAny": { + "type": "object", + "properties": { + "@type": { + "type": "string" + } + }, + "additionalProperties": {} + }, + "rpcStatus": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int32" + }, + "message": { + "type": "string" + }, + "details": { + "type": "array", + "items": { + "$ref": "#/definitions/protobufAny" + } + } + } + } + } +} diff --git a/protogen/gen/ocis/services/accounts/v1/accounts.pb.go b/protogen/gen/ocis/services/accounts/v1/accounts.pb.go new file mode 100644 index 0000000000..1a4389c67f --- /dev/null +++ b/protogen/gen/ocis/services/accounts/v1/accounts.pb.go @@ -0,0 +1,1680 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.27.1 +// protoc v3.17.3 +// source: ocis/services/accounts/v1/accounts.proto + +package v1 + +import ( + v1 "github.com/owncloud/ocis/protogen/gen/ocis/messages/accounts/v1" + _ "google.golang.org/genproto/googleapis/api/annotations" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + emptypb "google.golang.org/protobuf/types/known/emptypb" + fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type RebuildIndexRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *RebuildIndexRequest) Reset() { + *x = RebuildIndexRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RebuildIndexRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RebuildIndexRequest) ProtoMessage() {} + +func (x *RebuildIndexRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use RebuildIndexRequest.ProtoReflect.Descriptor instead. +func (*RebuildIndexRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{0} +} + +type RebuildIndexResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *RebuildIndexResponse) Reset() { + *x = RebuildIndexResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RebuildIndexResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RebuildIndexResponse) ProtoMessage() {} + +func (x *RebuildIndexResponse) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use RebuildIndexResponse.ProtoReflect.Descriptor instead. +func (*RebuildIndexResponse) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{1} +} + +type ListAccountsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Optional. The maximum number of accounts to return in the response + PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"` + // Optional. A pagination token returned from a previous call to `Get` + // that indicates from where search should continue + PageToken string `protobuf:"bytes,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"` + // Optional. Used to specify a subset of fields that should be + // returned by a get operation or modified by an update operation. + FieldMask *fieldmaskpb.FieldMask `protobuf:"bytes,3,opt,name=field_mask,json=fieldMask,proto3" json:"field_mask,omitempty"` + // Optional. Search criteria used to select the accounts to return. + // If no search criteria is specified then all accounts will be + // returned + // + // TODO update query language + // Query expressions can be used to restrict results based upon + // the account properties where the operators `=`, `NOT`, `AND` and `OR` + // can be used along with the suffix wildcard symbol `*`. + // + // The string properties in a query expression should use escaped quotes + // for values that include whitespace to prevent unexpected behavior. + // + // Some example queries are: + // + // * Query `display_name=Th*` returns accounts whose display_name + // starts with "Th" + // * Query `email=foo@example.com` returns accounts with + // `email` set to `foo@example.com` + // * Query `display_name=\\"Test String\\"` returns accounts with + // display names that include both "Test" and "String" + Query string `protobuf:"bytes,4,opt,name=query,proto3" json:"query,omitempty"` +} + +func (x *ListAccountsRequest) Reset() { + *x = ListAccountsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ListAccountsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ListAccountsRequest) ProtoMessage() {} + +func (x *ListAccountsRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ListAccountsRequest.ProtoReflect.Descriptor instead. +func (*ListAccountsRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{2} +} + +func (x *ListAccountsRequest) GetPageSize() int32 { + if x != nil { + return x.PageSize + } + return 0 +} + +func (x *ListAccountsRequest) GetPageToken() string { + if x != nil { + return x.PageToken + } + return "" +} + +func (x *ListAccountsRequest) GetFieldMask() *fieldmaskpb.FieldMask { + if x != nil { + return x.FieldMask + } + return nil +} + +func (x *ListAccountsRequest) GetQuery() string { + if x != nil { + return x.Query + } + return "" +} + +type ListAccountsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The field name should match the noun "accounts" in the method name. There + // will be a maximum number of items returned based on the page_size field + // in the request + Accounts []*v1.Account `protobuf:"bytes,1,rep,name=accounts,proto3" json:"accounts,omitempty"` + // Token to retrieve the next page of results, or empty if there are no + // more results in the list + NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"` +} + +func (x *ListAccountsResponse) Reset() { + *x = ListAccountsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ListAccountsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ListAccountsResponse) ProtoMessage() {} + +func (x *ListAccountsResponse) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ListAccountsResponse.ProtoReflect.Descriptor instead. +func (*ListAccountsResponse) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{3} +} + +func (x *ListAccountsResponse) GetAccounts() []*v1.Account { + if x != nil { + return x.Accounts + } + return nil +} + +func (x *ListAccountsResponse) GetNextPageToken() string { + if x != nil { + return x.NextPageToken + } + return "" +} + +type GetAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *GetAccountRequest) Reset() { + *x = GetAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetAccountRequest) ProtoMessage() {} + +func (x *GetAccountRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use GetAccountRequest.ProtoReflect.Descriptor instead. +func (*GetAccountRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{4} +} + +func (x *GetAccountRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type CreateAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The account resource to create + Account *v1.Account `protobuf:"bytes,1,opt,name=account,proto3" json:"account,omitempty"` +} + +func (x *CreateAccountRequest) Reset() { + *x = CreateAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CreateAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CreateAccountRequest) ProtoMessage() {} + +func (x *CreateAccountRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CreateAccountRequest.ProtoReflect.Descriptor instead. +func (*CreateAccountRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{5} +} + +func (x *CreateAccountRequest) GetAccount() *v1.Account { + if x != nil { + return x.Account + } + return nil +} + +type UpdateAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The account resource which replaces the resource on the server + Account *v1.Account `protobuf:"bytes,1,opt,name=account,proto3" json:"account,omitempty"` + // The update mask applies to the resource. For the `FieldMask` definition, + // see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"` +} + +func (x *UpdateAccountRequest) Reset() { + *x = UpdateAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdateAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdateAccountRequest) ProtoMessage() {} + +func (x *UpdateAccountRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use UpdateAccountRequest.ProtoReflect.Descriptor instead. +func (*UpdateAccountRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{6} +} + +func (x *UpdateAccountRequest) GetAccount() *v1.Account { + if x != nil { + return x.Account + } + return nil +} + +func (x *UpdateAccountRequest) GetUpdateMask() *fieldmaskpb.FieldMask { + if x != nil { + return x.UpdateMask + } + return nil +} + +type DeleteAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *DeleteAccountRequest) Reset() { + *x = DeleteAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DeleteAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DeleteAccountRequest) ProtoMessage() {} + +func (x *DeleteAccountRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use DeleteAccountRequest.ProtoReflect.Descriptor instead. +func (*DeleteAccountRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{7} +} + +func (x *DeleteAccountRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type ListGroupsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Optional. The maximum number of groups to return in the response + PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"` + // Optional. A pagination token returned from a previous call to `Get` + // that indicates from where search should continue + PageToken string `protobuf:"bytes,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"` + // Optional. Used to specify a subset of fields that should be + // returned by a get operation or modified by an update operation. + FieldMask *fieldmaskpb.FieldMask `protobuf:"bytes,3,opt,name=field_mask,json=fieldMask,proto3" json:"field_mask,omitempty"` + // Optional. Search criteria used to select the groups to return. + // If no search criteria is specified then all groups will be + // returned + // + // TODO update query language + // Query expressions can be used to restrict results based upon + // the account properties where the operators `=`, `NOT`, `AND` and `OR` + // can be used along with the suffix wildcard symbol `*`. + // + // The string properties in a query expression should use escaped quotes + // for values that include whitespace to prevent unexpected behavior. + // + // Some example queries are: + // + // * Query `display_name=Th*` returns accounts whose display_name + // starts with "Th" + // * Query `display_name=\\"Test String\\"` returns groups with + // display names that include both "Test" and "String" + Query string `protobuf:"bytes,4,opt,name=query,proto3" json:"query,omitempty"` +} + +func (x *ListGroupsRequest) Reset() { + *x = ListGroupsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ListGroupsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ListGroupsRequest) ProtoMessage() {} + +func (x *ListGroupsRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ListGroupsRequest.ProtoReflect.Descriptor instead. +func (*ListGroupsRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{8} +} + +func (x *ListGroupsRequest) GetPageSize() int32 { + if x != nil { + return x.PageSize + } + return 0 +} + +func (x *ListGroupsRequest) GetPageToken() string { + if x != nil { + return x.PageToken + } + return "" +} + +func (x *ListGroupsRequest) GetFieldMask() *fieldmaskpb.FieldMask { + if x != nil { + return x.FieldMask + } + return nil +} + +func (x *ListGroupsRequest) GetQuery() string { + if x != nil { + return x.Query + } + return "" +} + +type ListGroupsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The field name should match the noun "group" in the method name. There + // will be a maximum number of items returned based on the page_size field + // in the request + Groups []*v1.Group `protobuf:"bytes,1,rep,name=groups,proto3" json:"groups,omitempty"` + // Token to retrieve the next page of results, or empty if there are no + // more results in the list + NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"` +} + +func (x *ListGroupsResponse) Reset() { + *x = ListGroupsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ListGroupsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ListGroupsResponse) ProtoMessage() {} + +func (x *ListGroupsResponse) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ListGroupsResponse.ProtoReflect.Descriptor instead. +func (*ListGroupsResponse) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{9} +} + +func (x *ListGroupsResponse) GetGroups() []*v1.Group { + if x != nil { + return x.Groups + } + return nil +} + +func (x *ListGroupsResponse) GetNextPageToken() string { + if x != nil { + return x.NextPageToken + } + return "" +} + +type GetGroupRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *GetGroupRequest) Reset() { + *x = GetGroupRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetGroupRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetGroupRequest) ProtoMessage() {} + +func (x *GetGroupRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use GetGroupRequest.ProtoReflect.Descriptor instead. +func (*GetGroupRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{10} +} + +func (x *GetGroupRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type CreateGroupRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The account resource to create + Group *v1.Group `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"` +} + +func (x *CreateGroupRequest) Reset() { + *x = CreateGroupRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CreateGroupRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CreateGroupRequest) ProtoMessage() {} + +func (x *CreateGroupRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CreateGroupRequest.ProtoReflect.Descriptor instead. +func (*CreateGroupRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{11} +} + +func (x *CreateGroupRequest) GetGroup() *v1.Group { + if x != nil { + return x.Group + } + return nil +} + +type UpdateGroupRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The group resource which replaces the resource on the server + Group *v1.Group `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"` + // The update mask applies to the resource. For the `FieldMask` definition, + // see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"` +} + +func (x *UpdateGroupRequest) Reset() { + *x = UpdateGroupRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdateGroupRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdateGroupRequest) ProtoMessage() {} + +func (x *UpdateGroupRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use UpdateGroupRequest.ProtoReflect.Descriptor instead. +func (*UpdateGroupRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{12} +} + +func (x *UpdateGroupRequest) GetGroup() *v1.Group { + if x != nil { + return x.Group + } + return nil +} + +func (x *UpdateGroupRequest) GetUpdateMask() *fieldmaskpb.FieldMask { + if x != nil { + return x.UpdateMask + } + return nil +} + +type DeleteGroupRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *DeleteGroupRequest) Reset() { + *x = DeleteGroupRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DeleteGroupRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DeleteGroupRequest) ProtoMessage() {} + +func (x *DeleteGroupRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use DeleteGroupRequest.ProtoReflect.Descriptor instead. +func (*DeleteGroupRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{13} +} + +func (x *DeleteGroupRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type AddMemberRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The id of the group to add a member to + GroupId string `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` + // The account id to add + AccountId string `protobuf:"bytes,2,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` +} + +func (x *AddMemberRequest) Reset() { + *x = AddMemberRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AddMemberRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AddMemberRequest) ProtoMessage() {} + +func (x *AddMemberRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[14] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use AddMemberRequest.ProtoReflect.Descriptor instead. +func (*AddMemberRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{14} +} + +func (x *AddMemberRequest) GetGroupId() string { + if x != nil { + return x.GroupId + } + return "" +} + +func (x *AddMemberRequest) GetAccountId() string { + if x != nil { + return x.AccountId + } + return "" +} + +type RemoveMemberRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The id of the group to remove a member from + GroupId string `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` + // The account id to remove + AccountId string `protobuf:"bytes,2,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` +} + +func (x *RemoveMemberRequest) Reset() { + *x = RemoveMemberRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RemoveMemberRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RemoveMemberRequest) ProtoMessage() {} + +func (x *RemoveMemberRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[15] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use RemoveMemberRequest.ProtoReflect.Descriptor instead. +func (*RemoveMemberRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{15} +} + +func (x *RemoveMemberRequest) GetGroupId() string { + if x != nil { + return x.GroupId + } + return "" +} + +func (x *RemoveMemberRequest) GetAccountId() string { + if x != nil { + return x.AccountId + } + return "" +} + +type ListMembersRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"` + // Optional. A pagination token returned from a previous call to `Get` + // that indicates from where search should continue + PageToken string `protobuf:"bytes,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"` + // Optional. Used to specify a subset of fields that should be + // returned by a get operation or modified by an update operation. + FieldMask *fieldmaskpb.FieldMask `protobuf:"bytes,3,opt,name=field_mask,json=fieldMask,proto3" json:"field_mask,omitempty"` + // Optional. Search criteria used to select the groups to return. + // If no search criteria is specified then all groups will be + // returned + // + // TODO update query language + // Query expressions can be used to restrict results based upon + // the account properties where the operators `=`, `NOT`, `AND` and `OR` + // can be used along with the suffix wildcard symbol `*`. + // + // The string properties in a query expression should use escaped quotes + // for values that include whitespace to prevent unexpected behavior. + // + // Some example queries are: + // + // * Query `display_name=Th*` returns accounts whose display_name + // starts with "Th" + // * Query `display_name=\\"Test String\\"` returns groups with + // display names that include both "Test" and "String" + Query string `protobuf:"bytes,4,opt,name=query,proto3" json:"query,omitempty"` + // The id of the group to list members from + Id string `protobuf:"bytes,5,opt,name=id,proto3" json:"id,omitempty"` +} + +func (x *ListMembersRequest) Reset() { + *x = ListMembersRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ListMembersRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ListMembersRequest) ProtoMessage() {} + +func (x *ListMembersRequest) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[16] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ListMembersRequest.ProtoReflect.Descriptor instead. +func (*ListMembersRequest) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{16} +} + +func (x *ListMembersRequest) GetPageSize() int32 { + if x != nil { + return x.PageSize + } + return 0 +} + +func (x *ListMembersRequest) GetPageToken() string { + if x != nil { + return x.PageToken + } + return "" +} + +func (x *ListMembersRequest) GetFieldMask() *fieldmaskpb.FieldMask { + if x != nil { + return x.FieldMask + } + return nil +} + +func (x *ListMembersRequest) GetQuery() string { + if x != nil { + return x.Query + } + return "" +} + +func (x *ListMembersRequest) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +type ListMembersResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The field name should match the noun "members" in the method name. There + // will be a maximum number of items returned based on the page_size field + // in the request + Members []*v1.Account `protobuf:"bytes,1,rep,name=members,proto3" json:"members,omitempty"` + // Token to retrieve the next page of results, or empty if there are no + // more results in the list + NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"` +} + +func (x *ListMembersResponse) Reset() { + *x = ListMembersResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ListMembersResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ListMembersResponse) ProtoMessage() {} + +func (x *ListMembersResponse) ProtoReflect() protoreflect.Message { + mi := &file_ocis_services_accounts_v1_accounts_proto_msgTypes[17] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ListMembersResponse.ProtoReflect.Descriptor instead. +func (*ListMembersResponse) Descriptor() ([]byte, []int) { + return file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP(), []int{17} +} + +func (x *ListMembersResponse) GetMembers() []*v1.Account { + if x != nil { + return x.Members + } + return nil +} + +func (x *ListMembersResponse) GetNextPageToken() string { + if x != nil { + return x.NextPageToken + } + return "" +} + +var File_ocis_services_accounts_v1_accounts_proto protoreflect.FileDescriptor + +var file_ocis_services_accounts_v1_accounts_proto_rawDesc = []byte{ + 0x0a, 0x28, 0x6f, 0x63, 0x69, 0x73, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2f, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x19, 0x6f, 0x63, 0x69, 0x73, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2e, 0x76, 0x31, 0x1a, 0x28, 0x6f, 0x63, 0x69, 0x73, 0x2f, 0x6d, 0x65, 0x73, 0x73, + 0x61, 0x67, 0x65, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, + 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, + 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x66, 0x69, 0x65, 0x6c, + 0x64, 0x5f, 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, + 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1b, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, + 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x20, 0x67, 0x6f, 0x6f, + 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x66, 0x69, 0x65, + 0x6c, 0x64, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x15, 0x0a, + 0x13, 0x52, 0x65, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x22, 0x16, 0x0a, 0x14, 0x52, 0x65, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x49, + 0x6e, 0x64, 0x65, 0x78, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xb4, 0x01, 0x0a, + 0x13, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x08, 0x70, + 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x23, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, + 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x04, 0xe2, 0x41, 0x01, + 0x01, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x39, 0x0a, 0x0a, + 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, + 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x52, 0x09, 0x66, 0x69, + 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x12, 0x1a, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x05, 0x71, 0x75, + 0x65, 0x72, 0x79, 0x22, 0x7e, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x08, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, + 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x52, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x12, 0x26, 0x0a, 0x0f, 0x6e, + 0x65, 0x78, 0x74, 0x5f, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x6e, 0x65, 0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 0x54, 0x6f, + 0x6b, 0x65, 0x6e, 0x22, 0x23, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x54, 0x0a, 0x14, 0x43, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x3c, 0x0a, 0x07, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x22, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x07, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x91, + 0x01, 0x0a, 0x14, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3c, 0x0a, 0x07, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x07, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x3b, 0x0a, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, + 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, + 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, 0x69, 0x65, + 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x4d, 0x61, + 0x73, 0x6b, 0x22, 0x26, 0x0a, 0x14, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0xb2, 0x01, 0x0a, 0x11, 0x4c, + 0x69, 0x73, 0x74, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x21, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x05, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x23, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, + 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x09, 0x70, + 0x61, 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x39, 0x0a, 0x0a, 0x66, 0x69, 0x65, 0x6c, + 0x64, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, + 0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x52, 0x09, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x4d, + 0x61, 0x73, 0x6b, 0x12, 0x1a, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x22, + 0x76, 0x0a, 0x12, 0x4c, 0x69, 0x73, 0x74, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, 0x06, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x18, + 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, + 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, + 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x06, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x12, + 0x26, 0x0a, 0x0f, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, + 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x6e, 0x65, 0x78, 0x74, 0x50, 0x61, + 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x21, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x47, 0x72, + 0x6f, 0x75, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x4c, 0x0a, 0x12, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x36, 0x0a, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x20, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x52, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x89, 0x01, 0x0a, 0x12, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x36, 0x0a, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, + 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x52, 0x05, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x3b, 0x0a, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, + 0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x4d, 0x61, 0x73, 0x6b, 0x22, 0x24, 0x0a, 0x12, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x47, 0x72, + 0x6f, 0x75, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, 0x4c, 0x0a, 0x10, 0x41, 0x64, + 0x64, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x19, + 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x22, 0x4f, 0x0a, 0x13, 0x52, 0x65, 0x6d, 0x6f, + 0x76, 0x65, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x22, 0xc3, 0x01, 0x0a, 0x12, 0x4c, 0x69, + 0x73, 0x74, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x21, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x05, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, + 0x69, 0x7a, 0x65, 0x12, 0x23, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, + 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x09, 0x70, + 0x61, 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x39, 0x0a, 0x0a, 0x66, 0x69, 0x65, 0x6c, + 0x64, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46, + 0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x52, 0x09, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x4d, + 0x61, 0x73, 0x6b, 0x12, 0x1a, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x42, 0x04, 0xe2, 0x41, 0x01, 0x01, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, + 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x22, + 0x7b, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3c, 0x0a, 0x07, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, + 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, + 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, + 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x07, 0x6d, 0x65, 0x6d, + 0x62, 0x65, 0x72, 0x73, 0x12, 0x26, 0x0a, 0x0f, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x70, 0x61, 0x67, + 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x6e, + 0x65, 0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x32, 0xe9, 0x05, 0x0a, + 0x0f, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x12, 0x9a, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x73, 0x12, 0x2e, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, + 0x73, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x2f, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, + 0x73, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x61, 0x70, 0x69, + 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2d, 0x6c, 0x69, 0x73, 0x74, 0x3a, 0x01, 0x2a, 0x12, 0x88, 0x01, + 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2c, 0x2e, 0x6f, + 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x6f, 0x63, 0x69, + 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x28, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x22, 0x22, 0x1d, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x73, 0x2d, 0x67, 0x65, 0x74, 0x3a, 0x01, 0x2a, 0x12, 0x91, 0x01, 0x0a, 0x0d, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2f, 0x2e, 0x6f, 0x63, 0x69, + 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x6f, 0x63, + 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, + 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, + 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2d, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x91, 0x01, 0x0a, + 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x2f, + 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x22, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x22, 0x2b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2d, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x3a, 0x01, 0x2a, + 0x12, 0x85, 0x01, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x2f, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x44, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x2b, 0x82, 0xd3, 0xe4, + 0x93, 0x02, 0x25, 0x22, 0x20, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2d, 0x64, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x3a, 0x01, 0x2a, 0x32, 0x95, 0x09, 0x0a, 0x0d, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x73, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x92, 0x01, 0x0a, 0x0a, 0x4c, + 0x69, 0x73, 0x74, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x12, 0x2c, 0x2e, 0x6f, 0x63, 0x69, 0x73, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2d, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x22, 0x1c, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, + 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2d, 0x6c, 0x69, 0x73, 0x74, 0x3a, 0x01, 0x2a, 0x12, + 0x80, 0x01, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x2a, 0x2e, 0x6f, + 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, + 0x02, 0x20, 0x22, 0x1b, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2d, 0x67, 0x65, 0x74, 0x3a, + 0x01, 0x2a, 0x12, 0x89, 0x01, 0x0a, 0x0b, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x12, 0x2d, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x20, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, + 0x6f, 0x75, 0x70, 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x73, 0x2d, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x89, + 0x01, 0x0a, 0x0b, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x2d, + 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, + 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x22, + 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, + 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, + 0x2d, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x7f, 0x0a, 0x0b, 0x44, 0x65, + 0x6c, 0x65, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x2d, 0x2e, 0x6f, 0x63, 0x69, 0x73, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, + 0x22, 0x29, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x23, 0x22, 0x1e, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, + 0x31, 0x2f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x73, 0x2d, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x3a, 0x01, 0x2a, 0x12, 0x8f, 0x01, 0x0a, 0x09, + 0x41, 0x64, 0x64, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x2b, 0x2e, 0x6f, 0x63, 0x69, 0x73, + 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x64, 0x64, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, + 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, + 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x33, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x2d, + 0x22, 0x28, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, + 0x2f, 0x7b, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x3d, 0x2a, 0x7d, 0x2f, 0x6d, 0x65, + 0x6d, 0x62, 0x65, 0x72, 0x73, 0x2f, 0x24, 0x72, 0x65, 0x66, 0x3a, 0x01, 0x2a, 0x12, 0xa2, 0x01, + 0x0a, 0x0c, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x2e, + 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x76, + 0x65, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, + 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x2e, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x22, 0x40, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3a, 0x22, 0x35, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x76, + 0x31, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2f, 0x7b, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, + 0x69, 0x64, 0x3d, 0x2a, 0x7d, 0x2f, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x2f, 0x7b, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x7d, 0x2f, 0x24, 0x72, 0x65, 0x66, 0x3a, + 0x01, 0x2a, 0x12, 0x9b, 0x01, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x65, 0x6d, 0x62, 0x65, + 0x72, 0x73, 0x12, 0x2d, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4c, + 0x69, 0x73, 0x74, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x2e, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, + 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, + 0x73, 0x74, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x2d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x22, 0x22, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x76, 0x31, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x73, 0x2f, 0x7b, 0x69, 0x64, 0x3d, 0x2a, 0x7d, + 0x2f, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x2f, 0x24, 0x72, 0x65, 0x66, 0x3a, 0x01, 0x2a, + 0x32, 0xa2, 0x01, 0x0a, 0x0c, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x12, 0x91, 0x01, 0x0a, 0x0c, 0x52, 0x65, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x64, + 0x65, 0x78, 0x12, 0x2e, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x52, + 0x65, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x2f, 0x2e, 0x6f, 0x63, 0x69, 0x73, 0x2e, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x73, 0x2e, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x52, + 0x65, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x20, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1a, 0x22, 0x15, 0x2f, 0x61, 0x70, + 0x69, 0x2f, 0x76, 0x31, 0x2f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2f, 0x72, 0x65, 0x62, 0x75, 0x69, + 0x6c, 0x64, 0x3a, 0x01, 0x2a, 0x42, 0x43, 0x5a, 0x41, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x6a, 0x76, 0x69, 0x6c, 0x6c, 0x61, 0x66, 0x61, 0x6e, 0x65, 0x7a, 0x2f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x65, 0x73, 0x74, 0x30, 0x30, 0x31, 0x2f, 0x67, 0x65, 0x6e, + 0x2f, 0x6f, 0x63, 0x69, 0x73, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2f, 0x61, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, +} + +var ( + file_ocis_services_accounts_v1_accounts_proto_rawDescOnce sync.Once + file_ocis_services_accounts_v1_accounts_proto_rawDescData = file_ocis_services_accounts_v1_accounts_proto_rawDesc +) + +func file_ocis_services_accounts_v1_accounts_proto_rawDescGZIP() []byte { + file_ocis_services_accounts_v1_accounts_proto_rawDescOnce.Do(func() { + file_ocis_services_accounts_v1_accounts_proto_rawDescData = protoimpl.X.CompressGZIP(file_ocis_services_accounts_v1_accounts_proto_rawDescData) + }) + return file_ocis_services_accounts_v1_accounts_proto_rawDescData +} + +var file_ocis_services_accounts_v1_accounts_proto_msgTypes = make([]protoimpl.MessageInfo, 18) +var file_ocis_services_accounts_v1_accounts_proto_goTypes = []interface{}{ + (*RebuildIndexRequest)(nil), // 0: ocis.services.accounts.v1.RebuildIndexRequest + (*RebuildIndexResponse)(nil), // 1: ocis.services.accounts.v1.RebuildIndexResponse + (*ListAccountsRequest)(nil), // 2: ocis.services.accounts.v1.ListAccountsRequest + (*ListAccountsResponse)(nil), // 3: ocis.services.accounts.v1.ListAccountsResponse + (*GetAccountRequest)(nil), // 4: ocis.services.accounts.v1.GetAccountRequest + (*CreateAccountRequest)(nil), // 5: ocis.services.accounts.v1.CreateAccountRequest + (*UpdateAccountRequest)(nil), // 6: ocis.services.accounts.v1.UpdateAccountRequest + (*DeleteAccountRequest)(nil), // 7: ocis.services.accounts.v1.DeleteAccountRequest + (*ListGroupsRequest)(nil), // 8: ocis.services.accounts.v1.ListGroupsRequest + (*ListGroupsResponse)(nil), // 9: ocis.services.accounts.v1.ListGroupsResponse + (*GetGroupRequest)(nil), // 10: ocis.services.accounts.v1.GetGroupRequest + (*CreateGroupRequest)(nil), // 11: ocis.services.accounts.v1.CreateGroupRequest + (*UpdateGroupRequest)(nil), // 12: ocis.services.accounts.v1.UpdateGroupRequest + (*DeleteGroupRequest)(nil), // 13: ocis.services.accounts.v1.DeleteGroupRequest + (*AddMemberRequest)(nil), // 14: ocis.services.accounts.v1.AddMemberRequest + (*RemoveMemberRequest)(nil), // 15: ocis.services.accounts.v1.RemoveMemberRequest + (*ListMembersRequest)(nil), // 16: ocis.services.accounts.v1.ListMembersRequest + (*ListMembersResponse)(nil), // 17: ocis.services.accounts.v1.ListMembersResponse + (*fieldmaskpb.FieldMask)(nil), // 18: google.protobuf.FieldMask + (*v1.Account)(nil), // 19: ocis.messages.accounts.v1.Account + (*v1.Group)(nil), // 20: ocis.messages.accounts.v1.Group + (*emptypb.Empty)(nil), // 21: google.protobuf.Empty +} +var file_ocis_services_accounts_v1_accounts_proto_depIdxs = []int32{ + 18, // 0: ocis.services.accounts.v1.ListAccountsRequest.field_mask:type_name -> google.protobuf.FieldMask + 19, // 1: ocis.services.accounts.v1.ListAccountsResponse.accounts:type_name -> ocis.messages.accounts.v1.Account + 19, // 2: ocis.services.accounts.v1.CreateAccountRequest.account:type_name -> ocis.messages.accounts.v1.Account + 19, // 3: ocis.services.accounts.v1.UpdateAccountRequest.account:type_name -> ocis.messages.accounts.v1.Account + 18, // 4: ocis.services.accounts.v1.UpdateAccountRequest.update_mask:type_name -> google.protobuf.FieldMask + 18, // 5: ocis.services.accounts.v1.ListGroupsRequest.field_mask:type_name -> google.protobuf.FieldMask + 20, // 6: ocis.services.accounts.v1.ListGroupsResponse.groups:type_name -> ocis.messages.accounts.v1.Group + 20, // 7: ocis.services.accounts.v1.CreateGroupRequest.group:type_name -> ocis.messages.accounts.v1.Group + 20, // 8: ocis.services.accounts.v1.UpdateGroupRequest.group:type_name -> ocis.messages.accounts.v1.Group + 18, // 9: ocis.services.accounts.v1.UpdateGroupRequest.update_mask:type_name -> google.protobuf.FieldMask + 18, // 10: ocis.services.accounts.v1.ListMembersRequest.field_mask:type_name -> google.protobuf.FieldMask + 19, // 11: ocis.services.accounts.v1.ListMembersResponse.members:type_name -> ocis.messages.accounts.v1.Account + 2, // 12: ocis.services.accounts.v1.AccountsService.ListAccounts:input_type -> ocis.services.accounts.v1.ListAccountsRequest + 4, // 13: ocis.services.accounts.v1.AccountsService.GetAccount:input_type -> ocis.services.accounts.v1.GetAccountRequest + 5, // 14: ocis.services.accounts.v1.AccountsService.CreateAccount:input_type -> ocis.services.accounts.v1.CreateAccountRequest + 6, // 15: ocis.services.accounts.v1.AccountsService.UpdateAccount:input_type -> ocis.services.accounts.v1.UpdateAccountRequest + 7, // 16: ocis.services.accounts.v1.AccountsService.DeleteAccount:input_type -> ocis.services.accounts.v1.DeleteAccountRequest + 8, // 17: ocis.services.accounts.v1.GroupsService.ListGroups:input_type -> ocis.services.accounts.v1.ListGroupsRequest + 10, // 18: ocis.services.accounts.v1.GroupsService.GetGroup:input_type -> ocis.services.accounts.v1.GetGroupRequest + 11, // 19: ocis.services.accounts.v1.GroupsService.CreateGroup:input_type -> ocis.services.accounts.v1.CreateGroupRequest + 12, // 20: ocis.services.accounts.v1.GroupsService.UpdateGroup:input_type -> ocis.services.accounts.v1.UpdateGroupRequest + 13, // 21: ocis.services.accounts.v1.GroupsService.DeleteGroup:input_type -> ocis.services.accounts.v1.DeleteGroupRequest + 14, // 22: ocis.services.accounts.v1.GroupsService.AddMember:input_type -> ocis.services.accounts.v1.AddMemberRequest + 15, // 23: ocis.services.accounts.v1.GroupsService.RemoveMember:input_type -> ocis.services.accounts.v1.RemoveMemberRequest + 16, // 24: ocis.services.accounts.v1.GroupsService.ListMembers:input_type -> ocis.services.accounts.v1.ListMembersRequest + 0, // 25: ocis.services.accounts.v1.IndexService.RebuildIndex:input_type -> ocis.services.accounts.v1.RebuildIndexRequest + 3, // 26: ocis.services.accounts.v1.AccountsService.ListAccounts:output_type -> ocis.services.accounts.v1.ListAccountsResponse + 19, // 27: ocis.services.accounts.v1.AccountsService.GetAccount:output_type -> ocis.messages.accounts.v1.Account + 19, // 28: ocis.services.accounts.v1.AccountsService.CreateAccount:output_type -> ocis.messages.accounts.v1.Account + 19, // 29: ocis.services.accounts.v1.AccountsService.UpdateAccount:output_type -> ocis.messages.accounts.v1.Account + 21, // 30: ocis.services.accounts.v1.AccountsService.DeleteAccount:output_type -> google.protobuf.Empty + 9, // 31: ocis.services.accounts.v1.GroupsService.ListGroups:output_type -> ocis.services.accounts.v1.ListGroupsResponse + 20, // 32: ocis.services.accounts.v1.GroupsService.GetGroup:output_type -> ocis.messages.accounts.v1.Group + 20, // 33: ocis.services.accounts.v1.GroupsService.CreateGroup:output_type -> ocis.messages.accounts.v1.Group + 20, // 34: ocis.services.accounts.v1.GroupsService.UpdateGroup:output_type -> ocis.messages.accounts.v1.Group + 21, // 35: ocis.services.accounts.v1.GroupsService.DeleteGroup:output_type -> google.protobuf.Empty + 20, // 36: ocis.services.accounts.v1.GroupsService.AddMember:output_type -> ocis.messages.accounts.v1.Group + 20, // 37: ocis.services.accounts.v1.GroupsService.RemoveMember:output_type -> ocis.messages.accounts.v1.Group + 17, // 38: ocis.services.accounts.v1.GroupsService.ListMembers:output_type -> ocis.services.accounts.v1.ListMembersResponse + 1, // 39: ocis.services.accounts.v1.IndexService.RebuildIndex:output_type -> ocis.services.accounts.v1.RebuildIndexResponse + 26, // [26:40] is the sub-list for method output_type + 12, // [12:26] is the sub-list for method input_type + 12, // [12:12] is the sub-list for extension type_name + 12, // [12:12] is the sub-list for extension extendee + 0, // [0:12] is the sub-list for field type_name +} + +func init() { file_ocis_services_accounts_v1_accounts_proto_init() } +func file_ocis_services_accounts_v1_accounts_proto_init() { + if File_ocis_services_accounts_v1_accounts_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_ocis_services_accounts_v1_accounts_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RebuildIndexRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RebuildIndexResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListAccountsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListAccountsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetAccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CreateAccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateAccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*DeleteAccountRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListGroupsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListGroupsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetGroupRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CreateGroupRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateGroupRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*DeleteGroupRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AddMemberRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RemoveMemberRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListMembersRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_ocis_services_accounts_v1_accounts_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListMembersResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_ocis_services_accounts_v1_accounts_proto_rawDesc, + NumEnums: 0, + NumMessages: 18, + NumExtensions: 0, + NumServices: 3, + }, + GoTypes: file_ocis_services_accounts_v1_accounts_proto_goTypes, + DependencyIndexes: file_ocis_services_accounts_v1_accounts_proto_depIdxs, + MessageInfos: file_ocis_services_accounts_v1_accounts_proto_msgTypes, + }.Build() + File_ocis_services_accounts_v1_accounts_proto = out.File + file_ocis_services_accounts_v1_accounts_proto_rawDesc = nil + file_ocis_services_accounts_v1_accounts_proto_goTypes = nil + file_ocis_services_accounts_v1_accounts_proto_depIdxs = nil +} diff --git a/protogen/gen/ocis/services/accounts/v1/accounts.pb.micro.go b/protogen/gen/ocis/services/accounts/v1/accounts.pb.micro.go new file mode 100644 index 0000000000..5bf98c44aa --- /dev/null +++ b/protogen/gen/ocis/services/accounts/v1/accounts.pb.micro.go @@ -0,0 +1,627 @@ +// Code generated by protoc-gen-micro. DO NOT EDIT. +// source: ocis/services/accounts/v1/accounts.proto + +package v1 + +import ( + fmt "fmt" + v1 "github.com/owncloud/ocis/protogen/gen/ocis/messages/accounts/v1" + _ "google.golang.org/genproto/googleapis/api/annotations" + proto "google.golang.org/protobuf/proto" + emptypb "google.golang.org/protobuf/types/known/emptypb" + _ "google.golang.org/protobuf/types/known/fieldmaskpb" + math "math" +) + +import ( + context "context" + api "go-micro.dev/v4/api" + client "go-micro.dev/v4/client" + server "go-micro.dev/v4/server" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// Reference imports to suppress errors if they are not otherwise used. +var _ api.Endpoint +var _ context.Context +var _ client.Option +var _ server.Option + +// Api Endpoints for AccountsService service + +func NewAccountsServiceEndpoints() []*api.Endpoint { + return []*api.Endpoint{ + { + Name: "AccountsService.ListAccounts", + Path: []string{"/api/v1/accounts/accounts-list"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "AccountsService.GetAccount", + Path: []string{"/api/v1/accounts/accounts-get"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "AccountsService.CreateAccount", + Path: []string{"/api/v1/accounts/accounts-create"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "AccountsService.UpdateAccount", + Path: []string{"/api/v1/accounts/accounts-update"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "AccountsService.DeleteAccount", + Path: []string{"/api/v1/accounts/accounts-delete"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + } +} + +// Client API for AccountsService service + +type AccountsService interface { + // Lists accounts + ListAccounts(ctx context.Context, in *ListAccountsRequest, opts ...client.CallOption) (*ListAccountsResponse, error) + // Gets an account + //rpc GetAccount(GetAccountRequest) returns (Account) { + GetAccount(ctx context.Context, in *GetAccountRequest, opts ...client.CallOption) (*v1.Account, error) + // Creates an account + //rpc CreateAccount(CreateAccountRequest) returns (Account) { + CreateAccount(ctx context.Context, in *CreateAccountRequest, opts ...client.CallOption) (*v1.Account, error) + // Updates an account + //rpc UpdateAccount(UpdateAccountRequest) returns (Account) { + UpdateAccount(ctx context.Context, in *UpdateAccountRequest, opts ...client.CallOption) (*v1.Account, error) + // Deletes an account + DeleteAccount(ctx context.Context, in *DeleteAccountRequest, opts ...client.CallOption) (*emptypb.Empty, error) +} + +type accountsService struct { + c client.Client + name string +} + +func NewAccountsService(name string, c client.Client) AccountsService { + return &accountsService{ + c: c, + name: name, + } +} + +func (c *accountsService) ListAccounts(ctx context.Context, in *ListAccountsRequest, opts ...client.CallOption) (*ListAccountsResponse, error) { + req := c.c.NewRequest(c.name, "AccountsService.ListAccounts", in) + out := new(ListAccountsResponse) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *accountsService) GetAccount(ctx context.Context, in *GetAccountRequest, opts ...client.CallOption) (*v1.Account, error) { + req := c.c.NewRequest(c.name, "AccountsService.GetAccount", in) + out := new(v1.Account) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *accountsService) CreateAccount(ctx context.Context, in *CreateAccountRequest, opts ...client.CallOption) (*v1.Account, error) { + req := c.c.NewRequest(c.name, "AccountsService.CreateAccount", in) + out := new(v1.Account) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *accountsService) UpdateAccount(ctx context.Context, in *UpdateAccountRequest, opts ...client.CallOption) (*v1.Account, error) { + req := c.c.NewRequest(c.name, "AccountsService.UpdateAccount", in) + out := new(v1.Account) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *accountsService) DeleteAccount(ctx context.Context, in *DeleteAccountRequest, opts ...client.CallOption) (*emptypb.Empty, error) { + req := c.c.NewRequest(c.name, "AccountsService.DeleteAccount", in) + out := new(emptypb.Empty) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Server API for AccountsService service + +type AccountsServiceHandler interface { + // Lists accounts + ListAccounts(context.Context, *ListAccountsRequest, *ListAccountsResponse) error + // Gets an account + //rpc GetAccount(GetAccountRequest) returns (Account) { + GetAccount(context.Context, *GetAccountRequest, *v1.Account) error + // Creates an account + //rpc CreateAccount(CreateAccountRequest) returns (Account) { + CreateAccount(context.Context, *CreateAccountRequest, *v1.Account) error + // Updates an account + //rpc UpdateAccount(UpdateAccountRequest) returns (Account) { + UpdateAccount(context.Context, *UpdateAccountRequest, *v1.Account) error + // Deletes an account + DeleteAccount(context.Context, *DeleteAccountRequest, *emptypb.Empty) error +} + +func RegisterAccountsServiceHandler(s server.Server, hdlr AccountsServiceHandler, opts ...server.HandlerOption) error { + type accountsService interface { + ListAccounts(ctx context.Context, in *ListAccountsRequest, out *ListAccountsResponse) error + GetAccount(ctx context.Context, in *GetAccountRequest, out *v1.Account) error + CreateAccount(ctx context.Context, in *CreateAccountRequest, out *v1.Account) error + UpdateAccount(ctx context.Context, in *UpdateAccountRequest, out *v1.Account) error + DeleteAccount(ctx context.Context, in *DeleteAccountRequest, out *emptypb.Empty) error + } + type AccountsService struct { + accountsService + } + h := &accountsServiceHandler{hdlr} + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "AccountsService.ListAccounts", + Path: []string{"/api/v1/accounts/accounts-list"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "AccountsService.GetAccount", + Path: []string{"/api/v1/accounts/accounts-get"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "AccountsService.CreateAccount", + Path: []string{"/api/v1/accounts/accounts-create"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "AccountsService.UpdateAccount", + Path: []string{"/api/v1/accounts/accounts-update"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "AccountsService.DeleteAccount", + Path: []string{"/api/v1/accounts/accounts-delete"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + return s.Handle(s.NewHandler(&AccountsService{h}, opts...)) +} + +type accountsServiceHandler struct { + AccountsServiceHandler +} + +func (h *accountsServiceHandler) ListAccounts(ctx context.Context, in *ListAccountsRequest, out *ListAccountsResponse) error { + return h.AccountsServiceHandler.ListAccounts(ctx, in, out) +} + +func (h *accountsServiceHandler) GetAccount(ctx context.Context, in *GetAccountRequest, out *v1.Account) error { + return h.AccountsServiceHandler.GetAccount(ctx, in, out) +} + +func (h *accountsServiceHandler) CreateAccount(ctx context.Context, in *CreateAccountRequest, out *v1.Account) error { + return h.AccountsServiceHandler.CreateAccount(ctx, in, out) +} + +func (h *accountsServiceHandler) UpdateAccount(ctx context.Context, in *UpdateAccountRequest, out *v1.Account) error { + return h.AccountsServiceHandler.UpdateAccount(ctx, in, out) +} + +func (h *accountsServiceHandler) DeleteAccount(ctx context.Context, in *DeleteAccountRequest, out *emptypb.Empty) error { + return h.AccountsServiceHandler.DeleteAccount(ctx, in, out) +} + +// Api Endpoints for GroupsService service + +func NewGroupsServiceEndpoints() []*api.Endpoint { + return []*api.Endpoint{ + { + Name: "GroupsService.ListGroups", + Path: []string{"/api/v1/accounts/groups-list"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.GetGroup", + Path: []string{"/api/v1/accounts/groups-get"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.CreateGroup", + Path: []string{"/api/v1/accounts/groups-create"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.UpdateGroup", + Path: []string{"/api/v1/accounts/groups-update"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.DeleteGroup", + Path: []string{"/api/v1/accounts/groups-delete"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.AddMember", + Path: []string{"/api/v1/groups/{group_id=*}/members/$ref"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.RemoveMember", + Path: []string{"/api/v1/groups/{group_id=*}/members/{account_id}/$ref"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + { + Name: "GroupsService.ListMembers", + Path: []string{"/api/v1/groups/{id=*}/members/$ref"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + } +} + +// Client API for GroupsService service + +type GroupsService interface { + // Lists groups + ListGroups(ctx context.Context, in *ListGroupsRequest, opts ...client.CallOption) (*ListGroupsResponse, error) + // Gets an groups + GetGroup(ctx context.Context, in *GetGroupRequest, opts ...client.CallOption) (*v1.Group, error) + // Creates a group + CreateGroup(ctx context.Context, in *CreateGroupRequest, opts ...client.CallOption) (*v1.Group, error) + // Updates a group + UpdateGroup(ctx context.Context, in *UpdateGroupRequest, opts ...client.CallOption) (*v1.Group, error) + // Deletes a group + DeleteGroup(ctx context.Context, in *DeleteGroupRequest, opts ...client.CallOption) (*emptypb.Empty, error) + // group:addmember https://docs.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0&tabs=http + AddMember(ctx context.Context, in *AddMemberRequest, opts ...client.CallOption) (*v1.Group, error) + // group:removemember https://docs.microsoft.com/en-us/graph/api/group-delete-members?view=graph-rest-1.0 + RemoveMember(ctx context.Context, in *RemoveMemberRequest, opts ...client.CallOption) (*v1.Group, error) + // group:listmembers https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0 + ListMembers(ctx context.Context, in *ListMembersRequest, opts ...client.CallOption) (*ListMembersResponse, error) +} + +type groupsService struct { + c client.Client + name string +} + +func NewGroupsService(name string, c client.Client) GroupsService { + return &groupsService{ + c: c, + name: name, + } +} + +func (c *groupsService) ListGroups(ctx context.Context, in *ListGroupsRequest, opts ...client.CallOption) (*ListGroupsResponse, error) { + req := c.c.NewRequest(c.name, "GroupsService.ListGroups", in) + out := new(ListGroupsResponse) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) GetGroup(ctx context.Context, in *GetGroupRequest, opts ...client.CallOption) (*v1.Group, error) { + req := c.c.NewRequest(c.name, "GroupsService.GetGroup", in) + out := new(v1.Group) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) CreateGroup(ctx context.Context, in *CreateGroupRequest, opts ...client.CallOption) (*v1.Group, error) { + req := c.c.NewRequest(c.name, "GroupsService.CreateGroup", in) + out := new(v1.Group) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) UpdateGroup(ctx context.Context, in *UpdateGroupRequest, opts ...client.CallOption) (*v1.Group, error) { + req := c.c.NewRequest(c.name, "GroupsService.UpdateGroup", in) + out := new(v1.Group) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) DeleteGroup(ctx context.Context, in *DeleteGroupRequest, opts ...client.CallOption) (*emptypb.Empty, error) { + req := c.c.NewRequest(c.name, "GroupsService.DeleteGroup", in) + out := new(emptypb.Empty) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) AddMember(ctx context.Context, in *AddMemberRequest, opts ...client.CallOption) (*v1.Group, error) { + req := c.c.NewRequest(c.name, "GroupsService.AddMember", in) + out := new(v1.Group) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) RemoveMember(ctx context.Context, in *RemoveMemberRequest, opts ...client.CallOption) (*v1.Group, error) { + req := c.c.NewRequest(c.name, "GroupsService.RemoveMember", in) + out := new(v1.Group) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *groupsService) ListMembers(ctx context.Context, in *ListMembersRequest, opts ...client.CallOption) (*ListMembersResponse, error) { + req := c.c.NewRequest(c.name, "GroupsService.ListMembers", in) + out := new(ListMembersResponse) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Server API for GroupsService service + +type GroupsServiceHandler interface { + // Lists groups + ListGroups(context.Context, *ListGroupsRequest, *ListGroupsResponse) error + // Gets an groups + GetGroup(context.Context, *GetGroupRequest, *v1.Group) error + // Creates a group + CreateGroup(context.Context, *CreateGroupRequest, *v1.Group) error + // Updates a group + UpdateGroup(context.Context, *UpdateGroupRequest, *v1.Group) error + // Deletes a group + DeleteGroup(context.Context, *DeleteGroupRequest, *emptypb.Empty) error + // group:addmember https://docs.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0&tabs=http + AddMember(context.Context, *AddMemberRequest, *v1.Group) error + // group:removemember https://docs.microsoft.com/en-us/graph/api/group-delete-members?view=graph-rest-1.0 + RemoveMember(context.Context, *RemoveMemberRequest, *v1.Group) error + // group:listmembers https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0 + ListMembers(context.Context, *ListMembersRequest, *ListMembersResponse) error +} + +func RegisterGroupsServiceHandler(s server.Server, hdlr GroupsServiceHandler, opts ...server.HandlerOption) error { + type groupsService interface { + ListGroups(ctx context.Context, in *ListGroupsRequest, out *ListGroupsResponse) error + GetGroup(ctx context.Context, in *GetGroupRequest, out *v1.Group) error + CreateGroup(ctx context.Context, in *CreateGroupRequest, out *v1.Group) error + UpdateGroup(ctx context.Context, in *UpdateGroupRequest, out *v1.Group) error + DeleteGroup(ctx context.Context, in *DeleteGroupRequest, out *emptypb.Empty) error + AddMember(ctx context.Context, in *AddMemberRequest, out *v1.Group) error + RemoveMember(ctx context.Context, in *RemoveMemberRequest, out *v1.Group) error + ListMembers(ctx context.Context, in *ListMembersRequest, out *ListMembersResponse) error + } + type GroupsService struct { + groupsService + } + h := &groupsServiceHandler{hdlr} + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.ListGroups", + Path: []string{"/api/v1/accounts/groups-list"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.GetGroup", + Path: []string{"/api/v1/accounts/groups-get"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.CreateGroup", + Path: []string{"/api/v1/accounts/groups-create"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.UpdateGroup", + Path: []string{"/api/v1/accounts/groups-update"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.DeleteGroup", + Path: []string{"/api/v1/accounts/groups-delete"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.AddMember", + Path: []string{"/api/v1/groups/{group_id=*}/members/$ref"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.RemoveMember", + Path: []string{"/api/v1/groups/{group_id=*}/members/{account_id}/$ref"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "GroupsService.ListMembers", + Path: []string{"/api/v1/groups/{id=*}/members/$ref"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + return s.Handle(s.NewHandler(&GroupsService{h}, opts...)) +} + +type groupsServiceHandler struct { + GroupsServiceHandler +} + +func (h *groupsServiceHandler) ListGroups(ctx context.Context, in *ListGroupsRequest, out *ListGroupsResponse) error { + return h.GroupsServiceHandler.ListGroups(ctx, in, out) +} + +func (h *groupsServiceHandler) GetGroup(ctx context.Context, in *GetGroupRequest, out *v1.Group) error { + return h.GroupsServiceHandler.GetGroup(ctx, in, out) +} + +func (h *groupsServiceHandler) CreateGroup(ctx context.Context, in *CreateGroupRequest, out *v1.Group) error { + return h.GroupsServiceHandler.CreateGroup(ctx, in, out) +} + +func (h *groupsServiceHandler) UpdateGroup(ctx context.Context, in *UpdateGroupRequest, out *v1.Group) error { + return h.GroupsServiceHandler.UpdateGroup(ctx, in, out) +} + +func (h *groupsServiceHandler) DeleteGroup(ctx context.Context, in *DeleteGroupRequest, out *emptypb.Empty) error { + return h.GroupsServiceHandler.DeleteGroup(ctx, in, out) +} + +func (h *groupsServiceHandler) AddMember(ctx context.Context, in *AddMemberRequest, out *v1.Group) error { + return h.GroupsServiceHandler.AddMember(ctx, in, out) +} + +func (h *groupsServiceHandler) RemoveMember(ctx context.Context, in *RemoveMemberRequest, out *v1.Group) error { + return h.GroupsServiceHandler.RemoveMember(ctx, in, out) +} + +func (h *groupsServiceHandler) ListMembers(ctx context.Context, in *ListMembersRequest, out *ListMembersResponse) error { + return h.GroupsServiceHandler.ListMembers(ctx, in, out) +} + +// Api Endpoints for IndexService service + +func NewIndexServiceEndpoints() []*api.Endpoint { + return []*api.Endpoint{ + { + Name: "IndexService.RebuildIndex", + Path: []string{"/api/v1/index/rebuild"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + }, + } +} + +// Client API for IndexService service + +type IndexService interface { + RebuildIndex(ctx context.Context, in *RebuildIndexRequest, opts ...client.CallOption) (*RebuildIndexResponse, error) +} + +type indexService struct { + c client.Client + name string +} + +func NewIndexService(name string, c client.Client) IndexService { + return &indexService{ + c: c, + name: name, + } +} + +func (c *indexService) RebuildIndex(ctx context.Context, in *RebuildIndexRequest, opts ...client.CallOption) (*RebuildIndexResponse, error) { + req := c.c.NewRequest(c.name, "IndexService.RebuildIndex", in) + out := new(RebuildIndexResponse) + err := c.c.Call(ctx, req, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// Server API for IndexService service + +type IndexServiceHandler interface { + RebuildIndex(context.Context, *RebuildIndexRequest, *RebuildIndexResponse) error +} + +func RegisterIndexServiceHandler(s server.Server, hdlr IndexServiceHandler, opts ...server.HandlerOption) error { + type indexService interface { + RebuildIndex(ctx context.Context, in *RebuildIndexRequest, out *RebuildIndexResponse) error + } + type IndexService struct { + indexService + } + h := &indexServiceHandler{hdlr} + opts = append(opts, api.WithEndpoint(&api.Endpoint{ + Name: "IndexService.RebuildIndex", + Path: []string{"/api/v1/index/rebuild"}, + Method: []string{"POST"}, + Body: "*", + Handler: "rpc", + })) + return s.Handle(s.NewHandler(&IndexService{h}, opts...)) +} + +type indexServiceHandler struct { + IndexServiceHandler +} + +func (h *indexServiceHandler) RebuildIndex(ctx context.Context, in *RebuildIndexRequest, out *RebuildIndexResponse) error { + return h.IndexServiceHandler.RebuildIndex(ctx, in, out) +} diff --git a/protogen/gen/ocis/services/accounts/v1/accounts.pb.web.go b/protogen/gen/ocis/services/accounts/v1/accounts.pb.web.go new file mode 100644 index 0000000000..e0db958c8d --- /dev/null +++ b/protogen/gen/ocis/services/accounts/v1/accounts.pb.web.go @@ -0,0 +1,1038 @@ +// Code generated by protoc-gen-microweb. DO NOT EDIT. +// source: v1.proto + +package v1 + +import ( + "bytes" + "encoding/json" + "net/http" + + "github.com/go-chi/chi/v5" + "github.com/go-chi/render" + "github.com/golang/protobuf/jsonpb" + + ptypesempty "github.com/golang/protobuf/ptypes/empty" + accountsv1 "github.com/owncloud/ocis/protogen/gen/ocis/messages/accounts/v1" +) + +type webAccountsServiceHandler struct { + r chi.Router + h AccountsServiceHandler +} + +func (h *webAccountsServiceHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { + h.r.ServeHTTP(w, r) +} + +func (h *webAccountsServiceHandler) ListAccounts(w http.ResponseWriter, r *http.Request) { + req := &ListAccountsRequest{} + resp := &ListAccountsResponse{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.ListAccounts( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webAccountsServiceHandler) GetAccount(w http.ResponseWriter, r *http.Request) { + req := &GetAccountRequest{} + resp := &accountsv1.Account{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.GetAccount( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webAccountsServiceHandler) CreateAccount(w http.ResponseWriter, r *http.Request) { + req := &CreateAccountRequest{} + resp := &accountsv1.Account{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.CreateAccount( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webAccountsServiceHandler) UpdateAccount(w http.ResponseWriter, r *http.Request) { + req := &UpdateAccountRequest{} + resp := &accountsv1.Account{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.UpdateAccount( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webAccountsServiceHandler) DeleteAccount(w http.ResponseWriter, r *http.Request) { + req := &DeleteAccountRequest{} + resp := &ptypesempty.Empty{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.DeleteAccount( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusNoContent) + render.NoContent(w, r) +} + +func RegisterAccountsServiceWeb(r chi.Router, i AccountsServiceHandler, middlewares ...func(http.Handler) http.Handler) { + handler := &webAccountsServiceHandler{ + r: r, + h: i, + } + + r.MethodFunc("POST", "/api/v1/accounts/accounts-list", handler.ListAccounts) + r.MethodFunc("POST", "/api/v1/accounts/accounts-get", handler.GetAccount) + r.MethodFunc("POST", "/api/v1/accounts/accounts-create", handler.CreateAccount) + r.MethodFunc("POST", "/api/v1/accounts/accounts-update", handler.UpdateAccount) + r.MethodFunc("POST", "/api/v1/accounts/accounts-delete", handler.DeleteAccount) +} + +type webGroupsServiceHandler struct { + r chi.Router + h GroupsServiceHandler +} + +func (h *webGroupsServiceHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { + h.r.ServeHTTP(w, r) +} + +func (h *webGroupsServiceHandler) ListGroups(w http.ResponseWriter, r *http.Request) { + req := &ListGroupsRequest{} + resp := &ListGroupsResponse{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.ListGroups( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webGroupsServiceHandler) GetGroup(w http.ResponseWriter, r *http.Request) { + req := &GetGroupRequest{} + resp := &accountsv1.Group{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.GetGroup( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webGroupsServiceHandler) CreateGroup(w http.ResponseWriter, r *http.Request) { + req := &CreateGroupRequest{} + resp := &accountsv1.Group{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.CreateGroup( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webGroupsServiceHandler) UpdateGroup(w http.ResponseWriter, r *http.Request) { + req := &UpdateGroupRequest{} + resp := &accountsv1.Group{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.UpdateGroup( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webGroupsServiceHandler) DeleteGroup(w http.ResponseWriter, r *http.Request) { + req := &DeleteGroupRequest{} + resp := &ptypesempty.Empty{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.DeleteGroup( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusNoContent) + render.NoContent(w, r) +} + +func (h *webGroupsServiceHandler) AddMember(w http.ResponseWriter, r *http.Request) { + req := &AddMemberRequest{} + resp := &accountsv1.Group{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.AddMember( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webGroupsServiceHandler) RemoveMember(w http.ResponseWriter, r *http.Request) { + req := &RemoveMemberRequest{} + resp := &accountsv1.Group{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.RemoveMember( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func (h *webGroupsServiceHandler) ListMembers(w http.ResponseWriter, r *http.Request) { + req := &ListMembersRequest{} + resp := &ListMembersResponse{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.ListMembers( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func RegisterGroupsServiceWeb(r chi.Router, i GroupsServiceHandler, middlewares ...func(http.Handler) http.Handler) { + handler := &webGroupsServiceHandler{ + r: r, + h: i, + } + + r.MethodFunc("POST", "/api/v1/accounts/groups-list", handler.ListGroups) + r.MethodFunc("POST", "/api/v1/accounts/groups-get", handler.GetGroup) + r.MethodFunc("POST", "/api/v1/accounts/groups-create", handler.CreateGroup) + r.MethodFunc("POST", "/api/v1/accounts/groups-update", handler.UpdateGroup) + r.MethodFunc("POST", "/api/v1/accounts/groups-delete", handler.DeleteGroup) + r.MethodFunc("POST", "/api/v1/groups/{group_id=*}/members/$ref", handler.AddMember) + r.MethodFunc("POST", "/api/v1/groups/{group_id=*}/members/{account_id}/$ref", handler.RemoveMember) + r.MethodFunc("POST", "/api/v1/groups/{id=*}/members/$ref", handler.ListMembers) +} + +type webIndexServiceHandler struct { + r chi.Router + h IndexServiceHandler +} + +func (h *webIndexServiceHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { + h.r.ServeHTTP(w, r) +} + +func (h *webIndexServiceHandler) RebuildIndex(w http.ResponseWriter, r *http.Request) { + req := &RebuildIndexRequest{} + resp := &RebuildIndexResponse{} + + if err := json.NewDecoder(r.Body).Decode(&req); err != nil { + http.Error(w, err.Error(), http.StatusPreconditionFailed) + return + } + + if err := h.h.RebuildIndex( + r.Context(), + req, + resp, + ); err != nil { + http.Error(w, err.Error(), http.StatusBadRequest) + return + } + + render.Status(r, http.StatusCreated) + render.JSON(w, r, resp) +} + +func RegisterIndexServiceWeb(r chi.Router, i IndexServiceHandler, middlewares ...func(http.Handler) http.Handler) { + handler := &webIndexServiceHandler{ + r: r, + h: i, + } + + r.MethodFunc("POST", "/api/v1/index/rebuild", handler.RebuildIndex) +} + +// RebuildIndexRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of RebuildIndexRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var RebuildIndexRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *RebuildIndexRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := RebuildIndexRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*RebuildIndexRequest)(nil) + +// RebuildIndexRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of RebuildIndexRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var RebuildIndexRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *RebuildIndexRequest) UnmarshalJSON(b []byte) error { + return RebuildIndexRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*RebuildIndexRequest)(nil) + +// RebuildIndexResponseJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of RebuildIndexResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var RebuildIndexResponseJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *RebuildIndexResponse) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := RebuildIndexResponseJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*RebuildIndexResponse)(nil) + +// RebuildIndexResponseJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of RebuildIndexResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var RebuildIndexResponseJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *RebuildIndexResponse) UnmarshalJSON(b []byte) error { + return RebuildIndexResponseJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*RebuildIndexResponse)(nil) + +// ListAccountsRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of ListAccountsRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListAccountsRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *ListAccountsRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := ListAccountsRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*ListAccountsRequest)(nil) + +// ListAccountsRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of ListAccountsRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListAccountsRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *ListAccountsRequest) UnmarshalJSON(b []byte) error { + return ListAccountsRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*ListAccountsRequest)(nil) + +// ListAccountsResponseJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of ListAccountsResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListAccountsResponseJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *ListAccountsResponse) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := ListAccountsResponseJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*ListAccountsResponse)(nil) + +// ListAccountsResponseJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of ListAccountsResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListAccountsResponseJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *ListAccountsResponse) UnmarshalJSON(b []byte) error { + return ListAccountsResponseJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*ListAccountsResponse)(nil) + +// GetAccountRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of GetAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var GetAccountRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *GetAccountRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := GetAccountRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*GetAccountRequest)(nil) + +// GetAccountRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of GetAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var GetAccountRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *GetAccountRequest) UnmarshalJSON(b []byte) error { + return GetAccountRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*GetAccountRequest)(nil) + +// CreateAccountRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of CreateAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var CreateAccountRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *CreateAccountRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := CreateAccountRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*CreateAccountRequest)(nil) + +// CreateAccountRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of CreateAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var CreateAccountRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *CreateAccountRequest) UnmarshalJSON(b []byte) error { + return CreateAccountRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*CreateAccountRequest)(nil) + +// UpdateAccountRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of UpdateAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var UpdateAccountRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *UpdateAccountRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := UpdateAccountRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*UpdateAccountRequest)(nil) + +// UpdateAccountRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of UpdateAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var UpdateAccountRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *UpdateAccountRequest) UnmarshalJSON(b []byte) error { + return UpdateAccountRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*UpdateAccountRequest)(nil) + +// DeleteAccountRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of DeleteAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var DeleteAccountRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *DeleteAccountRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := DeleteAccountRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*DeleteAccountRequest)(nil) + +// DeleteAccountRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of DeleteAccountRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var DeleteAccountRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *DeleteAccountRequest) UnmarshalJSON(b []byte) error { + return DeleteAccountRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*DeleteAccountRequest)(nil) + +// ListGroupsRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of ListGroupsRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListGroupsRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *ListGroupsRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := ListGroupsRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*ListGroupsRequest)(nil) + +// ListGroupsRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of ListGroupsRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListGroupsRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *ListGroupsRequest) UnmarshalJSON(b []byte) error { + return ListGroupsRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*ListGroupsRequest)(nil) + +// ListGroupsResponseJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of ListGroupsResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListGroupsResponseJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *ListGroupsResponse) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := ListGroupsResponseJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*ListGroupsResponse)(nil) + +// ListGroupsResponseJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of ListGroupsResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListGroupsResponseJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *ListGroupsResponse) UnmarshalJSON(b []byte) error { + return ListGroupsResponseJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*ListGroupsResponse)(nil) + +// GetGroupRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of GetGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var GetGroupRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *GetGroupRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := GetGroupRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*GetGroupRequest)(nil) + +// GetGroupRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of GetGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var GetGroupRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *GetGroupRequest) UnmarshalJSON(b []byte) error { + return GetGroupRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*GetGroupRequest)(nil) + +// CreateGroupRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of CreateGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var CreateGroupRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *CreateGroupRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := CreateGroupRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*CreateGroupRequest)(nil) + +// CreateGroupRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of CreateGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var CreateGroupRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *CreateGroupRequest) UnmarshalJSON(b []byte) error { + return CreateGroupRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*CreateGroupRequest)(nil) + +// UpdateGroupRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of UpdateGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var UpdateGroupRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *UpdateGroupRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := UpdateGroupRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*UpdateGroupRequest)(nil) + +// UpdateGroupRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of UpdateGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var UpdateGroupRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *UpdateGroupRequest) UnmarshalJSON(b []byte) error { + return UpdateGroupRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*UpdateGroupRequest)(nil) + +// DeleteGroupRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of DeleteGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var DeleteGroupRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *DeleteGroupRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := DeleteGroupRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*DeleteGroupRequest)(nil) + +// DeleteGroupRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of DeleteGroupRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var DeleteGroupRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *DeleteGroupRequest) UnmarshalJSON(b []byte) error { + return DeleteGroupRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*DeleteGroupRequest)(nil) + +// AddMemberRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of AddMemberRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var AddMemberRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *AddMemberRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := AddMemberRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*AddMemberRequest)(nil) + +// AddMemberRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of AddMemberRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var AddMemberRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *AddMemberRequest) UnmarshalJSON(b []byte) error { + return AddMemberRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*AddMemberRequest)(nil) + +// RemoveMemberRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of RemoveMemberRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var RemoveMemberRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *RemoveMemberRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := RemoveMemberRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*RemoveMemberRequest)(nil) + +// RemoveMemberRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of RemoveMemberRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var RemoveMemberRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *RemoveMemberRequest) UnmarshalJSON(b []byte) error { + return RemoveMemberRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*RemoveMemberRequest)(nil) + +// ListMembersRequestJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of ListMembersRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListMembersRequestJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *ListMembersRequest) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := ListMembersRequestJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*ListMembersRequest)(nil) + +// ListMembersRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of ListMembersRequest. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListMembersRequestJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *ListMembersRequest) UnmarshalJSON(b []byte) error { + return ListMembersRequestJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*ListMembersRequest)(nil) + +// ListMembersResponseJSONMarshaler describes the default jsonpb.Marshaler used by all +// instances of ListMembersResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListMembersResponseJSONMarshaler = new(jsonpb.Marshaler) + +// MarshalJSON satisfies the encoding/json Marshaler interface. This method +// uses the more correct jsonpb package to correctly marshal the message. +func (m *ListMembersResponse) MarshalJSON() ([]byte, error) { + if m == nil { + return json.Marshal(nil) + } + + buf := &bytes.Buffer{} + + if err := ListMembersResponseJSONMarshaler.Marshal(buf, m); err != nil { + return nil, err + } + + return buf.Bytes(), nil +} + +var _ json.Marshaler = (*ListMembersResponse)(nil) + +// ListMembersResponseJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all +// instances of ListMembersResponse. This struct is safe to replace or modify but +// should not be done so concurrently. +var ListMembersResponseJSONUnmarshaler = new(jsonpb.Unmarshaler) + +// UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method +// uses the more correct jsonpb package to correctly unmarshal the message. +func (m *ListMembersResponse) UnmarshalJSON(b []byte) error { + return ListMembersResponseJSONUnmarshaler.Unmarshal(bytes.NewReader(b), m) +} + +var _ json.Unmarshaler = (*ListMembersResponse)(nil) diff --git a/protogen/gen/ocis/services/accounts/v1/accounts.swagger.json b/protogen/gen/ocis/services/accounts/v1/accounts.swagger.json new file mode 100644 index 0000000000..4c78973aeb --- /dev/null +++ b/protogen/gen/ocis/services/accounts/v1/accounts.swagger.json @@ -0,0 +1,1047 @@ +{ + "swagger": "2.0", + "info": { + "title": "ocis/services/accounts/v1/accounts.proto", + "version": "version not set" + }, + "tags": [ + { + "name": "AccountsService" + }, + { + "name": "GroupsService" + }, + { + "name": "IndexService" + } + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/api/v1/accounts/accounts-create": { + "post": { + "summary": "Creates an account\nrpc CreateAccount(CreateAccountRequest) returns (Account) {", + "operationId": "AccountsService_CreateAccount", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Account" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CreateAccountRequest" + } + } + ], + "tags": [ + "AccountsService" + ] + } + }, + "/api/v1/accounts/accounts-delete": { + "post": { + "summary": "Deletes an account", + "operationId": "AccountsService_DeleteAccount", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "properties": {} + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1DeleteAccountRequest" + } + } + ], + "tags": [ + "AccountsService" + ] + } + }, + "/api/v1/accounts/accounts-get": { + "post": { + "summary": "Gets an account\nrpc GetAccount(GetAccountRequest) returns (Account) {", + "operationId": "AccountsService_GetAccount", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Account" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1GetAccountRequest" + } + } + ], + "tags": [ + "AccountsService" + ] + } + }, + "/api/v1/accounts/accounts-list": { + "post": { + "summary": "Lists accounts", + "operationId": "AccountsService_ListAccounts", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1ListAccountsResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1ListAccountsRequest" + } + } + ], + "tags": [ + "AccountsService" + ] + } + }, + "/api/v1/accounts/accounts-update": { + "post": { + "summary": "Updates an account\nrpc UpdateAccount(UpdateAccountRequest) returns (Account) {", + "operationId": "AccountsService_UpdateAccount", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Account" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1UpdateAccountRequest" + } + } + ], + "tags": [ + "AccountsService" + ] + } + }, + "/api/v1/accounts/groups-create": { + "post": { + "summary": "Creates a group", + "operationId": "GroupsService_CreateGroup", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Group" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1CreateGroupRequest" + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/accounts/groups-delete": { + "post": { + "summary": "Deletes a group", + "operationId": "GroupsService_DeleteGroup", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "properties": {} + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1DeleteGroupRequest" + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/accounts/groups-get": { + "post": { + "summary": "Gets an groups", + "operationId": "GroupsService_GetGroup", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Group" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1GetGroupRequest" + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/accounts/groups-list": { + "post": { + "summary": "Lists groups", + "operationId": "GroupsService_ListGroups", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1ListGroupsResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1ListGroupsRequest" + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/accounts/groups-update": { + "post": { + "summary": "Updates a group", + "operationId": "GroupsService_UpdateGroup", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Group" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1UpdateGroupRequest" + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/groups/{groupId}/members/$ref": { + "post": { + "summary": "group:addmember https://docs.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0\u0026tabs=http", + "operationId": "GroupsService_AddMember", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Group" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "groupId", + "description": "The id of the group to add a member to", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "accountId": { + "type": "string", + "title": "The account id to add" + } + } + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/groups/{groupId}/members/{accountId}/$ref": { + "post": { + "summary": "group:removemember https://docs.microsoft.com/en-us/graph/api/group-delete-members?view=graph-rest-1.0", + "operationId": "GroupsService_RemoveMember", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1Group" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "groupId", + "description": "The id of the group to remove a member from", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "accountId", + "description": "The account id to remove", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object" + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/groups/{id}/members/$ref": { + "post": { + "summary": "group:listmembers https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0", + "operationId": "GroupsService_ListMembers", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1ListMembersResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "id", + "description": "The id of the group to list members from", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "type": "object", + "properties": { + "pageSize": { + "type": "integer", + "format": "int32" + }, + "pageToken": { + "type": "string", + "title": "Optional. A pagination token returned from a previous call to `Get`\nthat indicates from where search should continue" + }, + "fieldMask": { + "type": "string", + "description": "Optional. Used to specify a subset of fields that should be\nreturned by a get operation or modified by an update operation." + }, + "query": { + "type": "string", + "description": "TODO update query language\nQuery expressions can be used to restrict results based upon\nthe account properties where the operators `=`, `NOT`, `AND` and `OR`\ncan be used along with the suffix wildcard symbol `*`.\n\nThe string properties in a query expression should use escaped quotes\nfor values that include whitespace to prevent unexpected behavior.\n\nSome example queries are:\n\n* Query `display_name=Th*` returns accounts whose display_name\nstarts with \"Th\"\n* Query `display_name=\\\\\"Test String\\\\\"` returns groups with\ndisplay names that include both \"Test\" and \"String\"", + "title": "Optional. Search criteria used to select the groups to return.\nIf no search criteria is specified then all groups will be\nreturned" + } + } + } + } + ], + "tags": [ + "GroupsService" + ] + } + }, + "/api/v1/index/rebuild": { + "post": { + "operationId": "IndexService_RebuildIndex", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/v1RebuildIndexResponse" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/rpcStatus" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/v1RebuildIndexRequest" + } + } + ], + "tags": [ + "IndexService" + ] + } + } + }, + "definitions": { + "protobufAny": { + "type": "object", + "properties": { + "@type": { + "type": "string" + } + }, + "additionalProperties": {} + }, + "rpcStatus": { + "type": "object", + "properties": { + "code": { + "type": "integer", + "format": "int32" + }, + "message": { + "type": "string" + }, + "details": { + "type": "array", + "items": { + "$ref": "#/definitions/protobufAny" + } + } + } + }, + "v1Account": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The unique identifier for the user. Key. Not nullable. Non reassignable. Read-only." + }, + "accountEnabled": { + "type": "boolean", + "description": "*true* if the account is enabled; otherwise, *false*. This property is required when a user is created. Supports $filter." + }, + "isResourceAccount": { + "type": "boolean", + "description": "A resource account is also known as a /disabled user object/ in Azure AD, and can be used to represent resources in general.\nIn Exchange it might be used to represent conference rooms, for example, and allow them to have a phone number.\nYou could give printers or machines with a sync client resource accounts as well.\nA resource account can be homed in Microsoft 365 or on premises using Skype for Business Server 2019.\n*true* if the user is a resource account; otherwise, *false*. Null value should be considered false." + }, + "creationType": { + "type": "string", + "description": "Indicates whether the account was created as\n- a regular school or work account (\"\" / emptystring),\n- a local account, fully managed by oCIS (LocalAccount), includes synced accounts or\n- an external account (Invitation),\n- self-service sign-up using email verification (EmailVerified). Read-only." + }, + "identities": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Identities" + }, + "description": "Represents the identities that can be used to sign in to this account.\nAn identity can be provided by oCIS (also known as a local account), by organizations, or by social identity providers such as Facebook, Google, and Microsoft, and is tied to an account.\nMay contain multiple items with the same signInType value. Supports $filter." + }, + "displayName": { + "type": "string", + "title": "The name displayed in the address book for the account.\nThis is usually the combination of the user's first name, middle initial and last name.\nThis property is required when a user is created and it cannot be cleared during updates.\nSupports $filter and $orderby.\nposixaccount MUST cn" + }, + "preferredName": { + "type": "string", + "title": "The username\nposixaccount MUST uid" + }, + "uidNumber": { + "type": "string", + "format": "int64", + "title": "TODO rename to on_premise_? or move to extension? see https://docs.microsoft.com/en-us/graph/extensibility-open-users\nused for exposing the user using ldap\nposixaccount MUST uidnumber" + }, + "gidNumber": { + "type": "string", + "format": "int64", + "title": "used for exposing the user using ldap\nposixaccount MUST gidnumber" + }, + "mail": { + "type": "string", + "title": "The SMTP address for the user, for example, \"jeff@contoso.onmicrosoft.com\". Read-Only. Supports $filter.\ninetorgperson MAY mail" + }, + "description": { + "type": "string", + "title": "A description, useful for resource accounts\nposixaccount MAY description" + }, + "passwordProfile": { + "$ref": "#/definitions/v1PasswordProfile", + "title": "Specifies the password profile for the user.\nThe profile contains the user’s password. This property is required when a user is created.\nThe password in the profile must satisfy minimum requirements as specified by the passwordPolicies property.\nBy default, a strong password is required.\nposixaccount MAY authPassword" + }, + "memberOf": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Group" + }, + "title": "The groups, directory roles and administrative units that the user is a member of. Read-only. Nullable.\nshould we only respond with repeated strings of ids? no clients should a proper filter mask!" + }, + "createdDateTime": { + "type": "string", + "format": "date-time", + "description": "The created date of the account object." + }, + "deletedDateTime": { + "type": "string", + "format": "date-time", + "description": "The date and time the user was deleted. Returned only on $select." + }, + "onPremisesSyncEnabled": { + "type": "boolean", + "title": "*true* if this object is synced from an on-premises directory;\n*false* if this object was originally synced from an on-premises directory but is no longer synced;\nnull if this object has never been synced from an on-premises directory (default). Read-only" + }, + "onPremisesImmutableId": { + "type": "string", + "description": "This property is used to associate an on-premises LDAP user to the oCIS account object.\nThis property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property.\nImportant: The $ and _ characters cannot be used when specifying this property. Supports $filter." + }, + "onPremisesSecurityIdentifier": { + "type": "string", + "description": "Contains the on-premises security identifier (SID) for the user that was synchronized from on-premises to the cloud. Read-only." + }, + "onPremisesDistinguishedName": { + "type": "string", + "description": "Contains the on-premises LDAP `distinguished name` or `DN`.\nThe property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only." + }, + "onPremisesSamAccountName": { + "type": "string", + "description": "Contains the on-premises `samAccountName` synchronized from the on-premises directory.\nThe property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only." + }, + "onPremisesDomainName": { + "type": "string", + "description": "Contains the on-premises `domainFQDN`, also called `dnsDomainName` synchronized from the on-premises directory\nThe property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only." + }, + "onPremisesUserPrincipalName": { + "type": "string", + "description": "Contains the on-premises userPrincipalName synchronized from the on-premises directory.\nThe property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only." + }, + "onPremisesLastSyncDateTime": { + "type": "string", + "format": "date-time", + "description": "Indicates the last time at which the object was synced with the on-premises directory; Read-only." + }, + "onPremisesProvisioningErrors": { + "type": "array", + "items": { + "$ref": "#/definitions/v1OnPremisesProvisioningError" + }, + "description": "Errors when using synchronization during provisioning." + }, + "externalUserState": { + "type": "string", + "description": "For an external user invited to the tenant using the invitation API, this property represents the invited user's invitation status.\nFor invited users, the state can be `PendingAcceptance` or `Accepted`, or \"\" / emptystring for all other users.\nReturned only on $select. Supports $filter with the supported values. For example: $filter=externalUserState eq 'PendingAcceptance'." + }, + "externalUserStateChangeDateTime": { + "type": "string", + "format": "date-time", + "description": "Shows the timestamp for the latest change to the externalUserState property. Returned only on $select." + }, + "refreshTokensValidFromDateTime": { + "type": "string", + "format": "date-time", + "description": "Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get\nan error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph).\nIf this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint.\nReturned only on $select. Read-only. Use invalidateAllRefreshTokens to reset." + }, + "signInSessionsValidFromDateTime": { + "type": "string", + "format": "date-time", + "description": "Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get\nan error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph).\nIf this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint.\nRead-only. Use revokeSignInSessions to reset." + } + }, + "title": "Account follows the properties of the ms graph api user resource.\nSee https://docs.microsoft.com/en-us/graph/api/resources/user?view=graph-rest-1.0#properties" + }, + "v1CreateAccountRequest": { + "type": "object", + "properties": { + "account": { + "$ref": "#/definitions/v1Account", + "title": "The account resource to create" + } + } + }, + "v1CreateGroupRequest": { + "type": "object", + "properties": { + "group": { + "$ref": "#/definitions/v1Group", + "title": "The account resource to create" + } + } + }, + "v1DeleteAccountRequest": { + "type": "object", + "properties": { + "id": { + "type": "string" + } + } + }, + "v1DeleteGroupRequest": { + "type": "object", + "properties": { + "id": { + "type": "string" + } + } + }, + "v1GetAccountRequest": { + "type": "object", + "properties": { + "id": { + "type": "string" + } + } + }, + "v1GetGroupRequest": { + "type": "object", + "properties": { + "id": { + "type": "string" + } + } + }, + "v1Group": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The unique identifier for the group.\nReturned by default. Inherited from directoryObject. Key. Not nullable. Read-only." + }, + "displayName": { + "type": "string", + "title": "The display name for the group. This property is required when a group is created and cannot be cleared during updates.\nReturned by default. Supports $filter and $orderby.\ngroupofnames MUST cn" + }, + "members": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Account" + }, + "title": "Users, contacts, and groups that are members of this group. HTTP Methods: GET (supported for all groups), POST (supported for security groups and mail-enabled security groups), DELETE (supported only for security groups) Read-only. Nullable.\nTODO accounts (users) only for now, we can add groups with the dedicated message using oneof construct later" + }, + "owners": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Account" + }, + "title": "groupofnames MAY businessCategory\ngroupofnames MAY o\ngroupofnames MAY ou\ngroupofnames MAY owner, SINGLE-VALUE but there might be multiple owners" + }, + "description": { + "type": "string", + "title": "An optional description for the group. Returned by default.\ngroupofnames MAY description" + }, + "gidNumber": { + "type": "string", + "format": "int64", + "title": "used for exposing the user using ldap\nposixgroup MUST gidnumber" + }, + "createdDateTime": { + "type": "string", + "format": "date-time", + "description": "Timestamp of when the group was created. The value cannot be modified and is automatically populated when the group is created\nReturned by default. Read-only." + }, + "deletedDateTime": { + "type": "string", + "format": "date-time", + "description": "For some Azure Active Directory objects (user, group, application), if the object is deleted, it is first logically deleted, and this property is updated with the date and time when the object was deleted. Otherwise this property is null. If the object is restored, this property is updated to null.\nReturned by default. Read-only." + }, + "expirationDateTime": { + "type": "string", + "format": "date-time", + "description": "Timestamp of when the group is set to expire. The value cannot be modified and is automatically populated when the group is created.\nReturned by default. Read-only." + }, + "hideFromAddressLists": { + "type": "boolean", + "description": "True if the group is not displayed in certain parts of the Outlook user interface:\nin the Address Book, in address lists for selecting message recipients, and in the Browse Groups dialog for searching groups; false otherwise. Default value is false.\nReturned only on $select." + }, + "visibility": { + "type": "string", + "description": "Specifies the visibility of an Office 365 group. Possible values are: Private, Public, or Hiddenmembership; blank values are treated as public. See group visibility options to learn more.\nVisibility can be set only when a group is created; it is not editable.\nReturned by default." + }, + "onPremisesSyncEnabled": { + "type": "boolean", + "description": "*true* if this group is synced from an on-premises directory;\n*false* if this group was originally synced from an on-premises directory but is no longer synced;\nnull if this object has never been synced from an on-premises directory (default).\nReturned by default. Read-only. Supports $filter." + }, + "onPremisesImmutableId": { + "type": "string", + "description": "This property is used to associate an on-premises LDAP user to the oCIS account object.\nThis property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property.\nImportant: The $ and _ characters cannot be used when specifying this property. Supports $filter." + }, + "onPremisesSecurityIdentifier": { + "type": "string", + "description": "Contains the on-premises security identifier (SID) for the group that was synchronized from on-premises to the cloud. Returned by default. Read-only." + }, + "onPremisesDistinguishedName": { + "type": "string", + "description": "Contains the on-premises LDAP `distinguished name` or `DN`.\nThe property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only." + }, + "onPremisesSamAccountName": { + "type": "string", + "description": "Contains the on-premises `samAccountName` synchronized from the on-premises directory.\nThe property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Returned by default. Read-only." + }, + "onPremisesDomainName": { + "type": "string", + "description": "Contains the on-premises domain FQDN, also called dnsDomainName synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect.\nReturned by default. Read-only." + }, + "onPremisesNetBiosName": { + "type": "string", + "description": "Contains the on-premises netBios name synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect.\nReturned by default. Read-only." + }, + "onPremisesLastSyncDateTime": { + "type": "string", + "description": "Indicates the last time at which the group was synced with the on-premises directory.\nReturned by default. Read-only. Supports $filter." + }, + "onPremisesProvisioningErrors": { + "type": "array", + "items": { + "$ref": "#/definitions/v1OnPremisesProvisioningError" + }, + "description": "Errors when using synchronization during provisioning." + } + } + }, + "v1Identities": { + "type": "object", + "properties": { + "signInType": { + "type": "string", + "description": "Specifies the user sign-in types in your directory, such as `emailAddress`, `userName` or `federated`.\nHere, federated represents a unique identifier for a user from an issuer, that can be in any format chosen by the issuer.\nAdditional validation is enforced on *issuer_assigned_id* when the sign-in type is set to `emailAddress` or `userName`.\nThis property can also be set to any custom string." + }, + "issuer": { + "type": "string", + "description": "Specifies the issuer of the identity, for example facebook.com.\nFor local accounts (where signInType is not federated), this property is\nthe local B2C tenant default domain name, for example contoso.onmicrosoft.com.\nFor external users from other Azure AD organization, this will be the domain of\nthe federated organization, for example contoso.com.\nSupports $filter. 512 character limit." + }, + "issuerAssignedId": { + "type": "string", + "description": "Specifies the unique identifier assigned to the user by the issuer. The combination of *issuer* and *issuerAssignedId* must be unique within the organization. Represents the sign-in name for the user, when signInType is set to emailAddress or userName (also known as local accounts).\nWhen *signInType* is set to:\n* `emailAddress`, (or starts with `emailAddress` like `emailAddress1`) *issuerAssignedId* must be a valid email address\n* `userName`, issuer_assigned_id must be a valid local part of an email address\nSupports $filter. 512 character limit." + } + }, + "description": "Identities Represents an identity used to sign in to a user account.\nAn identity can be provided by oCIS, by organizations, or by social identity providers such as Facebook, Google, or Microsoft, that are tied to a user account.\nThis enables the user to sign in to the user account with any of those associated identities.\nThey are also used to keep a history of old usernames." + }, + "v1ListAccountsRequest": { + "type": "object", + "properties": { + "pageSize": { + "type": "integer", + "format": "int32", + "title": "Optional. The maximum number of accounts to return in the response" + }, + "pageToken": { + "type": "string", + "title": "Optional. A pagination token returned from a previous call to `Get`\nthat indicates from where search should continue" + }, + "fieldMask": { + "type": "string", + "description": "Optional. Used to specify a subset of fields that should be\nreturned by a get operation or modified by an update operation." + }, + "query": { + "type": "string", + "description": "TODO update query language\nQuery expressions can be used to restrict results based upon\nthe account properties where the operators `=`, `NOT`, `AND` and `OR`\ncan be used along with the suffix wildcard symbol `*`.\n\nThe string properties in a query expression should use escaped quotes\nfor values that include whitespace to prevent unexpected behavior.\n\nSome example queries are:\n\n* Query `display_name=Th*` returns accounts whose display_name\nstarts with \"Th\"\n* Query `email=foo@example.com` returns accounts with\n`email` set to `foo@example.com`\n* Query `display_name=\\\\\"Test String\\\\\"` returns accounts with\ndisplay names that include both \"Test\" and \"String\"", + "title": "Optional. Search criteria used to select the accounts to return.\nIf no search criteria is specified then all accounts will be\nreturned" + } + } + }, + "v1ListAccountsResponse": { + "type": "object", + "properties": { + "accounts": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Account" + }, + "title": "The field name should match the noun \"accounts\" in the method name. There\nwill be a maximum number of items returned based on the page_size field\nin the request" + }, + "nextPageToken": { + "type": "string", + "title": "Token to retrieve the next page of results, or empty if there are no\nmore results in the list" + } + } + }, + "v1ListGroupsRequest": { + "type": "object", + "properties": { + "pageSize": { + "type": "integer", + "format": "int32", + "title": "Optional. The maximum number of groups to return in the response" + }, + "pageToken": { + "type": "string", + "title": "Optional. A pagination token returned from a previous call to `Get`\nthat indicates from where search should continue" + }, + "fieldMask": { + "type": "string", + "description": "Optional. Used to specify a subset of fields that should be\nreturned by a get operation or modified by an update operation." + }, + "query": { + "type": "string", + "description": "TODO update query language\nQuery expressions can be used to restrict results based upon\nthe account properties where the operators `=`, `NOT`, `AND` and `OR`\ncan be used along with the suffix wildcard symbol `*`.\n\nThe string properties in a query expression should use escaped quotes\nfor values that include whitespace to prevent unexpected behavior.\n\nSome example queries are:\n\n* Query `display_name=Th*` returns accounts whose display_name\nstarts with \"Th\"\n* Query `display_name=\\\\\"Test String\\\\\"` returns groups with\ndisplay names that include both \"Test\" and \"String\"", + "title": "Optional. Search criteria used to select the groups to return.\nIf no search criteria is specified then all groups will be\nreturned" + } + } + }, + "v1ListGroupsResponse": { + "type": "object", + "properties": { + "groups": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Group" + }, + "title": "The field name should match the noun \"group\" in the method name. There\nwill be a maximum number of items returned based on the page_size field\nin the request" + }, + "nextPageToken": { + "type": "string", + "title": "Token to retrieve the next page of results, or empty if there are no\nmore results in the list" + } + } + }, + "v1ListMembersResponse": { + "type": "object", + "properties": { + "members": { + "type": "array", + "items": { + "$ref": "#/definitions/v1Account" + }, + "title": "The field name should match the noun \"members\" in the method name. There\nwill be a maximum number of items returned based on the page_size field\nin the request" + }, + "nextPageToken": { + "type": "string", + "title": "Token to retrieve the next page of results, or empty if there are no\nmore results in the list" + } + } + }, + "v1OnPremisesProvisioningError": { + "type": "object", + "properties": { + "category": { + "type": "string", + "description": "Category of the provisioning error. Note: Currently, there is only one possible value. Possible value: PropertyConflict - indicates a property value is not unique. Other objects contain the same value for the property." + }, + "occurredDateTime": { + "type": "string", + "format": "date-time", + "description": "The date and time at which the error occurred." + }, + "propertyCausingError": { + "type": "string", + "title": "Name of the directory property causing the error. Current possible values: UserPrincipalName or ProxyAddress" + }, + "value": { + "type": "string", + "description": "Value of the property causing the error." + } + } + }, + "v1PasswordProfile": { + "type": "object", + "properties": { + "password": { + "type": "string", + "description": "The password for the user. This property is required when a user is created.\nIt can be updated, but the user will be required to change the password on the next login.\nThe password must satisfy minimum requirements as specified by the user’s passwordPolicies property. By default, a strong password is required." + }, + "lastPasswordChangeDateTime": { + "type": "string", + "format": "date-time", + "description": "The time when this account last changed their password." + }, + "passwordPolicies": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Specifies password policies for the user.\nThis value is an enumeration with one possible value being “DisableStrongPassword”, which allows weaker passwords than the default policy to be specified.\n“DisablePasswordExpiration” can also be specified." + }, + "forceChangePasswordNextSignIn": { + "type": "boolean", + "description": "*true* if the user must change her password on the next login; otherwise false." + }, + "forceChangePasswordNextSignInWithMfa": { + "type": "boolean", + "description": "If *true*, at next sign-in, the user must perform a multi-factor authentication (MFA) before being forced to change their password. The behavior is identical to forceChangePasswordNextSignIn except that the user is required to first perform a multi-factor authentication before password change. After a password change, this property will be automatically reset to false. If not set, default is false." + } + } + }, + "v1RebuildIndexRequest": { + "type": "object" + }, + "v1RebuildIndexResponse": { + "type": "object" + }, + "v1UpdateAccountRequest": { + "type": "object", + "properties": { + "account": { + "$ref": "#/definitions/v1Account", + "title": "The account resource which replaces the resource on the server" + }, + "updateMask": { + "type": "string", + "title": "The update mask applies to the resource. For the `FieldMask` definition,\nsee https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask" + } + } + }, + "v1UpdateGroupRequest": { + "type": "object", + "properties": { + "group": { + "$ref": "#/definitions/v1Group", + "title": "The group resource which replaces the resource on the server" + }, + "updateMask": { + "type": "string", + "title": "The update mask applies to the resource. For the `FieldMask` definition,\nsee https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask" + } + } + } + } +} diff --git a/protogen/proto/buf.gen.yaml b/protogen/proto/buf.gen.yaml new file mode 100644 index 0000000000..6c8f06d436 --- /dev/null +++ b/protogen/proto/buf.gen.yaml @@ -0,0 +1,29 @@ +version: v1 +plugins: + - name: go + path: ../../.bingo/protoc-gen-go + out: ../gen/ + opt: + - paths=source_relative + + - name: micro + path: ../../.bingo/protoc-gen-micro + out: ../gen/ + opt: + - paths=source_relative + + - name: microweb + path: ../../.bingo/protoc-gen-microweb + out: ../gen/ + opt: + - paths=source_relative + + - name: openapiv2 + path: ../../.bingo/protoc-gen-openapiv2 + out: ../gen/ + + - name: doc + path: ../../.bingo/protoc-gen-doc + out: ../docs/extensions + opt: + - ../docs/GRPC.tmpl,grpc.md,source_relative diff --git a/protogen/proto/buf.lock b/protogen/proto/buf.lock new file mode 100644 index 0000000000..d1ae93a8d8 --- /dev/null +++ b/protogen/proto/buf.lock @@ -0,0 +1,10 @@ +# Generated by buf. DO NOT EDIT. +version: v1 +deps: + - remote: buf.build + owner: googleapis + repository: googleapis + branch: main + commit: 5860854adf6a48c39b19d54342b68385 + digest: b1-WayFxGJKhSLbpMCQ-VZ5-3R5Gj9iRFYsMG7o57lgqog= + create_time: 2021-12-14T15:10:38.563007Z diff --git a/protogen/proto/buf.yaml b/protogen/proto/buf.yaml new file mode 100644 index 0000000000..361675a46b --- /dev/null +++ b/protogen/proto/buf.yaml @@ -0,0 +1,9 @@ +version: v1 +lint: + use: + - DEFAULT +deps: + - buf.build/googleapis/googleapis +breaking: + use: + - FILE diff --git a/protogen/proto/ocis/messages/accounts/v1/accounts.proto b/protogen/proto/ocis/messages/accounts/v1/accounts.proto new file mode 100644 index 0000000000..106b19a6a5 --- /dev/null +++ b/protogen/proto/ocis/messages/accounts/v1/accounts.proto @@ -0,0 +1,329 @@ +syntax = "proto3"; + +package ocis.messages.accounts.v1; + +option go_package = "github.com/owncloud/ocis/protogen/gen/ocis/messages/accounts/v1"; + +import "google/protobuf/timestamp.proto"; +// Account follows the properties of the ms graph api user resource. +// See https://docs.microsoft.com/en-us/graph/api/resources/user?view=graph-rest-1.0#properties +message Account { + + // Note that field numbers in the range 1 through 15 take one byte to encode, including the field number and the field's type + + // The unique identifier for the user. Key. Not nullable. Non reassignable. Read-only. + string id = 1; + + // *true* if the account is enabled; otherwise, *false*. This property is required when a user is created. Supports $filter. + bool account_enabled = 2; + + // A resource account is also known as a /disabled user object/ in Azure AD, and can be used to represent resources in general. + // In Exchange it might be used to represent conference rooms, for example, and allow them to have a phone number. + // You could give printers or machines with a sync client resource accounts as well. + // A resource account can be homed in Microsoft 365 or on premises using Skype for Business Server 2019. + // *true* if the user is a resource account; otherwise, *false*. Null value should be considered false. + bool is_resource_account = 3; + + // Indicates whether the account was created as + // - a regular school or work account ("" / emptystring), + // - a local account, fully managed by oCIS (LocalAccount), includes synced accounts or + // - an external account (Invitation), + // - self-service sign-up using email verification (EmailVerified). Read-only. + string creation_type = 4; + + // Represents the identities that can be used to sign in to this account. + // An identity can be provided by oCIS (also known as a local account), by organizations, or by social identity providers such as Facebook, Google, and Microsoft, and is tied to an account. + // May contain multiple items with the same signInType value. Supports $filter. + repeated Identities identities = 5; + + // posixaccount properties + + // The name displayed in the address book for the account. + // This is usually the combination of the user's first name, middle initial and last name. + // This property is required when a user is created and it cannot be cleared during updates. + // Supports $filter and $orderby. + // posixaccount MUST cn + string display_name = 6; + + // The username + // posixaccount MUST uid + string preferred_name = 7; + + // TODO rename to on_premise_? or move to extension? see https://docs.microsoft.com/en-us/graph/extensibility-open-users + // used for exposing the user using ldap + // posixaccount MUST uidnumber + int64 uid_number = 8; + + // used for exposing the user using ldap + // posixaccount MUST gidnumber + int64 gid_number = 9; + + // posixaccount MUST homedirectory + // constructed dynamically in glauth + + // posixaccount MAY loginshell + // posixaccount MAY gecos + + // For the GECOS field: + // - User's full name (or application name, if the account is for a program) -> displayname (description) + // - Building and room number or contact person -> - + // - Office telephone number -> - + // - Any other contact information (pager number, fax, etc.) -> mail + // eg "Albert Einstein (Beware! I'm doing science!),,,einstein@example.com" as the gecos + + // The SMTP address for the user, for example, "jeff@contoso.onmicrosoft.com". Read-Only. Supports $filter. + // inetorgperson MAY mail + string mail = 10; + + // A description, useful for resource accounts + // posixaccount MAY description + string description = 11; + + // Specifies the password profile for the user. + // The profile contains the user’s password. This property is required when a user is created. + // The password in the profile must satisfy minimum requirements as specified by the passwordPolicies property. + // By default, a strong password is required. + // posixaccount MAY authPassword + PasswordProfile password_profile = 12; + + // The groups, directory roles and administrative units that the user is a member of. Read-only. Nullable. + // should we only respond with repeated strings of ids? no clients should a proper filter mask! + repeated Group memberOf = 13; + + // Field numbers in the range 16 through 2047 take two bytes. So you should reserve the field numbers 1 through 15 for very frequently occurring message elements. Remember to leave some room for frequently occurring elements that might be added in the future. + + // The created date of the account object. + google.protobuf.Timestamp created_date_time = 16; + + // The date and time the user was deleted. Returned only on $select. + google.protobuf.Timestamp deleted_date_time = 17; + + // properties for sync + + // *true* if this object is synced from an on-premises directory; + // *false* if this object was originally synced from an on-premises directory but is no longer synced; + // null if this object has never been synced from an on-premises directory (default). Read-only + bool on_premises_sync_enabled = 20; + + // This property is used to associate an on-premises LDAP user to the oCIS account object. + // This property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property. + // Important: The $ and _ characters cannot be used when specifying this property. Supports $filter. + string on_premises_immutable_id = 21; + + // Contains the on-premises security identifier (SID) for the user that was synchronized from on-premises to the cloud. Read-only. + string on_premises_security_identifier = 22; + + // Contains the on-premises LDAP `distinguished name` or `DN`. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + string on_premises_distinguished_name = 23; + + // Contains the on-premises `samAccountName` synchronized from the on-premises directory. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + string on_premises_sam_account_name = 24; + + // Contains the on-premises `domainFQDN`, also called `dnsDomainName` synchronized from the on-premises directory + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + string on_premises_domain_name = 25; + + // Contains the on-premises userPrincipalName synchronized from the on-premises directory. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + string on_premises_user_principal_name = 26; + + // Contains extensionAttributes 1-15 for the user. Note that the individual extension attributes are neither selectable nor filterable. + // For an onPremisesSyncEnabled user, this set of properties is mastered on-premises and is read-only. + // For a cloud-only user (where onPremisesSyncEnabled is false), these properties may be set during creation or update. + //onPremisesExtensionAttributes onPremisesExtensionAttributes = 27 + + // Indicates the last time at which the object was synced with the on-premises directory; Read-only. + google.protobuf.Timestamp on_premises_last_sync_date_time = 28; + + // Errors when using synchronization during provisioning. + repeated OnPremisesProvisioningError on_premises_provisioning_errors = 29; + + // TODO do we need to sync uidnumber and gidnumber from the external ldap? we may assign different numbers so eos has a non colliding namespace. + // we can sync them to the (uid|gid)_number fields but what if they changed in the external ldap and now collide? + // move those properties to a posixaccount message so we can exchange that part with an external (readonly or writeable) ldap server? + + // For an external user invited to the tenant using the invitation API, this property represents the invited user's invitation status. + // For invited users, the state can be `PendingAcceptance` or `Accepted`, or "" / emptystring for all other users. + // Returned only on $select. Supports $filter with the supported values. For example: $filter=externalUserState eq 'PendingAcceptance'. + string external_user_state = 40; + + // Shows the timestamp for the latest change to the externalUserState property. Returned only on $select. + google.protobuf.Timestamp external_user_state_change_date_time = 41; + + // Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get + // an error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph). + // If this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint. + // Returned only on $select. Read-only. Use invalidateAllRefreshTokens to reset. + google.protobuf.Timestamp refresh_tokens_valid_from_date_time = 60; + + // Any refresh tokens or sessions tokens (session cookies) issued before this time are invalid, and applications will get + // an error when using an invalid refresh or sessions token to acquire a delegated access token (to access APIs such as Microsoft Graph). + // If this happens, the application will need to acquire a new refresh token by making a request to the authorize endpoint. + // Read-only. Use revokeSignInSessions to reset. + google.protobuf.Timestamp sign_in_sessions_valid_from_date_time = 61; +} + +// Identities Represents an identity used to sign in to a user account. +// An identity can be provided by oCIS, by organizations, or by social identity providers such as Facebook, Google, or Microsoft, that are tied to a user account. +// This enables the user to sign in to the user account with any of those associated identities. +// They are also used to keep a history of old usernames. +message Identities { + // Specifies the user sign-in types in your directory, such as `emailAddress`, `userName` or `federated`. + // Here, federated represents a unique identifier for a user from an issuer, that can be in any format chosen by the issuer. + // Additional validation is enforced on *issuer_assigned_id* when the sign-in type is set to `emailAddress` or `userName`. + // This property can also be set to any custom string. + string sign_in_type = 1; + + // Specifies the issuer of the identity, for example facebook.com. + // For local accounts (where signInType is not federated), this property is + // the local B2C tenant default domain name, for example contoso.onmicrosoft.com. + // For external users from other Azure AD organization, this will be the domain of + // the federated organization, for example contoso.com. + // Supports $filter. 512 character limit. + string issuer = 2; + + // Specifies the unique identifier assigned to the user by the issuer. The combination of *issuer* and *issuerAssignedId* must be unique within the organization. Represents the sign-in name for the user, when signInType is set to emailAddress or userName (also known as local accounts). + // When *signInType* is set to: + // * `emailAddress`, (or starts with `emailAddress` like `emailAddress1`) *issuerAssignedId* must be a valid email address + // * `userName`, issuer_assigned_id must be a valid local part of an email address + // Supports $filter. 512 character limit. + string issuer_assigned_id = 3; +} +message PasswordProfile { + // The password for the user. This property is required when a user is created. + // It can be updated, but the user will be required to change the password on the next login. + // The password must satisfy minimum requirements as specified by the user’s passwordPolicies property. By default, a strong password is required. + string password = 1; + + // The time when this account last changed their password. + google.protobuf.Timestamp last_password_change_date_time = 2; + + // Specifies password policies for the user. + //This value is an enumeration with one possible value being “DisableStrongPassword”, which allows weaker passwords than the default policy to be specified. + // “DisablePasswordExpiration” can also be specified. + repeated string password_policies = 3; + + // *true* if the user must change her password on the next login; otherwise false. + bool force_change_password_next_sign_in = 4; + + // If *true*, at next sign-in, the user must perform a multi-factor authentication (MFA) before being forced to change their password. The behavior is identical to forceChangePasswordNextSignIn except that the user is required to first perform a multi-factor authentication before password change. After a password change, this property will be automatically reset to false. If not set, default is false. + bool force_change_password_next_sign_in_with_mfa = 5; +} + +message Group { + + // The unique identifier for the group. + // Returned by default. Inherited from directoryObject. Key. Not nullable. Read-only. + string id = 1; + + // groupofnames + + // The display name for the group. This property is required when a group is created and cannot be cleared during updates. + // Returned by default. Supports $filter and $orderby. + // groupofnames MUST cn + string display_name = 2; + // groupofnames MUST/MAY member + + // Users, contacts, and groups that are members of this group. HTTP Methods: GET (supported for all groups), POST (supported for security groups and mail-enabled security groups), DELETE (supported only for security groups) Read-only. Nullable. + // TODO accounts (users) only for now, we can add groups with the dedicated message using oneof construct later + repeated Account members = 3; + + // groupofnames MAY businessCategory + // groupofnames MAY o + // groupofnames MAY ou + // groupofnames MAY owner, SINGLE-VALUE but there might be multiple owners + repeated Account owners = 4; + + // An optional description for the group. Returned by default. + // groupofnames MAY description + string description = 5; + + // groupofnames MAY seeAlso + + // posixgroup + + // used for exposing the user using ldap + // posixgroup MUST gidnumber + int64 gid_number = 6; + // posixgroup MAY authPassword + // posixgroup MAY userPassword + // posixgroup MAY memberUid -> groupofnames member + // posixgroup MAY description -> groupofnames + + + // Timestamp of when the group was created. The value cannot be modified and is automatically populated when the group is created + // Returned by default. Read-only. + google.protobuf.Timestamp created_date_time = 7; + + // For some Azure Active Directory objects (user, group, application), if the object is deleted, it is first logically deleted, and this property is updated with the date and time when the object was deleted. Otherwise this property is null. If the object is restored, this property is updated to null. + // Returned by default. Read-only. + google.protobuf.Timestamp deleted_date_time = 8; + + // Timestamp of when the group is set to expire. The value cannot be modified and is automatically populated when the group is created. + // Returned by default. Read-only. + google.protobuf.Timestamp expiration_date_time = 9; + + // True if the group is not displayed in certain parts of the Outlook user interface: + // in the Address Book, in address lists for selecting message recipients, and in the Browse Groups dialog for searching groups; false otherwise. Default value is false. + // Returned only on $select. + bool hide_from_address_lists = 10; + + // Specifies the visibility of an Office 365 group. Possible values are: Private, Public, or Hiddenmembership; blank values are treated as public. See group visibility options to learn more. + // Visibility can be set only when a group is created; it is not editable. + // Returned by default. + string visibility = 11; + + // Field numbers in the range 16 through 2047 take two bytes. So you should reserve the field numbers 1 through 15 for very frequently occurring message elements. Remember to leave some room for frequently occurring elements that might be added in the future. + + // properties for sync + + // *true* if this group is synced from an on-premises directory; + // *false* if this group was originally synced from an on-premises directory but is no longer synced; + // null if this object has never been synced from an on-premises directory (default). + // Returned by default. Read-only. Supports $filter. + bool on_premises_sync_enabled = 20; + + // This property is used to associate an on-premises LDAP user to the oCIS account object. + // This property must be specified when creating a new user account in the Graph if you are using a federated domain for the user’s userPrincipalName (UPN) property. + // Important: The $ and _ characters cannot be used when specifying this property. Supports $filter. + string on_premises_immutable_id = 21; + + // Contains the on-premises security identifier (SID) for the group that was synchronized from on-premises to the cloud. Returned by default. Read-only. + string on_premises_security_identifier = 22; + + // Contains the on-premises LDAP `distinguished name` or `DN`. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Read-only. + string on_premises_distinguished_name = 23; + + // Contains the on-premises `samAccountName` synchronized from the on-premises directory. + // The property is only populated for customers who are synchronizing their on-premises directory to ocis-accounts. Returned by default. Read-only. + string on_premises_sam_account_name = 24; + + // Contains the on-premises domain FQDN, also called dnsDomainName synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect. + // Returned by default. Read-only. + string on_premises_domain_name = 25; + + // Contains the on-premises netBios name synchronized from the on-premises directory. The property is only populated for customers who are synchronizing their on-premises directory to Azure Active Directory via Azure AD Connect. + // Returned by default. Read-only. + string on_premises_net_bios_name = 26; + + // Indicates the last time at which the group was synced with the on-premises directory. + // Returned by default. Read-only. Supports $filter. + string on_premises_last_sync_date_time = 27; + + // Errors when using synchronization during provisioning. + repeated OnPremisesProvisioningError on_premises_provisioning_errors = 28; +} + +message OnPremisesProvisioningError { + // Category of the provisioning error. Note: Currently, there is only one possible value. Possible value: PropertyConflict - indicates a property value is not unique. Other objects contain the same value for the property. + string category = 1; + // The date and time at which the error occurred. + google.protobuf.Timestamp occurred_date_time = 2; + // Name of the directory property causing the error. Current possible values: UserPrincipalName or ProxyAddress + string property_causing_error = 3; + // Value of the property causing the error. + string value = 4; +} diff --git a/protogen/proto/ocis/services/accounts/v1/accounts.proto b/protogen/proto/ocis/services/accounts/v1/accounts.proto new file mode 100644 index 0000000000..471f35a1e9 --- /dev/null +++ b/protogen/proto/ocis/services/accounts/v1/accounts.proto @@ -0,0 +1,350 @@ +syntax = "proto3"; + +package ocis.services.accounts.v1; + +option go_package = "github.com/jvillafanez/prototest001/gen/ocis/services/accounts/v1"; + +import "ocis/messages/accounts/v1/accounts.proto"; +import "google/api/field_behavior.proto"; +import "google/api/annotations.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; +// Follow recommended Methods for rpc APIs https://cloud.google.com/apis/design/resources?hl=de#methods +// https://cloud.google.com/apis/design/standard_methods?hl=de#list +// https://cloud.google.com/apis/design/naming_convention?hl=de +service AccountsService { + // Lists accounts + rpc ListAccounts(ListAccountsRequest) returns (ListAccountsResponse) { + // List method maps to HTTP GET + option (google.api.http) = { + post: "/api/v1/accounts/accounts-list", + body: "*" + }; + } + // Gets an account + //rpc GetAccount(GetAccountRequest) returns (Account) { + rpc GetAccount(GetAccountRequest) returns (ocis.messages.accounts.v1.Account) { + option (google.api.http) = { + post: "/api/v1/accounts/accounts-get", + body: "*" + }; + } + // Creates an account + //rpc CreateAccount(CreateAccountRequest) returns (Account) { + rpc CreateAccount(CreateAccountRequest) returns (ocis.messages.accounts.v1.Account) { + // Create maps to HTTP POST. URL path as the collection name. + // HTTP request body contains the resource + option (google.api.http) = { + post: "/api/v1/accounts/accounts-create" + body: "*" + }; + } + // Updates an account + //rpc UpdateAccount(UpdateAccountRequest) returns (Account) { + rpc UpdateAccount(UpdateAccountRequest) returns (ocis.messages.accounts.v1.Account) { + // Update maps to HTTP PATCH. Resource name is mapped to a URL path. + // Resource is contained in the HTTP request body + option (google.api.http) = { + post: "/api/v1/accounts/accounts-update" + body: "*" + }; + }; + // Deletes an account + rpc DeleteAccount(DeleteAccountRequest) returns (google.protobuf.Empty) { + // Delete maps to HTTP DELETE. Resource name maps to the URL path. + // There is no request body + option (google.api.http) = { + post: "/api/v1/accounts/accounts-delete", + body: "*" + }; + } +} + +service GroupsService { + // Lists groups + rpc ListGroups(ListGroupsRequest) returns (ListGroupsResponse) { + // List method maps to HTTP GET + option (google.api.http) = { + post: "/api/v1/accounts/groups-list", + body: "*" + }; + } + // Gets an groups + rpc GetGroup(GetGroupRequest) returns (ocis.messages.accounts.v1.Group) { + option (google.api.http) = { + post: "/api/v1/accounts/groups-get", + body: "*" + }; + } + // Creates a group + rpc CreateGroup(CreateGroupRequest) returns (ocis.messages.accounts.v1.Group) { + // Create maps to HTTP POST. URL path as the collection name. + // HTTP request body contains the resource + option (google.api.http) = { + post: "/api/v1/accounts/groups-create" + body: "*" + }; + } + // Updates a group + rpc UpdateGroup(UpdateGroupRequest) returns (ocis.messages.accounts.v1.Group) { + // Update maps to HTTP PATCH. Resource name is mapped to a URL path. + // Resource is contained in the HTTP request body + option (google.api.http) = { + post: "/api/v1/accounts/groups-update" + body: "*" + }; + }; + // Deletes a group + rpc DeleteGroup(DeleteGroupRequest) returns (google.protobuf.Empty) { + // Delete maps to HTTP DELETE. Resource name maps to the URL path. + // There is no request body + option (google.api.http) = { + post: "/api/v1/accounts/groups-delete", + body: "*" + }; + } + + // additional group methods: https://docs.microsoft.com/en-us/graph/api/resources/group?view=graph-rest-1.0#methods + + // references are accessed using $ref, see http://docs.oasis-open.org/odata/odata/v4.0/cs01/part2-url-conventions/odata-v4.0-cs01-part2-url-conventions.html#_Toc365046422 + // or the stack overflow question https://stackoverflow.com/questions/49362894/why-is-the-microsoft-graph-api-using-ref-in-the-uri + + // group:addmember https://docs.microsoft.com/en-us/graph/api/group-post-members?view=graph-rest-1.0&tabs=http + rpc AddMember(AddMemberRequest) returns (ocis.messages.accounts.v1.Group) { + // All request parameters go into body. + option (google.api.http) = { + post: "/api/v1/groups/{group_id=*}/members/$ref" + body: "*" + }; + } + // group:removemember https://docs.microsoft.com/en-us/graph/api/group-delete-members?view=graph-rest-1.0 + rpc RemoveMember(RemoveMemberRequest) returns (ocis.messages.accounts.v1.Group) { + // All request parameters go into body. + option (google.api.http) = { + // URLs are broken + post: "/api/v1/groups/{group_id=*}/members/{account_id}/$ref" + body: "*" + }; + } + // group:listmembers https://docs.microsoft.com/en-us/graph/api/group-list-members?view=graph-rest-1.0 + rpc ListMembers(ListMembersRequest) returns (ListMembersResponse) { + // All request parameters go into body. + option (google.api.http) = { + // URLs are broken + post: "/api/v1/groups/{id=*}/members/$ref" + body: "*" + }; + } + +} + +service IndexService { + rpc RebuildIndex(RebuildIndexRequest) returns (RebuildIndexResponse) { + // All request parameters go into body. + option (google.api.http) = { + // URLs are broken + post: "/api/v1/index/rebuild" + body: "*" + }; + } +} + +message RebuildIndexRequest { +} + +message RebuildIndexResponse { +} + +message ListAccountsRequest { + // Optional. The maximum number of accounts to return in the response + int32 page_size = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A pagination token returned from a previous call to `Get` + // that indicates from where search should continue + string page_token = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Used to specify a subset of fields that should be + // returned by a get operation or modified by an update operation. + google.protobuf.FieldMask field_mask = 3; + + // Optional. Search criteria used to select the accounts to return. + // If no search criteria is specified then all accounts will be + // returned + // + // TODO update query language + // Query expressions can be used to restrict results based upon + // the account properties where the operators `=`, `NOT`, `AND` and `OR` + // can be used along with the suffix wildcard symbol `*`. + // + // The string properties in a query expression should use escaped quotes + // for values that include whitespace to prevent unexpected behavior. + // + // Some example queries are: + // + // * Query `display_name=Th*` returns accounts whose display_name + // starts with "Th" + // * Query `email=foo@example.com` returns accounts with + // `email` set to `foo@example.com` + // * Query `display_name=\\"Test String\\"` returns accounts with + // display names that include both "Test" and "String" + string query = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +message ListAccountsResponse { + // The field name should match the noun "accounts" in the method name. There + // will be a maximum number of items returned based on the page_size field + // in the request + repeated ocis.messages.accounts.v1.Account accounts = 1; + + // Token to retrieve the next page of results, or empty if there are no + // more results in the list + string next_page_token = 2; +} + +message GetAccountRequest { + string id = 1; +} + +message CreateAccountRequest { + // The account resource to create + ocis.messages.accounts.v1.Account account = 1; +} + +message UpdateAccountRequest { + // The account resource which replaces the resource on the server + ocis.messages.accounts.v1.Account account = 1; + + // The update mask applies to the resource. For the `FieldMask` definition, + // see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + google.protobuf.FieldMask update_mask = 2; + } + +message DeleteAccountRequest { + string id = 1; +} + +message ListGroupsRequest { + // Optional. The maximum number of groups to return in the response + int32 page_size = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A pagination token returned from a previous call to `Get` + // that indicates from where search should continue + string page_token = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Used to specify a subset of fields that should be + // returned by a get operation or modified by an update operation. + google.protobuf.FieldMask field_mask = 3; + + // Optional. Search criteria used to select the groups to return. + // If no search criteria is specified then all groups will be + // returned + // + // TODO update query language + // Query expressions can be used to restrict results based upon + // the account properties where the operators `=`, `NOT`, `AND` and `OR` + // can be used along with the suffix wildcard symbol `*`. + // + // The string properties in a query expression should use escaped quotes + // for values that include whitespace to prevent unexpected behavior. + // + // Some example queries are: + // + // * Query `display_name=Th*` returns accounts whose display_name + // starts with "Th" + // * Query `display_name=\\"Test String\\"` returns groups with + // display names that include both "Test" and "String" + string query = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +message ListGroupsResponse { + // The field name should match the noun "group" in the method name. There + // will be a maximum number of items returned based on the page_size field + // in the request + repeated ocis.messages.accounts.v1.Group groups = 1; + + // Token to retrieve the next page of results, or empty if there are no + // more results in the list + string next_page_token = 2; +} + +message GetGroupRequest { + string id = 1; +} + +message CreateGroupRequest { + // The account resource to create + ocis.messages.accounts.v1.Group group = 1; +} + +message UpdateGroupRequest { + // The group resource which replaces the resource on the server + ocis.messages.accounts.v1.Group group = 1; + + // The update mask applies to the resource. For the `FieldMask` definition, + // see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + google.protobuf.FieldMask update_mask = 2; + } + +message DeleteGroupRequest { + string id = 1; +} + +message AddMemberRequest { + // The id of the group to add a member to + string group_id = 1; + // The account id to add + string account_id = 2; +} + +message RemoveMemberRequest { + // The id of the group to remove a member from + string group_id = 1; + // The account id to remove + string account_id = 2; +} + +message ListMembersRequest { + int32 page_size = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A pagination token returned from a previous call to `Get` + // that indicates from where search should continue + string page_token = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Used to specify a subset of fields that should be + // returned by a get operation or modified by an update operation. + google.protobuf.FieldMask field_mask = 3; + + // Optional. Search criteria used to select the groups to return. + // If no search criteria is specified then all groups will be + // returned + // + // TODO update query language + // Query expressions can be used to restrict results based upon + // the account properties where the operators `=`, `NOT`, `AND` and `OR` + // can be used along with the suffix wildcard symbol `*`. + // + // The string properties in a query expression should use escaped quotes + // for values that include whitespace to prevent unexpected behavior. + // + // Some example queries are: + // + // * Query `display_name=Th*` returns accounts whose display_name + // starts with "Th" + // * Query `display_name=\\"Test String\\"` returns groups with + // display names that include both "Test" and "String" + string query = 4 [(google.api.field_behavior) = OPTIONAL]; + + // The id of the group to list members from + string id = 5; +} + +message ListMembersResponse { + // The field name should match the noun "members" in the method name. There + // will be a maximum number of items returned based on the page_size field + // in the request + repeated ocis.messages.accounts.v1.Account members = 1; + + // Token to retrieve the next page of results, or empty if there are no + // more results in the list + string next_page_token = 2; +}