user_account.proto
path mgmt/v1alpha1/user_account.proto
package mgmt.v1alpha1
Messages
AcceptTeamAccountInviteRequest
Name | Type | Description |
---|---|---|
token | string |
AcceptTeamAccountInviteResponse
Name | Type | Description |
---|---|---|
account | UserAccount |
AccountInvite
Name | Type | Description |
---|---|---|
id | string | |
account_id | string | |
sender_user_id | string | |
email | string | |
token | string | |
accepted | bool | |
created_at | google.protobuf.Timestamp | |
updated_at | google.protobuf.Timestamp | |
expires_at | google.protobuf.Timestamp | |
role | AccountRole | The role of the user to invite. Only used if RBAC is enabled. |
AccountOnboardingConfig
Name | Type | Description |
---|---|---|
has_created_source_connection | bool | @deprecated - use has_completed_onboarding |
has_created_destination_connection | bool | @deprecated - use has_completed_onboarding |
has_created_job | bool | @deprecated - use has_completed_onboarding |
has_invited_members | bool | @deprecated - use has_completed_onboarding |
has_completed_onboarding | bool |
AccountTemporalConfig
Name | Type | Description |
---|---|---|
url | string | |
namespace | string | |
sync_job_queue_name | string |
AccountUser
Name | Type | Description |
---|---|---|
id | string | |
name | string | |
image | string | |
email | string | |
role | AccountRole | The role of the user in the account. If RBAC is not enabled, will be unspecified. |
ConvertPersonalToTeamAccountRequest
Name | Type | Description |
---|---|---|
name | string | The name of the team account |
account_id | optional string | Optionally provide the personal account to convert. This may be used in break-glass scenarios where there are multiple personal accounts And we want to convert one of them. If not provided, it will find the first one and convert it, leaving the other. |
ConvertPersonalToTeamAccountResponse
Name | Type | Description |
---|---|---|
account_id | string | The id of the team account (will be the same identifier as the personal account) |
checkout_session_url | optional string | If NeosyncCloud, will respond with a checkout session url so they can setup billing |
new_personal_account_id | string | The identifier of the newly created personal account |
CreateTeamAccountRequest
Name | Type | Description |
---|---|---|
name | string | The name of the team account |
CreateTeamAccountResponse
Name | Type | Description |
---|---|---|
account_id | string | |
checkout_session_url | optional string | If NeosyncCloud, will respond with a checkout session url so they can setup billing |
GetAccountBillingCheckoutSessionRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetAccountBillingCheckoutSessionResponse
Name | Type | Description |
---|---|---|
checkout_session_url | string | The url that will be redirected to |
GetAccountBillingPortalSessionRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetAccountBillingPortalSessionResponse
Name | Type | Description |
---|---|---|
portal_session_url | string | The url that will be redirected to |
GetAccountOnboardingConfigRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetAccountOnboardingConfigResponse
Name | Type | Description |
---|---|---|
config | AccountOnboardingConfig |
GetAccountStatusRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetAccountStatusResponse
Name | Type | Description |
---|---|---|
used_record_count | uint64 | A count of the currently used records for the current billing period. This may go over the allowed record count depending on when the record count is polled by the metric system. |
allowed_record_count | optional uint64 | The allowed record count. It will be null if there is no limit. |
subscription_status | BillingStatus | The current subscription status determined by the billing system. |
GetAccountTemporalConfigRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetAccountTemporalConfigResponse
Name | Type | Description |
---|---|---|
config | AccountTemporalConfig |
GetBillingAccountsRequest
Name | Type | Description |
---|---|---|
account_ids | repeated string | Optional list of account identifiers to filter the response by |
GetBillingAccountsResponse
Name | Type | Description |
---|---|---|
accounts | repeated UserAccount |
GetSystemInformationRequest
Name | Type | Description |
---|
GetSystemInformationResponse
Name | Type | Description |
---|---|---|
version | string | The Git tagged version |
commit | string | The Git commit |
compiler | string | The Go compiler flag that was used to build this version of Neosync |
platform | string | The Go platform flag that was used to build this version of Neosync |
build_date | google.protobuf.Timestamp |
GetTeamAccountInvitesRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetTeamAccountInvitesResponse
Name | Type | Description |
---|---|---|
invites | repeated AccountInvite |
GetTeamAccountMembersRequest
Name | Type | Description |
---|---|---|
account_id | string |
GetTeamAccountMembersResponse
Name | Type | Description |
---|---|---|
users | repeated AccountUser |
GetUserAccountsRequest
Name | Type | Description |
---|
GetUserAccountsResponse
Name | Type | Description |
---|---|---|
accounts | repeated UserAccount |
GetUserRequest
Name | Type | Description |
---|
GetUserResponse
Name | Type | Description |
---|---|---|
user_id | string |
InviteUserToTeamAccountRequest
Name | Type | Description |
---|---|---|
account_id | string | The account id to invite the user to |
email | string | The email of the user to invite |
role | optional AccountRole | The role of the user to invite. Only used if RBAC is enabled. |
InviteUserToTeamAccountResponse
Name | Type | Description |
---|---|---|
invite | AccountInvite |
IsAccountStatusValidRequest
Name | Type | Description |
---|---|---|
account_id | string | |
requested_record_count | optional uint64 | An optional count of records to be added to the current usage for validation. |
IsAccountStatusValidResponse
Name | Type | Description |
---|---|---|
is_valid | bool | |
reason | optional string | If the account is not valid, a reason for why may be provided. |
should_poll | bool | Whether or not the process should decide to continue polling for validitiy updates |
used_record_count | uint64 | A count of the currently used records for the current billing period. This may go over the allowed record count depending on when the record count is polled by the metric system. @deprecated |
allowed_record_count | optional uint64 | The allowed record count. It will be null if there is no limit. @deprecated |
account_status | AccountStatus | The current status of the account. Default is valid. |
trial_expires_at | optional google.protobuf.Timestamp | The time when the trial expires |
IsUserInAccountRequest
Name | Type | Description |
---|---|---|
account_id | string |
IsUserInAccountResponse
Name | Type | Description |
---|---|---|
ok | bool |
RemoveTeamAccountInviteRequest
Name | Type | Description |
---|---|---|
id | string |
RemoveTeamAccountInviteResponse
Name | Type | Description |
---|
RemoveTeamAccountMemberRequest
Name | Type | Description |
---|---|---|
user_id | string | |
account_id | string |
RemoveTeamAccountMemberResponse
Name | Type | Description |
---|
SetAccountOnboardingConfigRequest
Name | Type | Description |
---|---|---|
account_id | string | |
config | AccountOnboardingConfig |
SetAccountOnboardingConfigResponse
Name | Type | Description |
---|---|---|
config | AccountOnboardingConfig |
SetAccountTemporalConfigRequest
Name | Type | Description |
---|---|---|
account_id | string | |
config | AccountTemporalConfig |
SetAccountTemporalConfigResponse
Name | Type | Description |
---|---|---|
config | AccountTemporalConfig |
SetBillingMeterEventRequest
Name | Type | Description |
---|---|---|
account_id | string | The account id to apply this metered event to |
event_name | string | The metered event name |
value | string | The value of the meter for the given time |
event_id | string | The unique identifier of this metered event |
timestamp | optional uint64 | The time of the event in Unix Epoch format. Defaults to the current timestamp if not specified. |
SetBillingMeterEventResponse
Name | Type | Description |
---|
SetPersonalAccountRequest
Name | Type | Description |
---|
SetPersonalAccountResponse
Name | Type | Description |
---|---|---|
account_id | string |
SetUserRequest
Name | Type | Description |
---|
SetUserResponse
Name | Type | Description |
---|---|---|
user_id | string |
SetUserRoleRequest
Name | Type | Description |
---|---|---|
account_id | string | The account id to apply this role to |
user_id | string | The user that this will be applied to |
role | AccountRole | The role that this user will obtain |
SetUserRoleResponse
Name | Type | Description |
---|
UserAccount
Name | Type | Description |
---|---|---|
id | string | The unique identifier of the account |
name | string | The account slug |
type | UserAccountType | The type of account |
has_stripe_customer_id | bool | Whether or not the account has an associated stripe customer id |
Enums
AccountRole
Name | Number | Description |
---|---|---|
ACCOUNT_ROLE_UNSPECIFIED | 0 | Default value, this should not be used, but will default to ACCOUNT_ROLE_JOB_VIEWER |
ACCOUNT_ROLE_ADMIN | 1 | Admin, can do anything in the account. |
ACCOUNT_ROLE_JOB_DEVELOPER | 2 | Can view, edit jobs and connections |
ACCOUNT_ROLE_JOB_VIEWER | 3 | Can view |
ACCOUNT_ROLE_JOB_EXECUTOR | 4 | Can view and execute |
AccountStatus
Name | Number | Description |
---|---|---|
ACCOUNT_STATUS_REASON_UNSPECIFIED | 0 | Default value, should be used when no reason is specified |
ACCOUNT_STATUS_EXCEEDS_ALLOWED_LIMIT | 1 | @deprecated - Current usage exceeds allowed limit |
ACCOUNT_STATUS_REQUESTED_EXCEEDS_LIMIT | 2 | @deprecated - Adding requested records exceeds the allowed limit |
ACCOUNT_STATUS_ACCOUNT_IN_EXPIRED_STATE | 3 | Account is currently in an expired state |
ACCOUNT_STATUS_ACCOUNT_TRIAL_ACTIVE | 4 | The account is currently in an active trial period |
ACCOUNT_STATUS_ACCOUNT_TRIAL_EXPIRED | 5 | The account is past the active trial period |
BillingStatus
Name | Number | Description |
---|---|---|
BILLING_STATUS_UNSPECIFIED | 0 | |
BILLING_STATUS_ACTIVE | 1 | Corresponds to a billing subscription and rolls up various states into active This may be split into the future to be more granular and mirror the underlying billing system |
BILLING_STATUS_EXPIRED | 2 | If the system could not find any active subscriptions |
BILLING_STATUS_TRIAL_ACTIVE | 3 | The account does not have an active subscription and is in a valid trial period |
BILLING_STATUS_TRIAL_EXPIRED | 4 | The account does not have an active subscription and the trial period has ended |
UserAccountType
Name | Number | Description |
---|---|---|
USER_ACCOUNT_TYPE_UNSPECIFIED | 0 | |
USER_ACCOUNT_TYPE_PERSONAL | 1 | |
USER_ACCOUNT_TYPE_TEAM | 2 | |
USER_ACCOUNT_TYPE_ENTERPRISE | 3 |
Services
UserAccountService
GetUser
Method | GetUser |
---|---|
Request | GetUserRequest |
Response | GetUserResponse |
Description |
SetUser
Method | SetUser |
---|---|
Request | SetUserRequest |
Response | SetUserResponse |
Description |
GetUserAccounts
Method | GetUserAccounts |
---|---|
Request | GetUserAccountsRequest |
Response | GetUserAccountsResponse |
Description |
SetPersonalAccount
Method | SetPersonalAccount |
---|---|
Request | SetPersonalAccountRequest |
Response | SetPersonalAccountResponse |
Description |
ConvertPersonalToTeamAccount
Method | ConvertPersonalToTeamAccount |
---|---|
Request | ConvertPersonalToTeamAccountRequest |
Response | ConvertPersonalToTeamAccountResponse |
Description | Convert a personal account to a team account retaining all of the jobs and connections. This will also create a new empty personal account. |
CreateTeamAccount
Method | CreateTeamAccount |
---|---|
Request | CreateTeamAccountRequest |
Response | CreateTeamAccountResponse |
Description | Creates a new team account |
IsUserInAccount
Method | IsUserInAccount |
---|---|
Request | IsUserInAccountRequest |
Response | IsUserInAccountResponse |
Description |
GetAccountTemporalConfig
Method | GetAccountTemporalConfig |
---|---|
Request | GetAccountTemporalConfigRequest |
Response | GetAccountTemporalConfigResponse |
Description |
SetAccountTemporalConfig
Method | SetAccountTemporalConfig |
---|---|
Request | SetAccountTemporalConfigRequest |
Response | SetAccountTemporalConfigResponse |
Description |
GetTeamAccountMembers
Method | GetTeamAccountMembers |
---|---|
Request | GetTeamAccountMembersRequest |
Response | GetTeamAccountMembersResponse |
Description |
RemoveTeamAccountMember
Method | RemoveTeamAccountMember |
---|---|
Request | RemoveTeamAccountMemberRequest |
Response | RemoveTeamAccountMemberResponse |
Description |
InviteUserToTeamAccount
Method | InviteUserToTeamAccount |
---|---|
Request | InviteUserToTeamAccountRequest |
Response | InviteUserToTeamAccountResponse |
Description |
GetTeamAccountInvites
Method | GetTeamAccountInvites |
---|---|
Request | GetTeamAccountInvitesRequest |
Response | GetTeamAccountInvitesResponse |
Description |
RemoveTeamAccountInvite
Method | RemoveTeamAccountInvite |
---|---|
Request | RemoveTeamAccountInviteRequest |
Response | RemoveTeamAccountInviteResponse |
Description |
AcceptTeamAccountInvite
Method | AcceptTeamAccountInvite |
---|---|
Request | AcceptTeamAccountInviteRequest |
Response | AcceptTeamAccountInviteResponse |
Description |
GetSystemInformation
Method | GetSystemInformation |
---|---|
Request | GetSystemInformationRequest |
Response | GetSystemInformationResponse |
Description |
GetAccountOnboardingConfig
Method | GetAccountOnboardingConfig |
---|---|
Request | GetAccountOnboardingConfigRequest |
Response | GetAccountOnboardingConfigResponse |
Description |
SetAccountOnboardingConfig
Method | SetAccountOnboardingConfig |
---|---|
Request | SetAccountOnboardingConfigRequest |
Response | SetAccountOnboardingConfigResponse |
Description |
GetAccountStatus
Method | GetAccountStatus |
---|---|
Request | GetAccountStatusRequest |
Response | GetAccountStatusResponse |
Description | Returns different metrics on the account status for the active billing period |
IsAccountStatusValid
Method | IsAccountStatusValid |
---|---|
Request | IsAccountStatusValidRequest |
Response | IsAccountStatusValidResponse |
Description | Distils the account status down to whether not it is in a valid state. |
GetAccountBillingCheckoutSession
Method | GetAccountBillingCheckoutSession |
---|---|
Request | GetAccountBillingCheckoutSessionRequest |
Response | GetAccountBillingCheckoutSessionResponse |
Description | Returns a new checkout session for the account to subscribe |
GetAccountBillingPortalSession
Method | GetAccountBillingPortalSession |
---|---|
Request | GetAccountBillingPortalSessionRequest |
Response | GetAccountBillingPortalSessionResponse |
Description | Returns a new billing portal session if the account has a billing customer id |
GetBillingAccounts
Method | GetBillingAccounts |
---|---|
Request | GetBillingAccountsRequest |
Response | GetBillingAccountsResponse |
Description | Returns user accounts that have a billing id. |
SetBillingMeterEvent
Method | SetBillingMeterEvent |
---|---|
Request | SetBillingMeterEventRequest |
Response | SetBillingMeterEventResponse |
Description | Sends a new metered event to the billing system |
SetUserRole
Method | SetUserRole |
---|---|
Request | SetUserRoleRequest |
Response | SetUserRoleResponse |
Description | Sets the users role |