4.4 About the AutoREST Page
Use the Automatic Enabling of Schema Objects for REST Access (AutoREST) feature to enable REST access for database objects in the current schema.
Enabling REST access for a schema object such as table, view, function, procedure and package allows it to be accessed through RESTful services. See AutoREST in Oracle REST Data Services Developer's Guide
To navigate to the AutoREST page, in the REST Overview page, click AutoREST or select AutoREST from the menu in the header.
The AutoREST page consists of three parts:
-
Objects: Displays the number of REST-enabled schema objects that are protected and require authorization out of the total number of schema objects enabled in the schema.
-
AutoREST: Displays the number of tables and views, packages, procedures and functions that are REST enabled in the schema. Click a card to see the corresponding objects listed below.
-
The bottom part of the page lists schema objects based on the selection made in AutoREST. You can view these objects in card view or grid view. The actions available in the context menu for an object are:
-
Edit: Edit the Object Alias or Require Authentication fields for the REST enabled object. For a description of the fields, see Enabling REST Access for a Database Object
-
Disable: Disable REST access for the object. See Disabling REST Access for a Database Object
-
Get Curl: Generate cURL calls for a REST enabled object. See Generating cURL Requests for a REST-Enabled Database Object
-
Export OpenAPI: Export the object as JSON Open API code.
-
OpenAPI View: Display the object as a Swagger UI implementation. You can view and execute the handlers, pass parameters to the handlers, and copy or download the responses.
-
4.4.1 Enabling REST Access for a Database Object
You can enable REST access for a table, view, materialized view, function, procedure or package.
To REST enable a schema object:
4.4.2 Disabling REST Access for a Database Object
This section describes how to disable REST access for a database object.
- In the SQL page, in the Navigator tab, right-click the database object that is REST enabled and select Disable.
- You see a prompt to confirm. Click OK.
4.4.3 Generating cURL Requests for a REST-Enabled Database Object
For a REST-enabled database object, you can generate sample cURL calls for GET, POST, PUT and DELETE requests for the selected object. Use the Copy to Clipboard icon to copy the cURL code.
To view the cURL call for a specific method for the selected object: