レコードフィールドクラス
Keeper Secrets Manager Go SDKで利用できる各フィールドタイプクラスの説明
レコードフィールドにアクセス
レコードフィールドにアクセスするには、GetFieldByType
関数を使用します。
loginField, ok := secret.GetFieldByType(ksm.Login{}).(*ksm.Login)
フィールドタイプクラスリファレンス
Keeperレコードフィールド
すべてのレコードフィールドはKeeperRecordField
クラスを拡張し、Label
フィールドとType
フィールドを含みます
type KeeperRecordField struct {
Type string `json:"type"`
Label string `json:"label,omitempty"`
}
フィールド値
Label
string
いいえ
""
型
string
はい
""
Password
type Password struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
EnforceGeneration bool `json:"enforceGeneration,omitempty"`
Complexity PasswordComplexity `json:"complexity,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
名前
型
必須
デフォルト
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
EnforceGeneration
bool
いいえ
false
Value
[]string
はい
Url
type Url struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
FileRef
type FileRef struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
Value
[]string
はい
OneTimeCode
type OneTimeCode struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
名前
type Name struct {
First string `json:"first,omitempty"`
Middle string `json:"middle,omitempty"`
Last string `json:"last,omitempty"`
}
フィールド値
First
string
いいえ
""
Middle
string
いいえ
""
Last
string
いいえ
""
Names
type Names struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []Name `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]Name
はい
BirthDate
type BirthDate struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []int64 `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]int64
はい
Date
type Date struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []int64 `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]int64
はい
ExpirationDate
type ExpirationDate struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []int64 `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]int64
はい
Text
type Text struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
SecurityQuestion
type SecurityQuestion struct {
Question string `json:"question,omitempty"`
Answer string `json:"answer,omitempty"`
}
フィールド値
Question
string
いいえ
""
Answer
string
いいえ
""
SecurityQuestions
type SecurityQuestions struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []SecurityQuestion `json:"value,omitempty"`
}
フィールド値
名前
型
必須
デフォルト
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]SecurityQuestion
はい
Multiline
type Multiline struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
Email
type Email struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
CardRef
type CardRef struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
AddressRef
type AddressRef struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
PinCode
type PinCode struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
Phone
type Phone struct {
Region string `json:"region,omitempty"`
Number string `json:"number,omitempty"`
Ext string `json:"ext,omitempty"`
Type string `json:"type,omitempty"`
}
フィールド値
Region
string
いいえ
""
Number
string
いいえ
""
Ext
string
いいえ
""
型
string
いいえ
""
Phones
type Phones struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []Phone `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]Phone
はい
Secret
type Secret struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
名前
型
必須
デフォルト
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
SecureNote
type SecureNote struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
AccountNumber
type AccountNumber struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
PaymentCard
type PaymentCard struct {
CardNumber string `json:"cardNumber,omitempty"`
CardExpirationDate string `json:"cardExpirationDate,omitempty"`
CardSecurityCode string `json:"cardSecurityCode,omitempty"`
}
フィールド値
名前
型
必須
デフォルト
CardNumber
string
いいえ
""
CardExpirationDate
string
いいえ
""
CardSecurityCode
string
いいえ
""
PaymentCards
type PaymentCards struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []PaymentCard `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]PaymentCard
はい
BankAccount
type BankAccount struct {
AccountType string `json:"accountType,omitempty"`
RoutingNumber string `json:"routingNumber,omitempty"`
AccountNumber string `json:"accountNumber,omitempty"`
OtherType string `json:"otherType,omitempty"`
}
フィールド値
AccountType
string
いいえ
""
RoutingNumber
string
いいえ
""
AccountNumber
string
いいえ
""
OtherType
string
いいえ
""
BankAccounts
type BankAccounts struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []BankAccount `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]BankAccount
はい
KeyPair
type KeyPair struct {
PublicKey string `json:"publicKey,omitempty"`
PrivateKey string `json:"privateKey,omitempty"`
}
PublicKey
string
いいえ
""
PrivateKey
string
いいえ
""
KeyPairs
type KeyPairs struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []KeyPair `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]KeyPair
はい
Host
type Host struct {
Hostname string `json:"hostName,omitempty"`
Port string `json:"port,omitempty"`
}
フィールド値
Hostname
string
いいえ
""
Port
string
いいえ
""
Hosts
type Hosts struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []Host `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]Host
はい
Address
type Address struct {
Street1 string `json:"street1,omitempty"`
Street2 string `json:"street2,omitempty"`
City string `json:"city,omitempty"`
State string `json:"state,omitempty"`
Country string `json:"country,omitempty"`
Zip string `json:"zip,omitempty"`
}
フィールド値
Street1
string
いいえ
""
Street2
string
いいえ
""
City
string
いいえ
""
State
string
いいえ
""
Country
string
いいえ
""
Zip
string
いいえ
""
Addresses
type Addresses struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []Address `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]Address
はい
LicenseNumber
type LicenseNumber struct {
KeeperRecordField
Required bool `json:"required,omitempty"`
PrivacyScreen bool `json:"privacyScreen,omitempty"`
Value []string `json:"value,omitempty"`
}
フィールド値
Label
string
いいえ
""
必須
bool
いいえ
false
PrivacyScreen
bool
いいえ
false
Value
[]string
はい
KeeperFileData
type KeeperFileData struct {
Title string `json:"title,omitempty"`
Name string `json:"name,omitempty"`
Type string `json:"type,omitempty"`
Size int64 `json:"size,omitempty"`
LastModified int64 `json:"lastModified,omitempty"`
}
フィールド値
名前
型
必須
デフォルト
Title
string
はい
Name
string
はい
型
string
はい
Size
int64
はい
LastModified
int64
はい
最終更新