Skip to content

Instantly share code, notes, and snippets.

View flyinmryan's full-sized avatar

Mike Ryan flyinmryan

View GitHub Profile
@drovani
drovani / shopify-multipass-demo.cs
Last active February 18, 2022 10:19
Sample C# Code to Generate Shopify Multipass Url
string secret = "[shopify-multipass-secret]";
string store = "[shopify-store]";
var json = System.Text.Json.JsonSerializer.Serialize(new {
email = "[customer-email]",
created_at = DateTime.Now.ToString("O"),
identifier = "[customer-uid]",
//remote_ip = ""
});
var hash = System.Security.Cryptography.SHA256.Create().ComputeHash(Encoding.UTF8.GetBytes(secret));