Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/kd_clients/core/GraphQlClient.ts>GraphQlClient

Various HTTP clients for miscellaneous use.
Latest
class GraphQlClient
Abstract
import { GraphQlClient } from "https://deno.land/x/kd_clients@v1.0.0-preview.13/core/GraphQlClient.ts";

Provides a base class for HTTP clients.

Constructors

new
GraphQlClient(
ownerName: string,
repoName: string,
token: string,
)

Initializes a new instance of the GraphQlClient class.

Properties

private
_ownerName: string
private
_repoName: string
private
baseUrl: string
protected
readonly
headers: Headers
ownerName: string

Gets the name of the owner of the repository.

repoName: string

Gets the name of the repository.

Methods

protected
containsToken(): boolean

Returns a value indicating whether or not a token was provided.

protected
executeQuery(query: string): Promise<GraphQlRequestResponseModel>

Fetch a resource from the network. It returns a Promise that resolves to the Response to that request, whether it is successful or not.

Gets the response data from a request.