jamf

package module
v0.0.0-...-58a68a8 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2023 License: MIT Imports: 17 Imported by: 0

README

Jamf API in Go

Install

import "github.com/yohan460/go-jamf-api"

Usage

sample code: examples

Get auth token in curl

$ curl -u username:password -X POST "https://xxxxx.jamfcloud.com/uapi/auth/tokens"
$ token=xxxxx
$ curl -X GET -H "Content-Type: application/json" -H "Authorization: Bearer $token" "https://xxxxx.jamfcloud.com/uapi/v1/departments"

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Building

type Building struct {
	Id             *string `json:"id,omitempty"` // The response type to be returned is a string
	Name           *string `json:"name,omitempty"`
	StreetAddress1 *string `json:"streetAddress1,omitempty"`
	StreetAddress2 *string `json:"streetAddress2,omitempty"`
	City           *string `json:"city,omitempty"`
	StateProvince  *string `json:"stateProvince,omitempty"`
	ZipPostalCode  *string `json:"zipPostalCode,omitempty"`
	Country        *string `json:"country,omitempty"`
	Href           *string `json:"href,omitempty"`
}

func (*Building) GetCity

func (d *Building) GetCity() string

func (*Building) GetCountry

func (d *Building) GetCountry() string

func (*Building) GetId

func (d *Building) GetId() string

func (*Building) GetName

func (d *Building) GetName() string

func (*Building) GetStateProvince

func (d *Building) GetStateProvince() string

func (*Building) GetStreetAddress1

func (d *Building) GetStreetAddress1() string

func (*Building) GetStreetAddress2

func (d *Building) GetStreetAddress2() string

func (*Building) GetZipPostalCode

func (d *Building) GetZipPostalCode() string

func (*Building) SetCity

func (d *Building) SetCity(v string)

func (*Building) SetCountry

func (d *Building) SetCountry(v string)

func (*Building) SetId

func (d *Building) SetId(v string)

Buildings

func (*Building) SetName

func (d *Building) SetName(v string)

func (*Building) SetStateProvince

func (d *Building) SetStateProvince(v string)

func (*Building) SetStreetAddress1

func (d *Building) SetStreetAddress1(v string)

func (*Building) SetStreetAddress2

func (d *Building) SetStreetAddress2(v string)

func (*Building) SetZipPostalCode

func (d *Building) SetZipPostalCode(v string)

type BuildingScope

type BuildingScope struct {
	ID   int    `xml:"id,omitempty"`
	Name string `xml:"name,omitempty"`
}

type Category

type Category struct {
	Id       *string `json:"id,omitempty"` // The response type to be returned is a string
	Name     *string `json:"name,omitempty"`
	Priority *int    `json:"priority,omitempty"`
	Href     *string `json:"href,omitempty"`
}

func (*Category) GetId

func (d *Category) GetId() string

func (*Category) GetName

func (d *Category) GetName() string

func (*Category) GetPriority

func (d *Category) GetPriority() int

func (*Category) SetId

func (d *Category) SetId(v string)

Categories

func (*Category) SetName

func (d *Category) SetName(v string)

func (*Category) SetPriority

func (d *Category) SetPriority(v int)

type Client

type Client struct {

	// The Http Client that is used to make requests
	HttpClient       *http.Client
	HttpRetryTimeout time.Duration

	// Option to specify extra headers like User-Agent
	ExtraHeader map[string]string
	// contains filtered or unexported fields
}

Client ... stores an object to talk with Jamf API

func NewClient

func NewClient(username, password, url string) (*Client, error)

NewClient ... returns a new jamf.Client which can be used to access the API

func NewOAuthClient

func NewOAuthClient(clientId, clientSecret, url string) (*Client, error)

NewOAuthClient ... returns a new jamf.Client which can be used to access the API using the new bearer tokens

func (*Client) CreateBuilding

func (c *Client) CreateBuilding(name, sa1, sa2, city, sp, zpc, country *string) (*Building, error)

func (*Client) CreateCategory

func (c *Client) CreateCategory(name *string, priority *int) (*Category, error)

func (*Client) CreateComputerConfigurationProfile

func (c *Client) CreateComputerConfigurationProfile(d *ComputerConfigurationProfile) (int, error)

func (*Client) CreateComputerExtensionAttribute

func (c *Client) CreateComputerExtensionAttribute(d *ComputerExtensionAttribute) (int, error)

func (*Client) CreateComputerGroup

func (c *Client) CreateComputerGroup(d *ComputerGroupRequest) (int, error)

func (*Client) CreateDepartment

func (c *Client) CreateDepartment(name *string) (*Department, error)

func (*Client) CreateMobileDeviceGroup

func (c *Client) CreateMobileDeviceGroup(d *MobileDeviceGroupRequest) (int, error)

func (*Client) CreatePackage

func (c *Client) CreatePackage(d *Package) (int, error)

func (*Client) CreatePolicy

func (c *Client) CreatePolicy(d *Policy) (int, error)

func (*Client) CreateScript

func (c *Client) CreateScript(d *Script) (string, error)

func (*Client) DeleteBuilding

func (c *Client) DeleteBuilding(name string) error

func (*Client) DeleteCategory

func (c *Client) DeleteCategory(name string) error

func (*Client) DeleteComputerConfigurationProfile

func (c *Client) DeleteComputerConfigurationProfile(id int) (int, error)

func (*Client) DeleteComputerExtensionAttribute

func (c *Client) DeleteComputerExtensionAttribute(id int) (int, error)

func (*Client) DeleteComputerGroup

func (c *Client) DeleteComputerGroup(id int) (int, error)

func (*Client) DeleteComputerInventoryByID

func (c *Client) DeleteComputerInventoryByID(id string) error

func (*Client) DeleteDepartment

func (c *Client) DeleteDepartment(name string) error

func (*Client) DeleteMobileDeviceGroup

func (c *Client) DeleteMobileDeviceGroup(id int) (int, error)

func (*Client) DeletePackage

func (c *Client) DeletePackage(id int) (int, error)

func (*Client) DeletePolicy

func (c *Client) DeletePolicy(id int) (int, error)

func (*Client) DeleteScript

func (c *Client) DeleteScript(id string) (string, error)

func (*Client) DoRequest

func (c *Client) DoRequest(method, api string, reqbody interface{}, params *url.Values, out interface{}) error

doJsonRequest ... A method to send a request to the jamf api

func (*Client) GetBuilding

func (c *Client) GetBuilding(id string) (*Building, error)

func (*Client) GetBuildingByName

func (c *Client) GetBuildingByName(name string) (*Building, error)

func (*Client) GetBuildingIdByName

func (c *Client) GetBuildingIdByName(name string) (string, error)

func (*Client) GetBuildings

func (c *Client) GetBuildings() (*ResponseBuildings, error)

func (*Client) GetCategories

func (c *Client) GetCategories() (*ResponseCategories, error)

func (*Client) GetCategory

func (c *Client) GetCategory(id string) (*Category, error)

func (*Client) GetCategoryByName

func (c *Client) GetCategoryByName(name string) (*Category, error)

func (*Client) GetCategoryIdByName

func (c *Client) GetCategoryIdByName(name string) (string, error)

func (*Client) GetComputerByID

func (c *Client) GetComputerByID(id int) (*Computer, error)

func (*Client) GetComputerByUDID

func (c *Client) GetComputerByUDID(udid string) (*Computer, error)

func (*Client) GetComputerConfigurationProfile

func (c *Client) GetComputerConfigurationProfile(id int) (*ComputerConfigurationProfile, error)

func (*Client) GetComputerConfigurationProfileByName

func (c *Client) GetComputerConfigurationProfileByName(name string) (*ComputerConfigurationProfile, error)

func (*Client) GetComputerConfigurationProfileIdByName

func (c *Client) GetComputerConfigurationProfileIdByName(name string) (int, error)

func (*Client) GetComputerConfigurationProfiles

func (c *Client) GetComputerConfigurationProfiles() (*ComputerConfigurationProfileListResponse, error)

func (*Client) GetComputerDataSubsetByID

func (c *Client) GetComputerDataSubsetByID(id int, subset ComputerDataSubsetName) (*Computer, error)

func (*Client) GetComputerDataSubsetByUDID

func (c *Client) GetComputerDataSubsetByUDID(udid string, subset ComputerDataSubsetName) (*Computer, error)

func (*Client) GetComputerExtensionAttribute

func (c *Client) GetComputerExtensionAttribute(id int) (*ComputerExtensionAttribute, error)

func (*Client) GetComputerExtensionAttributeByName

func (c *Client) GetComputerExtensionAttributeByName(name string) (*ComputerExtensionAttribute, error)

func (*Client) GetComputerExtensionAttributes

func (c *Client) GetComputerExtensionAttributes() (*ComputerExtensionAttributeListResponse, error)

func (*Client) GetComputerGroup

func (c *Client) GetComputerGroup(id int) (*ComputerGroup, error)

func (*Client) GetComputerGroupByName

func (c *Client) GetComputerGroupByName(name string) (*ComputerGroup, error)

func (*Client) GetComputerGroupIdByName

func (c *Client) GetComputerGroupIdByName(name string) (int, error)

func (*Client) GetComputerGroups

func (c *Client) GetComputerGroups() (*ComputerGroupsResponse, error)

func (*Client) GetComputerInventories

func (c *Client) GetComputerInventories(query *ComputerInventoriesQuery) (*ComputerInventoriesResponse, error)

func (*Client) GetComputerInventoryByID

func (c *Client) GetComputerInventoryByID(id string, sections ...ComputerInventoryDataSubsetName) (*ComputerInventory, error)

func (*Client) GetComputerInventoryDetailByID

func (c *Client) GetComputerInventoryDetailByID(id string) (*ComputerInventory, error)

func (*Client) GetComputers

func (c *Client) GetComputers() (*ComputersResponse, error)

func (*Client) GetDepartment

func (c *Client) GetDepartment(id string) (*Department, error)

func (*Client) GetDepartmentByName

func (c *Client) GetDepartmentByName(name string) (*Department, error)

func (*Client) GetDepartmentIdByName

func (c *Client) GetDepartmentIdByName(name string) (string, error)

func (*Client) GetDepartments

func (c *Client) GetDepartments() (*ResponseDepartments, error)

func (*Client) GetMobileDeviceGroup

func (c *Client) GetMobileDeviceGroup(id int) (*MobileDeviceGroup, error)

func (*Client) GetMobileDeviceGroupByName

func (c *Client) GetMobileDeviceGroupByName(name string) (*MobileDeviceGroup, error)

func (*Client) GetMobileDeviceGroupIdByName

func (c *Client) GetMobileDeviceGroupIdByName(name string) (int, error)

func (*Client) GetMobileDeviceGroups

func (c *Client) GetMobileDeviceGroups() (*MobileDeviceGroupsResponse, error)

func (*Client) GetPackage

func (c *Client) GetPackage(id int) (*Package, error)

func (*Client) GetPackageByName

func (c *Client) GetPackageByName(name string) (*Package, error)

func (*Client) GetPackageIdByName

func (c *Client) GetPackageIdByName(name string) (int, error)

func (*Client) GetPackages

func (c *Client) GetPackages() (*PackageListResponse, error)

func (*Client) GetPolicies

func (c *Client) GetPolicies() (*PolicyListResponse, error)

func (*Client) GetPolicy

func (c *Client) GetPolicy(id int) (*Policy, error)

func (*Client) GetPolicyByName

func (c *Client) GetPolicyByName(name string) (*Policy, error)

func (*Client) GetPolicyIdByName

func (c *Client) GetPolicyIdByName(name string) (int, error)

func (*Client) GetScript

func (c *Client) GetScript(id string) (*Script, error)

func (*Client) GetScriptByName

func (c *Client) GetScriptByName(name string) (*Script, error)

func (*Client) GetScripts

func (c *Client) GetScripts() (*ScriptsListResponse, error)

func (*Client) UpdateBuilding

func (c *Client) UpdateBuilding(d *Building) (*Building, error)

func (*Client) UpdateCategory

func (c *Client) UpdateCategory(d *Category) (*Category, error)

func (*Client) UpdateComputerConfigurationProfile

func (c *Client) UpdateComputerConfigurationProfile(d *ComputerConfigurationProfile) (int, error)

func (*Client) UpdateComputerExtensionAttribute

func (c *Client) UpdateComputerExtensionAttribute(d *ComputerExtensionAttribute) (int, error)

func (*Client) UpdateComputerGroup

func (c *Client) UpdateComputerGroup(d *ComputerGroup) (int, error)

func (*Client) UpdateComputerInventoryDetailByID

func (c *Client) UpdateComputerInventoryDetailByID(id string, computer ComputerInventory) (*ComputerInventory, error)

func (*Client) UpdateDepartment

func (c *Client) UpdateDepartment(d *Department) (*Department, error)

func (*Client) UpdateMobileDeviceGroup

func (c *Client) UpdateMobileDeviceGroup(d *MobileDeviceGroup) (int, error)

func (*Client) UpdatePackage

func (c *Client) UpdatePackage(d *Package) (int, error)

func (*Client) UpdatePolicy

func (c *Client) UpdatePolicy(d *Policy) (int, error)

func (*Client) UpdateScript

func (c *Client) UpdateScript(d *Script) (*Script, error)

type Computer

type Computer struct {
	General               ComputerDataSubsetGeneral               `json:"general,omitempty" xml:"general,omitempty"`
	Location              ComputerDataSubsetLocation              `json:"location,omitempty" xml:"location,omitempty"`
	Purchasing            ComputerDataSubsetPurchasing            `json:"purchasing,omitempty" xml:"purchasing,omitempty"`
	Peripherals           ComputerDataSubsetPeripherals           `json:"peripherals,omitempty" xml:"peripherals,omitempty"`
	Hardware              ComputerDataSubsetHardware              `json:"hardware,omitempty" xml:"hardware,omitempty"`
	Certificates          ComputerDataSubsetCertificates          `json:"certificates,omitempty" xml:"certificates,omitempty"`
	Security              ComputerDataSubsetSecurity              `json:"security,omitempty" xml:"security,omitempty"`
	Software              ComputerDataSubsetSoftware              `json:"software,omitempty" xml:"software,omitempty"`
	ExtensionAttributes   ComputerDataSubsetExtensionAttributes   `json:"extension_attributes,omitempty" xml:"extension_attributes,omitempty"`
	GroupAccounts         ComputerDataSubsetGroupAccounts         `json:"groups_accounts,omitempty" xml:"groups_accounts,omitempty"`
	IPhones               ComputerDataSubsetIPhones               `json:"iphones,omitempty" xml:"iphones,omitempty"`
	ConfigurationProfiles ComputerDataSubsetConfigurationProfiles `json:"configuration_profiles,omitempty" xml:"configuration_profiles,omitempty"`
}

type ComputerConfigurationProfile

type ComputerConfigurationProfile struct {
	General     ComputerConfigurationProfileGeneral     `xml:"general"`
	Scope       ComputerConfigurationProfileScope       `xml:"scope"`
	SelfService ComputerConfigurationProfileSelfService `xml:"self_service,omitempty"`
}

type ComputerConfigurationProfileGeneral

type ComputerConfigurationProfileGeneral struct {
	ID                 int             `xml:"id,omitempty"`
	Name               string          `xml:"name"`
	Description        string          `xml:"description"`
	Site               Site            `xml:"site"`
	Category           GeneralCategory `xml:"category,omitempty"`
	DistributionMethod string          `xml:"distribution_method"`
	UserRemovable      bool            `xml:"user_removable"`
	Level              string          `xml:"level"`
	UUID               string          `xml:"uuid"`
	RedeployOnUpdate   string          `xml:"redeploy_on_update"`
	Payload            string          `xml:"payloads"`
}

type ComputerConfigurationProfileListItem

type ComputerConfigurationProfileListItem struct {
	ID   int    `xml:"id"`
	Name string `xml:"name"`
}

type ComputerConfigurationProfileListResponse

type ComputerConfigurationProfileListResponse struct {
	Size    int                                    `xml:"size"`
	Results []ComputerConfigurationProfileListItem `xml:"os_x_configuration_profile"`
}

type ComputerConfigurationProfileScope

type ComputerConfigurationProfileScope struct {
	AllComputers   bool                                         `xml:"all_computers"`
	AllUsers       bool                                         `xml:"all_jss_users"`
	Computers      []ComputerScope                              `xml:"computers>computer,omitempty"`
	Buildings      []BuildingScope                              `xml:"buildings>building,omitempty"`
	Departments    []DepartmentScope                            `xml:"departments>department,omitempty"`
	ComputerGroups []ComputerGroupListResponse                  `xml:"computer_groups>computer_group,omitempty"`
	JamfUsers      []JamfUserScope                              `xml:"jss_users>jss_user,omitempty"`
	JamfUserGroups []UserGroupScope                             `xml:"jss_user_groups>jss_user_group,omitempty"`
	Limitiations   ComputerConfigurationProfileScopeLimitations `xml:"limitations"`
	Exclusions     ComputerConfigurationProfileScopeExclusions  `xml:"exclusions"`
}

type ComputerConfigurationProfileScopeExclusions

type ComputerConfigurationProfileScopeExclusions struct {
	Computers       []ComputerScope             `xml:"computers>computer,omitempty"`
	Buildings       []BuildingScope             `xml:"buildings>building,omitempty"`
	Departments     []DepartmentScope           `xml:"departments>department,omitempty"`
	ComputerGroups  []ComputerGroupListResponse `xml:"computer_groups>computer_group,omitempty"`
	Users           []UserScope                 `xml:"users>user,omitempty"`
	UserGroups      []UserGroupScope            `xml:"user_groups>user_group,omitempty"`
	NetworkSegments []NetworkSegmentScope       `xml:"network_segments>network_segment,omitempty"`
	IBeacons        []IBeaconScope              `xml:"ibeacons>ibeacon,omitempty"`
	JamfUsers       []JamfUserScope             `xml:"jss_users>jss_user,omitempty"`
	JamfUserGroups  []UserGroupScope            `xml:"jss_user_groups>jss_user_group,omitempty"`
}

type ComputerConfigurationProfileScopeLimitations

type ComputerConfigurationProfileScopeLimitations struct {
	Users           []UserScope           `xml:"users>user,omitempty"`
	UserGroups      []UserGroupScope      `xml:"user_groups>user_group,omitempty"`
	NetworkSegments []NetworkSegmentScope `xml:"network_segments>network_segment,omitempty"`
	IBeacons        []IBeaconScope        `xml:"ibeacons>ibeacon,omitempty"`
}

type ComputerConfigurationProfileSelfService

type ComputerConfigurationProfileSelfService struct {
	SelfServiceDisplayName      string                `xml:"self_service_display_name,omitempty"`
	InstallButtonText           string                `xml:"install_button_text,omitempty"`
	SelfServiceDescription      string                `xml:"self_service_description,omitempty"`
	ForceUsersToViewDescription bool                  `xml:"force_users_to_view_description,omitempty"`
	RemovalDisallowed           string                `xml:"security>removal_disallowed,omitempty"`
	SelfServiceIcon             SelfServiceIcon       `xml:"self_service_icon,omitempty,omitempty"`
	FeatureOnMainPage           bool                  `xml:"feature_on_main_page,omitempty"`
	SelfServiceCategories       []SelfServiceCategory `xml:"self_service_categories>category,omitempty,omitempty"`
}

type ComputerDataSubsetCertificates

type ComputerDataSubsetCertificates struct {
	Certificates []struct {
		CommonName   string `xml:"common_name,omitempty"`
		Identity     bool   `xml:"identity,omitempty"`
		ExpiresUtc   string `xml:"expires_utc,omitempty"`
		ExpiresEpoch int64  `xml:"expires_epoch,omitempty"`
		Name         string `xml:"name,omitempty"`
	} `xml:"certificate,omitempty"`
}

type ComputerDataSubsetConfigurationProfiles

type ComputerDataSubsetConfigurationProfiles struct {
	Size                 string `xml:"size,omitempty"`
	ConfigurationProfile []struct {
		ID          int    `xml:"id,omitempty"`
		Name        string `xml:"name,omitempty"`
		UUID        string `xml:"uuid,omitempty"`
		IsRemovable bool   `xml:"is_removable,omitempty"`
	} `xml:"configuration_profile,omitempty"`
}

type ComputerDataSubsetExtensionAttributes

type ComputerDataSubsetExtensionAttributes struct {
	ExtensionAttributes []struct {
		ID         int    `xml:"id,omitempty"`
		Name       string `xml:"name,omitempty"`
		Type       string `xml:"type,omitempty"`
		MultiValue bool   `xml:"multi_value,omitempty"`
		Value      string `xml:"value,omitempty"`
	} `xml:"extension_attribute,omitempty"`
}

type ComputerDataSubsetGeneral

