-
Notifications
You must be signed in to change notification settings - Fork 2
/
azure_settings.go
84 lines (66 loc) · 2.84 KB
/
azure_settings.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
// Code generated by go-swagger; DO NOT EDIT.
package models
// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command
import (
"context"
"github.com/go-openapi/strfmt"
"github.com/go-openapi/swag"
)
// AzureSettings Azure IDP specific settings
//
// swagger:model AzureSettings
type AzureSettings struct {
// Application ID from your Microsoft Azure application settings
ClientID string `json:"client_id,omitempty" yaml:"client_id,omitempty"`
// If enabled, the groups a user belongs to are collected
//
// Groups are collections of users and other principals who share access to resources in
// Microsoft services or in your app. Microsoft Graph provides APIs that you can use to create
// and manage different types of groups and group functionality according to your scenario.
//
// You can only get groups data if you are entitled to call the Microsoft Graph API.
FetchGroups bool `json:"fetch_groups,omitempty" yaml:"fetch_groups,omitempty"`
// If enabled, users' data is collected from the Microsoft Graph API
//
// You can only get user's data if you are entitled to call the Microsoft Graph API.
GetUser bool `json:"get_user,omitempty" yaml:"get_user,omitempty"`
// An array of user attributes fetched from the Microsoft Graph API
GraphUserAttributes []string `json:"graph_user_attributes" yaml:"graph_user_attributes"`
// String represented group name format used for fetching groups
//
// It's value can be either `id` or `name`.
GroupNameFormat string `json:"group_name_format,omitempty" yaml:"group_name_format,omitempty"`
// If enabled, only security groups a user belongs to are collected.
OnlySecurityGroups bool `json:"only_security_groups,omitempty" yaml:"only_security_groups,omitempty"`
// An array of additional scopes your client requests
Scopes []string `json:"scopes" yaml:"scopes"`
// Whether to send the identifier as a `login_hint` parameter to the IDP
SendLoginHint bool `json:"send_login_hint,omitempty" yaml:"send_login_hint,omitempty"`
// Directory ID from your Microsoft Azure application settings
Tenant string `json:"tenant,omitempty" yaml:"tenant,omitempty"`
}
// Validate validates this azure settings
func (m *AzureSettings) Validate(formats strfmt.Registry) error {
return nil
}
// ContextValidate validates this azure settings based on context it is used
func (m *AzureSettings) ContextValidate(ctx context.Context, formats strfmt.Registry) error {
return nil
}
// MarshalBinary interface implementation
func (m *AzureSettings) MarshalBinary() ([]byte, error) {
if m == nil {
return nil, nil
}
return swag.WriteJSON(m)
}
// UnmarshalBinary interface implementation
func (m *AzureSettings) UnmarshalBinary(b []byte) error {
var res AzureSettings
if err := swag.ReadJSON(b, &res); err != nil {
return err
}
*m = res
return nil
}