github.com/axw/juju@v0.0.0-20161005053422-4bd6544d08d4/provider/azure/internal/ad/models.go (about) 1 // This file is based on code from Azure/azure-sdk-for-go, 2 // which is Copyright Microsoft Corporation. See the LICENSE 3 // file in this directory for details. 4 // 5 // NOTE(axw) this file contains types for a subset of the 6 // Microsoft Graph API, which is not currently supported by 7 // the Azure SDK. When it is, this will be deleted. 8 9 package ad 10 11 import ( 12 "time" 13 14 "github.com/Azure/go-autorest/autorest" 15 ) 16 17 type AADObject struct { 18 autorest.Response `json:"-"` 19 ObjectID string `json:"objectId"` 20 ObjectType string `json:"objectType"` 21 DisplayName string `json:"displayName"` 22 UserPrincipalName string `json:"userPrincipalName"` 23 Mail string `json:"mail"` 24 MailEnabled bool `json:"mailEnabled"` 25 SecurityEnabled bool `json:"securityEnabled"` 26 SignInName string `json:"signInName"` 27 ServicePrincipalNames []string `json:"servicePrincipalNames"` 28 UserType string `json:"userType"` 29 } 30 31 type PasswordCredentialsListResult struct { 32 autorest.Response `json:"-"` 33 Value []PasswordCredential `json:"value,omitempty"` 34 } 35 36 type PasswordCredentialsUpdateParameters struct { 37 Value []PasswordCredential `json:"value,omitempty"` 38 } 39 40 type PasswordCredential struct { 41 CustomKeyIdentifier []byte `json:"customKeyIdentifier,omitempty"` 42 KeyId string `json:"keyId,omitempty"` 43 Value string `json:"value,omitempty"` 44 StartDate time.Time `json:"startDate,omitempty"` 45 EndDate time.Time `json:"endDate,omitempty"` 46 } 47 48 type ServicePrincipalListResult struct { 49 autorest.Response `json:"-"` 50 Value []ServicePrincipal `json:"value,omitempty"` 51 } 52 53 type ServicePrincipalCreateParameters struct { 54 ApplicationID string `json:"appId,omitempty"` 55 AccountEnabled bool `json:"accountEnabled,omitempty"` 56 PasswordCredentials []PasswordCredential `json:"passwordCredentials,omitempty"` 57 } 58 59 type ServicePrincipal struct { 60 autorest.Response `json:"-"` 61 ApplicationID string `json:"appId,omitempty"` 62 ObjectID string `json:"objectId,omitempty"` 63 AccountEnabled bool `json:"accountEnabled,omitempty"` 64 }