Endpoints
Interpreter for algebra.Endpoints that produces an endpoints4s.openapi.model.OpenApi instance for endpoints, and uses algebra.BuiltInErrors to model client and server errors.
Type members
Inherited classlikes
- Value parameters:
- entity
Contents of the callback message
- method
HTTP method used for the callback
- response
Expected response
- Inherited from:
- EndpointsWithCustomErrors
- Inherited from:
- EndpointsWithCustomErrors
- Value parameters:
- name
Name of the parameter
- required
Whether this parameter is required or not (MUST be true for path parameters)
- Inherited from:
- Urls
A query string parameter documentation description for type A
A query string parameter documentation description for type A
- Value parameters:
- encoder
JSON encoder for query string parameter value, primarily used for encoding of the parameter's default value. Result of the encoding is optional since the empty value of optional query string parameter should result in the empty encoded value.
- isRequired
Whether the query string parameter is required
- schema
Schema that corresponds to type
A
- Inherited from:
- Urls
- Inherited from:
- Requests
- Value parameters:
- content
Map that associates each possible content-type (e.g. “text/html”) with a
MediaType
description- documentation
Human readable documentation. Not optional because its required by openapi
- headers
Response headers documentation
- status
Response status code (e.g. OK or NotFound)
- Inherited from:
- Responses
- Value parameters:
- path
List of path segments. Left is a static segment, right is a path parameter
- queryParameters
Query string parameters
- Inherited from:
- Urls
- Value parameters:
- callbacks
Callbacks indexed by event name
- deprecated
Indicates whether this endpoint is deprecated or not
- description
Detailed description
- operationId
A unique identifier which identifies this operation
- summary
Short description
- tags
OpenAPI tags
- Inherited from:
- EndpointsWithCustomErrors
Extension methods for Endpoint.
Extension methods for Endpoint.
- Inherited from:
- EndpointsWithCustomErrors
Extension methods for values of type F[A]
for which there is an implicit
InvariantFunctor[F]
instance.
Extension methods for values of type F[A]
for which there is an implicit
InvariantFunctor[F]
instance.
- Inherited from:
- InvariantFunctorSyntax
- Inherited from:
- PartialInvariantFunctorSyntax
Inherited types
Callbacks indexed by URL pattern
Callbacks indexed by URL pattern
- See also:
Swagger Documentation at https://swagger.io/docs/specification/callbacks/
- Inherited from:
- EndpointsWithCustomErrors
Value members
Inherited methods
Bad Request (400) response, with an entity of type ClientErrors
.
Bad Request (400) response, with an entity of type ClientErrors
.
- See also:
- Inherited from:
- Responses
- Inherited from:
- Urls
Helper method to perform DELETE request
Helper method to perform DELETE request
- Type parameters:
- HeadersP
Payload carried by headers
- UrlP
Payload carried by url
- Inherited from:
- Requests
Helper method to perform GET request
Helper method to perform GET request
- Type parameters:
- HeadersP
Payload carried by headers
- UrlP
Payload carried by url
- Inherited from:
- Requests
Internal Server Error (500) response, with an entity of type ServerError
.
Internal Server Error (500) response, with an entity of type ServerError
.
- See also:
- Inherited from:
- Responses
- Definition Classes
- Inherited from:
- EndpointsWithCustomErrors
- Definition Classes
- Inherited from:
- EndpointsWithCustomErrors
- Definition Classes
- Inherited from:
- EndpointsWithCustomErrors
OK (200) Response with the given entity
OK (200) Response with the given entity
- Inherited from:
- Responses
- Value parameters:
- endpoints
The endpoints to generate the documentation for
- info
General information about the documentation to generate
- Returns:
An
OpenApi
instance for the given endpoint descriptions- Inherited from:
- EndpointsWithCustomErrors
Helper method to perform PATCH request
Helper method to perform POST request
- Inherited from:
- Urls
- Inherited from:
- Requests
- Inherited from:
- Responses
- Inherited from:
- Urls
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).
- Inherited from:
- Responses
Inherited fields
Response used by endpoints4s when decoding a request fails.
Response used by endpoints4s when decoding a request fails.
The provided implementation forwards to badRequest
.
- Inherited from:
- Errors
An empty path.
An empty path.
Useful to begin a path definition:
path / "foo" / segment[Int] /? qs[String]("bar")
- Inherited from:
- Urls
Response used by endpoints4s when the business logic of an endpoint fails.
Response used by endpoints4s when the business logic of an endpoint fails.
The provided implementation forwards to internalServerError
- Inherited from:
- Errors
Implicits
Inherited implicits
Extension methods for Endpoint.
Extension methods for Endpoint.
- Inherited from:
- EndpointsWithCustomErrors
Extension methods for values of type F[A]
for which there is an implicit
InvariantFunctor[F]
instance.
Extension methods for values of type F[A]
for which there is an implicit
InvariantFunctor[F]
instance.
- Inherited from:
- InvariantFunctorSyntax
- Inherited from:
- PartialInvariantFunctorSyntax
- Inherited from:
- SemigroupalSyntax
- Inherited from:
- Urls
- Inherited from:
- Urls
- Inherited from:
- Urls