type ComputerDataSubsetGeneral struct {
	ID                    int    `xml:"id,omitempty"`
	Name                  string `xml:"name,omitempty"`
	NetworkAdapterType    string `xml:"network_adapter_type,omitempty"`
	MacAddress            string `xml:"mac_address,omitempty"`
	AltNetworkAdapterType string `xml:"alt_network_adapter_type,omitempty"`
	AltMacAddress         string `xml:"alt_mac_address,omitempty"`
	IPAddress             string `xml:"ip_address,omitempty"`
	LastReportedIP        string `xml:"last_reported_ip,omitempty"`
	SerialNumber          string `xml:"serial_number,omitempty"`
	UDID                  string `xml:"udid,omitempty"`
	JamfVersion           string `xml:"jamf_version,omitempty"`
	Platform              string `xml:"platform,omitempty"`
	Barcode1              string `xml:"barcode_1,omitempty"`
	Barcode2              string `xml:"barcode_2,omitempty"`
	AssetTag              string `xml:"asset_tag,omitempty"`
	RemoteManagement      struct {
		Managed                  bool   `xml:"managed,omitempty"`
		ManagementUsername       string `xml:"management_username,omitempty"`
		ManagementPasswordSha256 string `xml:"management_password_sha256,omitempty"`
	} `xml:"remote_management,omitempty"`
	Supervised      string `xml:"supervised,omitempty"`
	MdmCapable      string `xml:"mdm_capable,omitempty"`
	MdmCapableUsers []struct {
		MdmCapableUser string `xml:"mdm_capable_user,omitempty"`
	} `xml:"mdm_capable_users,omitempty"`
	ManagementStatus struct {
		EnrolledViaDep  bool `xml:"enrolled_via_dep,omitempty"`
		UserApprovedMdm bool `xml:"user_approved_mdm,omitempty"`
	} `xml:"management_status,omitempty"`
	ReportDate                string `xml:"report_date,omitempty"`
	ReportDateEpoch           string `xml:"report_date_epoch,omitempty"`
	ReportDateUtc             string `xml:"report_date_utc,omitempty"`
	LastContactTime           string `xml:"last_contact_time,omitempty"`
	LastContactTimeEpoch      string `xml:"last_contact_time_epoch,omitempty"`
	LastContactTimeUtc        string `xml:"last_contact_time_utc,omitempty"`
	InitialEntryDate          string `xml:"initial_entry_date,omitempty"`
	InitialEntryDateEpoch     string `xml:"initial_entry_date_epoch,omitempty"`
	InitialEntryDateUtc       string `xml:"initial_entry_date_utc,omitempty"`
	LastCloudBackupDateEpoch  string `xml:"last_cloud_backup_date_epoch,omitempty"`
	LastCloudBackupDateUtc    string `xml:"last_cloud_backup_date_utc,omitempty"`
	LastEnrolledDateEpoch     string `xml:"last_enrolled_date_epoch,omitempty"`
	LastEnrolledDateUtc       string `xml:"last_enrolled_date_utc,omitempty"`
	MdmProfileExpirationEpoch string `xml:"mdm_profile_expiration_epoch,omitempty"`
	MdmProfileExpirationUtc   string `xml:"mdm_profile_expiration_utc,omitempty"`
	DistributionPoint         string `xml:"distribution_point,omitempty"`
	Sus                       string `xml:"sus,omitempty"`
	Site                      struct {
		ID   int    `xml:"id,omitempty"`
		Name string `xml:"name,omitempty"`
	} `xml:"site,omitempty"`
	ItunesStoreAccountIsActive string `xml:"itunes_store_account_is_active"`
}

type ComputerDataSubsetGroupAccounts

type ComputerDataSubsetGroupAccounts struct {
	ComputerGroupMemberships struct {
		Groups []string `xml:"group,omitempty"`
	} `xml:"computer_group_memberships,omitempty"`
	LocalAccounts struct {
		Users []struct {
			Name             string `xml:"name,omitempty"`
			Realname         string `xml:"realname,omitempty"`
			UID              int    `xml:"uid,omitempty"`
			Home             string `xml:"home,omitempty"`
			HomeSize         string `xml:"home_size,omitempty"`
			HomeSizeMb       int    `xml:"home_size_mb,omitempty"`
			Administrator    bool   `xml:"administrator,omitempty"`
			FilevaultEnabled bool   `xml:"filevault_enabled,omitempty"`
		} `xml:"user,omitempty"`
	} `xml:"local_accounts,omitempty"`
	UserInventories struct {
		DisableAutomaticLogin bool `xml:"disable_automatic_login,omitempty"`
		Users                 []struct {
			Username                     string `xml:"username,omitempty"`
			PasswordHistoryDepth         string `xml:"password_history_depth,omitempty"`
			PasswordMinLength            string `xml:"password_min_length,omitempty"`
			PasswordMaxAge               string `xml:"password_max_age,omitempty"`
			PasswordMinComplexCharacters string `xml:"password_min_complex_characters,omitempty"`
			PasswordRequireAlphanumeric  string `xml:"password_require_alphanumeric,omitempty"`
		} `xml:"user,omitempty"`
	} `xml:"user_inventories,omitempty"`
}

type ComputerDataSubsetHardware

type ComputerDataSubsetHardware struct {
	Make                        string `xml:"make,omitempty"`
	Model                       string `xml:"model,omitempty"`
	ModelIdentifier             string `xml:"model_identifier,omitempty"`
	OsName                      string `xml:"os_name,omitempty"`
	OsVersion                   string `xml:"os_version,omitempty"`
	OsBuild                     string `xml:"os_build,omitempty"`
	SoftwareUpdateDeviceID      string `xml:"software_update_device_id,omitempty"`
	ActiveDirectoryStatus       string `xml:"active_directory_status,omitempty"`
	ServicePack                 string `xml:"service_pack,omitempty"`
	ProcessorType               string `xml:"processor_type,omitempty"`
	IsAppleSilicon              bool   `xml:"is_apple_silicon,omitempty"`
	ProcessorArchitecture       string `xml:"processor_architecture,omitempty"`
	ProcessorSpeed              int    `xml:"processor_speed,omitempty"`
	ProcessorSpeedMhz           int    `xml:"processor_speed_mhz,omitempty"`
	NumberProcessors            int    `xml:"number_processors,omitempty"`
	NumberCores                 int    `xml:"number_cores,omitempty"`
	TotalRAM                    int    `xml:"total_ram,omitempty"`
	TotalRAMMb                  int    `xml:"total_ram_mb,omitempty"`
	BootRom                     string `xml:"boot_rom,omitempty"`
	BusSpeed                    int    `xml:"bus_speed,omitempty"`
	BusSpeedMhz                 int    `xml:"bus_speed_mhz,omitempty"`
	BatteryCapacity             int    `xml:"battery_capacity,omitempty"`
	CacheSize                   int    `xml:"cache_size,omitempty"`
	CacheSizeKb                 int    `xml:"cache_size_kb,omitempty"`
	AvailableRAMSlots           int    `xml:"available_ram_slots,omitempty"`
	OpticalDrive                string `xml:"optical_drive,omitempty"`
	NicSpeed                    string `xml:"nic_speed,omitempty"`
	SmcVersion                  string `xml:"smc_version,omitempty"`
	BleCapable                  bool   `xml:"ble_capable,omitempty"`
	SupportsIosAppInstalls      bool   `xml:"supports_ios_app_installs,omitempty"`
	SipStatus                   string `xml:"sip_status,omitempty"`
	GatekeeperStatus            string `xml:"gatekeeper_status,omitempty"`
	XprotectVersion             string `xml:"xprotect_version,omitempty"`
	InstitutionalRecoveryKey    string `xml:"institutional_recovery_key,omitempty"`
	DiskEncryptionConfiguration string `xml:"disk_encryption_configuration,omitempty"`
	Filevault2Users             []struct {
		User string `xml:"user,omitempty"`
	} `xml:"filevault2_users,omitempty"`
	Storage struct {
		Devices []struct {
			Disk            string `xml:"disk,omitempty"`
			Model           string `xml:"model,omitempty"`
			Revision        string `xml:"revision,omitempty"`
			SerialNumber    string `xml:"serial_number,omitempty"`
			Size            int    `xml:"size,omitempty"`
			DriveCapacityMb int    `xml:"drive_capacity_mb,omitempty"`
			ConnectionType  string `xml:"connection_type,omitempty"`
			SmartStatus     string `xml:"smart_status,omitempty"`
			Partitions      struct {
				Partitions []struct {
					Name                 string `xml:"name,omitempty"`
					Size                 int    `xml:"size,omitempty"`
					Type                 string `xml:"type,omitempty"`
					PartitionCapacityMb  int    `xml:"partition_capacity_mb,omitempty"`
					PercentageFull       int    `xml:"percentage_full,omitempty"`
					AvailableMb          int    `xml:"available_mb,omitempty"`
					FilevaultStatus      string `xml:"filevault_status,omitempty"`
					FilevaultPercent     int    `xml:"filevault_percent,omitempty"`
					Filevault2Status     string `xml:"filevault2_status,omitempty"`
					Filevault2Percent    int    `xml:"filevault2_percent,omitempty"`
					BootDriveAvailableMb int    `xml:"boot_drive_available_mb,omitempty"`
					LvgUUID              string `xml:"lvgUUID,omitempty"`
					LvUUID               string `xml:"lvUUID,omitempty"`
					PvUUID               string `xml:"pvUUID,omitempty"`
				} `xml:"partition,omitempty"`
			} `xml:"partitions,omitempty"`
		} `xml:"device,omitempty"`
	} `xml:"storage,omitempty"`
	MappedPrinters string `xml:"mapped_printers,omitempty"`
}

type ComputerDataSubsetIPhones

type ComputerDataSubsetIPhones struct {
}

type ComputerDataSubsetLocation

type ComputerDataSubsetLocation struct {
	Username     string `xml:"username,omitempty"`
	RealName     string `xml:"real_name,omitempty"`
	EmailAddress string `xml:"email_address,omitempty"`
	Position     string `xml:"position,omitempty"`
	Phone        string `xml:"phone,omitempty"`
	PhoneNumber  string `xml:"phone_number,omitempty"`
	Department   string `xml:"department,omitempty"`
	Building     string `xml:"building,omitempty"`
	Room         string `xml:"room,omitempty"`
}

type ComputerDataSubsetName

type ComputerDataSubsetName string
const (
	ComputerDataSubsetNameGeneral               ComputerDataSubsetName = "General"
	ComputerDataSubsetNameLocation              ComputerDataSubsetName = "Location"
	ComputerDataSubsetNamePurchasing            ComputerDataSubsetName = "Purchasing"
	ComputerDataSubsetNamePeripherals           ComputerDataSubsetName = "Peripherals"
	ComputerDataSubsetNameHardware              ComputerDataSubsetName = "Hardware"
	ComputerDataSubsetNameCertificates          ComputerDataSubsetName = "Certificates"
	ComputerDataSubsetNameSecurity              ComputerDataSubsetName = "Security"
	ComputerDataSubsetNameSoftware              ComputerDataSubsetName = "Software"
	ComputerDataSubsetNameExtensionAttributes   ComputerDataSubsetName = "ExtensionAttributes"
	ComputerDataSubsetNameGroupAccounts         ComputerDataSubsetName = "GroupsAccounts"
	ComputerDataSubsetNameIPhones               ComputerDataSubsetName = "iphones"
	ComputerDataSubsetNameConfigurationProfiles ComputerDataSubsetName = "ConfigurationProfiles"
)

type ComputerDataSubsetPeripherals

type ComputerDataSubsetPeripherals struct {
}

Don't have example data for this to construct resulting struct. Please cut a PR to populate if needed

type ComputerDataSubsetPurchasing

