Tesla.Middleware.BearerAuth (tesla v1.15.3)
View SourceBearer authentication middleware.
Adds a {"authorization", "Bearer <token>"} header.
Examples
defmodule MyClient do
def new(token) do
Tesla.client([
{Tesla.Middleware.BearerAuth, token: token}
])
end
endOptions
:token- token (defaults to"")