I have a URL I need to call.

(cn=kxxxxx) 

"cn" is the logon of the user, and it returns user details.

However I need to formulate this type of URL:

(cn=kxxxxx)&appid=GPVC 

i.e. to send in the app_id.

I may also want to specify which fields I want to return:

(cn=kxxxxx)&appid=GPVC&attrs=sn,displayName 

i.e. return only the surname and display name in the response

declare l_clob clob; l_buffer varchar2(32767); l_amount number; l_offset number; begin l_clob := apex_web_service.make_rest_request( p_url => '(cn=kxxxxx)', p_http_method => 'GET', p_parm_name => apex_util.string_to_table('appid'), p_parm_value => apex_util.string_to_table('GPVC') ); DBMS_OUTPUT.put_line(l_clob); end; 

But the response I get is:

{ "error": { "message": "Consumer application identification is now enforced - please go to and contact us to obtain an appid for your requests." } } 

So I am hitting the web service, just probably not creating a URL in the right format.

If I add the &appid=GPVC to the URL in the PLSQL, I get a pop up box asking me to pass in the bind parameter at run time.....

l_clob := apex_web_service.make_rest_request( p_url => '(cn=kxxxxx)&appid=GPVC', p_http_method => 'GET' ); 

"set define off" (as people are suggesting) to ignore the ampersand doesn't work. I would really like to know why make_rest_request isnt working with the parameters. "set define off" just generates this error:

*Cause: The stored procedure 'raise_application_error' was called which causes this error to be generated. *Action: Correct the problem as described in the error message or contact the application administrator or DBA for more information. 

The url is good....works fine in the browser and gives me a response

6

Related questions 9 Extra Query parameters in the REST API Url 0 java restful web service, can't figure how to execute a specific Query 0 How to use the method APEX_WEB_SERVICE.make_rest_request? Related questions 9 Extra Query parameters in the REST API Url 0 java restful web service, can't figure how to execute a specific Query 0 How to use the method APEX_WEB_SERVICE.make_rest_request? 0 Adding parameters to Rest calls 2 call restful API through oracle query 0 How do I pass a list in url for a REST api? 1 How to invoke a REST web service, with POST method sending the parameters as json in a query string in plsql? 2 How to get data from REST API to Oracle DB 0 REST service works via Postman, not using PL/SQL 0 How can I pass REST query parameters as optional in Oracle Application Express Listener? Load 7 more related questions Show fewer related questions

Reset to default

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

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