Skip to main content

base_url

Function base_url 

Source
pub fn base_url(service: &str) -> &'static str
Expand description

Returns the base URL for calling service, without a trailing slash (so paths can be appended directly, e.g. {base}/users/42).

§Panics

Panics if the runtime has no base URL configured for service — either because no service with that name exists or because the process was started without Encore service discovery (such as a plain cargo test).