# README
go-graphql-client
Preface: This is a fork of https://github.com/hasura/go-graphql-client
reworked to work easily with Dgraph's GraphQL implementation and is a WIP.
References
- https://github.com/shurcooL/graphql
- https://github.com/hasura/go-graphql-client
- https://github.com/apollographql/subscriptions-transport-ws/blob/master/PROTOCOL.md
- https://github.com/nhooyr/websocket
License
# Functions
No description provided by the author
No description provided by the author
NewClient creates a GraphQL client targeting the specified GraphQL server URL.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Constants
Server sends this message to indicate that a GraphQL operation is done, and no more data will arrive for the specific operation.
The server may responses with this message to the GQL_CONNECTION_INIT from client, indicates the server accepted the connection.
The server may responses with this message to the GQL_CONNECTION_INIT from client, indicates the server rejected the connection.
Client sends this message after plain websocket connection to start the communication with the server.
Server message that should be sent right after each GQL_CONNECTION_ACK processed and then periodically to keep the client connection alive.
Client sends this message to terminate the connection.
The server sends this message to transfter the GraphQL execution result from the server to the client, this message is a response for GQL_START message.
Server sends this message upon a failing operation, before the GraphQL execution, usually due to GraphQL validation errors (resolver errors are part of GQL_DATA message, and will be added as errors array).
Internal status, for logging only.
Client sends this message to execute GraphQL operation.
Client sends this message in order to stop a running GraphQL operation execution (for example: unsubscribe).
Unknown operation type, for logging only.
# Structs
Client is a GraphQL client.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
SubscriptionClient is a GraphQL subscription client.
# Interfaces
WebsocketHandler abstracts WebSocket connecton functions ReadJSON and WriteJSON data of a frame from the WebSocket connection.
# Type aliases
OperationMessageType.