The path of the asset
An HTTP request to retrieve an asset
An HTTP response containing an asset
HTTP method used for the callback
Contents of the callback message
Expected response
Callbacks indexed by URL pattern
Callbacks indexed by URL pattern
Documentation" https://swagger.io/docs/specification/callbacks/
Errors in a request built by a client
Errors in a request built by a client
Information carried by an HTTP endpoint
Information carried by an HTTP endpoint
Short description
Detailed description
OpenAPI tags
Callbacks indexed by event name
Indicates whether this endpoint is deprecated or not
HTTP Method
HTTP Method
An URL path carrying an A
information
An URL path carrying an A
information
Convenient methods for Paths.
A query string carrying an A
information
A single query string parameter carrying an A
information.
A single query string parameter carrying an A
information.
Extension methods on QueryString.
Extension methods on QueryString.
Information carried by a whole request (headers and entity)
Information carried by a whole request (headers and entity)
Information carried by request entity
Information carried by request entity
Information carried by requests’ headers
Information carried by requests’ headers
An HTTP response (status, headers, and entity) carrying an information of type A
An HTTP response (status, headers, and entity) carrying an information of type A
An HTTP response entity carrying an information of type A
An HTTP response entity carrying an information of type A
Extension methods for Response.
An URL path segment carrying an A
information.
An URL path segment carrying an A
information.
Error raised by the business logic of a server
Error raised by the business logic of a server
HTTP Status Code
HTTP Status Code
An URL carrying an A
information
An URL carrying an A
information
You should use the badRequest
constructor provided by the Responses
trait to ensure that errors produced by endponits are consistently
handled by interpreters.
You should use the internalServerError
constructor provided by the
Responses trait to ensure that errors produced by endpoints
are consistently handled by interpreters.
A Path that extracts an AssetPath from all the path segments.
URL description
description of a response when asset is found. Required by openapi
description of a not found asset response. Required by openapi
An HTTP endpoint serving assets
Chains the two paths
Chains the two paths
Alternative between two possible choices of responses.
Alternative between two possible choices of responses.
Server interpreters construct either one or the other response. Client interpreters accept either one or the other response. Documentation interpreters list all the possible responses.
Format of the response entity carrying the client errors.
Format of the response entity carrying the client errors.
Concatenates two QueryString
s
Concatenates two QueryString
s
The digests of the assets
No particular information.
No particular information. Does not mean that the headers *have to* be empty. Just that, from a server point of view no information will be extracted from them, and from a client point of view no particular headers will be built in the request.
Use description
of endpoints.algebra.Endpoints#endpoint to document empty headers.
Empty request -- request without a body.
Empty request -- request without a body.
Use description
of endpoints.algebra.Endpoints#endpoint to document an empty body.
Empty response entity
Empty response entity
HTTP endpoint.
HTTP endpoint.
Request
Response
Documentation (used by documentation interpreters)
Make a query string parameter optional:
Make a query string parameter optional:
path / "articles" /? qs[Option[Int]]("page")
Client interpreters must omit optional query string parameters that are empty. Server interpreters must accept incoming requests whose optional query string parameters are missing. Server interpreters must report a failure for incoming requests whose optional query string parameters are present, but malformed.
Builds a QueryString
with one parameter.
Builds a QueryString
with one parameter.
Examples:
qs[Int]("page") // mandatory `page` parameter qs[Option[String]]("lang") // optional `lang` parameter qs[List[Long]]("id") // repeated `id` parameter
Type of the value carried by the parameter
Parameter’s name
The remaining segments of the path.
The remaining segments of the path. The String
value carried by this Path
is still URL-encoded.
Support query string parameters with multiple values:
Support query string parameters with multiple values:
path / "articles" /? qs[List[Long]]("id")
Server interpreters must accept incoming requests where such parameters are missing (in such a case, its value is an empty collection), and report a failure if at least one value is malformed.
Request for given parameters
Request for given parameters
Payload carried by url
Payload carried by body
Payload carried by headers
Payloads of Url and Body tupled together by Tupler
Request method
Request URL
Request entity
Request documentation
Request headers
Response status code
Response entity
Response documentation Server interpreters construct a response with the given status and entity. Client interpreters accept a response only if it has a corresponding status code.
A path segment carrying an A
information
A path segment carrying an A
information
Format of the response entity carrying the server error.
Format of the response entity carrying the server error.
A path segment whose value is the given segment
A path segment whose value is the given segment
Ability to define String
query string parameters
Ability to define String
query string parameters
Ability to define String
path segments
Servers should return an URL-decoded string value,
and clients should take an URL-decoded string value.
Ability to define String
path segments
Servers should return an URL-decoded string value,
and clients should take an URL-decoded string value.
Request with a String
body.
Request with a String
body.
Text response entity
Text response entity
Builds an URL from the given path and query string
Builds an URL from the given path and query string
Bad Request (400) response, with an entity of type ClientErrors
.
Bad Request (400) response, with an entity of type ClientErrors
.
endpoints.algebra.Errors and endpoints.algebra.BuiltInErrors
Query string parameter containing a Boolean
value
Query string parameter containing a Boolean
value
Response used by the endpoints library when decoding a request fails.
Response used by the endpoints library when decoding a request fails.
The provided implementation forwards to badRequest
.
Helper method to perform DELETE request
Helper method to perform DELETE request
Payload carried by url
Payload carried by headers
Implicit conversion to get rid of intellij errors when defining paths.
Implicit conversion to get rid of intellij errors when defining paths. Effectively should not be called.
Helper method to perform GET request
Helper method to perform GET request
Payload carried by url
Payload carried by headers
Ability to define Int
query string parameters
Ability to define Int
query string parameters
Ability to define Int
path segments
Ability to define Int
path segments
Internal Server Error (500) response, with an entity of type ServerError
.
Internal Server Error (500) response, with an entity of type ServerError
.
endpoints.algebra.Errors and endpoints.algebra.BuiltInErrors
Query string parameter containing a Long
value
Query string parameter containing a Long
value
Segment containing a Long
value
Segment containing a Long
value
OK (200) Response with the given entity
OK (200) Response with the given entity
An empty path.
An empty path.
Useful to begin a path definition:
path / "foo" / segment[Int] /? qs[String]("bar")
Helper method to perform POST request
Helper method to perform PUT request
Response used by the endpoints library when the business logic of an endpoint fails.
Response used by the endpoints library when the business logic of an endpoint fails.
The provided implementation forwards to internalServerError
Ability to define UUID
query string parameters
Ability to define UUID
query string parameters
Ability to define UUID
path segments
Ability to define UUID
path segments
Turns a Response[A]
into a Response[Option[A]]
.
Turns a Response[A]
into a Response[Option[A]]
.
Interpreters represent None
with
an empty HTTP response whose status code is 404 (Not Found).
Describes endpoints related to static assets (e.g. medias, scripts, stylesheets, etc.)