github softwaremill/tapir v0.19.0-M14

latest releases: v1.10.6, v1.10.5, v1.10.4...
2 years ago

Breaking changes

This release brings some security improvements, most notably extending Endpoint with an additional type parameter A for security inputs.

More information on the change:

Migrating from previous versions:

  • replace any occurrence of the Endpoint type with PublicEndpoint
  • replace ServerEndpoint[I, E, O, R, F] with ServerEndpoint[R, F] (e.g. ServerEndpointp[Any, Future]), or with ServerEndpoint.Full[Unit, Unit, I, E, O, R, F] if you need to preserve the types of inputs/outputs
  • replace any calls to server interpreter which provided the endpoint and server logic separately, with a call to one of the .serverLogic variants. For example, AkkaHttpServerInterpreter().toRoute(helloWorld)(name => Future.successful(Right(s"Hello, $name!"))) should be replaced with AkkaHttpServerInterpreter().toRoute(helloWorld.serverLogicSuccess(name => Future.successful(s"Hello, $name!"))).

This should make the code compile using the new version. The next step would be to move security-related inputs from .in to .securityIn when defining the endpoint, and taking advantage of the security improvements (e.g. separate security and server logic).

What’s Changed

Dependency updates

Don't miss a new tapir release

NewReleases is sending notifications on new releases.