resource

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 17, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateFullEventPayload

func CreateFullEventPayload(resource ScimResource) map[string]interface{}

func CreateNoticeEventPaylaod

func CreateNoticeEventPaylaod(resource ScimResource) map[string]interface{}

Types

type Address

type Address struct {
	StreetAddress string `json:"streetAddress,omitempty"`
	Locality      string `json:"locality,omitempty"`
	Region        string `json:"region,omitempty"`
	PostalCode    string `json:"postalCode,omitempty"`
	Country       string `json:"country,omitempty"`
	Formatted     string `json:"formatted,omitempty"`
	Type          string `json:"type,omitempty"`
	Primary       bool   `json:"primary,omitempty"`
}

type Extensions

type Extensions map[string]interface{}

type Group

type Group struct {
	DisplayName string `json:"displayName,omitempty"`
	Members     []GroupValue
}

type GroupValue

type GroupValue struct {
	Value   string
	Ref     string `json:"$ref,omitempty"`
	Display string `json:"display,omitempty"`
}

type Meta

type Meta struct {
	ResourceType string `json:"resourceType"`
	Created      time.Time
	LastModified time.Time
	Version      string
	Location     string
}

type MultiValuedAttribute

type MultiValuedAttribute struct {
	Value   string
	Type    string `json:"type,omitempty"`
	Primary bool   `json:"primary,omitempty"`
}

type Name

type Name struct {
	Formatted       string `json:"formatted,omitempty"`
	FamilyName      string `json:"familyName,omitempty"`
	GivenName       string `json:"givenName,omitempty"`
	MiddleName      string `json:"middleName,omitempty"`
	HonorificPrefix string `json:"honorificPrefix,omitempty"`
	HonorificSuffix string `json:"honorificSuffix,omitempty"`
}

type ScimResource

type ScimResource struct {
	Schemas    []string `json:"schemas"`
	Id         string
	ExternalId string
	Meta       Meta
	User
	Group
	Extensions
}

func GenerateFakeUser

func GenerateFakeUser(basePath string) ScimResource

type User

type User struct {
	Name              Name
	UserName          string `json:"userName,omitempty"`
	DisplayName       string `json:"displayName,omitempty"`
	Nickname          string `json:"nickname,omitempty"`
	ProfileUrl        string `json:"profileUrl,omitempty"`
	Emails            []MultiValuedAttribute
	Addresses         []Address
	PhoneNumbers      []MultiValuedAttribute
	Photos            []MultiValuedAttribute
	UserType          string `json:"userType,omitempty"`
	Title             string `json:"title,omitempty"`
	PreferredLanguage string `json:"preferredLanguage,omitempty"`
	Locale            string `json:"locale,omitempty"`
	Timezone          string `json:"timezone,omitempty"`
	Active            bool   `json:"active,omitempty"`
	Password          string `json:"password,omitempty"`
	Groups            []GroupValue
	X509Certificates  []MultiValuedAttribute
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL