Search code examples
oracle-databaseweb-servicesapioracle-apexapi-key

How to hide web service API key?


I'm using oracle apex 4.2.6. I have a web service that I want to use. ( Web service is not mine ) I need to hide the API key when calling it. I want to know how.

Can I create my own web service that will call this one and then send my API key with the call? If yes , how?


Solution

  • You have 2 ways to consume web services on the back-end (and hiding your api key).

    1) Under Shared Components --> Web server reference --> Create You can consume REST / Based on WSDL and Custom. Then you can reference the Web service in your APEX application and the back-end does the call.

    2) Create a custom PL/SQL function/procedure that uses UTL_TCP or UTL_DBWS (or UTL_HTTP if it's a simple REST service) to call the web-service and crunch the response.

    http://www.oraclecafe.com/2014/08/calling-wsdl-webservice-from-plsql/

    If the web service is simple then going with option 1) would be the quickest way.

    Creating and Using a Manual SOAP Web Service in Your Application