type ComputerDataSubsetPurchasing struct {
	IsPurchased          bool   `xml:"is_purchased,omitempty"`
	IsLeased             bool   `xml:"is_leased,omitempty"`
	PoNumber             string `xml:"po_number,omitempty"`
	Vendor               string `xml:"vendor,omitempty"`
	ApplecareID          string `xml:"applecare_id,omitempty"`
	PurchasePrice        string `xml:"purchase_price,omitempty"`
	PurchasingAccount    string `xml:"purchasing_account,omitempty"`
	PoDate               string `xml:"po_date,omitempty"`
	PoDateEpoch          int64  `xml:"po_date_epoch,omitempty"`
	PoDateUtc            string `xml:"po_date_utc,omitempty"`
	WarrantyExpires      string `xml:"warranty_expires,omitempty"`
	WarrantyExpiresEpoch int64  `xml:"warranty_expires_epoch,omitempty"`
	WarrantyExpiresUtc   string `xml:"warranty_expires_utc,omitempty"`
	LeaseExpires         string `xml:"lease_expires,omitempty"`
	LeaseExpiresEpoch    int64  `xml:"lease_expires_epoch,omitempty"`
	LeaseExpiresUtc      string `xml:"lease_expires_utc,omitempty"`
	LifeExpectancy       int    `xml:"life_expectancy,omitempty"`
	PurchasingContact    string `xml:"purchasing_contact,omitempty"`
	OsApplecareID        string `xml:"os_applecare_id,omitempty"`
	OsMaintenanceExpires string `xml:"os_maintenance_expires,omitempty"`
	Attachments          string `xml:"attachments,omitempty"`
}

type ComputerDataSubsetSecurity

type ComputerDataSubsetSecurity struct {
	ActivationLock      bool   `xml:"activation_lock,omitempty"`
	RecoveryLockEnabled bool   `xml:"recovery_lock_enabled,omitempty"`
	SecureBootLevel     string `xml:"secure_boot_level,omitempty"`
	ExternalBootLevel   string `xml:"external_boot_level,omitempty"`
	FirewallEnabled     bool   `xml:"firewall_enabled,omitempty"`
}

type ComputerDataSubsetSoftware

type ComputerDataSubsetSoftware struct {
	// UnixExecutables   string `xml:"unix_executables,omitempty"`  - unknown format, accepting PRs
	// LicensedSoftware  string `xml:"licensed_software,omitempty"` - unknown format, accepting PRs
	InstalledByCasper []struct {
		Package string `xml:"package,omitempty"`
	} `xml:"installed_by_casper,omitempty"`
	InstalledByInstallerSwu []struct {
		Package []string `xml:"package,omitempty"`
	} `xml:"installed_by_installer_swu,omitempty"`
	CachedByCasper []struct {
		Package string `xml:"package,omitempty"`
	} `xml:"cached_by_casper,omitempty"`
	AvailableSoftwareUpdates []struct {
		Name string `xml:"name,omitempty"`
	} `xml:"available_software_updates,omitempty"`
	AvailableUpdates []struct {
		Update struct {
			Text        string `xml:",chardata,omitempty"`
			Name        string `xml:"name,omitempty"`
			PackageName string `xml:"package_name,omitempty"`
			Version     string `xml:"version,omitempty"`
		} `xml:"update,omitempty"`
	} `xml:"available_updates,omitempty"`
	RunningServices struct {
		Names []string `xml:"name,omitempty"`
	} `xml:"running_services,omitempty"`
	Applications struct {
		Size         int `xml:"size,omitempty"`
		Applications []struct {
			Name     string `xml:"name,omitempty"`
			Path     string `xml:"path,omitempty"`
			Version  string `xml:"version,omitempty"`
			BundleID string `xml:"bundle_id,omitempty"`
		} `xml:"application,omitempty"`
	} `xml:"applications,omitempty"`
}

type ComputerExtensionAttribute

type ComputerExtensionAttribute struct {
	Id               int                                 `xml:"id"`
	Name             string                              `xml:"name"`
	Enabled          bool                                `xml:"enabled,omitempty"`
	Description      string                              `xml:"description"`
	DataType         string                              `xml:"data_type"`
	InputType        ComputerExtensionAttributeInputType `xml:"input_type,omitempty"`
	InventoryDisplay string                              `xml:"inventory_display,omitempty"`
	ReconDisplay     string                              `xml:"recon_display,omitempty"`
}

type ComputerExtensionAttributeInputType

type ComputerExtensionAttributeInputType struct {
	Type     string   `xml:"type"`
	Platform string   `xml:"platform,omitempty"`
	Script   string   `xml:"script,omitempty"`
	Choices  []string `xml:"popup_choices>choice,omitempty"`
}

type ComputerExtensionAttributeListItem

type ComputerExtensionAttributeListItem struct {
	Id      int    `xml:"id"`
	Name    string `xml:"name"`
	Enabled bool   `xml:"enabled"`
}

type ComputerExtensionAttributeListResponse

type ComputerExtensionAttributeListResponse struct {
	Size    int                                    `xml:"size"`
	Results []ComputerConfigurationProfileListItem `xml:"computer_extension_attribute"`
}

type ComputerGroup

type ComputerGroup struct {
	ID           int                          `xml:"id"`
	Name         string                       `xml:"name"`
	IsSmart      bool                         `xml:"is_smart"`
	Site         Site                         `xml:"site"`
	Criteria     []ComputerGroupCriterion     `xml:"criteria>criterion"`
	CriteriaSize int                          `xml:"criteria>size"`
	Computers    []ComputerGroupComputerEntry `xml:"computers>computer"`
	ComputerSize int                          `xml:"computers>size"`
}

type ComputerGroupComputerEntry

type ComputerGroupComputerEntry struct {
	ID           int    `json:"id,omitempty" xml:"id,omitempty"`
	Name         string `json:"name,omitempty" xml:"name,omitempty"`
	SerialNumber string `json:"serial_number,omitempty" xml:"serial_number,omitempty"`
}

type ComputerGroupCriterion

type ComputerGroupCriterion struct {
	Name         string           `xml:"name"`
	Priority     int              `xml:"priority"`
	AndOr        DeviceGroupAndOr `xml:"and_or"`
	SearchType   string           `xml:"search_type"`
	SearchValue  string           `xml:"value"`
	OpeningParen bool             `xml:"opening_paren"`
	ClosingParen bool             `xml:"closing_paren"`
}

type ComputerGroupListResponse

type ComputerGroupListResponse struct {
	ID      int    `xml:"id,omitempty"`
	Name    string `xml:"name,omitempty"`
	IsSmart bool   `xml:"is_smart,omitempty"`
}

type ComputerGroupRequest

type ComputerGroupRequest struct {
	Name      string                       `xml:"name"`
	IsSmart   bool                         `xml:"is_smart"`
	Site      Site                         `xml:"site"`
	Criteria  []ComputerGroupCriterion     `xml:"criteria>criterion"`
	Computers []ComputerGroupComputerEntry `xml:"computers>computer,omitempty"`
}

type ComputerGroupsResponse

type ComputerGroupsResponse struct {
	Size    int                         `xml:"size"`
	Results []ComputerGroupListResponse `xml:"computer_group"`
}

type ComputerInventoriesQuery

type ComputerInventoriesQuery struct {
	Sections *[]ComputerInventoryDataSubsetName
	Page     int
	PageSize int
	Sort     *[]string
	Filter   string
}

type ComputerInventoriesResponse

type ComputerInventoriesResponse struct {
	TotalCount int                 `json:"totalCount,omitempty"`
	Results    []ComputerInventory `json:"results,omitempty"`
}

type ComputerInventory

type ComputerInventory struct {
	ID                    string                                              `json:"id,omitempty"`
	Udid                  string                                              `json:"udid,omitempty"`
	General               *ComputerInventoryDataSubsetGeneral                 `json:"general,omitempty"`
	DiskEncryption        *ComputerInventoryDataSubsetDiskEncryption          `json:"diskEncryption,omitempty"`
	Purchasing            *ComputerInventoryDataSubsetPurchasing              `json:"purchasing,omitempty"`
	Applications          *[]ComputerInventoryDataSubsetApplications          `json:"applications,omitempty"`
	Storage               *ComputerInventoryDataSubsetStorage                 `json:"storage,omitempty"`
	UserAndLocation       *ComputerInventoryDataSubsetUserAndLocation         `json:"userAndLocation,omitempty"`
	ConfigurationProfiles *[]ComputerInventoryDataSubsetConfigurationProfiles `json:"configurationProfiles,omitempty"`
	Printers              *[]ComputerInventoryDataSubsetPrinters              `json:"printers,omitempty"`
	Services              *[]ComputerInventoryDataSubsetServices              `json:"services,omitempty"`
	Hardware              *ComputerInventoryDataSubsetHardware                `json:"hardware,omitempty"`
	LocalUserAccounts     *[]ComputerInventoryDataSubsetLocalUserAccounts     `json:"localUserAccounts,omitempty"`
	Certificates          *[]ComputerInventoryDataSubsetCertificates          `json:"certificates,omitempty"`
	Attachments           *[]ComputerInventoryDataSubsetAttachments           `json:"attachments,omitempty"`
	Plugins               *[]ComputerInventoryDataSubsetPlugins               `json:"plugins,omitempty"`
	PackageReceipts       *ComputerInventoryDataSubsetPackageReceipts         `json:"packageReceipts,omitempty"`
	Fonts                 *[]ComputerInventoryDataSubsetFonts                 `json:"fonts,omitempty"`
	Security              *ComputerInventoryDataSubsetSecurity                `json:"security,omitempty"`
	OperatingSystem       *ComputerInventoryDataSubsetOperatingSystem         `json:"operatingSystem,omitempty"`
	LicensedSoftware      *[]ComputerInventoryDataSubsetLicensedSoftware      `json:"licensedSoftware,omitempty"`
	Ibeacons              *[]ComputerInventoryDataSubsetIbeacons              `json:"ibeacons,omitempty"`
	SoftwareUpdates       *[]ComputerInventoryDataSubsetSoftwareUpdates       `json:"softwareUpdates,omitempty"`
	ExtensionAttributes   *[]ComputerInventoryDataSubsetExtensionAttributes   `json:"extensionAttributes,omitempty"`
	ContentCaching        *ComputerInventoryDataSubsetContentCaching          `json:"contentCaching,omitempty"`
	GroupMemberships      *[]ComputerInventoryDataSubsetGroupMemberships      `json:"groupMemberships,omitempty"`
}

type ComputerInventoryDataSubsetApplications

type ComputerInventoryDataSubsetApplications struct {
	Name              string `json:"name,omitempty"`
	Path              string `json:"path,omitempty"`
	Version           string `json:"version,omitempty"`
	MacAppStore       bool   `json:"macAppStore,omitempty"`
	SizeMegabytes     int    `json:"sizeMegabytes,omitempty"`
	BundleID          string `json:"bundleId,omitempty"`
	UpdateAvailable   bool   `json:"updateAvailable,omitempty"`
	ExternalVersionID string `json:"externalVersionId,omitempty"`
}

type ComputerInventoryDataSubsetAttachments

type ComputerInventoryDataSubsetAttachments struct {
	ID        string `json:"id,omitempty"`
	Name      string `json:"name,omitempty"`
	FileType  string `json:"fileType,omitempty"`
	SizeBytes int    `json:"sizeBytes,omitempty"`
}

type ComputerInventoryDataSubsetCertificates

type ComputerInventoryDataSubsetCertificates struct {
	CommonName        string    `json:"commonName,omitempty"`
	Identity          bool      `json:"identity,omitempty"`
	ExpirationDate    time.Time `json:"expirationDate,omitempty"`
	Username          string    `json:"username,omitempty"`
	LifecycleStatus   string    `json:"lifecycleStatus,omitempty"`
	CertificateStatus string    `json:"certificateStatus,omitempty"`
}

type ComputerInventoryDataSubsetConfigurationProfiles

