Verifying Permissions via API
You can use the Permissions Webservices API to verify user or user group permissions.
As of SAP Commerce Cloud version 2105, the default method to verify permissions is POST. GET is disabled by default.
Verifying Permissions via POST (Default Method)
The following HTTP POST endpoints that allow verification of permissions are parametrized by the principal UID and are available by default:
- searchGlobalPermissions
- searchTypesPermissions
- searchAttributesPermissions
- searchCatalogPermissions
Verifying Permissions via GET (Available for Backwards Compatibility)
The following HTTP GET endpoints are disabled by default:
- getGlobalPermissions
- getTypesPermissions
- getAttributesPermissions
- getCatalogPermissions
Enabling the GET API
For backwards compatibility, you can still enable GET if required although it's not recommended. To do so, remove the endpoint identifiers getGlobalPermissions, getTypesPermissions, getAttributesPermissions and getCatalogPermissions from the permissionswebservices.api.restrictions.disabled.endpoints configuration property by setting it to an empty value. For example:
Enabling GET API Tests
When GET endpoints are enabled, enable the GET API tests. To do so, set the permissionswebservices.enableGetPermissionsTest property to true. For example: