API Reference TypedGql v#0.13.0

Copy Markdown View Source

Modules

Compile-time GraphQL client for Elixir.

Returned — never raised — when a 2xx GraphQL response carries data the generated result schema cannot load: an unknown union __typename, an enum value outside the schema, or a scalar of the wrong type.

Base module for generated GraphQL embedded schemas.

Represents a GraphQL error from the response.

Formatter plugin for the ~GQL sigil.

Read-only context passed to TypedGql.Generation.Plugin callbacks.

A single generated schema field, before lowering to EctoTypedSchema AST.

Behaviour for hooking into the response-type generation pipeline.

Built-in generation plugin for the @include and @skip directives.

A node in the generated-schema tree, built by the resolve step before lowering to EctoTypedSchema AST.

Generates Ecto embedded schema modules for GraphQL input types.

Behaviour for JSON encoding/decoding.

The abstract syntax tree of a parsed GraphQL document.

A single argument supplied to a field or a directive.

A true or false literal.

A directive applied to a node, written @name(...).

A directive @name on ... definition: where a custom directive may be applied and whether it may repeat.

A parsed GraphQL document: the root of the tree, holding every operation, fragment and type definition the source declared.

An enum definition: the set of named values the type admits.

An unquoted enum member literal, such as ACTIVE.

A single member declared by an enum type definition.

A field selection: a name, optional alias, arguments, directives and sub-selections.

A field declared on an object or interface type, with the arguments it accepts and the type it returns.

A float literal.

A named fragment definition: a type condition and the selections it contributes wherever it is spread.

A spread of a named fragment into a selection set, written ...Name.

An inline fragment: an optional type condition and the selections it guards.

An input definition: an object type usable only as an argument or variable value.

An input position — an argument or an input object field — with the type it accepts and the default it falls back to.

An integer literal.

An interface definition: the fields every implementing type must provide.

A list type, written [Type].

A list literal, written [...].

A type referred to by name, such as User.

A non-null type, written Type!.

The null literal.

A single name/value pair inside an input object literal.

A type definition: a concrete object type, the interfaces it implements and the fields it exposes.

An input object literal, written {...}.

A query, mutation or subscription operation, whether written with the operation keyword or in the shorthand selection-set form.

A scalar definition, introducing a leaf type whose representation the service decides.

A schema { ... } block declaring which types serve as the query, mutation and subscription roots.

A braced block of selections requested from one type.

The raw GraphQL text a document was parsed from, and the label used for it when reporting errors.

A string literal, from either the quoted or the block-string form.

An extend definition, adding members to a type declared elsewhere.

A union definition: the set of object types a value of this type may be.

A use of an operation variable, written $name.

A variable declared in an operation's signature, with the type it must satisfy and the default it falls back to.

The macros a client module gets from use TypedGql.

Tags outgoing requests with their originating defgql operation so that multiple requests can be told apart — most usefully inside Req.Test stubs.

Represents a compiled GraphQL operation ready for execution.

Decodes GraphQL JSON response data into typed embedded schema structs.

Represents a GraphQL response.

A GraphQL schema loaded from an introspection result.

A directive a loaded schema declares, along with the locations it may be applied to.

One member of an enum type in a loaded schema.

A field an object or interface type exposes in a loaded schema.

An input position in a loaded schema: a field argument, a directive argument or an input object field.

A named type in a loaded schema: object, interface, union, enum, scalar or input object, with whichever shape its kind gives it.

A reference to a type in a loaded schema, wrapping a named type in the list and non-null modifiers that apply to it.

Generates EctoTypedSchema embedded schema modules from GraphQL query AST.

Maps GraphQL type references to Ecto schema types.

Ecto Type for GraphQL DateTime custom scalar.

Parameterized Ecto Type for GraphQL enum types.

Ecto Type for GraphQL error path segments.

Parameterized Ecto Type for GraphQL __typename fields.

Dynamic parameterized Ecto Type for GraphQL union/interface types.

Dumps a variables struct to wire JSON, keeping only the keys the caller actually provided.

A TypedStructor plugin that implements the Access behaviour for structs.

Mix Tasks

Downloads a GraphQL schema via introspection and saves it as JSON.