Test the integration

Having completed the integration steps, you can now test the setup using the cURL testing utility.

Note

You must have added a weblogic user to the API Gateway local user store as outlined in Prerequisites.

Assuming you are running API Gateway on a machine called apigateway on the default port of 8080, you can send a POST request to the authorization policy on API Gateway using HTTP basic authentication with the following command:

You can see that the success message has been returned by API Gateway meaning that the weblogic user has been successfully authorized by OES to access the resource. A quick look at the API Gateway’s trace output shows the OES 11g Authorization filter making the successful authorization request for the MyApplication/MyResourceType/MyResource resource:

Now let's see what happens when you authenticate with a user that is present in the API Gateway's local user store, but that has not been configured with authorization rights in OES. To demonstrate this, you can send up a request using the credentials of the default API Gatewayadmin user: