Documentation
¶
Index ¶
- Constants
- Variables
- func FilterJSON(filter Filter) (string, error)
- type Accountability
- type Alterations
- type Client
- type ClientOption
- type Collection
- type CollectionCollapse
- type CollectionMeta
- type CollectionSchema
- type CollectionTranslation
- type CustomTranslation
- type Dashboard
- type Error
- type ErrorCode
- type ErrorExtensions
- type Field
- type FieldChoice
- type FieldChoices
- type FieldMeta
- type FieldOptions
- type FieldSchema
- type FieldSpecial
- type FieldTranslation
- type FieldType
- type FieldWidth
- type File
- type Filter
- func And(filters ...Filter) Filter
- func Between(field string, from, to any) Filter
- func Empty(field string) Filter
- func Eq(field string, value any) Filter
- func Gt(field string, value any) Filter
- func Gte(field string, value any) Filter
- func In(field string, values ...any) Filter
- func Lt(field string, value any) Filter
- func Lte(field string, value any) Filter
- func Neq(field string, value any) Filter
- func Noop() Filter
- func NotEmpty(field string) Filter
- func Or(filters ...Filter) Filter
- func Related(field string, filter Filter) Filter
- func StartsWith(field string, value string) Filter
- type Flow
- type Folder
- type Icon
- type ItemsClient
- func (items *ItemsClient[T]) Create(ctx context.Context, item *T) (*T, error)
- func (items *ItemsClient[T]) Delete(ctx context.Context, id string) error
- func (items *ItemsClient[T]) Filter(ctx context.Context, filter Filter, opts ...ReadOption) ([]*T, error)
- func (items *ItemsClient[T]) Get(ctx context.Context, id string, opts ...ReadOption) (*T, error)
- func (items *ItemsClient[T]) List(ctx context.Context, opts ...ReadOption) ([]*T, error)
- func (items *ItemsClient[T]) Update(ctx context.Context, id string, item *T) (*T, error)
- type ModuleBar
- type ModuleBarType
- type Nullable
- type Operation
- type Panel
- type Permission
- type PermissionAction
- type Preset
- type ProtoJSON
- type ReadOption
- type Relation
- type RelationAction
- type RelationDefinition
- type RelationMeta
- type RelationSchema
- type ResourceClient
- func (rc *ResourceClient[T, PK]) Create(ctx context.Context, item *T) (*T, error)
- func (rc *ResourceClient[T, PK]) Delete(ctx context.Context, id PK) error
- func (rc *ResourceClient[T, PK]) Get(ctx context.Context, id PK) (*T, error)
- func (rc *ResourceClient[T, PK]) List(ctx context.Context) ([]*T, error)
- func (rc *ResourceClient[T, PK]) Patch(ctx context.Context, id PK, item *T) (*T, error)
- type Role
- type ServerInfo
- type Settings
- type SingletonClient
- type User
Constants ¶
const ( ErrorCodeRecordNotUnique = "RECORD_NOT_UNIQUE" ErrorCodeInvalidForeignKey = "INVALID_FOREIGN_KEY" )
Variables ¶
var ( // ErrItemNotFound is returned when the item is not found in the collection. ErrItemNotFound = errors.New("directus: item not found") // ErrIEmpty is returned when the item is returned empty. ErrEmpty = errors.New("directus: empty") )
Functions ¶
func FilterJSON ¶
Types ¶
type Accountability ¶ added in v0.16.0
type Accountability string
const ( AccountabilityAll Accountability = "all" AccountabilityActivity Accountability = "activity" )
func (*Accountability) MarshalJSON ¶ added in v0.21.6
func (accountability *Accountability) MarshalJSON() ([]byte, error)
func (*Accountability) UnmarshalJSON ¶ added in v0.21.6
func (accountability *Accountability) UnmarshalJSON(data []byte) error
type Alterations ¶ added in v0.16.15
type Client ¶
type Client struct {
Collections *ResourceClient[Collection, string]
CustomTranslations *ResourceClient[CustomTranslation, string]
Folders *ResourceClient[Folder, string]
Roles *ResourceClient[Role, string]
Users *ResourceClient[User, string]
Presets *ResourceClient[Preset, int64]
Operations *ResourceClient[Operation, string]
Flows *ResourceClient[Flow, string]
Files *ResourceClient[File, string]
Permissions *ResourceClient[Permission, int64]
Dashboards *ResourceClient[Dashboard, string]
Panels *ResourceClient[Panel, string]
Relations *clientRelations
Fields *clientFields
Settings *clientSettings
Server *clientServer
// contains filtered or unexported fields
}
Client keeps a connection to a Directus instance.
type ClientOption ¶
type ClientOption func(client *Client)
ClientOption configures a client when creating it.
func WithBodyLogger ¶
func WithBodyLogger() ClientOption
WithBodyLogger prints the request and response bodies to the logger.
func WithLogger ¶
func WithLogger(logger *slog.Logger) ClientOption
WithLogger sets a custom logger for the sent requests and responses received from the server.
type Collection ¶ added in v0.16.0
type Collection struct {
Collection string `json:"collection"`
Meta CollectionMeta `json:"meta"`
Schema *CollectionSchema `json:"schema,omitempty"`
Fields []*Field `json:"fields,omitempty"`
}
type CollectionCollapse ¶ added in v0.16.0
type CollectionCollapse string
const ( CollectionCollapseOpen CollectionCollapse = "open" CollectionCollapseClosed CollectionCollapse = "closed" CollectionCollapseLocked CollectionCollapse = "locked" )
func (*CollectionCollapse) MarshalJSON ¶ added in v0.21.6
func (collapse *CollectionCollapse) MarshalJSON() ([]byte, error)
func (*CollectionCollapse) UnmarshalJSON ¶ added in v0.21.6
func (collapse *CollectionCollapse) UnmarshalJSON(data []byte) error
type CollectionMeta ¶ added in v0.16.0
type CollectionMeta struct {
Collection string `json:"collection,omitempty"`
Color string `json:"color,omitempty"`
Icon Icon `json:"icon,omitempty"`
Note string `json:"note,omitempty"`
Hidden bool `json:"hidden"`
Singleton bool `json:"singleton"`
ArchiveField string `json:"archive_field,omitempty"`
ArchiveValue string `json:"archive_value,omitempty"`
UnarchiveValue string `json:"unarchive_value,omitempty"`
ArchiveAppFilter bool `json:"archive_app_filter"`
SortField string `json:"sort_field,omitempty"`
Group Nullable[string] `json:"group,omitempty"`
Sort int64 `json:"sort,omitempty"`
Collapse CollectionCollapse `json:"collapse,omitempty"`
Versioning bool `json:"versioning,omitempty"`
Accountability Nullable[Accountability] `json:"accountability"`
System bool `json:"system,omitempty"`
PreviewURL string `json:"preview_url,omitempty"`
DisplayTemplate string `json:"display_template,omitempty"`
Translations []*CollectionTranslation `json:"translations,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*CollectionMeta) MarshalJSON ¶ added in v0.16.0
func (meta *CollectionMeta) MarshalJSON() ([]byte, error)
func (*CollectionMeta) Translation ¶ added in v0.24.2
func (meta *CollectionMeta) Translation(language string) *CollectionTranslation
func (*CollectionMeta) UnmarshalJSON ¶ added in v0.16.0
func (meta *CollectionMeta) UnmarshalJSON(data []byte) error
type CollectionSchema ¶ added in v0.16.0
type CollectionSchema struct {
Name string `json:"name"`
Comment string `json:"comment,omitempty"`
Collation string `json:"collation,omitempty"`
Engine string `json:"engine,omitempty"`
Schema string `json:"schema,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*CollectionSchema) MarshalJSON ¶ added in v0.16.0
func (schema *CollectionSchema) MarshalJSON() ([]byte, error)
func (*CollectionSchema) UnmarshalJSON ¶ added in v0.16.0
func (schema *CollectionSchema) UnmarshalJSON(data []byte) error
type CollectionTranslation ¶ added in v0.24.1
type CustomTranslation ¶ added in v0.16.0
type Error ¶ added in v0.15.0
type Error struct {
Message string `json:"message"`
Extensions ErrorExtensions `json:"extensions"`
}
type ErrorExtensions ¶ added in v0.15.0
type ErrorExtensions struct {
Code ErrorCode `json:"code"`
}
type Field ¶ added in v0.12.0
type Field struct {
Collection string `json:"collection"`
Field string `json:"field"`
Type FieldType `json:"type"`
Meta FieldMeta `json:"meta"`
Schema *FieldSchema `json:"schema,omitempty"`
}
type FieldChoice ¶ added in v0.24.5
type FieldChoices ¶ added in v0.24.8
type FieldChoices struct {
Choices []*FieldChoice
Values []any
}
func (*FieldChoices) MarshalJSON ¶ added in v1.0.1
func (choices *FieldChoices) MarshalJSON() ([]byte, error)
func (*FieldChoices) UnmarshalJSON ¶ added in v0.24.8
func (choices *FieldChoices) UnmarshalJSON(data []byte) error
type FieldMeta ¶ added in v0.12.0
type FieldMeta struct {
ID int64 `json:"id,omitempty"`
Hidden bool `json:"hidden"`
Width FieldWidth `json:"width,omitempty"`
ReadOnly bool `json:"read_only"`
Required bool `json:"required"`
Sort int64 `json:"sort,omitempty"`
System bool `json:"system,omitempty"`
Special []FieldSpecial `json:"special,omitempty"`
Translations []*FieldTranslation `json:"translations,omitempty"`
Options *FieldOptions `json:"options,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*FieldMeta) HasSpecial ¶ added in v0.16.12
func (meta *FieldMeta) HasSpecial(special FieldSpecial) bool
func (*FieldMeta) MarshalJSON ¶ added in v0.21.4
func (*FieldMeta) Translation ¶ added in v0.24.3
func (meta *FieldMeta) Translation(language string) *FieldTranslation
func (*FieldMeta) UnmarshalJSON ¶ added in v0.16.0
type FieldOptions ¶ added in v0.24.5
type FieldOptions struct {
Choices FieldChoices `json:"choices,omitempty"`
// contains filtered or unexported fields
}
func (*FieldOptions) MarshalJSON ¶ added in v0.24.5
func (options *FieldOptions) MarshalJSON() ([]byte, error)
func (*FieldOptions) UnmarshalJSON ¶ added in v0.24.5
func (options *FieldOptions) UnmarshalJSON(data []byte) error
type FieldSchema ¶ added in v0.16.0
type FieldSchema struct {
Name string `json:"name,omitempty"`
Table string `json:"table,omitempty"`
DataType string `json:"data_type"`
MaxLength int64 `json:"max_length,omitempty"`
IsNullable bool `json:"is_nullable"`
IsUnique bool `json:"is_unique,omitempty"`
IsPrimaryKey bool `json:"is_primary_key,omitempty"`
HasAutoIncrement bool `json:"has_auto_increment,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*FieldSchema) MarshalJSON ¶ added in v0.21.4
func (schema *FieldSchema) MarshalJSON() ([]byte, error)
func (*FieldSchema) UnmarshalJSON ¶ added in v0.16.0
func (schema *FieldSchema) UnmarshalJSON(data []byte) error
type FieldSpecial ¶ added in v0.16.0
type FieldSpecial string
const ( FieldSpecialManyToOne FieldSpecial = "m2o" FieldSpecialDateCreated FieldSpecial = "date-created" FieldSpecialDateUpdated FieldSpecial = "date-updated" FieldSpecialUUID FieldSpecial = "uuid" FieldSpecialUserCreated FieldSpecial = "user-created" FieldSpecialUserUpdated FieldSpecial = "user-updated" FieldSpecialFile FieldSpecial = "file" FieldSpecialAlias FieldSpecial = "alias" FieldSpecialNoData FieldSpecial = "no-data" FieldSpecialCastBoolean FieldSpecial = "cast-boolean" FieldSpecialGroup FieldSpecial = "group" )
func (*FieldSpecial) UnmarshalJSON ¶ added in v0.16.2
func (special *FieldSpecial) UnmarshalJSON(data []byte) error
type FieldTranslation ¶ added in v0.24.3
type FieldWidth ¶ added in v0.12.0
type FieldWidth string
const ( FieldWidthFull FieldWidth = "full" FieldWidthHalf FieldWidth = "half" )
func (*FieldWidth) UnmarshalJSON ¶ added in v0.21.5
func (width *FieldWidth) UnmarshalJSON(data []byte) error
type File ¶ added in v0.19.0
type File struct {
FileSize Nullable[int64] `json:"file_size"`
ID string `json:"id,omitempty"`
Folder Nullable[string] `json:"folder"`
Title Nullable[string] `json:"title"`
Type Nullable[string] `json:"type"`
Description Nullable[string] `json:"description"`
Storage string `json:"storage"`
Charset Nullable[string] `json:"charset"`
FilenameDowload string `json:"filename_download"`
FocalPointX Nullable[int32] `json:"focal_point_x"`
FocalPointY Nullable[int32] `json:"focal_point_y"`
Width Nullable[int32] `json:"width"`
Height Nullable[int32] `json:"height"`
Duration Nullable[int32] `json:"duration"`
Location Nullable[string] `json:"location"`
Tags Nullable[string] `json:"tags"`
Embed Nullable[string] `json:"embed"`
FilenameDisk Nullable[string] `json:"filename_disk"`
Unknown map[string]any `json:"-"`
}
func (*File) MarshalJSON ¶ added in v0.19.0
func (*File) UnmarshalJSON ¶ added in v0.19.0
type Filter ¶
type Filter interface {
String() string
// contains filtered or unexported methods
}
func StartsWith ¶ added in v0.17.0
type Flow ¶ added in v0.19.0
type Flow struct {
ID string `json:"id,omitempty"`
Name string `json:"name"`
Status string `json:"status"`
Description Nullable[string] `json:"description"`
Accountability Accountability `json:"accountability"`
Color string `json:"color,omitempty"`
Icon Icon `json:"icon,omitempty"`
Operation Nullable[string] `json:"operation"`
Operations []string `json:"operations,omitempty"`
UserCreated Nullable[string] `json:"user_created"`
Unknown map[string]any `json:"-"`
}
func (*Flow) MarshalJSON ¶ added in v0.19.0
func (*Flow) UnmarshalJSON ¶ added in v0.19.0
type Icon ¶ added in v0.16.0
type Icon string
func (*Icon) MarshalJSON ¶ added in v0.21.6
func (*Icon) UnmarshalJSON ¶ added in v0.21.6
type ItemsClient ¶
type ItemsClient[T any] struct { // contains filtered or unexported fields }
ItemsClient access the items API in a type-safe way.
func NewItemsClient ¶
func NewItemsClient[T any](client *Client, collection string, opts ...ReadOption) *ItemsClient[T]
NewItemsClient creates a new client to access & write items in a type-safe way.
func (*ItemsClient[T]) Create ¶
func (items *ItemsClient[T]) Create(ctx context.Context, item *T) (*T, error)
Create a new item in the collection.
func (*ItemsClient[T]) Delete ¶
func (items *ItemsClient[T]) Delete(ctx context.Context, id string) error
Delete an item from the collection by its primary key.
func (*ItemsClient[T]) Filter ¶
func (items *ItemsClient[T]) Filter(ctx context.Context, filter Filter, opts ...ReadOption) ([]*T, error)
Filter items of the collection.
func (*ItemsClient[T]) Get ¶
func (items *ItemsClient[T]) Get(ctx context.Context, id string, opts ...ReadOption) (*T, error)
Get a single item by its primary key. If it cannot be found, it returns ErrItemNotFound.
func (*ItemsClient[T]) List ¶
func (items *ItemsClient[T]) List(ctx context.Context, opts ...ReadOption) ([]*T, error)
List items of the collection.
type ModuleBarType ¶ added in v0.21.0
type ModuleBarType string
const ( ModuleBarTypeLink ModuleBarType = "link" ModuleBarTypeModule ModuleBarType = "module" )
func (*ModuleBarType) UnmarshalJSON ¶ added in v0.21.3
func (tp *ModuleBarType) UnmarshalJSON(data []byte) error
type Nullable ¶
func NewNullableValue ¶ added in v0.24.4
func (Nullable[T]) MarshalJSON ¶
func (*Nullable[T]) UnmarshalJSON ¶
type Operation ¶ added in v0.19.0
type Operation struct {
ID string `json:"id,omitempty"`
Flow string `json:"flow"`
Key string `json:"key"`
PositionX int32 `json:"position_x"`
PositionY int32 `json:"position_y"`
Type string `json:"type"`
Name Nullable[string] `json:"name"`
Reject Nullable[string] `json:"reject"`
Resolve Nullable[string] `json:"resolve"`
UserCreated Nullable[string] `json:"user_created"`
Unknown map[string]any `json:"-"`
}
func (*Operation) MarshalJSON ¶ added in v0.19.0
func (*Operation) UnmarshalJSON ¶ added in v0.19.0
type Panel ¶ added in v0.19.0
type Panel struct {
ID string `json:"id,omitempty"`
Dashboard string `json:"dashboard"`
Height int32 `json:"height"`
Width int32 `json:"width"`
PositionX int32 `json:"position_x"`
PositionY int32 `json:"position_y"`
ShowHeader bool `json:"show_header"`
Type string `json:"type"`
Color Nullable[string] `json:"color"`
Icon Icon `json:"icon"`
Name Nullable[string] `json:"name"`
Note Nullable[string] `json:"note"`
Unknown map[string]any `json:"-"`
}
func (*Panel) MarshalJSON ¶ added in v0.19.0
func (*Panel) UnmarshalJSON ¶ added in v0.19.0
type Permission ¶ added in v0.19.0
type Permission struct {
ID int64 `json:"id,omitempty"`
Role Nullable[string] `json:"role"`
Collection string `json:"collection"`
Action PermissionAction `json:"action"`
Fields Nullable[[]string] `json:"fields"`
System bool `json:"system,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*Permission) MarshalJSON ¶ added in v0.19.0
func (permission *Permission) MarshalJSON() ([]byte, error)
func (*Permission) UnmarshalJSON ¶ added in v0.19.0
func (permission *Permission) UnmarshalJSON(data []byte) error
type PermissionAction ¶ added in v0.19.0
type PermissionAction string
const ( PermissionActionCreate PermissionAction = "create" PermissionActionRead PermissionAction = "read" PermissionActionUpdate PermissionAction = "update" PermissionActionDelete PermissionAction = "delete" )
func (*PermissionAction) MarshalJSON ¶ added in v0.21.6
func (action *PermissionAction) MarshalJSON() ([]byte, error)
func (*PermissionAction) UnmarshalJSON ¶ added in v0.21.6
func (action *PermissionAction) UnmarshalJSON(data []byte) error
type Preset ¶ added in v0.18.0
type Preset struct {
ID int64 `json:"id,omitempty"`
Bookmark Nullable[string] `json:"bookmark"`
User Nullable[string] `json:"user"`
Role Nullable[string] `json:"role"`
Collection string `json:"collection"`
Layout Nullable[string] `json:"layout"`
Icon Nullable[string] `json:"icon"`
Unknown map[string]any `json:"-"`
}
func (*Preset) MarshalJSON ¶ added in v0.18.0
func (*Preset) UnmarshalJSON ¶ added in v0.18.0
type ProtoJSON ¶
func NewProtoJSON ¶
func (ProtoJSON[T]) MarshalJSON ¶
func (*ProtoJSON[T]) UnmarshalJSON ¶
type ReadOption ¶
ReadOption configures the returned data from Directus when reading or returning items.
func WithDeepLimit ¶ added in v0.10.0
func WithDeepLimit(field string, limit int64) ReadOption
WithDeepLimit limits the number of returned deep relations of each item.
func WithDeepSort ¶ added in v0.10.0
func WithDeepSort(field string, sort ...string) ReadOption
WithDeepSort sorts the deep relations of each returned item by the given fields. Use a minus sign (-) to sort in descending order. It does not order the items themselves. To sort the items, use WithSort.
func WithFields ¶
func WithFields(fields ...string) ReadOption
WithFields filters the fields of each returned item. It can add relations deep fields to the response to obtain them in the same request.
func WithLimit ¶ added in v0.10.0
func WithLimit(limit int64) ReadOption
WithLimit limits the number of returned items.
func WithOffset ¶ added in v0.10.0
func WithOffset(offset int64) ReadOption
WithOffset skips the first n items.
func WithSort ¶
func WithSort(sort ...string) ReadOption
WithSort sorts the returned items by the given fields. Use a minus sign (-) to sort in descending order. It does not order deep relations inside each of the items. To sort deep relations, use WithDeepSort.
type Relation ¶
type Relation[T any] struct { // contains filtered or unexported fields }
func NewRelation ¶
func NewRelationID ¶ added in v0.24.0
func NewRelationNumericID ¶ added in v0.24.0
func (Relation[T]) MarshalJSON ¶
func (*Relation[T]) UnmarshalJSON ¶
type RelationAction ¶ added in v0.16.0
type RelationAction string
const ( RelationActionCascade RelationAction = "CASCADE" RelationActionSetNull RelationAction = "SET NULL" RelationActionNoAction RelationAction = "NO ACTION" )
func (*RelationAction) UnmarshalJSON ¶ added in v0.16.11
func (action *RelationAction) UnmarshalJSON(data []byte) error
type RelationDefinition ¶ added in v0.16.0
type RelationDefinition struct {
Collection string `json:"collection"`
Field string `json:"field"`
RelatedCollection string `json:"related_collection"`
Schema RelationSchema `json:"schema"`
Meta RelationMeta `json:"meta"`
}
type RelationMeta ¶ added in v0.16.0
type RelationMeta struct {
ID int64 `json:"id,omitempty"`
System bool `json:"system,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*RelationMeta) MarshalJSON ¶ added in v0.16.0
func (meta *RelationMeta) MarshalJSON() ([]byte, error)
func (*RelationMeta) UnmarshalJSON ¶ added in v0.16.0
func (meta *RelationMeta) UnmarshalJSON(data []byte) error
type RelationSchema ¶ added in v0.16.0
type RelationSchema struct {
Table string `json:"table,omitempty"`
Column string `json:"column,omitempty"`
OnUpdate RelationAction `json:"on_update,omitempty"`
OnDelete RelationAction `json:"on_delete,omitempty"`
Unknown map[string]any `json:"-"`
}
func (*RelationSchema) MarshalJSON ¶ added in v0.16.0
func (schema *RelationSchema) MarshalJSON() ([]byte, error)
func (*RelationSchema) UnmarshalJSON ¶ added in v0.16.0
func (schema *RelationSchema) UnmarshalJSON(data []byte) error
type ResourceClient ¶ added in v0.16.0
func NewResourceClient ¶ added in v0.16.0
func (*ResourceClient[T, PK]) Create ¶ added in v0.16.0
func (rc *ResourceClient[T, PK]) Create(ctx context.Context, item *T) (*T, error)
func (*ResourceClient[T, PK]) Delete ¶ added in v0.16.0
func (rc *ResourceClient[T, PK]) Delete(ctx context.Context, id PK) error
func (*ResourceClient[T, PK]) Get ¶ added in v0.16.0
func (rc *ResourceClient[T, PK]) Get(ctx context.Context, id PK) (*T, error)
type ServerInfo ¶ added in v1.0.0
func (*ServerInfo) UnmarshalJSON ¶ added in v1.0.0
func (server *ServerInfo) UnmarshalJSON(data []byte) error
type Settings ¶ added in v0.21.0
type Settings struct {
ID int32 `json:"id"`
ProjectName string `json:"project_name"`
ProjectURL Nullable[string] `json:"project_url"`
ProjectDescriptor Nullable[string] `json:"project_descriptor"`
ProjectColor string `json:"project_color"`
DefaultLanguage string `json:"default_language"`
ModuleBar []ModuleBar `json:"module_bar,omitempty"`
AuthPasswordPolicy Nullable[string] `json:"auth_password_policy"`
AuthLoginAttempts int32 `json:"auth_login_attempts"`
CustomCSS Nullable[string] `json:"custom_css"`
Unknown map[string]any `json:"-"`
}
func (*Settings) MarshalJSON ¶ added in v0.21.0
func (*Settings) UnmarshalJSON ¶ added in v0.21.0
type SingletonClient ¶
type SingletonClient[T any] struct { // contains filtered or unexported fields }
func NewSingletonClient ¶
func NewSingletonClient[T any](client *Client, collection string, opts ...ReadOption) *SingletonClient[T]
type User ¶ added in v0.13.0
type User struct {
ID string `json:"id,omitempty"`
FirstName string `json:"first_name,omitempty"`
LastName string `json:"last_name,omitempty"`
Email string `json:"email,omitempty"`
Role string `json:"role,omitempty"`
Provider string `json:"provider,omitempty"`
ExternalIdentifier string `json:"external_identifier,omitempty"`
}