Documentation ¶
Index ¶
- Constants
- func Category2Template(c Category) string
- func ParseTags(d *schema.ResourceData) []string
- func ProcessField(srcFields []SectionField) []map[string]interface{}
- func ProcessSections(srcSections []Section) []map[string]interface{}
- func Provider() *schema.Provider
- type Address
- type Annotation
- type Category
- type Details
- type Field
- type FieldType
- type Group
- type Item
- type Meta
- type OnePassClient
- func (o *OnePassClient) CreateDocument(v *Item, filePath string) error
- func (o *OnePassClient) CreateGroup(v *Group) (*Group, error)
- func (o *OnePassClient) CreateGroupMember(groupID string, userID string) error
- func (o *OnePassClient) CreateItem(v *Item) error
- func (o *OnePassClient) CreateVault(v *Vault) (*Vault, error)
- func (o *OnePassClient) Delete(resource string, id string) error
- func (o *OnePassClient) DeleteGroup(id string) error
- func (o *OnePassClient) DeleteGroupMember(groupID string, userID string) error
- func (o *OnePassClient) DeleteItem(id string) error
- func (o *OnePassClient) DeleteVault(id string) error
- func (o *OnePassClient) ListGroupMembers(id string) ([]User, error)
- func (o *OnePassClient) ReadDocument(id string) (string, error)
- func (o *OnePassClient) ReadGroup(id string) (*Group, error)
- func (o *OnePassClient) ReadItem(id string, vaultID string) (*Item, error)
- func (o *OnePassClient) ReadUser(id string) (*User, error)
- func (o *OnePassClient) ReadVault(id string) (*Vault, error)
- func (o *OnePassClient) SignIn() error
- func (o *OnePassClient) UpdateGroup(id string, v *Group) error
- type Overview
- type Resource
- type Section
- type SectionField
- type SectionFieldType
- type SectionGroup
- type User
- type Vault
Constants ¶
View Source
const ( // GroupResource is 1Password's internal designator for Groups GroupResource = "group" // GroupStateActive indicates an Active Group GroupStateActive = "A" // GroupStateDeleted indicates a Deleted Group GroupStateDeleted = "D" )
View Source
const ( // UserResource is 1Password's internal designator for Users UserResource = "user" // UserStateActive indicates an Active User UserStateActive = "A" // UserStateSuspended indicates a Suspended User UserStateSuspended = "S" )
View Source
const DocumentResource = "document"
View Source
const ItemResource = "item"
View Source
const VaultResource = "vault"
Variables ¶
This section is empty.
Functions ¶
func Category2Template ¶
func ParseTags ¶
func ParseTags(d *schema.ResourceData) []string
func ProcessField ¶
func ProcessField(srcFields []SectionField) []map[string]interface{}
func ProcessSections ¶
Types ¶
type Annotation ¶
type Annotation struct {
// contains filtered or unexported fields
}
type Category ¶
type Category string
const ( LoginCategory Category = "Login" IdentityCategory Category = "Identity" DatabaseCategory Category = "Database" MembershipCategory Category = "Membership" WirelessRouterCategory Category = "Wireless Router" SecureNoteCategory Category = "Secure Note" SoftwareLicenseCategory Category = "Software License" CreditCardCategory Category = "Credit Card" DriverLicenseCategory Category = "Driver License" OutdoorLicenseCategory Category = "Outdoor License" PassportCategory Category = "Passport" EmailAccountCategory Category = "Email Account" PasswordCategory Category = "Password" RewardProgramCategory Category = "Reward Program" SocialSecurityNumberCategory Category = "Social Security Number" BankAccountCategory Category = "Bank Account" DocumentCategory Category = "Document" ServerCategory Category = "Server" UnknownCategory Category = "UNKNOWN" )
func Template2Category ¶
type Meta ¶
type Meta struct {
// contains filtered or unexported fields
}
func NewMeta ¶
func NewMeta(d *schema.ResourceData) (*Meta, diag.Diagnostics)
func (*Meta) NewOnePassClient ¶
func (m *Meta) NewOnePassClient() (*OnePassClient, error)
type OnePassClient ¶
type OnePassClient struct { Password string Email string SecretKey string Subdomain string PathToOp string Session string // contains filtered or unexported fields }
func (*OnePassClient) CreateDocument ¶
func (o *OnePassClient) CreateDocument(v *Item, filePath string) error
func (*OnePassClient) CreateGroup ¶
func (o *OnePassClient) CreateGroup(v *Group) (*Group, error)
CreateGroup creates a new 1Password Group
func (*OnePassClient) CreateGroupMember ¶
func (o *OnePassClient) CreateGroupMember(groupID string, userID string) error
CreateGroupMember adds a User to a Group
func (*OnePassClient) CreateItem ¶
func (o *OnePassClient) CreateItem(v *Item) error
func (*OnePassClient) CreateVault ¶
func (o *OnePassClient) CreateVault(v *Vault) (*Vault, error)
func (*OnePassClient) DeleteGroup ¶
func (o *OnePassClient) DeleteGroup(id string) error
DeleteGroup deletes a 1Password Group
func (*OnePassClient) DeleteGroupMember ¶
func (o *OnePassClient) DeleteGroupMember(groupID string, userID string) error
DeleteGroupMember removes a User from a Group
func (*OnePassClient) DeleteItem ¶
func (o *OnePassClient) DeleteItem(id string) error
func (*OnePassClient) DeleteVault ¶
func (o *OnePassClient) DeleteVault(id string) error
func (*OnePassClient) ListGroupMembers ¶
func (o *OnePassClient) ListGroupMembers(id string) ([]User, error)
ListGroupMembers lists the existing Users in a given Group
func (*OnePassClient) ReadDocument ¶
func (o *OnePassClient) ReadDocument(id string) (string, error)
func (*OnePassClient) ReadGroup ¶
func (o *OnePassClient) ReadGroup(id string) (*Group, error)
ReadGroup gets an existing 1Password Group
func (*OnePassClient) ReadItem ¶
func (o *OnePassClient) ReadItem(id string, vaultID string) (*Item, error)
func (*OnePassClient) ReadUser ¶
func (o *OnePassClient) ReadUser(id string) (*User, error)
ReadUser gets an existing 1Password User This supports multiple id parameter values, including "First Last", "Email", and "UUID".
func (*OnePassClient) SignIn ¶
func (o *OnePassClient) SignIn() error
func (*OnePassClient) UpdateGroup ¶
func (o *OnePassClient) UpdateGroup(id string, v *Group) error
UpdateGroup updates an existing 1Password Group
type Section ¶
type Section struct { Name string `json:"name"` Title string `json:"title"` Fields []SectionField `json:"fields"` }
func ParseSections ¶
func ParseSections(d *schema.ResourceData) []Section
type SectionField ¶
type SectionField struct { Type SectionFieldType `json:"k"` Text string `json:"t"` Value interface{} `json:"v"` N string `json:"n"` A Annotation `json:"a"` Inputs map[string]string `json:"inputTraits"` }
func ParseField ¶
func ParseField(fl map[string]interface{}) SectionField
func ParseFields ¶
func ParseFields(s map[string]interface{}) []SectionField
type SectionFieldType ¶
type SectionFieldType string
const ( TypeSex SectionFieldType = "menu" TypeCard SectionFieldType = "cctype" TypeAddress SectionFieldType = "address" TypeString SectionFieldType = "string" TypeURL SectionFieldType = "URL" TypeEmail SectionFieldType = "email" TypeDate SectionFieldType = "date" TypeMonthYear SectionFieldType = "monthYear" TypeConcealed SectionFieldType = "concealed" TypePhone SectionFieldType = "phone" TypeReference SectionFieldType = "reference" )
type SectionGroup ¶
Source Files ¶
- data_group.go
- data_item_common.go
- data_item_credit_card.go
- data_item_document.go
- data_item_identity.go
- data_item_login.go
- data_item_password.go
- data_item_secure_note.go
- data_item_software_license.go
- data_user.go
- data_vault.go
- group.go
- helper.go
- item.go
- provider.go
- resource_group.go
- resource_group_member.go
- resource_item_common.go
- resource_item_credit_card.go
- resource_item_document.go
- resource_item_identity.go
- resource_item_login.go
- resource_item_password.go
- resource_item_secure_note.go
- resource_item_software_license.go
- resource_vault.go
- section.go
- user.go
- vault.go
Click to show internal directories.
Click to hide internal directories.