Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options func(c bitwarden.PasswordManager)
func DisableRetryBackoff ¶
func DisableRetryBackoff() Options
func DisableSync ¶
func DisableSync() Options
func WithAppDataDir ¶
func WithExtraCACertsPath ¶
type PasswordManagerClient ¶ added in v0.10.0
type PasswordManagerClient interface { CreateAttachmentFromContent(ctx context.Context, itemId, filename string, content []byte) (*models.Item, error) CreateAttachmentFromFile(ctx context.Context, itemId, filePath string) (*models.Item, error) CreateFolder(context.Context, models.Folder) (*models.Folder, error) CreateItem(context.Context, models.Item) (*models.Item, error) CreateOrganizationCollection(ctx context.Context, collection models.OrgCollection) (*models.OrgCollection, error) DeleteAttachment(ctx context.Context, itemId, attachmentId string) error DeleteFolder(context.Context, models.Folder) error DeleteItem(context.Context, models.Item) error DeleteOrganizationCollection(ctx context.Context, obj models.OrgCollection) error EditFolder(context.Context, models.Folder) (*models.Folder, error) EditItem(context.Context, models.Item) (*models.Item, error) EditOrganizationCollection(ctx context.Context, collection models.OrgCollection) (*models.OrgCollection, error) FindFolder(ctx context.Context, options ...bitwarden.ListObjectsOption) (*models.Folder, error) FindItem(ctx context.Context, options ...bitwarden.ListObjectsOption) (*models.Item, error) FindOrganization(ctx context.Context, options ...bitwarden.ListObjectsOption) (*models.Organization, error) FindOrganizationMember(ctx context.Context, options ...bitwarden.ListObjectsOption) (*models.OrgMember, error) FindOrganizationCollection(ctx context.Context, options ...bitwarden.ListObjectsOption) (*models.OrgCollection, error) GetAttachment(ctx context.Context, itemId, attachmentId string) ([]byte, error) GetFolder(context.Context, models.Folder) (*models.Folder, error) GetItem(context.Context, models.Item) (*models.Item, error) GetOrganization(context.Context, models.Organization) (*models.Organization, error) GetOrganizationMember(context.Context, models.OrgMember) (*models.OrgMember, error) GetOrganizationCollection(ctx context.Context, collection models.OrgCollection) (*models.OrgCollection, error) GetSessionKey() string HasSessionKey() bool LoginWithAPIKey(ctx context.Context, password, clientId, clientSecret string) error LoginWithPassword(ctx context.Context, username, password string) error Logout(context.Context) error SetServer(context.Context, string) error SetSessionKey(string) Status(context.Context) (*Status, error) Sync(context.Context) error Unlock(ctx context.Context, password string) error }
func NewPasswordManagerClient ¶ added in v0.10.0
func NewPasswordManagerClient(execPath string, opts ...Options) PasswordManagerClient
type Status ¶
type Status struct { ServerURL string `json:"serverURL,omitempty"` LastSync time.Time `json:"lastSync,omitempty"` UserEmail string `json:"userEmail,omitempty"` UserID string `json:"userID,omitempty"` Status VaultStatus `json:"status,omitempty"` }
func (*Status) VaultFromServer ¶
func (*Status) VaultOfUser ¶
type VaultStatus ¶
type VaultStatus string
const ( StatusLocked VaultStatus = "locked" StatusUnauthenticated VaultStatus = "unauthenticated" StatusUnlocked VaultStatus = "unlocked" )
Click to show internal directories.
Click to hide internal directories.