mirror of
https://github.com/usememos/memos.git
synced 2024-12-29 16:42:11 +08:00
49 lines
1,023 B
Protocol Buffer
49 lines
1,023 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
package memos.store;
|
|
|
|
option go_package = "gen/store";
|
|
|
|
message UserSetting {
|
|
int32 user_id = 1;
|
|
|
|
UserSettingKey key = 2;
|
|
|
|
oneof value {
|
|
AccessTokensUserSetting access_tokens = 3;
|
|
string locale = 4;
|
|
string appearance = 5;
|
|
string memo_visibility = 6;
|
|
string telegram_user_id = 7;
|
|
}
|
|
}
|
|
|
|
enum UserSettingKey {
|
|
USER_SETTING_KEY_UNSPECIFIED = 0;
|
|
|
|
// Access tokens for the user.
|
|
USER_SETTING_ACCESS_TOKENS = 1;
|
|
|
|
// The locale of the user.
|
|
USER_SETTING_LOCALE = 2;
|
|
|
|
// The appearance of the user.
|
|
USER_SETTING_APPEARANCE = 3;
|
|
|
|
// The visibility of the memo.
|
|
USER_SETTING_MEMO_VISIBILITY = 4;
|
|
|
|
// The telegram user id of the user.
|
|
USER_SETTING_TELEGRAM_USER_ID = 5;
|
|
}
|
|
|
|
message AccessTokensUserSetting {
|
|
message AccessToken {
|
|
// The access token is a JWT token.
|
|
// Including expiration time, issuer, etc.
|
|
string access_token = 1;
|
|
// A description for the access token.
|
|
string description = 2;
|
|
}
|
|
repeated AccessToken access_tokens = 1;
|
|
}
|