graphql

package
v0.7.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 23, 2024 License: MPL-2.0 Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func New

func New(ktx kit.Kontext, dependency kit.ComponentDep) *Client

func (*Client) Mutate

func (c *Client) Mutate(m interface{}, variables map[string]interface{}, options ...graphql.Option) error

Mutate executes a single GraphQL mutation request, with a mutation derived from m, populating the response into it. m should be a pointer to struct that corresponds to the GraphQL schema.

func (*Client) MutateCtx

func (c *Client) MutateCtx(ctx context.Context, m interface{}, variables map[string]interface{}, options ...graphql.Option) error

See Mutate for details.

func (*Client) MutateRaw

func (c *Client) MutateRaw(m interface{}, variables map[string]interface{}, options ...graphql.Option) ([]byte, error)

MutateRaw executes a single GraphQL mutation request, with a mutation derived from m, populating the response into it. m should be a pointer to struct that corresponds to the GraphQL schema. return raw bytes message.

func (*Client) MutateRawCtx

func (c *Client) MutateRawCtx(ctx context.Context, m interface{}, variables map[string]interface{}, options ...graphql.Option) ([]byte, error)

See MutateRaw for details.

func (*Client) Query

func (c *Client) Query(q interface{}, variables map[string]interface{}, options ...graphql.Option) error

Query executes a single GraphQL query request, with a query derived from q, populating the response into it. q should be a pointer to struct that corresponds to the GraphQL schema.

func (*Client) QueryCtx

func (c *Client) QueryCtx(ctx context.Context, q interface{}, variables map[string]interface{}, options ...graphql.Option) error

See Query for details.

func (*Client) QueryRaw

func (c *Client) QueryRaw(q interface{}, variables map[string]interface{}, options ...graphql.Option) ([]byte, error)

Query executes a single GraphQL query request, with a query derived from q, populating the response into it. q should be a pointer to struct that corresponds to the GraphQL schema. return raw bytes message.

func (*Client) QueryRawCtx

func (c *Client) QueryRawCtx(ctx context.Context, q interface{}, variables map[string]interface{}, options ...graphql.Option) ([]byte, error)

See QueryRaw for details.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL