Closed brylie closed 6 years ago
My opinion is that this would be closely related to api-umbrella wrapper code, related to Umbrella Admin API v1 what path Admin API lives. So I would handle that path inside wrapper so that our code would not need to know what path Admin API lives.
So we would pass only "host" for ApiUmbrellaWeb https://github.com/apinf/meteor-api-umbrella/blob/master/server/apiUmbrellaWeb.js#L22 instead of baseUrl that could be constructed by concatenating /api-umbrella/ after that. If that is v1 related under v1 (self.adminApi.v1.baseUrl) or just as one private member of ApiUmbrellaWeb class (self.baseUrl = self.host + /api-umbrella/
I was thinking of a regex for the url this morning. In effect, we want the URL to
As an aside, I would like to introduce a regex library that would allow us to define our regular expressions in a similar manner to the above list. One option would be the regularity library.
The Proxies collection schema contains a sub object for apiUmbrella settings. The
apiUmbrella
object contains a host field that is used in two ways in our code:In both cases, the URL takes slightly different structure:
http://base.url/api-umbrella/
http://base.url/<proxy_base_path>
Determine what input to take in the Proxy Settings form, and how to construct the URLs in both of the above scenarios.