View Source GraphqlMarkdown.OperationDetailsHelpers (Graphql Markdown v0.5.0)

A set of helpers to generate query and mutation details.

Summary

Functions

Creates a map with the details of a query or mutation. The details created include the operation type, operation name, arguments, and return type.

Types

@type argument() :: %{name: String.t(), type: String.t(), required: boolean()}
@type field() :: %{name: String.t(), type: String.t()}
Link to this type

graphql_operation_details()

View Source
@type graphql_operation_details() :: %{
  operation_type: String.t(),
  operation_name: String.t(),
  arguments: [argument()],
  return_type: return_type()
}
@type return_type() :: %{
  name: String.t(),
  kind: String.t(),
  fields: [field()],
  possible_types: [field()]
}

Functions

Link to this function

generate_operation_details(type, field, schema_details)

View Source
@spec generate_operation_details(String.t(), map(), GraphqlMarkdown.Schema.t()) ::
  graphql_operation_details()

Creates a map with the details of a query or mutation. The details created include the operation type, operation name, arguments, and return type.