Skip to content

Customer_Attributes

mauryaratan edited this page Mar 27, 2023 · 1 revision

Customer.Attributes

An object representing the resources data.

public struct Attributes: Codable 

Inheritance

Codable

Properties

storeId

The ID of the store this order belongs to.

public let storeId: Int

name

The full name of the customer.

public let name: String

email

The email address of the customer.

public let email: String

status

The email marketing status of the customer. One of:​

public let status: String
  • subscribed - This customer is subscribed to marketing emails.

  • unsubscribed - This customer has unsubscribed from marketing emails.

  • archived - This customer has been archived and will no longer recieve marketing emails.

  • requires_verification - The customers email address need to be verified (happens automatically).

  • invalid_email - The customers email address has failed validation.

  • bounced - The customers email has hard bounced.

city

The city of the customer.

public let city: String?

region

The region of the customer.

public let region: String?

country

The country of the customer.

public let country: String?

totalRevenueCurrency

A positive integer in cents representing the total revenue from the customer (USD).

public let totalRevenueCurrency: Int

mrr

A positive integer in cents representing the monthly recurring revenue from the customer (USD).

public let mrr: Int

statusFormatted

The formatted status of the customer.

public let statusFormatted: String

countryFormatted

The formatted country of the customer.

public let countryFormatted: String?

totalRevenueCurrencyFormatted

A human-readable string representing the total revenue from the customer (e.g. $9.99).

public let totalRevenueCurrencyFormatted: String

mrrFormatted

A human-readable string representing the monthly recurring revenue from the customer (e.g. $9.99).

public let mrrFormatted: String

createdAt

An ISO-8601 formatted date-time string indicating when the object was created.

public let createdAt: String

updatedAt

An ISO-8601 formatted date-time string indicating when the object was last updated.

public let updatedAt: String

testMode

A boolean indicating if the returned subscription object was created within test mode.

public let testMode: Bool
Types
Global Functions
Clone this wiki locally