I am consuming a test api and would like to change the base url to a production url when deploying.
Is there a way to set the host name of a rest api base url to a site property? (eg. https://{hostName}/) This would also be useful when accessing subdomain apis based on username. (eg. https://{username}.contoso.com/)
I've checked outsystems' forums and training and haven't found references to this.
The following informational page only directs using {var} for changing the method url path. (eg. /customer/{customerId})
https://success.outsystems.com/Documentation/10/Extensibility_and_Integration/REST/Expose_REST_APIs/Customize_REST_URLs
The instructions on the following url are deprecated and I'm not finding an OnBeforeRequest property for changing the url of this api call.
https://www.outsystems.com/help/servicestudio/9.0/default.htm#Integrating_with_other_systems/Web_Services/Advanced_Customizations.htm
Any recommendations?
If you are consuming the service, you have the option to set it on Service Center:
- Go to eSpace properties on Service Center
- Click on Integrations Tab
- Select the Consumed API
- Set the Effective URL and username/password (if applicable)
Cheers!
Edit: adding to this, I've written an article in the past that shows how this is done (https://itnext.io/credit-or-debit-or-the-story-of-accepting-payments-in-the-outsystems-platform-b1b4bf15f736)
Armando Gomes wrote:
Right