Skip to Main Content

ORDS, SODA & JSON in the Database

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

How to Resolve Custom API Conflict with Auto-Enabled API in ORDS

Hargun SuriOct 25 2024

Hello Team,

I've enabled the diary table for auto REST, which has created multiple ORDS CRUD APIs, like one of them being GET <host:port>/ords/super/diary for listing entries. I now need to add a custom API while keeping the base URI the same, "/ords/super/diary".

To do this, I've created a service, module, and template that returns a custom response based on a specific query. This generates a URL, "<host:port>/ords/super/diary/choicesOnly", but when I try accessing it, I receive a 400 BAD Request error with the message: "Invalid value provided for parameter DIARY_UID. The detailed error message: Character c is neither a decimal digit number, decimal point, nor "e" notation exponential mark.".

It seems the custom API is conflicting with the auto-enabled API. How can I achieve this without causing conflicts and keeping the URI “/ords/super/diary” same?

Any guidance would be greatly appreciated!

Comments
Post Details
Added on Oct 25 2024
6 comments
203 views