Метод | Описание | |
---|---|---|
Authorize ( string code, string myShopifyUrl, string shopifyApiKey, string shopifySecretKey ) : Task |
Authorizes an application installation, generating an access token for the given shop.
|
|
BuildAuthorizationUrl ( IEnumerable |
Builds an authorization URL for Shopify OAuth integration.
|
|
BuildAuthorizationUrl ( IEnumerable |
Builds an authorization URL for Shopify OAuth integration.
|
|
IsAuthenticProxyRequest ( |
Determines if an incoming proxy page request is authentic. Conceptually similar to IsAuthenticRequest(NameValueCollection, string), except that proxy requests use HMACSHA256 rather than MD5.
|
|
IsAuthenticRequest ( |
Determines if an incoming request is authentic.
|
|
IsAuthenticWebhook ( |
Determines if an incoming webhook request is authentic.
|
|
IsAuthenticWebhook ( |
Determines if an incoming webhook request is authentic.
|
|
IsValidMyShopifyUrl ( string url ) : Task |
A convenience function that tries to ensure that a given URL is a valid Shopify store by checking the response headers for X-ShopId.
|
public static Authorize ( string code, string myShopifyUrl, string shopifyApiKey, string shopifySecretKey ) : Task |
||
code | string | The authorization code generated by Shopify, which should be a parameter named 'code' on the request querystring. |
myShopifyUrl | string | The store's *.myshopify.com URL, which should be a paramter named 'shop' on the request querystring. |
shopifyApiKey | string | Your app's public API key. |
shopifySecretKey | string | Your app's secret key. |
Результат | Task |
public static BuildAuthorizationUrl ( IEnumerable |
||
scopes | IEnumerable |
An array of |
myShopifyUrl | string | The shop's *.myshopify.com URL. |
shopifyApiKey | string | Your app's public API key. |
redirectUrl | string | An optional URL to redirect the user to after integration. Overrides the Shopify app's default redirect URL. |
state | string | An optional, random string value provided by your application which is unique for each authorization request. During the OAuth callback phase, your application should check that this value matches the one you provided to this method. |
grants | IEnumerable |
Requested grant types, which will change the type of access token granted upon OAuth completion. Only known grant type is "per-user", which will give an access token restricted to the permissions of the user accepting OAuth integration and will expire when that user logs out. Leave the grants array empty or null to receive a full access token that doesn't expire. |
Результат |
public static BuildAuthorizationUrl ( IEnumerable |
||
scopes | IEnumerable |
An array of Shopify permission strings, e.g. 'read_orders' or 'write_script_tags'. These are the permissions that your app needs to run. |
myShopifyUrl | string | The shop's *.myshopify.com URL. |
shopifyApiKey | string | Your app's public API key. |
redirectUrl | string | An optional URL to redirect the user to after integration. Overrides the Shopify app's default redirect URL. |
state | string | An optional, random string value provided by your application which is unique for each authorization request. During the OAuth callback phase, your application should check that this value matches the one you provided to this method. |
grants | IEnumerable |
Requested grant types, which will change the type of access token granted upon OAuth completion. Only known grant type is "per-user", which will give an access token restricted to the permissions of the user accepting OAuth integration and will expire when that user logs out. Leave the grants array empty or null to receive a full access token that doesn't expire. |
Результат |
public static IsAuthenticProxyRequest ( |
||
querystring | The collection of querystring parameters from the request. Hint: use Request.QueryString if you're calling this from an ASP.NET MVC controller. | |
shopifySecretKey | string | Your app's secret key. |
Результат | bool |
public static IsAuthenticRequest ( |
||
querystring | The collection of querystring parameters from the request. Hint: use Request.QueryString if you're calling this from an ASP.NET MVC controller. | |
shopifySecretKey | string | Your app's secret key. |
Результат | bool |
public static IsAuthenticWebhook ( |
||
requestHeaders | The request's headers. Hint: use Request.Headers if you're calling this from an ASP.NET MVC controller. | |
inputStream | Stream | The request's input stream. This method does NOT dispose the stream. /// Hint: use Request.InputStream if you're calling this from an ASP.NET MVC controller. |
shopifySecretKey | string | Your app's secret key. |
Результат | Task |
public static IsAuthenticWebhook ( |
||
requestHeaders | The request's headers. Hint: use Request.Headers if you're calling this from an ASP.NET MVC controller. | |
requestBody | string | The body of the request. |
shopifySecretKey | string | Your app's secret key. |
Результат | bool |
public static IsValidMyShopifyUrl ( string url ) : Task |
||
url | string | The URL of the shop to check. |
Результат | Task |