type ComputerInventoryDataSubsetConfigurationProfiles struct {
	ID                string    `json:"id,omitempty"`
	Username          string    `json:"username,omitempty"`
	LastInstalled     time.Time `json:"lastInstalled,omitempty"`
	Removable         bool      `json:"removable,omitempty"`
	DisplayName       string    `json:"displayName,omitempty"`
	ProfileIdentifier string    `json:"profileIdentifier,omitempty"`
}

type ComputerInventoryDataSubsetContentCaching

type ComputerInventoryDataSubsetContentCaching struct {
	ComputerContentCachingInformationID string `json:"computerContentCachingInformationId,omitempty"`
	Parents                             []struct {
		ContentCachingParentID string `json:"contentCachingParentId,omitempty"`
		Address                string `json:"address,omitempty"`
		Alerts                 struct {
			ContentCachingParentAlertID string        `json:"contentCachingParentAlertId,omitempty"`
			Addresses                   []interface{} `json:"addresses,omitempty"`
			ClassName                   string        `json:"className,omitempty"`
			PostDate                    time.Time     `json:"postDate,omitempty"`
		} `json:"alerts,omitempty"`
		Details struct {
			ContentCachingParentDetailsID string `json:"contentCachingParentDetailsId,omitempty"`
			AcPower                       bool   `json:"acPower,omitempty"`
			CacheSizeBytes                int    `json:"cacheSizeBytes,omitempty"`
			Capabilities                  struct {
				ContentCachingParentCapabilitiesID string `json:"contentCachingParentCapabilitiesId,omitempty"`
				Imports                            bool   `json:"imports,omitempty"`
				Namespaces                         bool   `json:"namespaces,omitempty"`
				PersonalContent                    bool   `json:"personalContent,omitempty"`
				QueryParameters                    bool   `json:"queryParameters,omitempty"`
				SharedContent                      bool   `json:"sharedContent,omitempty"`
				Prioritization                     bool   `json:"prioritization,omitempty"`
			} `json:"capabilities,omitempty"`
			Portable     bool `json:"portable,omitempty"`
			LocalNetwork []struct {
				ContentCachingParentLocalNetworkID string `json:"contentCachingParentLocalNetworkId,omitempty"`
				Speed                              int    `json:"speed,omitempty"`
				Wired                              bool   `json:"wired,omitempty"`
			} `json:"localNetwork,omitempty"`
		} `json:"details,omitempty"`
		GUID    string `json:"guid,omitempty"`
		Healthy bool   `json:"healthy,omitempty"`
		Port    int    `json:"port,omitempty"`
		Version string `json:"version,omitempty"`
	} `json:"parents,omitempty"`
	Alerts []struct {
		CacheBytesLimit      int       `json:"cacheBytesLimit,omitempty"`
		ClassName            string    `json:"className,omitempty"`
		PathPreventingAccess string    `json:"pathPreventingAccess,omitempty"`
		PostDate             time.Time `json:"postDate,omitempty"`
		ReservedVolumeBytes  int       `json:"reservedVolumeBytes,omitempty"`
		Resource             string    `json:"resource,omitempty"`
	} `json:"alerts,omitempty"`
	Activated            bool `json:"activated,omitempty"`
	Active               bool `json:"active,omitempty"`
	ActualCacheBytesUsed int  `json:"actualCacheBytesUsed,omitempty"`
	CacheDetails         []struct {
		ComputerContentCachingCacheDetailsID string `json:"computerContentCachingCacheDetailsId,omitempty"`
		CategoryName                         string `json:"categoryName,omitempty"`
		DiskSpaceBytesUsed                   int    `json:"diskSpaceBytesUsed,omitempty"`
	} `json:"cacheDetails,omitempty"`
	CacheBytesFree                  int64  `json:"cacheBytesFree,omitempty"`
	CacheBytesLimit                 int    `json:"cacheBytesLimit,omitempty"`
	CacheStatus                     string `json:"cacheStatus,omitempty"`
	CacheBytesUsed                  int    `json:"cacheBytesUsed,omitempty"`
	DataMigrationCompleted          bool   `json:"dataMigrationCompleted,omitempty"`
	DataMigrationProgressPercentage int    `json:"dataMigrationProgressPercentage,omitempty"`
	DataMigrationError              struct {
		Code     int    `json:"code,omitempty"`
		Domain   string `json:"domain,omitempty"`
		UserInfo []struct {
			Key   string `json:"key,omitempty"`
			Value string `json:"value,omitempty"`
		} `json:"userInfo,omitempty"`
	} `json:"dataMigrationError,omitempty"`
	MaxCachePressureLast1HourPercentage int       `json:"maxCachePressureLast1HourPercentage,omitempty"`
	PersonalCacheBytesFree              int64     `json:"personalCacheBytesFree,omitempty"`
	PersonalCacheBytesLimit             int       `json:"personalCacheBytesLimit,omitempty"`
	PersonalCacheBytesUsed              int       `json:"personalCacheBytesUsed,omitempty"`
	Port                                int       `json:"port,omitempty"`
	PublicAddress                       string    `json:"publicAddress,omitempty"`
	RegistrationError                   string    `json:"registrationError,omitempty"`
	RegistrationResponseCode            int       `json:"registrationResponseCode,omitempty"`
	RegistrationStarted                 time.Time `json:"registrationStarted,omitempty"`
	RegistrationStatus                  string    `json:"registrationStatus,omitempty"`
	RestrictedMedia                     bool      `json:"restrictedMedia,omitempty"`
	ServerGUID                          string    `json:"serverGuid,omitempty"`
	StartupStatus                       string    `json:"startupStatus,omitempty"`
	TetheratorStatus                    string    `json:"tetheratorStatus,omitempty"`
	TotalBytesAreSince                  time.Time `json:"totalBytesAreSince,omitempty"`
	TotalBytesDropped                   int       `json:"totalBytesDropped,omitempty"`
	TotalBytesImported                  int       `json:"totalBytesImported,omitempty"`
	TotalBytesReturnedToChildren        int       `json:"totalBytesReturnedToChildren,omitempty"`
	TotalBytesReturnedToClients         int       `json:"totalBytesReturnedToClients,omitempty"`
	TotalBytesReturnedToPeers           int       `json:"totalBytesReturnedToPeers,omitempty"`
	TotalBytesStoredFromOrigin          int       `json:"totalBytesStoredFromOrigin,omitempty"`
	TotalBytesStoredFromParents         int       `json:"totalBytesStoredFromParents,omitempty"`
	TotalBytesStoredFromPeers           int       `json:"totalBytesStoredFromPeers,omitempty"`
}

type ComputerInventoryDataSubsetDiskEncryption

type ComputerInventoryDataSubsetDiskEncryption struct {
	BootPartitionEncryptionDetails struct {
		PartitionName              string `json:"partitionName,omitempty"`
		PartitionFileVault2State   string `json:"partitionFileVault2State,omitempty"`
		PartitionFileVault2Percent int    `json:"partitionFileVault2Percent,omitempty"`
	} `json:"bootPartitionEncryptionDetails,omitempty"`
	IndividualRecoveryKeyValidityStatus string   `json:"individualRecoveryKeyValidityStatus,omitempty"`
	InstitutionalRecoveryKeyPresent     bool     `json:"institutionalRecoveryKeyPresent,omitempty"`
	DiskEncryptionConfigurationName     string   `json:"diskEncryptionConfigurationName,omitempty"`
	FileVault2EnabledUserNames          []string `json:"fileVault2EnabledUserNames,omitempty"`
	FileVault2EligibilityMessage        string   `json:"fileVault2EligibilityMessage,omitempty"`
}

type ComputerInventoryDataSubsetExtensionAttributes

type ComputerInventoryDataSubsetExtensionAttributes struct {
	DefinitionID string   `json:"definitionId,omitempty"`
	Name         string   `json:"name,omitempty"`
	Description  string   `json:"description,omitempty"`
	Enabled      bool     `json:"enabled,omitempty"`
	MultiValue   bool     `json:"multiValue,omitempty"`
	Values       []string `json:"values,omitempty"`
	DataType     string   `json:"dataType,omitempty"`
	Options      []string `json:"options,omitempty"`
	InputType    string   `json:"inputType,omitempty"`
}

type ComputerInventoryDataSubsetFonts

type ComputerInventoryDataSubsetFonts struct {
	Name    string `json:"name,omitempty"`
	Version string `json:"version,omitempty"`
	Path    string `json:"path,omitempty"`
}

type ComputerInventoryDataSubsetGeneral

type ComputerInventoryDataSubsetGeneral struct {
	Name              string `json:"name,omitempty"`
	LastIPAddress     string `json:"lastIpAddress,omitempty"`
	LastReportedIP    string `json:"lastReportedIp,omitempty"`
	JamfBinaryVersion string `json:"jamfBinaryVersion,omitempty"`
	Platform          string `json:"platform,omitempty"`
	Barcode1          string `json:"barcode1,omitempty"`
	Barcode2          string `json:"barcode2,omitempty"`
	AssetTag          string `json:"assetTag,omitempty"`
	RemoteManagement  struct {
		Managed            bool   `json:"managed,omitempty"`
		ManagementUsername string `json:"managementUsername,omitempty"`
	} `json:"remoteManagement,omitempty"`
	Supervised bool `json:"supervised,omitempty"`
	MdmCapable struct {
		Capable      bool     `json:"capable,omitempty"`
		CapableUsers []string `json:"capableUsers,omitempty"`
	} `json:"mdmCapable,omitempty"`
	ReportDate           time.Time `json:"reportDate,omitempty"`
	LastContactTime      time.Time `json:"lastContactTime,omitempty"`
	LastCloudBackupDate  time.Time `json:"lastCloudBackupDate,omitempty"`
	LastEnrolledDate     time.Time `json:"lastEnrolledDate,omitempty"`
	MdmProfileExpiration time.Time `json:"mdmProfileExpiration,omitempty"`
	InitialEntryDate     string    `json:"initialEntryDate,omitempty"`
	DistributionPoint    string    `json:"distributionPoint,omitempty"`
	EnrollmentMethod     struct {
		ID         string `json:"id,omitempty"`
		ObjectName string `json:"objectName,omitempty"`
		ObjectType string `json:"objectType,omitempty"`
	} `json:"enrollmentMethod,omitempty"`
	Site struct {
		ID   string `json:"id,omitempty"`
		Name string `json:"name,omitempty"`
	} `json:"site,omitempty"`
	ItunesStoreAccountActive             bool `json:"itunesStoreAccountActive,omitempty"`
	EnrolledViaAutomatedDeviceEnrollment bool `json:"enrolledViaAutomatedDeviceEnrollment,omitempty"`
	UserApprovedMdm                      bool `json:"userApprovedMdm,omitempty"`
	ExtensionAttributes                  []struct {
		DefinitionID string   `json:"definitionId,omitempty"`
		Name         string   `json:"name,omitempty"`
		Description  string   `json:"description,omitempty"`
		Enabled      bool     `json:"enabled,omitempty"`
		MultiValue   bool     `json:"multiValue,omitempty"`
		Values       []string `json:"values,omitempty"`
		DataType     string   `json:"dataType,omitempty"`
		Options      []string `json:"options,omitempty"`
		InputType    string   `json:"inputType,omitempty"`
	} `json:"extensionAttributes,omitempty"`
}

