Skip to content

Instantly share code, notes, and snippets.

@adamw
Created February 18, 2019 12:47
Show Gist options
  • Save adamw/2be0c88ecbc7d4172da7063cf7e5e921 to your computer and use it in GitHub Desktop.
Save adamw/2be0c88ecbc7d4172da7063cf7e5e921 to your computer and use it in GitHub Desktop.
import tapir._
val addBook: Endpoint[(Book, String), Unit, Boolean, Nothing] =
endpoint
.in(jsonBody[Book])
.in(header[String]("X-Auth-Token"))
.out(plainBody[Boolean])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment