Shopify SDK for Unity
Public Member Functions | List of all members
Shopify.Unity.SDK.UnityLoader Class Reference

Performs network communication to send GraphQL queries between Unity and a Shopify GraphQL endpoint. More...

Inheritance diagram for Shopify.Unity.SDK.UnityLoader:
Shopify.Unity.SDK.BaseLoader

Public Member Functions

 UnityLoader (string domain, string accessToken, string locale=null)
 
override void Load (string query, LoaderResponseHandler callback)
 Send a query to the Storefront API. More...
 
override void SetHeader (string key, string value)
 Assigns a custom header field to the loader. More...
 
override string SDKVariantName ()
 Returns the loader's X-SDK-Variant header value. Required by a BaseLoader implementation to let the server know who is sending the request. More...
 
- Public Member Functions inherited from Shopify.Unity.SDK.BaseLoader
 BaseLoader (string domain, string accessToken, string locale=null)
 

Additional Inherited Members

- Properties inherited from Shopify.Unity.SDK.BaseLoader
string Domain [get]
 Domain of a Shopify store. More...
 
string AccessToken [get]
 Access token used to communicate with a Shopify store. More...
 
string Locale [get]
 Locale for translated content of supported types and fields. More...
 

Detailed Description

Performs network communication to send GraphQL queries between Unity and a Shopify GraphQL endpoint.

Constructor & Destructor Documentation

◆ UnityLoader()

Shopify.Unity.SDK.UnityLoader.UnityLoader ( string  domain,
string  accessToken,
string  locale = null 
)
inline
Parameters
domainShopify store domain that you'd like to query on
accessTokenaccess token used to communicate with the Shopify Store

Member Function Documentation

◆ Load()

override void Shopify.Unity.SDK.UnityLoader.Load ( string  query,
LoaderResponseHandler  callback 
)
inlinevirtual

Send a query to the Storefront API.

Parameters
queryQuery that will be sent to the Storefront API
callbackcallback that receives a response

Implements Shopify.Unity.SDK.BaseLoader.

◆ SDKVariantName()

override string Shopify.Unity.SDK.UnityLoader.SDKVariantName ( )
inlinevirtual

Returns the loader's X-SDK-Variant header value. Required by a BaseLoader implementation to let the server know who is sending the request.

Returns
Identifying name of the loader to be sent to the server using the X-SDK-Variant header.

Implements Shopify.Unity.SDK.BaseLoader.

◆ SetHeader()

override void Shopify.Unity.SDK.UnityLoader.SetHeader ( string  key,
string  value 
)
inlinevirtual

Assigns a custom header field to the loader.

Parameters
keyHeader field name
valueHeader field value

Implements Shopify.Unity.SDK.BaseLoader.


The documentation for this class was generated from the following file: