Typeclass used during RestMetadata materialization to determine whether a real method is a valid HTTP
method. Usually this means that the result must be a type wrapped into something that captures asynchronous
computation, e.g. Future. Because REST framework core tries to be agnostic about this
asynchronous wrapper (not everyone likes Futures), there are no default implicits provided for HttpResponseType.
They must be provided externally.
For example, FutureRestImplicits introduces an instance of HttpResponseType for Future[T],
for arbitrary type T. For RestMetadata materialization this means that every method which returns a
Future is considered a valid HTTP method. FutureRestImplicits is injected into materialization of
RestMetadata through one of the base companion classes, e.g. DefaultRestApiCompanion.
See MacroInstances for more information on injection of implicits.
Typeclass used during RestMetadata materialization to determine whether a real method is a valid HTTP method. Usually this means that the result must be a type wrapped into something that captures asynchronous computation, e.g.
Future
. Because REST framework core tries to be agnostic about this asynchronous wrapper (not everyone likesFuture
s), there are no default implicits provided for HttpResponseType. They must be provided externally.For example, FutureRestImplicits introduces an instance of HttpResponseType for
Future[T]
, for arbitrary typeT
. For RestMetadata materialization this means that every method which returns aFuture
is considered a valid HTTP method. FutureRestImplicits is injected into materialization of RestMetadata through one of the base companion classes, e.g. DefaultRestApiCompanion. SeeMacroInstances
for more information on injection of implicits.