1

To create a handler, it seems that I would need to create a template with a URI template to create bindings.

However, the bindings seem to me only possible as a path structure (e.g. /:id/:records/:department) instead of being searchParams (?id=1&department=IT)

How could I allow optional parameters in the URL for handlers?

3

1 Answer 1

2

You can access search params variables just as you would access it in the URL template. There's no need to strictly define all possible input parameters in the URL template.

You can use binds or parameters, or even a mix.

I have full code examples here.

Run the sql's...

enter image description here

Confirm your APIs have been created, and call the API...

In this case a

GET http://localhost:8080/ords/hr/parameters/headers-classic?id=4

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.