Updated December 7, 2020
Oracle Autonomous Database is a Platform as a Service (PaaS) offering on the Oracle Cloud (OCI). It’s managed, meaning you don’t have to worry about updates, patches, or much in way of configuration.
One of the core features is the ability to publish and consume REST APIs for the data in your Autonomous Database – whether that be on the Dedicated, Serverless, or Always Free service offerings.
I wanted to answer a few frequently asked questions and share a couple of useful resources for you in this post.
How are my endpoints addressed?
Not all HTTP is REST, but all REST APIs use HTTP for communication. And a HTTP call generally has two main components, an address and a verb.
Well, if you publish a REST API in Autonomous, what the heck is my URL? We show you this critical information in your Service Console.
From there, you want to go look in the ‘Development’ page.
So what comes after the /ords/ ?
Your REST APIs will look like this –
The schema is the REST Enabled schema name, or it’s schema alias, which we refer to as the url_mapping_pattern.
What else do I need to know about ORDS in Autonomous?
OS Authentication is available if you want it. But note that means consumers of your API will be logging in as actual Oracle Database users, and you’ll be using BASIC Auth, which is generally frowned upon, even when HTTPS is in play.
We recommend you use an ORDS provided OAUTH2 client. Hot Tip #1 – use Todd’s awesome blog post to see how to do this.
Speaking of database users – for Autonomous your default administrator account is called ‘admin,’ and it’s REST Enabled by default. That means the admin user can login to SQL Developer Web AND publish REST APIs in its schema.
WE DO NOT RECOMMEND YOU USE ADMIN FOR PUBLISHING REST APIs.
Building Services – with what tools?
You can use anything that can connect to your database and exercise the ORDS PL/SQL APIs. We recommend you either use SQL Developer on your desktop or stay in your browser and simply use Oracle SQL Developer Web..
As of November 2020, you can now do all of your REST development in SQL Developer Web –
Just give me a movie to watch, TL;DR
I have a 12 minute video demonstration showing a REST service in Autonmous that you can watch here.