AbsintheAuth v0.2.1 AbsintheAuth

Macros to add policies to your Absinthe GraphQL schema. See documentation for more details.

Link to this section Summary

Functions

Add a policy to the current field. Only works inside the block with a call to field. Assumes that Absinthe.Schema or Absinthe.Schema.Notation has been imported to the module

Link to this section Functions

Link to this macro policy(module, func, opts \\ []) (macro)

Add a policy to the current field. Only works inside the block with a call to field. Assumes that Absinthe.Schema or Absinthe.Schema.Notation has been imported to the module.

field :name, :string do
  policy Admin, :allow
end