Skip to content

Commit

Permalink
Further support for authorize roles and permissions (#346)
Browse files Browse the repository at this point in the history
* authz corrections

* add resource application resources

* add `EnumResourceApplicationResourceType` enum and docs

* Add `ApplicationPermissionsSettings` to the `Resource` model

* changelogs

* rename `CreateApplicationPermissions` to `CreateApplicationPermission`

* Add support for User Application Role Assignment API

* corrections to `ApplicationRolePermission`
  • Loading branch information
patrickcping authored Jun 4, 2024
1 parent a02bb96 commit debb63c
Show file tree
Hide file tree
Showing 59 changed files with 8,400 additions and 925 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,16 @@
* **Feature** Add support for Application Roles API. [#344](https://github.com/patrickcping/pingone-go-sdk-v2/pull/344)
* **Feature** Add support for Application Role Assignments API. [#344](https://github.com/patrickcping/pingone-go-sdk-v2/pull/344)
* **Feature** Add support for Application Role Permissions API. [#344](https://github.com/patrickcping/pingone-go-sdk-v2/pull/344)
* **Feature** Add support for Application Roles API. [#344](https://github.com/patrickcping/pingone-go-sdk-v2/pull/344)
* **Enhancement** Add the `com.au` top level domain to the connection configuration. [#351](https://github.com/patrickcping/pingone-go-sdk-v2/pull/351)
* `github.com/patrickcping/pingone-go-sdk-v2/credentials` : [v0.8.0](./credentials/CHANGELOG.md)
* **Enhancement** Add the `com.au` top level domain to the connection configuration. [#351](https://github.com/patrickcping/pingone-go-sdk-v2/pull/351)
* `github.com/patrickcping/pingone-go-sdk-v2/management` : [v0.40.0](./management/CHANGELOG.md)
* **Breaking Change** Removed the `FormSocialLoginButtonStyles` data model. Use the `FormStyles` data model going forward. [#350](https://github.com/patrickcping/pingone-go-sdk-v2/pull/350)
* **Note** Removed unnecessary `Width` and `IconSrc` fields from `FormSocialLoginButton` and associated data models. [#350](https://github.com/patrickcping/pingone-go-sdk-v2/pull/350)
* **Feature** Add support for Application Resource API. [#346](https://github.com/patrickcping/pingone-go-sdk-v2/pull/346)
* **Feature** Add support for Application Resource Permissions API. [#346](https://github.com/patrickcping/pingone-go-sdk-v2/pull/346)
* **Feature** Add support for User Application Role Assignment API. [#346](https://github.com/patrickcping/pingone-go-sdk-v2/pull/346)
* **Enhancement** Added `ApplicationPermissionsSettings` to the `Resource` model. [#346](https://github.com/patrickcping/pingone-go-sdk-v2/pull/346)
* **Enhancement** Added `Key` field to `FormSocialLoginButton` and associated data models. [#350](https://github.com/patrickcping/pingone-go-sdk-v2/pull/350)
* **Enhancement** Added the `DeletePreviousResourceSecret` function to control resource secret rotation. [#347](https://github.com/patrickcping/pingone-go-sdk-v2/pull/347)
* **Enhancement** Added `Previous` to the `ResourceSecret` model to control resource secret rotation. [#347](https://github.com/patrickcping/pingone-go-sdk-v2/pull/347)
Expand Down
8 changes: 2 additions & 6 deletions authorize/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ api/openapi.yaml
api_api_servers.go
api_application_resource_permissions.go
api_application_resources.go
api_application_role.go
api_application_role_assignments.go
api_application_role_permissions.go
api_application_roles.go
Expand All @@ -20,12 +19,10 @@ docs/ApplicationResourcePermissionResource.md
docs/ApplicationResourcePermissionsApi.md
docs/ApplicationResourcesApi.md
docs/ApplicationRole.md
docs/ApplicationRoleApi.md
docs/ApplicationRoleAssignment.md
docs/ApplicationRoleAssignmentsApi.md
docs/ApplicationRolePermission.md
docs/ApplicationRolePermissionPermission.md
docs/ApplicationRolePermissionPermissionResource.md
docs/ApplicationRolePermissionResource.md
docs/ApplicationRolePermissionsApi.md
docs/ApplicationRolesApi.md
docs/DecisionEndpoint.md
Expand Down Expand Up @@ -59,8 +56,7 @@ model_application_resource_permission_resource.go
model_application_role.go
model_application_role_assignment.go
model_application_role_permission.go
model_application_role_permission_permission.go
model_application_role_permission_permission_resource.go
model_application_role_permission_resource.go
model_decision_endpoint.go
model_decision_endpoint_authorization_version.go
model_decision_endpoint_recent_decisions.go
Expand Down
9 changes: 4 additions & 5 deletions authorize/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,22 +82,22 @@ Class | Method | HTTP request | Description
*APIServersApi* | [**ReadAllAPIServers**](docs/APIServersApi.md#readallapiservers) | **Get** /environments/{environmentID}/apiServers | READ All API Servers
*APIServersApi* | [**ReadOneAPIServer**](docs/APIServersApi.md#readoneapiserver) | **Get** /environments/{environmentID}/apiServers/{apiServerID} | READ One API Server
*APIServersApi* | [**UpdateAPIServer**](docs/APIServersApi.md#updateapiserver) | **Put** /environments/{environmentID}/apiServers/{apiServerID} | UPDATE API Server
*ApplicationResourcePermissionsApi* | [**CreateApplicationPermissions**](docs/ApplicationResourcePermissionsApi.md#createapplicationpermissions) | **Post** /environments/{environmentID}/applicationResources/{applicationResourceID}/permissions | CREATE Application Permissions
*ApplicationResourcePermissionsApi* | [**CreateApplicationPermission**](docs/ApplicationResourcePermissionsApi.md#createapplicationpermission) | **Post** /environments/{environmentID}/applicationResources/{applicationResourceID}/permissions | CREATE Application Permission
*ApplicationResourcePermissionsApi* | [**DeleteApplicationPermission**](docs/ApplicationResourcePermissionsApi.md#deleteapplicationpermission) | **Delete** /environments/{environmentID}/applicationResources/{applicationResourceID}/permissions/{applicationResourcePermissionID} | DELETE Application Permission
*ApplicationResourcePermissionsApi* | [**ReadApplicationPermissions**](docs/ApplicationResourcePermissionsApi.md#readapplicationpermissions) | **Get** /environments/{environmentID}/applicationResources/{applicationResourceID}/permissions | READ Application Permissions
*ApplicationResourcePermissionsApi* | [**ReadOneApplicationPermission**](docs/ApplicationResourcePermissionsApi.md#readoneapplicationpermission) | **Get** /environments/{environmentID}/applicationResources/{applicationResourceID}/permissions/{applicationResourcePermissionID} | READ One Application Permission
*ApplicationResourcePermissionsApi* | [**UpdateApplicationPermission**](docs/ApplicationResourcePermissionsApi.md#updateapplicationpermission) | **Put** /environments/{environmentID}/applicationResources/{applicationResourceID}/permissions/{applicationResourcePermissionID} | UPDATE Application Permission
*ApplicationResourcesApi* | [**ReadApplicationResources**](docs/ApplicationResourcesApi.md#readapplicationresources) | **Get** /environments/{environmentID}/applicationResources | READ Application Resources
*ApplicationResourcesApi* | [**ReadOneApplicationResource**](docs/ApplicationResourcesApi.md#readoneapplicationresource) | **Get** /environments/{environmentID}/applicationResources/{applicationResourceID} | READ One Application Resource
*ApplicationRoleApi* | [**DeleteApplicationRole**](docs/ApplicationRoleApi.md#deleteapplicationrole) | **Delete** /environments/{environmentID}/applicationRoles/{applicationRoleID} | DELETE Application Role
*ApplicationRoleApi* | [**UpdateApplicationRole**](docs/ApplicationRoleApi.md#updateapplicationrole) | **Put** /environments/{environmentID}/applicationRoles/{applicationRoleID} | UPDATE Application Role
*ApplicationRoleAssignmentsApi* | [**ReadApplicationRoleAssignments**](docs/ApplicationRoleAssignmentsApi.md#readapplicationroleassignments) | **Get** /environments/{environmentID}/applicationRoles/{applicationRoleID}/assignments | READ Application Role Assignments
*ApplicationRolePermissionsApi* | [**CreateApplicationRolePermission**](docs/ApplicationRolePermissionsApi.md#createapplicationrolepermission) | **Post** /environments/{environmentID}/applicationRoles/{applicationRoleID}/permissions | CREATE Application Role Permission
*ApplicationRolePermissionsApi* | [**DeleteApplicationRolePermission**](docs/ApplicationRolePermissionsApi.md#deleteapplicationrolepermission) | **Delete** /environments/{environmentID}/applicationRoles/{applicationRoleID}/permissions/{applicationRolePermissionID} | DELETE Application Role Permission
*ApplicationRolePermissionsApi* | [**ReadApplicationRolePermissions**](docs/ApplicationRolePermissionsApi.md#readapplicationrolepermissions) | **Get** /environments/{environmentID}/applicationRoles/{applicationRoleID}/permissions | READ Application Role Permissions
*ApplicationRolesApi* | [**CreateApplicationRoles**](docs/ApplicationRolesApi.md#createapplicationroles) | **Post** /environments/{environmentID}/applicationRoles | CREATE Application Roles
*ApplicationRolesApi* | [**DeleteApplicationRole**](docs/ApplicationRolesApi.md#deleteapplicationrole) | **Delete** /environments/{environmentID}/applicationRoles/{applicationRoleID} | DELETE Application Role
*ApplicationRolesApi* | [**ReadApplicationRoles**](docs/ApplicationRolesApi.md#readapplicationroles) | **Get** /environments/{environmentID}/applicationRoles | READ Application Roles
*ApplicationRolesApi* | [**ReadOneApplicationRole**](docs/ApplicationRolesApi.md#readoneapplicationrole) | **Get** /environments/{environmentID}/applicationRoles/{applicationRoleID} | READ One Application Role
*ApplicationRolesApi* | [**UpdateApplicationRole**](docs/ApplicationRolesApi.md#updateapplicationrole) | **Put** /environments/{environmentID}/applicationRoles/{applicationRoleID} | UPDATE Application Role
*PolicyDecisionManagementApi* | [**CreateDecisionEndpoint**](docs/PolicyDecisionManagementApi.md#createdecisionendpoint) | **Post** /environments/{environmentID}/decisionEndpoints | CREATE Decision Endpoint
*PolicyDecisionManagementApi* | [**DeleteDecisionEndpoint**](docs/PolicyDecisionManagementApi.md#deletedecisionendpoint) | **Delete** /environments/{environmentID}/decisionEndpoints/{decisionEndpointID} | DELETE Decision Endpoint
*PolicyDecisionManagementApi* | [**ReadAllDecisionEndpoints**](docs/PolicyDecisionManagementApi.md#readalldecisionendpoints) | **Get** /environments/{environmentID}/decisionEndpoints | READ All Decision Endpoints
Expand All @@ -117,8 +117,7 @@ Class | Method | HTTP request | Description
- [ApplicationRole](docs/ApplicationRole.md)
- [ApplicationRoleAssignment](docs/ApplicationRoleAssignment.md)
- [ApplicationRolePermission](docs/ApplicationRolePermission.md)
- [ApplicationRolePermissionPermission](docs/ApplicationRolePermissionPermission.md)
- [ApplicationRolePermissionPermissionResource](docs/ApplicationRolePermissionPermissionResource.md)
- [ApplicationRolePermissionResource](docs/ApplicationRolePermissionResource.md)
- [DecisionEndpoint](docs/DecisionEndpoint.md)
- [DecisionEndpointAuthorizationVersion](docs/DecisionEndpointAuthorizationVersion.md)
- [DecisionEndpointRecentDecisions](docs/DecisionEndpointRecentDecisions.md)
Expand Down
56 changes: 26 additions & 30 deletions authorize/api/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -945,7 +945,7 @@ paths:
tags:
- Application Resource Permissions
post:
operationId: createApplicationPermissions
operationId: createApplicationPermission
parameters:
- explode: false
in: path
Expand Down Expand Up @@ -1023,7 +1023,7 @@ paths:
schema:
$ref: '#/components/schemas/ApplicationResourcePermission'
description: Successful response
summary: CREATE Application Permissions
summary: CREATE Application Permission
tags:
- Application Resource Permissions
/environments/{environmentID}/applicationResources/{applicationResourceID}/permissions/{applicationResourcePermissionID}:
Expand Down Expand Up @@ -1464,7 +1464,7 @@ paths:
description: Successful response
summary: DELETE Application Role
tags:
- Application Role
- Application Roles
get:
operationId: readOneApplicationRole
parameters:
Expand Down Expand Up @@ -1609,7 +1609,7 @@ paths:
description: Successful response
summary: UPDATE Application Role
tags:
- Application Role
- Application Roles
/environments/{environmentID}/applicationRoles/{applicationRoleID}/permissions:
get:
operationId: readApplicationRolePermissions
Expand Down Expand Up @@ -2109,20 +2109,34 @@ components:
type: object
ApplicationRolePermission:
example:
permission:
resource:
name: name
id: id
action: action
environment:
id: id
resource:
name: name
id: id
description: description
action: action
id: id
key: key
properties:
id:
description: The ID of the application resource permission to associate
with this role.
type: string
permission:
$ref: '#/components/schemas/ApplicationRolePermission_permission'
environment:
$ref: '#/components/schemas/ObjectEnvironment'
key:
readOnly: true
type: string
description:
readOnly: true
type: string
action:
description: The action associated with this permission.
readOnly: true
type: string
resource:
$ref: '#/components/schemas/ApplicationRolePermission_resource'
required:
- id
type: object
Expand Down Expand Up @@ -2502,7 +2516,7 @@ components:
type: string
readOnly: true
type: object
ApplicationRolePermission_permission_resource:
ApplicationRolePermission_resource:
example:
name: name
id: id
Expand All @@ -2514,24 +2528,6 @@ components:
description: The name of the applicawtion resource associated with this
permission.
type: string
type: object
ApplicationRolePermission_permission:
example:
resource:
name: name
id: id
action: action
id: id
properties:
id:
description: The ID of the permission resource associated with a specified
role.
type: string
action:
description: The action associated with this permission.
type: string
resource:
$ref: '#/components/schemas/ApplicationRolePermission_permission_resource'
readOnly: true
type: object
DecisionEndpoint_authorizationVersion:
Expand Down
24 changes: 12 additions & 12 deletions authorize/api_application_resource_permissions.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit debb63c

Please sign in to comment.