Oracle REST Data Services (ORDS) started as web listener for the database. It’s job was to accept requests and deliver data from the database – be that HTML, XML, JSON, or files.

But a few years ago ORDS received a game-changing update – SQL Developer Web.

Instead of needing SQL Developer (on your desktop), APEX, or making yourself learn and use the PL/SQL APIs to define a RESTful Web Service, you can now easily build these directly in your browser.

Disclaimers:

  1. There is nothing wrong with SQL Developer desktop’s REST interface – but it requires you have it installed
  2. There is nothing wrong with APEX’s REST Workshop – it just requires that you already have APEX going
  3. There is nothing wrong with our PL/SQL APIs – in fact, they should be used when you want to automate deployments and source control/backup your REST definitions

But…being able to do an install, rest enable a schema, and immediately login to a rich interface for managing your database AND your RESTful Web Services is the best thing to happen to ORDS in a very long time.

A Quick Tour

New kid, meet the old kid.

Getting Started

You need to have ORDS installed and SQL Developer Web enabled. You need a REST Enabled schema.

Then you can login and start building stuff.

If you need help with this part, watch the movie!

Get going with REST and SQL Developer Web with ORDS version 20.3

The REST Dashboard

You can open the REST dashboard via the Hamburger button, upper left hand corner, or click the REST card on the SQL Developer Web home page.

I’m logged in as HR, and HR is REST Enabled.
The REST home screen is pretty self-explanatory.

If you need help, take the tour – click the binoculars button up top in the right hand corner.

Objects – an overview of what REST bits are defined in my schema. Does not currently include REST Enabled schema objects like tables, views, & PL/SQL – coming in version 20.4

Security – Is my schema catalog protected? Do I have modules defined but not published? Of those published modules, how many aren’t protected by name or pattern by a privilege?

Recent Objects – Not just a report of recent activity, I can also use this to quickly tweak an object definition without having to navigate using the cards or menus.

Let’s Build Something

I’m not going to show you everything, all at once – there’s just too much for a single blog post. But let’s quickly build a working REST endpoint (GET).

This quick screengrab shows –

  1. defining a module
  2. building a template
  3. coding a handler (code insight, sql execution with binds!)
  4. testing the call
  5. exporting the PL/SQL API definition
animated gif building a restful web service for oracle using ords and sql developer web
Where RESTful Services come from…

More to come!

We’ll talk in more detail on building Web Services, but also SECURING them, specifically with the new OAuth2 client interface.

Author

I'm a Distinguished Product Manager at Oracle. My mission is to help you and your company be more efficient with our database tools.

5 Comments

  1. I have already worked with that. But I can’t separate Oracle Rest data service configuration between ords and different server.
    Please help me . How can I do that ?

    Thanks

    • I can’t enable rest service on remote database schema. It gets no data found error and ORA-06512 ORDS_METADATA no data found error ..
      Is there any solution ? or how I enable this schema ? If you have any documentation or tutorial ,
      please on the comment below.please

      Thanks for reply

    • Please run
      Java -jar ords.war validate

      That will make sure your database has ords_metadata objects as expected.

Write A Comment