Twirp v0.4.1 Twirp.Error View Source

This module defines the different error codes as specified in https://twitchtv.github.io/twirp/docs/spec_v5.html#error-codes.

We provide a function for each error code to that its easy for users to return errors in their handlers.

Link to this section Summary

Link to this section Types

Specs

t() :: %Twirp.Error{
  code: atom(),
  meta: %{required(atom()) => binary()},
  msg: binary()
}

Link to this section Functions

Link to this function

aborted(msg, meta \\ [])

View Source
Link to this function

already_exists(msg, meta \\ [])

View Source
Link to this function

bad_route(msg, meta \\ [])

View Source
Link to this function

canceled(msg, meta \\ [])

View Source
Link to this function

data_loss(msg, meta \\ [])

View Source
Link to this function

deadline_exceeded(msg, meta \\ [])

View Source
Link to this function

failed_precondition(msg, meta \\ [])

View Source
Link to this function

internal(msg, meta \\ [])

View Source
Link to this function

invalid_argument(msg, meta \\ [])

View Source
Link to this function

new(code, msg, meta \\ [])

View Source
Link to this function

not_found(msg, meta \\ [])

View Source
Link to this function

out_of_range(msg, meta \\ [])

View Source
Link to this function

permission_denied(msg, meta \\ [])

View Source
Link to this function

resource_exhausted(msg, meta \\ [])

View Source
Link to this function

unauthenticated(msg, meta \\ [])

View Source
Link to this function

unavailable(msg, meta \\ [])

View Source
Link to this function

unimplemented(msg, meta \\ [])

View Source
Link to this function

unknown(msg, meta \\ [])

View Source