type ComputerInventoryDataSubsetGroupMemberships

type ComputerInventoryDataSubsetGroupMemberships struct {
	GroupID    string `json:"groupId,omitempty"`
	GroupName  string `json:"groupName,omitempty"`
	SmartGroup bool   `json:"smartGroup,omitempty"`
}

type ComputerInventoryDataSubsetHardware

type ComputerInventoryDataSubsetHardware struct {
	Make                   string `json:"make,omitempty"`
	Model                  string `json:"model,omitempty"`
	ModelIdentifier        string `json:"modelIdentifier,omitempty"`
	SerialNumber           string `json:"serialNumber,omitempty"`
	ProcessorSpeedMhz      int    `json:"processorSpeedMhz,omitempty"`
	ProcessorCount         int    `json:"processorCount,omitempty"`
	CoreCount              int    `json:"coreCount,omitempty"`
	ProcessorType          string `json:"processorType,omitempty"`
	ProcessorArchitecture  string `json:"processorArchitecture,omitempty"`
	BusSpeedMhz            int    `json:"busSpeedMhz,omitempty"`
	CacheSizeKilobytes     int    `json:"cacheSizeKilobytes,omitempty"`
	NetworkAdapterType     string `json:"networkAdapterType,omitempty"`
	MacAddress             string `json:"macAddress,omitempty"`
	AltNetworkAdapterType  string `json:"altNetworkAdapterType,omitempty"`
	AltMacAddress          string `json:"altMacAddress,omitempty"`
	TotalRAMMegabytes      int    `json:"totalRamMegabytes,omitempty"`
	OpenRAMSlots           int    `json:"openRamSlots,omitempty"`
	BatteryCapacityPercent int    `json:"batteryCapacityPercent,omitempty"`
	SmcVersion             string `json:"smcVersion,omitempty"`
	NicSpeed               string `json:"nicSpeed,omitempty"`
	OpticalDrive           string `json:"opticalDrive,omitempty"`
	BootRom                string `json:"bootRom,omitempty"`
	BleCapable             bool   `json:"bleCapable,omitempty"`
	SupportsIosAppInstalls bool   `json:"supportsIosAppInstalls,omitempty"`
	AppleSilicon           bool   `json:"appleSilicon,omitempty"`
	ExtensionAttributes    []struct {
		DefinitionID string   `json:"definitionId,omitempty"`
		Name         string   `json:"name,omitempty"`
		Description  string   `json:"description,omitempty"`
		Enabled      bool     `json:"enabled,omitempty"`
		MultiValue   bool     `json:"multiValue,omitempty"`
		Values       []string `json:"values,omitempty"`
		DataType     string   `json:"dataType,omitempty"`
		Options      []string `json:"options,omitempty"`
		InputType    string   `json:"inputType,omitempty"`
	} `json:"extensionAttributes,omitempty"`
}

type ComputerInventoryDataSubsetIbeacons

type ComputerInventoryDataSubsetIbeacons struct {
	Name string `json:"name,omitempty"`
}

type ComputerInventoryDataSubsetLicensedSoftware

type ComputerInventoryDataSubsetLicensedSoftware struct {
	ID   string `json:"id,omitempty"`
	Name string `json:"name,omitempty"`
}

type ComputerInventoryDataSubsetLocalUserAccounts

type ComputerInventoryDataSubsetLocalUserAccounts struct {
	UID                            string `json:"uid,omitempty"`
	Username                       string `json:"username,omitempty"`
	FullName                       string `json:"fullName,omitempty"`
	Admin                          bool   `json:"admin,omitempty"`
	HomeDirectory                  string `json:"homeDirectory,omitempty"`
	HomeDirectorySizeMb            int    `json:"homeDirectorySizeMb,omitempty"`
	FileVault2Enabled              bool   `json:"fileVault2Enabled,omitempty"`
	UserAccountType                string `json:"userAccountType,omitempty"`
	PasswordMinLength              int    `json:"passwordMinLength,omitempty"`
	PasswordMaxAge                 int    `json:"passwordMaxAge,omitempty"`
	PasswordMinComplexCharacters   int    `json:"passwordMinComplexCharacters,omitempty"`
	PasswordHistoryDepth           int    `json:"passwordHistoryDepth,omitempty"`
	PasswordRequireAlphanumeric    bool   `json:"passwordRequireAlphanumeric,omitempty"`
	ComputerAzureActiveDirectoryID string `json:"computerAzureActiveDirectoryId,omitempty"`
	UserAzureActiveDirectoryID     string `json:"userAzureActiveDirectoryId,omitempty"`
	AzureActiveDirectoryID         string `json:"azureActiveDirectoryId,omitempty"`
}

type ComputerInventoryDataSubsetName

type ComputerInventoryDataSubsetName string
const (
	ComputerInventoryDataSubsetNameGeneral               ComputerInventoryDataSubsetName = "GENERAL"
	ComputerInventoryDataSubsetNameLocation              ComputerInventoryDataSubsetName = "DISK_ENCRYPTION"
	ComputerInventoryDataSubsetNamePurchasing            ComputerInventoryDataSubsetName = "PURCHASING"
	ComputerInventoryDataSubsetNameApplications          ComputerInventoryDataSubsetName = "APPLICATIONS"
	ComputerInventoryDataSubsetNameStorage               ComputerInventoryDataSubsetName = "STORAGE"
	ComputerInventoryDataSubsetNameUserAndLocation       ComputerInventoryDataSubsetName = "USER_AND_LOCATION"
	ComputerInventoryDataSubsetNameConfigurationProfiles ComputerInventoryDataSubsetName = "CONFIGURATION_PROFILES"
	ComputerInventoryDataSubsetNamePrinters              ComputerInventoryDataSubsetName = "PRINTERS"
	ComputerInventoryDataSubsetNameServices              ComputerInventoryDataSubsetName = "SERVICES"
	ComputerInventoryDataSubsetNameHardware              ComputerInventoryDataSubsetName = "HARDWARE"
	ComputerInventoryDataSubsetNameLocalUserAccounts     ComputerInventoryDataSubsetName = "LOCAL_USER_ACCOUNTS"
	ComputerInventoryDataSubsetNameCertificates          ComputerInventoryDataSubsetName = "CERTIFICATES"
	ComputerInventoryDataSubsetNameAttachments           ComputerInventoryDataSubsetName = "ATTACHMENTS"
	ComputerInventoryDataSubsetNamePlugins               ComputerInventoryDataSubsetName = "PLUGINS"
	ComputerInventoryDataSubsetNamePackageReceipts       ComputerInventoryDataSubsetName = "PACKAGE_RECEIPTS"
	ComputerInventoryDataSubsetNameFonts                 ComputerInventoryDataSubsetName = "FONTS"
	ComputerInventoryDataSubsetNameSecurity              ComputerInventoryDataSubsetName = "SECURITY"
	ComputerInventoryDataSubsetNameOperatingSystem       ComputerInventoryDataSubsetName = "OPERATING_SYSTEM"
	ComputerInventoryDataSubsetNameLicensedSoftware      ComputerInventoryDataSubsetName = "LICENSED_SOFTWARE"
	ComputerInventoryDataSubsetNameIBeacons              ComputerInventoryDataSubsetName = "IBEACONS"
	ComputerInventoryDataSubsetNameSoftwareUpdates       ComputerInventoryDataSubsetName = "SOFTWARE_UPDATES"
	ComputerInventoryDataSubsetNameExtensionAttributes   ComputerInventoryDataSubsetName = "EXTENSION_ATTRIBUTES"
	ComputerInventoryDataSubsetNameContentCaching        ComputerInventoryDataSubsetName = "CONTENT_CACHING"
	ComputerInventoryDataSubsetNameGroupMemberships      ComputerInventoryDataSubsetName = "GROUP_MEMBERSHIPS"
)

type ComputerInventoryDataSubsetOperatingSystem

type ComputerInventoryDataSubsetOperatingSystem struct {
	Name                   string `json:"name,omitempty"`
	Version                string `json:"version,omitempty"`
	Build                  string `json:"build,omitempty"`
	ActiveDirectoryStatus  string `json:"activeDirectoryStatus,omitempty"`
	FileVault2Status       string `json:"fileVault2Status,omitempty"`
	SoftwareUpdateDeviceID string `json:"softwareUpdateDeviceId,omitempty"`
	ExtensionAttributes    []struct {
		DefinitionID string   `json:"definitionId,omitempty"`
		Name         string   `json:"name,omitempty"`
		Description  string   `json:"description,omitempty"`
		Enabled      bool     `json:"enabled,omitempty"`
		MultiValue   bool     `json:"multiValue,omitempty"`
		Values       []string `json:"values,omitempty"`
		DataType     string   `json:"dataType,omitempty"`
		Options      []string `json:"options,omitempty"`
		InputType    string   `json:"inputType,omitempty"`
	} `json:"extensionAttributes,omitempty"`
}

type ComputerInventoryDataSubsetPackageReceipts

type ComputerInventoryDataSubsetPackageReceipts struct {
	InstalledByJamfPro      []string `json:"installedByJamfPro,omitempty"`
	InstalledByInstallerSwu []string `json:"installedByInstallerSwu,omitempty"`
	Cached                  []string `json:"cached,omitempty"`
}

type ComputerInventoryDataSubsetPlugins

type ComputerInventoryDataSubsetPlugins struct {
	Name    string `json:"name,omitempty"`
	Version string `json:"version,omitempty"`
	Path    string `json:"path,omitempty"`
}

type ComputerInventoryDataSubsetPrinters

type ComputerInventoryDataSubsetPrinters struct {
	Name     string `json:"name,omitempty"`
	Type     string `json:"type,omitempty"`
	URI      string `json:"uri,omitempty"`
	Location string `json:"location,omitempty"`
}

type ComputerInventoryDataSubsetPurchasing

type ComputerInventoryDataSubsetPurchasing struct {
	Leased              bool   `json:"leased,omitempty"`
	Purchased           bool   `json:"purchased,omitempty"`
	PoNumber            string `json:"poNumber,omitempty"`
	PoDate              string `json:"poDate,omitempty"`
	Vendor              string `json:"vendor,omitempty"`
	WarrantyDate        string `json:"warrantyDate,omitempty"`
	AppleCareID         string `json:"appleCareId,omitempty"`
	LeaseDate           string `json:"leaseDate,omitempty"`
	PurchasePrice       string `json:"purchasePrice,omitempty"`
	LifeExpectancy      int    `json:"lifeExpectancy,omitempty"`
	PurchasingAccount   string `json:"purchasingAccount,omitempty"`
	PurchasingContact   string `json:"purchasingContact,omitempty"`
	ExtensionAttributes []struct {
		DefinitionID string   `json:"definitionId,omitempty"`
		Name         string   `json:"name,omitempty"`
		Description  string   `json:"description,omitempty"`
		Enabled      bool     `json:"enabled,omitempty"`
		MultiValue   bool     `json:"multiValue,omitempty"`
		Values       []string `json:"values,omitempty"`
		DataType     string   `json:"dataType,omitempty"`
		Options      []string `json:"options,omitempty"`
		InputType    string   `json:"inputType,omitempty"`
	} `json:"extensionAttributes,omitempty"`
}

