Skip to content

Commit

Permalink
Merge pull request #1260 from GreenStage/egomes/AUTH-5076
Browse files Browse the repository at this point in the history
Add auto_redirect_to_identity to access organizations
  • Loading branch information
jacobbednarz authored Apr 6, 2023
2 parents 93d8999 + fdde842 commit 835007c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .changelog/1260.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
access: Add `auto_redirect_to_identity` flag to Access organizations
```
1 change: 1 addition & 0 deletions access_organization.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ type AccessOrganization struct {
IsUIReadOnly *bool `json:"is_ui_read_only,omitempty"`
UIReadOnlyToggleReason string `json:"ui_read_only_toggle_reason,omitempty"`
UserSeatExpirationInactiveTime string `json:"user_seat_expiration_inactive_time,omitempty"`
AutoRedirectToIdentity *bool `json:"auto_redirect_to_identity,omitempty"`
}

// AccessOrganizationLoginDesign represents the login design options.
Expand Down
2 changes: 2 additions & 0 deletions access_organization_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ func TestAccessOrganization(t *testing.T) {
"auth_domain": "test.cloudflareaccess.com",
"is_ui_read_only": false,
"user_seat_expiration_inactive_time": "720h",
"auto_redirect_to_identity": true,
"login_design": {
"background_color": "#c5ed1b",
"logo_path": "https://example.com/logo.png",
Expand Down Expand Up @@ -57,6 +58,7 @@ func TestAccessOrganization(t *testing.T) {
},
IsUIReadOnly: BoolPtr(false),
UserSeatExpirationInactiveTime: "720h",
AutoRedirectToIdentity: BoolPtr(true),
}

mux.HandleFunc("/accounts/"+testAccountID+"/access/organizations", handler)
Expand Down

0 comments on commit 835007c

Please sign in to comment.