Skip to content

Commit

Permalink
[ts] Add email_marketing_consent to I{,Order}Customer (#646)
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickyau-visualsquares committed Feb 8, 2024
1 parent 6be11b2 commit 66e2a83
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions types/index.d.ts
Expand Up @@ -1387,8 +1387,15 @@ declare namespace Shopify {

type CustomerState = 'declined' | 'disabled' | 'enabled' | 'invited';

interface IEmailMarketingConsent {
state: string;
opt_in_level: string | null;
consent_updated_at: string;
}

interface ICustomer {
accepts_marketing: boolean;
accepts_marketing?: boolean;
email_marketing_consent?: IEmailMarketingConsent,
addresses?: ICustomerAddress[];
created_at: string;
currency: string;
Expand Down Expand Up @@ -2186,7 +2193,8 @@ declare namespace Shopify {
}

interface IOrderCustomer {
accepts_marketing: boolean;
accepts_marketing?: boolean;
email_marketing_consent?: IEmailMarketingConsent,
created_at: string;
default_address: ICustomerAddress;
email: string;
Expand Down

0 comments on commit 66e2a83

Please sign in to comment.