type ComputerInventoryDataSubsetSecurity

type ComputerInventoryDataSubsetSecurity struct {
	SipStatus             string `json:"sipStatus,omitempty"`
	GatekeeperStatus      string `json:"gatekeeperStatus,omitempty"`
	XprotectVersion       string `json:"xprotectVersion,omitempty"`
	AutoLoginDisabled     bool   `json:"autoLoginDisabled,omitempty"`
	RemoteDesktopEnabled  bool   `json:"remoteDesktopEnabled,omitempty"`
	ActivationLockEnabled bool   `json:"activationLockEnabled,omitempty"`
	RecoveryLockEnabled   bool   `json:"recoveryLockEnabled,omitempty"`
	FirewallEnabled       bool   `json:"firewallEnabled,omitempty"`
	SecureBootLevel       string `json:"secureBootLevel,omitempty"`
	ExternalBootLevel     string `json:"externalBootLevel,omitempty"`
	BootstrapTokenAllowed bool   `json:"bootstrapTokenAllowed,omitempty"`
}

type ComputerInventoryDataSubsetServices

type ComputerInventoryDataSubsetServices struct {
	Name string `json:"name,omitempty"`
}

type ComputerInventoryDataSubsetSoftwareUpdates

type ComputerInventoryDataSubsetSoftwareUpdates struct {
	Name        string `json:"name,omitempty"`
	Version     string `json:"version,omitempty"`
	PackageName string `json:"packageName,omitempty"`
}

type ComputerInventoryDataSubsetStorage

type ComputerInventoryDataSubsetStorage struct {
	BootDriveAvailableSpaceMegabytes int `json:"bootDriveAvailableSpaceMegabytes,omitempty"`
	Disks                            []struct {
		ID            string `json:"id,omitempty"`
		Device        string `json:"device,omitempty"`
		Model         string `json:"model,omitempty"`
		Revision      string `json:"revision,omitempty"`
		SerialNumber  string `json:"serialNumber,omitempty"`
		SizeMegabytes int    `json:"sizeMegabytes,omitempty"`
		SmartStatus   string `json:"smartStatus,omitempty"`
		Type          string `json:"type,omitempty"`
		Partitions    []struct {
			Name                      string `json:"name,omitempty"`
			SizeMegabytes             int    `json:"sizeMegabytes,omitempty"`
			AvailableMegabytes        int    `json:"availableMegabytes,omitempty"`
			PartitionType             string `json:"partitionType,omitempty"`
			PercentUsed               int    `json:"percentUsed,omitempty"`
			FileVault2State           string `json:"fileVault2State,omitempty"`
			FileVault2ProgressPercent int    `json:"fileVault2ProgressPercent,omitempty"`
			LvmManaged                bool   `json:"lvmManaged,omitempty"`
		} `json:"partitions,omitempty"`
	} `json:"disks,omitempty"`
}

type ComputerInventoryDataSubsetUserAndLocation

type ComputerInventoryDataSubsetUserAndLocation struct {
	Username            string `json:"username,omitempty"`
	Realname            string `json:"realname,omitempty"`
	Email               string `json:"email,omitempty"`
	Position            string `json:"position,omitempty"`
	Phone               string `json:"phone,omitempty"`
	DepartmentID        string `json:"departmentId,omitempty"`
	BuildingID          string `json:"buildingId,omitempty"`
	Room                string `json:"room,omitempty"`
	ExtensionAttributes []struct {
		DefinitionID string   `json:"definitionId,omitempty"`
		Name         string   `json:"name,omitempty"`
		Description  string   `json:"description,omitempty"`
		Enabled      bool     `json:"enabled,omitempty"`
		MultiValue   bool     `json:"multiValue,omitempty"`
		Values       []string `json:"values,omitempty"`
		DataType     string   `json:"dataType,omitempty"`
		Options      []string `json:"options,omitempty"`
		InputType    string   `json:"inputType,omitempty"`
	} `json:"extensionAttributes,omitempty"`
}

type ComputerListResponse

type ComputerListResponse struct {
	ID              int    `json:"id,omitempty" xml:"id,omitempty"`
	UDID            string `json:"udid,omitempty" xml:"udid,omitempty"`
	Name            string `json:"name,omitempty" xml:"name,omitempty"`
	SerialNumber    string `json:"serial_number,omitempty" xml:"serial_number,omitempty"`
	Managed         bool   `json:"managed,omitempty" xml:"managed,omitempty"`
	Model           string `json:"model,omitempty" xml:"model,omitempty"`
	Department      string `json:"department,omitempty" xml:"department,omitempty"`
	Building        string `json:"building,omitempty" xml:"building,omitempty"`
	MACAddress      string `json:"mac_address,omitempty" xml:"mac_address,omitempty"`
	ReportDateUTC   string `json:"report_date_utc,omitempty" xml:"report_date_utc,omitempty"`
	ReportDateEpoch int64  `json:"report_date_epoch,omitempty" xml:"report_date_epoch,omitempty"`
}

type ComputerScope

type ComputerScope struct {
	ID   int    `xml:"id,omitempty"`
	Name string `xml:"name,omitempty"`
	UDID string `xml:"udid,omitempty"`
}

type ComputersResponse

type ComputersResponse struct {
	Size    int                    `xml:"size"`
	Results []ComputerListResponse `xml:"computer"`
}

type Department

type Department struct {
	Id   *string `json:"id,omitempty"` // The response type to be returned is a string
	Name *string `json:"name,omitempty"`
	Href *string `json:"href,omitempty"`
}

func (*Department) GetId

func (d *Department) GetId() string

func (*Department) GetName

func (d *Department) GetName() string

func (*Department) SetId

func (d *Department) SetId(v string)

Departments

func (*Department) SetName

func (d *Department) SetName(v string)

type DepartmentScope

type DepartmentScope struct {
	ID   int    `xml:"id,omitempty"`
	Name string `xml:"name,omitempty"`
}

type DeviceGroupAndOr

type DeviceGroupAndOr string
const (
	And DeviceGroupAndOr = "and"
	Or  DeviceGroupAndOr = "or"
)

type Error

type Error interface {
	Error() string
	StatusCode() int
	URI() string
	Body() string
}

type FormOptions

type FormOptions struct {
	ClientId     string `url:"client_id"`
	ClientSecret string `url:"client_secret"`
	GrantType    string `url:"grant_type"`
}

type GeneralCategory

type GeneralCategory struct {
	ID   string `xml:"id,omitempty"`
	Name string `xml:"name,omitempty"`
}

type IBeaconScope

type IBeaconScope struct {
	Id   int    `xml:"id"`
	Name string `xml:"name"`
}

type JamfUserScope

type JamfUserScope struct {
	Id   int    `xml:"id"`
	Name string `xml:"name"`
}

type MobileDeviceGroup

type MobileDeviceGroup struct {
	ID           int                            `xml:"id"`
	Name         string                         `xml:"name"`
	IsSmart      bool                           `xml:"is_smart"`
	Site         Site                           `xml:"site"`
	Criteria     []MobileDeviceGroupCriterion   `xml:"criteria>criterion"`
	CriteriaSize int                            `xml:"criteria>size"`
	Devices      []MobileDeviceGroupDeviceEntry `xml:"mobile_devices>mobile_device"`
	DeviceSize   int                            `xml:"mobile_devices>size"`
}

type MobileDeviceGroupCriterion

type MobileDeviceGroupCriterion struct {
	Name         string           `xml:"name"`
	Priority     int              `xml:"priority"`
	AndOr        DeviceGroupAndOr `xml:"and_or"`
	SearchType   string           `xml:"search_type"`
	SearchValue  string           `xml:"value"`
	OpeningParen bool             `xml:"opening_paren"`
	ClosingParen bool             `xml:"closing_paren"`
}

type MobileDeviceGroupDeviceEntry

type MobileDeviceGroupDeviceEntry struct {
	ID           int    `json:"id,omitempty" xml:"id,omitempty"`
	Name         string `json:"name,omitempty" xml:"name,omitempty"`
	SerialNumber string `json:"serial_number,omitempty" xml:"serial_number,omitempty"`
}

type MobileDeviceGroupListResponse

type MobileDeviceGroupListResponse struct {
	ID      int    `xml:"id,omitempty"`
	Name    string `xml:"name,omitempty"`
	IsSmart bool   `xml:"is_smart,omitempty"`
}

type MobileDeviceGroupRequest

type MobileDeviceGroupRequest struct {
	Name     string                         `xml:"name"`
	IsSmart  bool                           `xml:"is_smart"`
	Site     Site                           `xml:"site"`
	Criteria []MobileDeviceGroupCriterion   `xml:"criteria>criterion"`
	Devices  []MobileDeviceGroupDeviceEntry `xml:"mobile_devices>mobile_device,omitempty"`
}

type MobileDeviceGroupsResponse

type MobileDeviceGroupsResponse struct {
	Size    int                             `xml:"size"`
	Results []MobileDeviceGroupListResponse `xml:"mobile_device_group"`
}

type NetworkSegmentScope

type NetworkSegmentScope struct {
	ID   int    `xml:"id"`
	UID  string `xml:"uid,omitempty"`
	Name int    `xml:"name"`
}

type Package

type Package struct {
	ID                 int    `xml:"id"`
	Name               string `xml:"name"`
	CategoryName       string `xml:"category"`
	Filename           string `xml:"filename"`
	Info               string `xml:"info"`
	Notes              string `xml:"notes"`
	RebootRequired     bool   `xml:"reboot_required"`
	Priority           int    `xml:"priority"`
	FillExistingUsers  bool   `xml:"fill_existing_users"`
	BootVolumeRequired bool   `xml:"boot_volume_required"`
	AllowUninstalled   bool   `xml:"allow_uninstalled"`
	OsRequirements     string `xml:"os_requirements"`
	RequiredProcessor  string `xml:"required_processor"`
	HashType           string `xml:"hash_type,omitempty"`
	HashValue          string `xml:"hash_value,omitempty"`
}

type PackageListItem

type PackageListItem struct {
	ID   int    `xml:"id"`
	Name string `xml:"name"`
}

type PackageListResponse

type PackageListResponse struct {
	Size    int               `xml:"size"`
	Results []PackageListItem `xml:"package"`
}

type Policy

type Policy struct {
	General              PolicyGeneral              `xml:"general"`
	Scope                PolicyScope                `xml:"scope,omitempty"`
	SelfService          PolicySelfService          `xml:"self_service"`
	PackageConfiguration PolicyPackageConfiguration `xml:"package_configuration,omitempty"`
	ScriptsConfiguration PolicyScripts              `xml:"scripts,omitempty"`
	Reboot               PolicyReboot               `xml:"reboot"`
	Maintenance          PolicyMaintenance          `xml:"maintenance"`
	FilesAndProcesses    PolicyFilesAndProcesses    `xml:"files_processes"`
	UserInteraction      PolicyUserInteraction      `xml:"user_interaction"`
}

type PolicyFilesAndProcesses

