spring-boot/spring-boot-project/spring-boot-actuator-autoco.../src/main/asciidoc/endpoints/env.adoc

56 lines
1.4 KiB
Plaintext

[[env]]
= Environment (`env`)
The `env` endpoint provides information about the application's `Environment`.
[[env-entire]]
== Retrieving the Entire Environment
To retrieve the entire environment, make a `GET` request to `/application/env`, as shown in
the following curl-based example:
include::{snippets}env/all/curl-request.adoc[]
The resulting response is similar to the following:
include::{snippets}env/all/http-response.adoc[]
[[env-entire-response-structure]]
=== Response Structure
The response contains details of the application's `Environment`. The following table
describes the structure of the response:
[cols="3,1,3"]
include::{snippets}env/all/response-fields.adoc[]
[[env-single-property]]
== Retrieving a Single Property
To retrieve a single property, make a `GET` request to `/application/env/{property.name}`,
as shown in the following curl-based example:
include::{snippets}env/single/curl-request.adoc[]
The preceding example retrieves information about the property named
`com.example.cache.max-size`. The resulting response is similar to the following:
include::{snippets}env/single/http-response.adoc[]
[[env-single-response-structure]]
=== Response Structure
The response contains details of the requested property. The following table describes the
structure of the response:
[cols="3,1,3"]
include::{snippets}env/single/response-fields.adoc[]