type PolicyFilesAndProcesses struct {
	SearchByPath         string `xml:"search_by_path"`
	DeleteFile           bool   `xml:"delete_file"`
	LocateFile           string `xml:"locate_file"`
	UpdateLocateDatabase bool   `xml:"update_locate_database"`
	SpotlightSearch      string `xml:"spotlight_search"`
	SearchForProcess     string `xml:"search_for_process"`
	KillProcess          bool   `xml:"kill_process"`
	RunCommand           string `xml:"run_command"`
}

type PolicyGeneral

type PolicyGeneral struct {
	ID                         int                                  `xml:"id"`
	Name                       string                               `xml:"name"`
	Enabled                    bool                                 `xml:"enabled"`
	Trigger                    string                               `xml:"trigger"`
	TriggerCheckin             bool                                 `xml:"trigger_checkin"`
	TriggerEnrollmentComplete  bool                                 `xml:"trigger_enrollment_complete"`
	TriggerLogin               bool                                 `xml:"trigger_login"`
	TriggerLogout              bool                                 `xml:"trigger_logout"`
	TriggerNetworkStateChanged bool                                 `xml:"trigger_network_state_changed"`
	TriggerStartup             bool                                 `xml:"trigger_startup"`
	TriggerOther               string                               `xml:"trigger_other"`
	Frequency                  string                               `xml:"frequency"`
	RetryEvent                 string                               `xml:"retry_event"`
	RetryAttempts              int                                  `xml:"retry_attempts"`
	NotifyOnEachFailedRetry    bool                                 `xml:"notify_on_each_failed_retry"`
	LocationUserOnly           bool                                 `xml:"location_user_only"`
	TargetDrive                string                               `xml:"target_drive"`
	Offline                    bool                                 `xml:"offline"`
	Category                   GeneralCategory                      `xml:"category,omitempty"`
	DateTimeLimitations        PolicyGeneralDateTimeLimitations     `xml:"date_time_limitations"`
	NetworkLimitations         PolicyGeneralNetworkLimitations      `xml:"network_limitations"`
	OverrideDefaultSettings    PolicyGeneralOverrideDefaultSettings `xml:"override_default_settings"`
	NetworkRequirements        string                               `xml:"network_requirements"`
	Site                       Site                                 `xml:"site"`
}

type PolicyGeneralDateTimeLimitations

type PolicyGeneralDateTimeLimitations struct {
	ActivationDate      string `xml:"activation_date"`
	ActivationDateEpoch int    `xml:"activation_date_epoch"`
	ActivationDateUtc   string `xml:"activation_date_utc"`
	ExpirationDate      string `xml:"expiration_date"`
	ExpirationDateEpoch int    `xml:"expiration_date_epoch"`
	ExpirationDateUtc   string `xml:"expiration_date_utc"`
	NoExecuteOn         string `xml:"no_execute_on"`
	NoExecuteStart      string `xml:"no_execute_start"`
	NoExecuteEnd        string `xml:"no_execute_end"`
}

TODO Get types and test

type PolicyGeneralNetworkLimitations

type PolicyGeneralNetworkLimitations struct {
	MinimumNetworkConnection string `xml:"minimum_network_connection"`
	AnyIpAddress             bool   `xml:"any_ip_address"`
	NetworkSegments          string `xml:"network_segments"`
}

TODO Get types and test

type PolicyGeneralOverrideDefaultSettings

type PolicyGeneralOverrideDefaultSettings struct {
	TargetDrive       string `xml:"target_drive"`
	DistributionPoint string `xml:"distribution_point"`
	ForceAfpSmb       bool   `xml:"force_afp_smb"`
	Sus               string `xml:"sus"`
	NetbootServer     string `xml:"netboot_server"`
}

TODO Get types and test

type PolicyListItem

type PolicyListItem struct {
	ID   int    `xml:"id"`
	Name string `xml:"name"`
}

type PolicyListResponse

type PolicyListResponse struct {
	Size    int              `xml:"size"`
	Results []PolicyListItem `xml:"policy"`
}

type PolicyMaintenance

type PolicyMaintenance struct {
	Recon                    bool `xml:"recon"`
	ResetName                bool `xml:"reset_name"`
	InstallAllCachedPackages bool `xml:"install_all_cached_packages"`
	Heal                     bool `xml:"heal"`
	Prebindings              bool `xml:"prebindings"`
	Permissions              bool `xml:"permissions"`
	Byhost                   bool `xml:"byhost"`
	SystemCache              bool `xml:"system_cache"`
	UserCache                bool `xml:"user_cache"`
	Verify                   bool `xml:"verify"`
}

type PolicyPackageConfiguration

type PolicyPackageConfiguration struct {
	Packages []PolicyPackageConfigurationPackage `xml:"packages>package,omitempty"`
}

type PolicyPackageConfigurationPackage

type PolicyPackageConfigurationPackage struct {
	ID                int    `xml:"id,omitempty"`
	Name              string `xml:"name,omitempty"`
	Action            string `xml:"action,omitempty"`
	FillUserTemplate  bool   `xml:"fut,omitempty"`
	FillExistingUsers bool   `xml:"feu,omitempty"`
	UpdateAutorun     bool   `xml:"update_autorun,omitempty"`
}

type PolicyReboot

type PolicyReboot struct {
	Message                     string `xml:"message"`
	StartupDisk                 string `xml:"startup_disk"`
	SpecifyStartup              string `xml:"specify_startup"`
	NoUserLoggedIn              string `xml:"no_user_logged_in"`
	UserLoggedIn                string `xml:"user_logged_in"`
	MinutesUntilReboot          int    `xml:"minutes_until_reboot"`
	StartRebootTimerImmediately bool   `xml:"start_reboot_timer_immediately"`
	FileVault2Reboot            bool   `xml:"file_vault_2_reboot"`
}

type PolicyScope

type PolicyScope struct {
	AllComputers   bool                        `xml:"all_computers"`
	Computers      []ComputerScope             `xml:"computers>computer,omitempty"`
	ComputerGroups []ComputerGroupListResponse `xml:"computer_groups>computer_group,omitempty"`
	Buildings      []BuildingScope             `xml:"buildings>building,omitempty"`
	Departments    []DepartmentScope           `xml:"departments>department,omitempty"`
	Exclusions     PolicyScopeExclusions       `xml:"exclusions,omitempty"`
}

type PolicyScopeExclusions

type PolicyScopeExclusions struct {
	Computers      []ComputerScope             `xml:"computers>computer,omitempty"`
	ComputerGroups []ComputerGroupListResponse `xml:"computer_groups>computer_group,omitempty"`
	Buildings      []BuildingScope             `xml:"buildings>building,omitempty"`
	Departments    []DepartmentScope           `xml:"departments>department,omitempty"`
}

type PolicyScript

type PolicyScript struct {
	ID          string `xml:"id,omitempty"`
	Name        string `xml:"name,omitempty"`
	Priority    string `xml:"priority,omitempty"`
	Parameter4  string `xml:"parameter4,omitempty"`
	Parameter5  string `xml:"parameter5,omitempty"`
	Parameter6  string `xml:"parameter6,omitempty"`
	Parameter7  string `xml:"parameter7,omitempty"`
	Parameter8  string `xml:"parameter8,omitempty"`
	Parameter9  string `xml:"parameter9,omitempty"`
	Parameter10 string `xml:"parameter10,omitempty"`
	Parameter11 string `xml:"parameter11,omitempty"`
}

type PolicyScripts

type PolicyScripts struct {
	Scripts []PolicyScript `xml:"script,omitempty"`
}

type PolicySelfService

type PolicySelfService struct {
	UseForSelfService           bool                  `xml:"use_for_self_service"`
	SelfServiceDisplayName      string                `xml:"self_service_display_name"`
	InstallButtonText           string                `xml:"install_button_text"`
	ReinstallButtonText         string                `xml:"reinstall_button_text"`
	SelfServiceDescription      string                `xml:"self_service_description"`
	ForceUsersToViewDescription bool                  `xml:"force_users_to_view_description"`
	SelfServiceIcon             SelfServiceIcon       `xml:"self_service_icon,omitempty"`
	FeatureOnMainPage           bool                  `xml:"feature_on_main_page"`
	SelfServiceCategories       []SelfServiceCategory `xml:"self_service_categories>category,omitempty"`
}

type PolicyUserInteraction

type PolicyUserInteraction struct {
	MessageStart          string `xml:"message_start"`
	AllowUsersToDefer     bool   `xml:"allow_users_to_defer"`
	AllowDeferralUntilUtc string `xml:"allow_deferral_until_utc"`
	AllowDeferralMinutes  int    `xml:"allow_deferral_minutes"`
	MessageFinish         string `xml:"message_finish"`
}

type ResponseBuildings

type ResponseBuildings struct {
	TotalCount *int       `json:"totalCount,omitempty"`
	Results    []Building `json:"results,omitempty"`
}

type ResponseCategories

type ResponseCategories struct {
	TotalCount *int       `json:"totalCount,omitempty"`
	Results    []Category `json:"results,omitempty"`
}

type ResponseDepartments

type ResponseDepartments struct {
	TotalCount *int         `json:"totalCount,omitempty"`
	Results    []Department `json:"results,omitempty"`
}

type Script

type Script struct {
	ID             string `json:"id,omitempty"`
	Name           string `json:"name"`
	CategoryID     string `json:"categoryId"`
	CategoryName   string `json:"categoryName"`
	Info           string `json:"info"`
	Notes          string `json:"notes"`
	Priority       string `json:"priority"`
	Parameter4     string `json:"parameter4"`
	Parameter5     string `json:"parameter5"`
	Parameter6     string `json:"parameter6"`
	Parameter7     string `json:"parameter7"`
	Parameter8     string `json:"parameter8"`
	Parameter9     string `json:"parameter9"`
	Parameter10    string `json:"parameter10"`
	Parameter11    string `json:"parameter11"`
	OsRequirements string `json:"osRequirements"`
	ScriptContents string `json:"scriptContents"`
}

type ScriptCreateResponse

type ScriptCreateResponse struct {
	ID   string `json:"id,omitempty"`
	Href string `json:"href,omitempty"`
}

type ScriptsListResponse

type ScriptsListResponse struct {
	Count   int      `json:"totalCount,omitempty"`
	Results []Script `json:"results,omitempty"`
}

type SelfServiceCategory

type SelfServiceCategory struct {
	ID        int    `xml:"id,omitempty"`
	Name      string `xml:"name,omitempty"`
	DisplayIn bool   `xml:"display_in,omitempty"`
	FeatureIn bool   `xml:"feature_in,omitempty"`
}

type SelfServiceIcon

type SelfServiceIcon struct {
	ID       int    `xml:"id,omitempty"`
	Filename string `xml:"filename,omitempty"`
	URI      string `xml:"uri,omitempty"`
}

type Site

type Site struct {
	ID   int    `json:"id,omitempty" xml:"id,omitempty"`
	Name string `json:"name,omitempty" xml:"name,omitempty"`
}

type UserGroupScope

type UserGroupScope struct {
	Id   int    `xml:"id"`
	Name string `xml:"name"`
}

type UserScope

type UserScope struct {
	Name string `xml:"name"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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