{"components":{"schemas":{"PeriodUnit":{"enum":["year","month","week","day"],"type":"string"},"PaginationResult":{"type":"object","properties":{"totalCount":{"type":"number"},"totalPages":{"type":"number"},"pageSize":{"type":"number"},"pageNumber":{"type":"number"}},"required":["totalCount","totalPages","pageSize","pageNumber"]},"SmartrrSortType":{"type":"string","enum":["ASC","DESC"]},"ProductVariantInventoryPolicy":{"description":"The inventory policy for a product variant controls whether customers can continue to buy the variant when it is out of stock. When the value is <code>continue</code>, customers are able to buy the variant when it's out of stock. When the value is <code>deny</code>, customers can't buy the variant when it's out of stock.\n* DENY: Stop selling a product variant when it is out of stock.\n* CONTINUE: Continue selling a product variant when it is out of stock.","type":"string","enum":["DENY","CONTINUE"],"nullable":true},"CurrencyCode":{"type":"string","enum":["STN","VED","USD","USDC","EUR","GBP","CAD","AFN","ALL","DZD","AOA","ARS","AMD","AWG","AUD","BBD","AZN","BDT","BSD","BHD","BIF","BZD","BMD","BTN","BAM","BRL","BOB","BWP","BND","BGN","MMK","KHR","CVE","KYD","XAF","CLP","CNY","COP","KMF","CDF","CRC","HRK","CZK","DKK","DOP","XCD","EGP","ETB","XPF","FJD","GMD","GHS","GTQ","GYD","GEL","HTG","HNL","HKD","HUF","ISK","INR","IDR","ILS","IQD","JMD","JPY","JEP","JOD","KZT","KES","KWD","KGS","LAK","LVL","LBP","LSL","LRD","LTL","MGA","MKD","MOP","MWK","MVR","MXN","MYR","MUR","MDL","MAD","MNT","MZN","NAD","NPR","ANG","NZD","NIO","NGN","NOK","OMR","PAB","PKR","PGK","PYG","PEN","PHP","PLN","QAR","RON","RUB","RWF","WST","SAR","STD","RSD","SCR","SGD","SDG","SYP","ZAR","KRW","SSP","SBD","LKR","SRD","SZL","SEK","CHF","TWD","THB","TZS","TTD","TND","TRY","TMT","UGX","UAH","AED","UYU","UZS","VUV","VND","XOF","YER","ZMW","BYN","BYR","DJF","ERN","FKP","GIP","GNF","IRR","KID","LYD","MRU","SLL","SHP","SOS","TJS","TOP","VEF","VES","XXX"]},"SubscriptionContractSubscriptionStatus":{"type":"string","enum":["ACTIVE","PAUSED","CANCELLED","EXPIRED","FAILED"]},"CountryCode":{"description":"ISO 3166-1 alpha-2 country codes with some differences","type":"string","enum":["AF","AX","AL","DZ","AD","AO","AI","AG","AR","AM","AW","AC","AU","AT","AZ","BS","BH","BD","BB","BY","BE","BZ","BJ","BM","BT","BO","BA","BW","BV","BR","IO","BN","BG","BF","BI","KH","CA","CV","BQ","KY","CF","TD","CL","CN","CX","CC","CO","KM","CG","CD","CK","CR","HR","CU","CW","CY","CZ","CI","DK","DJ","DM","DO","EC","EG","SV","GQ","ER","EE","SZ","ET","FK","FO","FJ","FI","FR","GF","PF","TF","GA","GM","GE","DE","GH","GI","GR","GL","GD","GP","GT","GG","GN","GW","GY","HT","HM","VA","HN","HK","HU","IS","IN","ID","IR","IQ","IE","IM","IL","IT","JM","JP","JE","JO","KZ","KE","KI","KP","XK","KW","KG","LA","LV","LB","LS","LR","LY","LI","LT","LU","MO","MG","MW","MY","MV","ML","MT","MQ","MR","MU","YT","MX","MD","MC","MN","ME","MS","MA","MZ","MM","NA","NR","NP","NL","AN","NC","NZ","NI","NE","NG","NU","NF","MK","NO","OM","PK","PS","PA","PG","PY","PE","PH","PN","PL","PT","QA","CM","RE","RO","RU","RW","BL","SH","KN","LC","MF","PM","WS","SM","ST","SA","SN","RS","SC","SL","SG","SX","SK","SI","SB","SO","ZA","GS","KR","SS","ES","LK","VC","SD","SR","SJ","SE","CH","SY","TW","TJ","TZ","TH","TL","TG","TK","TO","TT","TA","TN","TR","TM","TC","TV","UG","UA","AE","GB","US","UM","UY","UZ","VU","VE","VN","VG","WF","EH","YE","ZM","ZW","ZZ"]},"MailingAddressInput":{"properties":{"address1":{"type":"string","title":"The first line of the address. Typically the street address or PO Box number."},"address2":{"type":"string","title":"The second line of the address. Typically the number of the apartment, suite, or unit."},"city":{"type":"string","title":"The name of the city, district, village, or town."},"company":{"type":"string","title":"The name of the customer's company or organization."},"country":{"type":"string","title":"The name of the country. This argument is deprecated: Use `countryCode` instead."},"countryCode":{"type":"string","title":"The two-letter code for the country of the address."},"firstName":{"type":"string","title":"The first name of the customer."},"lastName":{"type":"string","title":"The last name of the customer."},"phone":{"type":"string","title":"A unique phone number for the customer.","description":"Formatted using E.164 standard. For example, _+16135551111_."},"province":{"type":"string","title":"The region of the address, such as the province, state, or district. This argument is deprecated: Use `provinceCode` instead."},"provinceCode":{"type":"string","description":"The code for the region of the address, such as the province, state, or district.\nFor example QC for Quebec, Canada."},"zip":{"type":"string","title":"The zip or postal code of the address."}},"additionalProperties":false,"title":"The fields used to create or update a mailing address.","type":"object"},"SellingPlanInterval":{"type":"string","enum":["DAY","WEEK","MONTH","YEAR"]},"SubscriptionBillingPolicyInput":{"properties":{"interval":{"$ref":"#/components/schemas/SellingPlanInterval"},"intervalCount":{"title":"The number of billing intervals between invoices.","type":"number"},"minCycles":{"title":"Minimum amount of cycles required in the subscription.","type":"number","nullable":true},"maxCycles":{"title":"Maximum amount of cycles required in the subscription.","type":"number","nullable":true},"anchors":{"title":"Specific anchor dates upon which the billing interval calculations should be made.","nullable":true}},"required":["interval","intervalCount"],"additionalProperties":false,"title":"Specifies the input fields for a Subscription Billing Policy.","type":"object"},"Decimal":{"type":"string","description":"string formatted like \"10.00\""},"IReChargeLineItem":{"properties":{"grams":{"type":"number"},"images":{"properties":{"large":{"type":"string"},"medium":{"type":"string"},"original":{"type":"string"},"small":{"type":"string"}},"required":["large","medium","original","small"],"additionalProperties":false,"type":"object"},"price":{"$ref":"#/components/schemas/Decimal"},"properties":{"items":{"properties":{"name":{"type":"string"},"value":{}},"required":["name","value"],"additionalProperties":false,"type":"object"},"type":"array"},"quantity":{"type":"number"},"shopify_product_id":{"anyOf":[{"type":"string"},{"type":"number"}]},"shopify_variant_id":{"anyOf":[{"type":"string"},{"type":"number"}]},"sku":{"type":"string"},"subscription_id":{"type":"number"},"tax_lines":{"items":{},"type":"array"},"title":{"type":"string"},"variant_title":{"type":"string"},"vendor":{"nullable":true,"type":"string"}},"required":["grams","images","price","properties","quantity","shopify_product_id","shopify_variant_id","sku","subscription_id","tax_lines","title","variant_title","vendor"],"additionalProperties":false,"type":"object"},"IReChargeAddress":{"properties":{"id":{"type":"number"},"cart_note":{"nullable":true,"type":"string"},"created_at":{"type":"string"},"customer_id":{"type":"number"},"discount_id":{"nullable":true,"type":"number"},"note_attributes":{"items":{"properties":{"name":{"type":"string"},"value":{"type":"string"}},"required":["name","value"],"additionalProperties":false,"type":"object"},"type":"array"},"original_shipping_lines":{"anyOf":[{"nullable":true},{"items":{"properties":{"code":{"type":"string"},"price":{"$ref":"#/components/schemas/Decimal"},"tax_lines":{"items":{},"type":"array"},"title":{"type":"string"}},"required":["code","price","tax_lines","title"],"additionalProperties":false,"type":"object"},"type":"array"}]},"shipping_lines_override":{"anyOf":[{"nullable":true},{"items":{"properties":{"code":{"type":"string"},"price":{"$ref":"#/components/schemas/Decimal"},"title":{"type":"string"}},"required":["code","price","title"],"additionalProperties":false,"type":"object"},"type":"array"}]},"updated_at":{"type":"string"}},"required":["id","cart_note","created_at","customer_id","discount_id","note_attributes","original_shipping_lines","shipping_lines_override","updated_at"],"additionalProperties":false,"type":"object"},"IReChargeCharge":{"properties":{"id":{"type":"number"},"address_id":{"type":"number"},"analytics_data":{"$ref":"#/components/schemas/IReChargeAnalyticsData"},"billing_address":{"$ref":"#/components/schemas/IReChargeBaseAddress"},"client_details":{"properties":{"browser_ip":{"nullable":true,"type":"string"},"user_agent":{"nullable":true,"type":"string"}},"required":["browser_ip","user_agent"],"additionalProperties":false,"type":"object"},"created_at":{"type":"string"},"customer_hash":{"type":"string"},"customer_id":{"type":"number"},"discount_codes":{"items":{"$ref":"#/components/schemas/IReChargeDiscountCode"},"type":"array"},"email":{"type":"string"},"first_name":{"type":"string"},"has_uncommited_changes":{"type":"boolean"},"last_name":{"type":"string"},"line_items":{"items":{"$ref":"#/components/schemas/IReChargeLineItem"},"type":"array"},"note":{"type":"string"},"note_attributes":{"items":{"properties":{"name":{"type":"string"},"value":{"type":"string"}},"required":["name","value"],"additionalProperties":false,"type":"object"},"type":"array"},"processor_name":{"type":"string"},"processed_at":{"type":"string"},"scheduled_at":{"type":"string"},"shipments_count":{"nullable":true,"type":"number"},"shipping_address":{"$ref":"#/components/schemas/IReChargeBaseAddress"},"shipping_lines":{"items":{"$ref":"#/components/schemas/IReChargeShippingLine"},"type":"array"},"shopify_order_id":{"type":"string"},"sub_total":{"nullable":true},"subtotal_price":{"$ref":"#/components/schemas/Decimal"},"tags":{"type":"string"},"tax_lines":{"$ref":"#/components/schemas/Decimal"},"total_discounts":{"$ref":"#/components/schemas/Decimal"},"total_line_items_price":{"nullable":true,"type":"string"},"total_price":{"$ref":"#/components/schemas/Decimal"},"total_refunds":{"nullable":true,"type":"string"},"total_tax":{"$ref":"#/components/schemas/Decimal"},"total_weight":{"type":"number"},"transaction_id":{"type":"string"},"type":{"type":"string","enum":["CHECKOUT","RECURRING"]},"updated_at":{"type":"string"}},"required":["id","address_id","analytics_data","billing_address","client_details","created_at","customer_hash","customer_id","discount_codes","email","first_name","has_uncommited_changes","last_name","line_items","note","note_attributes","processor_name","processed_at","scheduled_at","shipments_count","shipping_address","shipping_lines","shopify_order_id","sub_total","subtotal_price","tags","tax_lines","total_discounts","total_line_items_price","total_price","total_refunds","total_tax","total_weight","transaction_id","type","updated_at"],"additionalProperties":false,"type":"object"},"IReChargeDiscount":{"properties":{"id":{"type":"number"},"applies_to":{"type":"string","enum":["shopify_collection_id","shopify_product"]},"applies_to_id":{"nullable":true,"type":"number"},"applies_to_product_type":{"type":"string","enum":["ALL","ONE TIME","SUBSCRIPTION"]},"applies_to_resource":{"nullable":true,"type":"string","enum":["shopify_product","shopify_collection_id"]},"channel_settings":{"properties":{"api":{"properties":{"can_apply":{"type":"boolean"}},"required":["can_apply"],"additionalProperties":false,"type":"object"},"checkout_page":{"properties":{"can_apply":{"type":"boolean"}},"required":["can_apply"],"additionalProperties":false,"type":"object"},"customer_portal":{"properties":{"can_apply":{"type":"boolean"}},"required":["can_apply"],"additionalProperties":false,"type":"object"},"merchant_portal":{"properties":{"can_apply":{"type":"boolean"}},"required":["can_apply"],"additionalProperties":false,"type":"object"}},"required":["api","checkout_page","customer_portal","merchant_portal"],"additionalProperties":false,"type":"object"},"code":{"type":"string"},"created_at":{"type":"string"},"discount_type":{"type":"string","enum":["percentage","fixed_amount"]},"duration":{"type":"string","enum":["forever","usage_limit","single_use"]},"duration_usage_limit":{"nullable":true,"type":"number"},"ends_at":{"nullable":true,"type":"string"},"external_discount_id":{"nullable":true,"type":"string"},"external_discount_source":{"nullable":true,"type":"string"},"first_time_customer_restriction":{"nullable":true,"type":"string"},"once_per_customer":{"type":"boolean"},"prerequisite_subtotal_min":{"nullable":true,"type":"number"},"starts_at":{"type":"string"},"status":{"type":"string","enum":["enabled","disabled","fully_disabled"]},"times_used":{"type":"number"},"updated_at":{"type":"string"},"usage_limit":{"nullable":true,"type":"number"},"value":{"type":"number"}},"required":["id","applies_to","applies_to_id","applies_to_product_type","applies_to_resource","channel_settings","code","created_at","discount_type","duration","duration_usage_limit","ends_at","external_discount_id","external_discount_source","first_time_customer_restriction","once_per_customer","prerequisite_subtotal_min","starts_at","status","times_used","updated_at","usage_limit","value"],"additionalProperties":false,"type":"object"},"IReChargeCustomer":{"properties":{"id":{"type":"number"},"analytics_data":{"$ref":"#/components/schemas/IReChargeAnalyticsData"},"billing_address1":{"type":"string"},"billing_address2":{"nullable":true,"type":"string"},"billing_city":{"type":"string"},"billing_company":{"nullable":true,"type":"string"},"billing_country":{"type":"string"},"billing_phone":{"type":"string"},"billing_province":{"type":"string"},"billing_zip":{"type":"string"},"created_at":{"type":"string"},"email":{"type":"string"},"first_charge_processed_at":{"nullable":true,"type":"string"},"first_name":{"type":"string"},"hash":{"type":"string"},"has_card_error_in_dunning":{"type":"boolean"},"has_valid_payment_method":{"type":"boolean"},"last_name":{"type":"string"},"number_active_subscriptions":{"type":"number"},"number_subscriptions":{"type":"number"},"reason_payment_method_not_valid":{"nullable":true,"type":"string"},"processor_type":{"nullable":true,"type":"string"},"shopify_customer_id":{"nullable":true,"type":"string"},"status":{"type":"string","enum":["ACTIVE","INACTIVE"]},"stripe_customer_token":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","analytics_data","billing_address1","billing_address2","billing_city","billing_company","billing_country","billing_phone","billing_province","billing_zip","created_at","email","first_charge_processed_at","first_name","hash","has_card_error_in_dunning","has_valid_payment_method","last_name","number_active_subscriptions","number_subscriptions","reason_payment_method_not_valid","processor_type","shopify_customer_id","status","stripe_customer_token","updated_at"],"additionalProperties":false,"type":"object"},"IReChargeSubscription":{"properties":{"id":{"type":"number"},"address_id":{"type":"number"},"analytics_data":{"$ref":"#/components/schemas/IReChargeAnalyticsData"},"cancellation_reason":{"nullable":true,"type":"string"},"cancellation_reason_comments":{"nullable":true,"type":"string"},"cancelled_at":{"nullable":true,"type":"string"},"charge_interval_frequency":{"type":"string"},"created_at":{"type":"string"},"customer_id":{"type":"number"},"email":{"type":"string"},"expire_after_specific_number_of_charges":{"nullable":true,"type":"number"},"has_queued_charges":{"type":"number"},"is_prepaid":{"type":"boolean"},"is_skippable":{"type":"boolean"},"is_swappable":{"type":"boolean"},"max_retries_reached":{"type":"number"},"next_charge_scheduled_at":{"nullable":true,"type":"string"},"order_day_of_month":{"nullable":true,"type":"number"},"order_day_of_week":{"nullable":true,"type":"number"},"order_interval_frequency":{"type":"string"},"order_interval_unit":{"type":"string"},"price":{"type":"number"},"product_title":{"type":"string"},"properties":{"items":{"properties":{"name":{"type":"string"},"value":{}},"required":["name","value"],"additionalProperties":false,"type":"object"},"type":"array"},"quantity":{"type":"number"},"recharge_product_id":{"type":"number"},"shopify_product_id":{"type":"number"},"shopify_variant_id":{"type":"number"},"sku":{"nullable":true,"type":"string"},"sku_override":{"type":"boolean"},"status":{"type":"string","enum":["ACTIVE","CANCELLED","EXPIRED"]},"updated_at":{"type":"string"},"variant_title":{"type":"string"}},"required":["id","address_id","analytics_data","cancellation_reason","cancellation_reason_comments","cancelled_at","charge_interval_frequency","created_at","customer_id","email","expire_after_specific_number_of_charges","has_queued_charges","is_prepaid","is_skippable","is_swappable","max_retries_reached","next_charge_scheduled_at","order_day_of_month","order_day_of_week","order_interval_frequency","order_interval_unit","price","product_title","properties","quantity","recharge_product_id","shopify_product_id","shopify_variant_id","sku","sku_override","status","updated_at","variant_title"],"additionalProperties":false,"type":"object"},"IReChargePaymentSource":{"properties":{"billing_address":{"$ref":"#/components/schemas/IReChargeBaseAddress"},"cardholder_name":{"nullable":true,"type":"string"},"card_brand":{"nullable":true,"type":"string"},"card_exp_month":{"nullable":true,"type":"number"},"card_exp_year":{"nullable":true,"type":"number"},"card_last4":{"nullable":true,"type":"number"},"customer_id":{"type":"number"},"has_card_error_in_dunning":{"type":"boolean"},"payment_token":{"type":"string"},"payment_type":{"type":"string"},"processor_name":{"type":"string"},"status":{"type":"string"},"status_reason":{"nullable":true,"type":"string"}},"required":["billing_address","cardholder_name","card_brand","card_exp_month","card_exp_year","card_last4","customer_id","has_card_error_in_dunning","payment_token","payment_type","processor_name","status","status_reason"],"additionalProperties":false,"type":"object"},"IReChargeShop":{"properties":{"shop":{"properties":{"checkout_logo_url":{"type":"string"}},"required":["checkout_logo_url"],"additionalProperties":false,"type":"object"},"store":{"properties":{"id":{"type":"number"},"created_at":{"type":"string"},"currency":{"type":"string"},"domain":{"type":"string"},"iana_timezone":{"type":"string"},"my_shopify_domain":{"type":"string"},"name":{"type":"string"},"shop_email":{"type":"string"},"shop_phone":{"type":"string"},"timezone":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","created_at","currency","domain","iana_timezone","my_shopify_domain","name","shop_email","shop_phone","timezone","updated_at"],"additionalProperties":false,"type":"object"}},"required":["shop","store"],"additionalProperties":false,"type":"object"},"IReChargeOrder":{"properties":{"id":{"type":"number"},"address_id":{"type":"number"},"billing_address":{"$ref":"#/components/schemas/IReChargeBaseAddress"},"charge_id":{"type":"number"},"charge_status":{"type":"string","enum":["SUCCESS","REFUNDED"]},"created_at":{"type":"string"},"currency":{"type":"string"},"customer":{"properties":{"accepts_marketing":{"type":"boolean"},"email":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"phone":{"nullable":true,"type":"string"},"send_email_welcome":{"type":"boolean"},"verified_email":{"type":"boolean"}},"required":["accepts_marketing","email","first_name","last_name","phone","send_email_welcome","verified_email"],"additionalProperties":false,"type":"object"},"customer_id":{"type":"number"},"discount_codes":{"items":{"$ref":"#/components/schemas/IReChargeDiscountCode"},"type":"array"},"email":{"type":"string"},"first_name":{"type":"string"},"hash":{"type":"string"},"is_prepaid":{"type":"number"},"last_name":{"type":"string"},"line_items":{"items":{"$ref":"#/components/schemas/IReChargeLineItem"},"type":"array"},"note":{"nullable":true,"type":"string"},"note_attributes":{"anyOf":[{"nullable":true},{"items":{"properties":{"name":{"type":"string"},"value":{"type":"string"}},"required":["name","value"],"additionalProperties":false,"type":"object"},"type":"array"}]},"payment_processor":{"type":"string"},"processed_at":{"nullable":true,"type":"string"},"scheduled_at":{"type":"string"},"shipped_date":{"nullable":true,"type":"string"},"shipping_address":{"$ref":"#/components/schemas/IReChargeBaseAddress"},"shipping_lines":{"items":{"$ref":"#/components/schemas/IReChargeShippingLine"},"type":"array"},"shopify_cart_token":{"type":"string"},"shopify_customer_id":{"type":"string"},"shopify_order_id":{"nullable":true,"type":"string"},"shopify_order_number":{"nullable":true,"type":"number"},"status":{"type":"string","enum":["SUCCESS","QUEUED","SKIPPED","REFUNDED","PARTIALLY_REFUNDED"]},"subtotal_price":{"anyOf":[{"$ref":"#/components/schemas/Decimal"},{"type":"number"}]},"tags":{"type":"string"},"tax_lines":{"items":{},"type":"array"},"total_discounts":{"anyOf":[{"$ref":"#/components/schemas/Decimal"},{"type":"number"}]},"total_line_items_price":{"anyOf":[{"$ref":"#/components/schemas/Decimal"},{"nullable":true},{"type":"number"}]},"total_price":{"anyOf":[{"$ref":"#/components/schemas/Decimal"},{"type":"number"}]},"total_refunds":{"anyOf":[{"$ref":"#/components/schemas/Decimal"},{"nullable":true}]},"total_tax":{"anyOf":[{"$ref":"#/components/schemas/Decimal"},{"type":"number"}]},"total_weight":{"type":"number"},"transaction_id":{"type":"string"},"type":{"type":"string","enum":["CHECKOUT","RECURRING"]},"updated_at":{"type":"string"}},"required":["id","address_id","billing_address","charge_id","charge_status","created_at","currency","customer","customer_id","discount_codes","email","first_name","hash","is_prepaid","last_name","line_items","note","note_attributes","payment_processor","processed_at","scheduled_at","shipped_date","shipping_address","shipping_lines","shopify_cart_token","shopify_customer_id","shopify_order_id","shopify_order_number","status","subtotal_price","tags","tax_lines","total_discounts","total_line_items_price","total_price","total_refunds","total_tax","total_weight","transaction_id","type","updated_at"],"additionalProperties":false,"type":"object"},"IReChargeProduct":{"properties":{"id":{"type":"number"},"collection_id":{"nullable":true,"type":"number"},"created_at":{"type":"string"},"discount_amount":{"nullable":true,"type":"number"},"discount_type":{"type":"string","nullable":true,"enum":["percentage","fixed"]},"handle":{"nullable":true,"type":"string"},"images":{"properties":{"large":{"type":"string"},"medium":{"type":"string"},"original":{"type":"string"},"small":{"type":"string"}},"required":["large","medium","original","small"],"additionalProperties":false,"type":"object"},"product_id":{"type":"number"},"shopify_product_id":{"type":"number"},"subscription_defaults":{"properties":{"charge_interval_frequency":{"type":"number"},"cutoff_day_of_month":{"nullable":true,"type":"number"},"cutoff_day_of_week":{"nullable":true,"type":"number"},"expire_after_specific_number_of_charges":{"nullable":true,"type":"number"},"modifiable_properties":{"items":{"type":"string"},"type":"array"},"number_charges_until_expiration":{"nullable":true,"type":"number"},"order_day_of_month":{"nullable":true,"type":"number"},"order_day_of_week":{"nullable":true,"type":"number"},"order_interval_frequency_options":{"items":{"type":"string"},"type":"array"},"order_interval_unit":{"type":"string"},"storefront_purchase_options":{"type":"string"}},"required":["charge_interval_frequency","cutoff_day_of_month","cutoff_day_of_week","expire_after_specific_number_of_charges","modifiable_properties","number_charges_until_expiration","order_day_of_month","order_day_of_week","order_interval_frequency_options","order_interval_unit","storefront_purchase_options"],"additionalProperties":false,"type":"object"},"title":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","collection_id","created_at","discount_amount","discount_type","handle","images","product_id","shopify_product_id","subscription_defaults","title","updated_at"],"additionalProperties":false,"type":"object"},"ReChargeBaseListQuery":{"properties":{"limit":{"type":"number"},"page":{"type":"number"},"sort_by":{"type":"string"}},"additionalProperties":false,"title":"Supported sort_by values","description":"Addresses\nGET /addresses\tDefault: id-desc\nid-asc,id-desc,updated_at-asc,updated_at-desc\n\nAsync Batches\nGET /async_batches\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc\n\nCharges\nGET /charges\tDefault: id-asc\nid-asc,id-desc,created_at-asc,created_at-desc, updated_at-asc, updated_at-desc, charge_date-asc, charge-date-desc\n\nCustomers\nGET /customers\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc, updated_at-asc, updated_at-desc\n\nDiscounts\nGET /discounts\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc, updated_at-asc, updated_at-desc\n\nMetafields\nGET /metafields\tDefault: id-desc\nid-asc,id-desc,updated_at-asc,updated_at-desc\n\nOne Time Products\nGET /onetimes\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc,updated_at-asc, updated_at-desc\n\nOrders\nGET /orders\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc, shipped_date-asc, shipped_date-desc, shipping_date-asc, shipping_date-desc, updated_at-asc, updated_at-desc\n\nProducts\nGET /products\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc, updated_at-asc,updated_at-desc, title-asc, title-desc\n\nSubscriptions\nGET /subscriptions\tDefault: id-desc\nid-asc,id-desc,created_at-asc,created_at-desc, updated_at-asc, updated_at-desc\n\nWebhooks\nGET /webhooks\tDefault: id-desc\nid-asc,id-desc","type":"object"},"ReChargeCountSubscriptionsQuery":{"properties":{"address_id":{"type":"number"},"created_at_max":{"type":"string"},"created_at_min":{"type":"string"},"customer_id":{"type":"number"},"shopify_customer_id":{"type":"number"},"status":{"type":"string","enum":["ACTIVE","CANCELLED","EXPIRED"]},"updated_at_max":{"type":"string"},"updated_at_min":{"type":"string"}},"additionalProperties":false,"type":"object"},"ReChargeCountChargesQuery":{"properties":{"address_id":{"type":"number"},"customer_id":{"type":"number"},"date":{"type":"string"},"date_min":{"type":"string"},"date_max":{"type":"string"},"discount_id":{"type":"number"},"shopify_order_id":{"type":"number"},"status":{"type":"string","enum":["SUCCESS","QUEUED","ERROR","REFUNDED","PARTIALLY_REFUNDED","SKIPPED"]},"subscription_id":{"type":"number"}},"additionalProperties":false,"type":"object"},"ReChargeListChargesQuery":{"additionalProperties":false,"type":"object"},"ReChargeListSubscriptionsQuery":{"properties":{"ids":{"type":"string"},"status":{"type":"string","enum":["ACTIVE","CANCELLED","EXPIRED"]}},"additionalProperties":false,"type":"object"},"ReChargeListDiscountsQuery":{"additionalProperties":false,"type":"object"},"ReChargeListCustomersQuery":{"properties":{"created_at_max":{"type":"string"},"created_at_min":{"type":"string"},"updated_at_max":{"type":"string"},"updated_at_min":{"type":"string"}},"additionalProperties":false,"type":"object"},"ReChargeListOrdersQuery":{"properties":{"customer_id":{"type":"number"},"subscription_id":{"type":"number"}},"additionalProperties":false,"type":"object"},"ReChargeListPaymentSourcesQuery":{"properties":{"cardholder_name":{"type":"string"},"card_brand":{"type":"string"},"card_exp_month":{"type":"number"},"card_exp_year":{"type":"number"},"card_last4":{"type":"number"},"has_card_error_in_dunning":{"type":"boolean"},"payment_type":{"type":"string"},"processor_name":{"type":"string"},"status":{"type":"string"},"status_reason":{"type":"string"}},"additionalProperties":false,"type":"object"},"ReChargeCountResponse":{"properties":{"count":{"type":"number"}},"required":["count"],"additionalProperties":false,"type":"object"},"IReChargeStreamEmission":{"properties":{"customer":{"$ref":"#/components/schemas/IReChargeCustomer"}},"required":["customer"],"additionalProperties":false,"type":"object"},"IReChargeStreamEmissionWithSupportingData":{"properties":{"subscriptions":{"items":{"$ref":"#/components/schemas/IReChargeSubscription"},"type":"array"},"addresses":{"items":{"$ref":"#/components/schemas/IReChargeAddress"},"type":"array"},"orders":{"items":{"$ref":"#/components/schemas/IReChargeOrder"},"type":"array"},"charges":{"items":{"$ref":"#/components/schemas/IReChargeCharge"},"type":"array"}},"required":["subscriptions","addresses","orders","charges"],"additionalProperties":false,"type":"object"},"IReChargeCustomerTableData":{"properties":{"status":{"$ref":"#/components/schemas/Status"},"sourceJson":{"properties":{"customer":{"$ref":"#/components/schemas/IReChargeCustomer"}},"required":["customer"],"additionalProperties":false,"type":"object"},"sourceType":{"$ref":"#/components/schemas/SourceType"},"sourceDate":{"$ref":"#/components/schemas/ISODateString"},"custRelShopifyId":{"type":"string"},"email":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"},"stShopifyId":{"type":"string"},"nextBillingDate":{"type":"string","format":"date-time"},"purchaseStateStatus":{"$ref":"#/components/schemas/PurchaseStateStatus"},"externalSubscriptionType":{"$ref":"#/components/schemas/PurchaseStateExternalSubscriptionType"},"rechargeSubscriptionIds":{"type":"array","items":{"type":"string"}},"error":{"nullable":true,"type":"string"}},"required":["status","sourceJson","sourceType","sourceDate","nextBillingDate","purchaseStateStatus","rechargeSubscriptionIds","error"],"additionalProperties":false,"type":"object"},"IReChargePurchaseStateTableData":{"properties":{"id":{"type":"string"},"shopifyId":{"type":"string"},"externalSubscriptionId":{"type":"string"},"externalSubscriptionStatus":{"$ref":"#/components/schemas/SubscriptionContractSubscriptionStatus"},"originalExternalSubscriptionStatus":{"$ref":"#/components/schemas/SubscriptionContractSubscriptionStatus"},"purchaseStateStatus":{"$ref":"#/components/schemas/PurchaseStateStatus"},"nextBillingDate":{"$ref":"#/components/schemas/ISODateString","nullable":true},"custRel":{"properties":{"id":{"type":"string"},"email":{"type":"string"},"shopifyId":{"type":"string"}},"required":["id","email"],"additionalProperties":false,"type":"object"}},"required":["id","shopifyId","externalSubscriptionId","externalSubscriptionStatus","originalExternalSubscriptionStatus","purchaseStateStatus","nextBillingDate"],"additionalProperties":false,"type":"object"},"IReChargeAnalyticsData":{"properties":{"utm_params":{"items":{"properties":{"utm_campaign":{"type":"string"},"utm_content":{"type":"string"},"utm_data_source":{"type":"string"},"utm_source":{"type":"string"},"utm_term":{"type":"string"},"utm_time_stamp":{"type":"string"},"utm_medium":{"type":"string"}},"required":["utm_campaign","utm_content","utm_data_source","utm_source","utm_term","utm_time_stamp","utm_medium"],"additionalProperties":false,"type":"object"},"type":"array"}},"required":["utm_params"],"additionalProperties":false,"type":"object"},"IReChargeBaseAddress":{"properties":{"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"company":{"nullable":true,"type":"string"},"country":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"phone":{"type":"string"},"province":{"type":"string"},"zip":{"type":"string"}},"required":["address1","address2","city","company","country","first_name","last_name","phone","province","zip"],"additionalProperties":false,"type":"object"},"IReChargeDiscountCode":{"properties":{"amount":{"$ref":"#/components/schemas/Decimal"},"code":{"type":"string"},"type":{"type":"string","enum":["percentage","fixed_amount"]},"recharge_discount_id":{"type":"number"}},"required":["amount","code","type"],"additionalProperties":false,"type":"object"},"IReChargeShippingLine":{"properties":{"code":{"type":"string"},"price":{"$ref":"#/components/schemas/Decimal"},"tax_lines":{"items":{},"type":"array"},"title":{"type":"string"}},"required":["code","price","tax_lines","title"],"additionalProperties":false,"type":"object"},"IDiscount":{"properties":{"allocationMethod":{"$ref":"#/components/schemas/DiscountAllocationMethod"},"code":{"type":"string"},"currency":{"$ref":"#/components/schemas/CurrencyCode"},"description":{"type":"string"},"rejectionReason":{"type":"string"},"recurringCycleLimit":{"type":"number"},"targetSelection":{"$ref":"#/components/schemas/DiscountTargetSelection"},"targetType":{"$ref":"#/components/schemas/DiscountTargetType"},"title":{"type":"string"},"type":{"$ref":"#/components/schemas/DiscountApplicationType"},"value":{"type":"number"},"valueType":{"$ref":"#/components/schemas/DiscountValueType"},"vendorId":{"type":"string"}},"required":["type","value","valueType"],"additionalProperties":false,"type":"object"},"DiscountValueType":{"type":"number","enum":[0,1],"description":"- 0: FIXED\n- 1: PERCENTAGE"},"DiscountApplicationType":{"type":"number","enum":[0,1,2,3],"description":"- 0: MANUAL\n- 1: SCRIPT\n- 2: DISCOUNT_CODE\n- 3: AUTOMATIC"},"DiscountTargetType":{"type":"number","enum":[0,1],"description":"- 0: LINE_ITEM\n- 1: SHIPPING_LINE"},"DiscountTargetSelection":{"type":"number","enum":[0,1,2],"description":"- 0: ALL\n- 1: ENTITLED\n- 2: EXPLICIT"},"DiscountAllocationMethod":{"type":"number","enum":[0,1,2],"description":"- 0: ACROSS\n- 1: EACH\n- 2: ONE"},"ILineItemDiscount":{"allOf":[{"$ref":"#/components/schemas/IDiscount"}]},"IOrderLineItemDiscount":{"allOf":[{"$ref":"#/components/schemas/ILineItemDiscount"},{"properties":{"calculatedValue":{"type":"number"}},"required":["calculatedValue"],"additionalProperties":false,"type":"object"}]},"IPurchaseStateLineItemDiscount":{"allOf":[{"$ref":"#/components/schemas/ILineItemDiscount"},{"properties":{"usageCount":{"type":"number"}},"required":["usageCount"],"additionalProperties":false,"type":"object"}]},"IOrderDiscount":{"allOf":[{"$ref":"#/components/schemas/IDiscount"}]},"IPurchaseStateDiscount":{"allOf":[{"$ref":"#/components/schemas/IDiscount"},{"properties":{"usageCount":{"type":"number"}},"required":["usageCount"],"additionalProperties":false,"type":"object"}]},"ISmartrrProvince":{"properties":{"id":{"type":"number"},"province":{"type":"string"},"provinceCode":{"type":"string"},"label":{"type":"string"}},"required":["id","province","provinceCode","label"],"additionalProperties":false,"type":"object"},"ISmartrrCountry":{"properties":{"id":{"type":"number"},"country":{"type":"string"},"countryCode":{"$ref":"#/components/schemas/CountryCode"},"provinceLabel":{"type":"string"},"provinces":{"items":{"$ref":"#/components/schemas/ISmartrrProvince"},"type":"array"},"zipLabel":{"type":"string"},"zipPlaceholder":{"type":"string"},"zipRequired":{"type":"boolean"}},"required":["id","country","countryCode","provinceLabel","provinces","zipLabel","zipPlaceholder","zipRequired"],"additionalProperties":false,"type":"object"},"IBaseAddress":{"properties":{"latitude":{"type":"number","nullable":true},"longitude":{"type":"number","nullable":true},"city":{"type":"string"},"province":{"type":"string"},"provinceCode":{"type":"string"},"zip":{"type":"string"},"country":{"type":"string"},"countryCode":{"$ref":"#/components/schemas/CountryCode"}}},"IGoogleAutocompleteAddress":{"allOf":[{"$ref":"#/components/schemas/IBaseAddress"},{"properties":{"streetNumber":{"type":"string"},"streetName":{"type":"string"},"neighborhood":{"type":"string"},"county":{"type":"string"},"countryName":{"type":"string"}},"additionalProperties":false,"type":"object"}]},"ISimpleAddress":{"allOf":[{"$ref":"#/components/schemas/IBaseAddress"},{"properties":{"address1":{"type":"string"},"address2":{"type":"string"}},"additionalProperties":false,"type":"object"}]},"IShopifyLikeMailingAddress":{"properties":{"address1":{"title":"The first line of the address. Typically the street address or PO Box number.","type":"string"},"address2":{"title":"The second line of the address. Typically the number of the apartment, suite, or unit.","type":"string"},"city":{"title":"The name of the city, district, village, or town.","type":"string"},"company":{"title":"The name of the customer's company or organization.","type":"string"},"country":{"title":"The name of the country. This argument is deprecated: Use `countryCode` instead.","type":"string"},"countryCode":{"title":"The two-letter code for the country of the address.","type":"string"},"firstName":{"title":"The first name of the customer.","type":"string"},"lastName":{"title":"The last name of the customer.","type":"string"},"phone":{"title":"A unique phone number for the customer.","description":"Formatted using E.164 standard. For example, _+16135551111_.","type":"string"},"province":{"title":"The region of the address, such as the province, state, or district. This argument is deprecated: Use `provinceCode` instead.","type":"string"},"provinceCode":{"description":"The code for the region of the address, such as the province, state, or district.\nFor example QC for Quebec, Canada.","type":"string"},"zip":{"title":"The zip or postal code of the address.","type":"string"}},"additionalProperties":false,"type":"object"},"WebhookEventType":{"type":"string","enum":["SUBSCRIPTION_CREATE","SUBSCRIPTION_ACTIVATE","SUBSCRIPTION_CANCEL","SUBSCRIPTION_LINE_UPDATE","SUBSCRIPTION_ITEM_OUT_OF_STOCK","SUBSCRIPTION_PRODUCT_UNAVAILABLE","SUBSCRIPTION_PAUSE","SUBSCRIPTION_AUTO_RESUME","SUBSCRIPTION_SKIP","SUBSCRIPTION_UNSKIP","SUBSCRIPTION_GIFT","SUBSCRIPTION_SET_NEXT_DATE","SUBSCRIPTION_SEND_NOW","SUBSCRIPTION_UPCOMING_ORDER","SUBSCRIPTION_FAILED_PAYMENT","SUBSCRIPTION_SUCCESSFUL_PAYMENT","PAYMENT_METHOD_UPDATE","PAYMENT_EXPIRED_NOTIFICATION","BUNDLE_COMPLETE","CUSTOMER_OTP_AUTH_CREATED","CUSTOMER_MAGIC_LINK_AUTH_CREATED","LOYALTY_POINTS_EARNED","REFERRAL_CODE_GENERATED","LOYALTY_BONUS_EARNED","LOYALTY_POINTS_REDEEMED","LOYALTY_TIER_ADVANCEMENT","LOYALTY_TIER_DOWNGRADE","SUCCESSFUL_REFERRAL","SUBSCRIPTION_AUTO_CANCEL"]},"IWebhook":{"allOf":[{"$ref":"#/components/schemas/IWebhookCreate"},{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"],"additionalProperties":false}]},"IWebhookCreate":{"type":"object","properties":{"eventType":{"$ref":"#/components/schemas/WebhookEventType"},"url":{"type":"string"}},"required":["eventType","url"],"additionalProperties":false},"IVendorUser":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IVendorUserCreate"}]},"IVendorUserCreate":{"allOf":[{"$ref":"#/components/schemas/IUserNameFields"},{"$ref":"#/components/schemas/IUninstantiatedVendorUserIdentifiers"},{"properties":{"isSuperUser":{"type":"boolean"},"hasPassword":{"type":"boolean"},"userPhoto":{"type":"string"},"gender":{"type":"string"},"googleId":{"type":"string"},"googlePhoto":{"type":"string"},"vendorOrgRoles":{"items":{"$ref":"#/components/schemas/IOrganizationVendorUserRole"},"type":"array"}},"additionalProperties":false,"type":"object"}]},"IShopifyVendorRelationshipFields":{"properties":{"vendorShopifyUserId":{"type":"string"},"isShopifyAccountOwner":{"type":"boolean"},"isShopifyCollaborator":{"type":"boolean"},"isShopOperator":{"type":"boolean"},"isShopifyEmailVerified":{"type":"boolean"}},"additionalProperties":false,"type":"object"},"VendorUserRole":{"type":"string","enum":["vendorAdmin","vendorEmployee"]},"IOrganizationVendorUserRole":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IShopifyVendorRelationshipFields"},{"properties":{"id":{"type":"string"},"role":{"$ref":"#/components/schemas/VendorUserRole"},"organization":{"$ref":"#/components/schemas/IOrganization"},"user":{"$ref":"#/components/schemas/IVendorUser"},"vendorShopifyUserId":{"type":"string"}},"required":["id","role","organization","user"],"additionalProperties":false,"type":"object"}]},"IUserNameFields":{"properties":{"originalFirstName":{"type":"string"},"originalLastName":{"type":"string"}},"additionalProperties":false,"type":"object"},"IUninstantiatedVendorUserIdentifiers":{"properties":{"originalEmail":{"type":"string"},"originalPhoneNumber":{"type":"string"}},"additionalProperties":false,"type":"object"},"SubscriptionEventType":{"type":"string","enum":["CHANGE_ORDER_DATE","CHANGE_SELLING_PLAN","PAUSE","CANCEL_PREPAID","CANCEL","EXPIRED","ACTIVATE","FAILED_DISCOUNT","SUCCESSFUL_DISCOUNT","SUCCESSFUL_BILLING_ATTEMPT","FAILED_BILLING_ATTEMPT","CREATE_BILL","SKIP","UNSKIP","GIFT","UNDO_GIFT","ADD_ADDRESS","CHANGE_ADDRESS","UPDATE_ADDRESS","DELETE_ADDRESS","REMOVE_DISCOUNT","REMOVE_LINE_ITEM","UPDATE_LINE_ITEM","ADD_LINE_ITEM","CHANGE_SHIPPING_PRICE","SWAP_LINE_ITEM","FAILED_CHANGE_ORDER_DATE","FAILED_CHANGE_SELLING_PLAN","FAILED_PAUSE","FAILED_CANCEL","FAILED_ACTIVATE","FAILED_SKIP","FAILED_UNSKIP","FAILED_GIFT","FAILED_UNDO_GIFT","FAILED_ADD_ADDRESS","FAILED_UPDATE_ADDRESS","FAILED_CHANGE_ADDRESS","FAILED_DELETE_ADDRESS","FAILED_REMOVE_DISCOUNT","FAILED_REMOVE_LINE_ITEM","FAILED_UPDATE_LINE_ITEM","FAILED_ADD_LINE_ITEM","FAILED_CHANGE_SHIPPING_PRICE","FAILED_SWAP_LINE_ITEM","OOS_AUTOMATIC_PAUSE","UNAVAILABLE_AUTOMATIC_PAUSE","OOS_LINE_ITEM_REMOVED","OOS_LINE_ITEM_REINSERTED","OOS_AUTOMATIC_SKIP","REWARDS_REDEEMED_PRODUCT","REWARDS_REDEEMED_INCENTIVE","REWARDS_POINTS_EARNED","REWARDS_POINTS_CORRECTION","UPDATE_EXTERNAL_SUBSCRIPTION_DATES","FAILED_UPDATE_EXTERNAL_SUBSCRIPTION_DATES","NOTIFICATION_SUBS_CREATED_NEW","NOTIFICATION_SUBS_CREATED_EXISTING","NOTIFICATION_PAYMENT_FAILED","NOTIFICATION_SUBSCRIPTION_CANCELED","NOTIFICATION_SUBSCRIPTION_PAUSED","NOTIFICATION_SUBSCRIPTION_ACTIVATED","NOTIFICATION_UPCOMING_ORDER","NOTIFICATION_PAYMENT_EXPIRATION","NOTIFICATION_ITEM_OUT_OF_STOCK","NOTIFICATION_GIFT_CREATED","NOTIFICATION_GIFT_SHIPPING","BILL_CREATION_FAILED","AUTO_RESUMED","ADMIN_LOGGEDIN_AS_CUSTOMER","SUPER_USER_LOGGEDIN_AS_CUSTOMER","ADMIN_ADDED_COMMENT","SUCCESSFUL_REFERRAL","CHANGE_EMAIL","SEQUENTIAL_SWAP","SEQUENTIAL_REMOVE_PRODUCT","SEQUENTIAL_TERMINATE_CONTRACT","SEQUENTIAL_RESTART_SEQUENCE","AUTO_CANCELED","PAYMENT_METHOD_UPDATED","ADD_ON_INSTANT_DIGITAL_ORDER"]},"SubscriptionEventCreator":{"type":"string","enum":["CUSTOMER","AGENT","SCRIPT","SEQUENTIAL","SMARTRR","API"]},"ISubscriptionEventData":{"type":"object","properties":{"previousShippingPrice":{"type":"number"},"updatedShippingPrice":{"type":"number"},"discountCode":{"type":"string"},"address":{"type":"object"},"sellingPlanId":{"type":"string"},"discountShopifyId":{"type":"string"},"billEventType":{"type":"string"},"orderDate":{"$ref":"#/components/schemas/ISODateString"},"billId":{"type":"string"},"addedLineItem":{"type":"object","properties":{"quantity":{"type":"number"},"variantId":{"type":"string"},"sellingPlanId":{"type":"string"},"skdIdx":{"type":"number"},"price":{"type":"number"},"orderDate":{"$ref":"#/components/schemas/ISODateString"},"productName":{"type":"string"},"variantName":{"type":"string"}}},"updatedLineItem":{"type":"object","properties":{"lineItemId":{"type":"string"},"variantId":{"type":"string"},"sellingPlanId":{"type":"string"},"updatedPrice":{"type":"number"},"productName":{"type":"string"},"variantName":{"type":"string"},"updatedQuantity":{"type":"number"},"previousQuantity":{"type":"number"}},"required":["lineItemId"]},"removedLineItem":{"type":"object","properties":{"lineItemId":{"type":"string"},"orderDate":{"$ref":"#/components/schemas/ISODateString"},"productName":{"type":"string"},"variantName":{"type":"string"}},"required":["lineItemId"]},"paymentMethodDetails":{"type":"object","properties":{"oldLastFour":{"type":"string"},"newLastFour":{"type":"string"},"cpsShopifyId":{"type":"string"}},"required":["oldLastFour","newLastFour"]}}},"ISubscriptionEvent":{"type":"object","properties":{"id":{"type":"string"},"eventData":{"$ref":"#/components/schemas/ISubscriptionEventData"},"createdBy":{"$ref":"#/components/schemas/SubscriptionEventCreator"},"eventDate":{"$ref":"#/components/schemas/ISODateString"},"eventType":{"$ref":"#/components/schemas/SubscriptionEventType"}},"required":["id","createdBy","eventDate","eventType"]},"ISmsAddon":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"properties":{"organization":{"$ref":"#/components/schemas/IOrganization"},"variant":{"$ref":"#/components/schemas/IPurchasableVariant"}},"required":["organization","variant"]}],"type":"object"},"ISmsAddonCreate":{"type":"object","properties":{"variantIds":{"type":"array","items":{"type":"string"}}}},"ResourceAccessLevel":{"type":"number","enum":[0,1,2,3,4],"x-enum-varnames":["NONE","READ","READ_AND_WRITE","AUTH_ONLY","SUPER_USER_ONLY"]},"ResourceScope":{"type":"string","enum":["SELLING_PLAN","SUBSCRIPTION","BILL","PRODUCT","CUSTOMER","ORDER","ANALYTICS","CUSTOMER_PORTAL_THEME","STORE_DATA","EMAIL_CONFIG","SMS_CONFIG","INTEGRATIONS_CONFIG","WEBHOOK"]},"ISmartrrApiToken":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ICreateSmartrrApiToken"}]},"ICreateSmartrrApiToken":{"properties":{"tokenNickName":{"type":"string"},"applicationName":{"type":"string"},"smartrrAccessToken":{"type":"string"},"clientId":{"type":"string"},"scopeSettings":{"$ref":"#/components/schemas/ScopeSettings"}},"required":["tokenNickName","applicationName","smartrrAccessToken","clientId","scopeSettings"],"additionalProperties":false,"type":"object"},"ScopeSettings":{"additionalProperties":{"$ref":"#/components/schemas/ResourceAccessLevel"},"description":"Accepts a hash map of `ResourceScope`s to `ResourceAccessLevel`s\n`ResourceScope`s:\n- SELLING_PLAN\n- SUBSCRIPTION\n- BILL\n- PRODUCT\n- CUSTOMER\n- ORDER\n- ANALYTICS\n- CUSTOMER_PORTAL_THEME\n- STORE_DATA\n- EMAIL_CONFIG\n- SMS_CONFIG\n- INTEGRATIONS_CONFIG\n- WEBHOOK\n<br/><br/> `ResourceAccessLevel`s:\n- 0: NONE\n- 1: READ\n- 2: READ_AND_WRITE\n- 3: AUTH_ONLY\n- 4: SUPER_USER_ONLY","example":{"SMS_CONFIG":0,"EMAIL_CONFIG":2,"ANALYTICS":1}},"IShopifyData":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IShopifyDataCreate"}]},"IShopifyDataCreate":{"properties":{"rawShopifyStoreId":{"type":"number"},"myShopifyDomain":{"type":"string"},"shopify_app_script_id":{"type":"string"},"address1":{"type":"string","nullable":true},"address2":{"type":"string"},"city":{"type":"string","nullable":true},"cookie_consent_level":{"type":"string"},"country":{"type":"string"},"country_code":{"type":"string"},"country_name":{"type":"string"},"created_at":{"type":"string"},"currency":{"$ref":"#/components/schemas/CurrencyCode"},"customer_email":{"type":"string"},"email":{"type":"string"},"enabled_presentment_currencies":{"items":{"$ref":"#/components/schemas/CurrencyCode"},"type":"array"},"google_apps_domain":{"type":"string"},"google_apps_login_enabled":{"type":"string"},"iana_timezone":{"type":"string"},"latitude":{"type":"number","nullable":true},"longitude":{"type":"number","nullable":true},"money_format":{"type":"string"},"money_in_emails_format":{"type":"string"},"money_with_currency_format":{"type":"string"},"money_with_currency_in_emails_format":{"type":"string"},"domain":{"type":"string"},"name":{"type":"string"},"phone":{"type":"string","nullable":true},"plan_display_name":{"type":"string"},"plan_name":{"type":"string"},"primary_locale":{"type":"string"},"primary_location_id":{"$ref":"#/components/schemas/BigIntString"},"province":{"type":"string","nullable":true},"province_code":{"type":"string"},"shop_owner":{"type":"string"},"source":{"type":"string"},"timezone":{"type":"string"},"updated_at":{"type":"string"},"visitor_tracking_consent_preference":{"type":"string"},"weight_unit":{"type":"string"},"zip":{"type":"string","nullable":true},"checkout_api_supported":{"type":"boolean"},"finances":{"type":"boolean"},"force_ssl":{"type":"boolean"},"has_discounts":{"type":"boolean"},"has_gift_cards":{"type":"boolean"},"has_storefront":{"type":"boolean"},"multi_location_enabled":{"type":"boolean"},"county_taxes":{"type":"boolean"},"tax_shipping":{"type":"boolean"},"eligible_for_payments":{"type":"boolean"},"password_enabled":{"type":"boolean"},"eligible_for_card_reader_giveaway":{"type":"boolean"},"pre_launch_enabled":{"type":"boolean"},"requires_extra_payments_agreement":{"type":"boolean"},"setup_required":{"type":"boolean"},"taxes_included":{"type":"boolean"}},"required":["rawShopifyStoreId","myShopifyDomain","address1","city","cookie_consent_level","country","country_code","country_name","created_at","currency","customer_email","email","enabled_presentment_currencies","iana_timezone","money_format","money_in_emails_format","money_with_currency_format","money_with_currency_in_emails_format","domain","name","phone","plan_display_name","plan_name","primary_locale","primary_location_id","province","shop_owner","timezone","updated_at","visitor_tracking_consent_preference","weight_unit","zip","checkout_api_supported","finances","force_ssl","has_discounts","has_gift_cards","has_storefront","multi_location_enabled","county_taxes","eligible_for_payments","password_enabled","eligible_for_card_reader_giveaway","pre_launch_enabled","requires_extra_payments_agreement","setup_required","taxes_included"],"additionalProperties":false,"type":"object"},"IPurchasableCollection":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPurchasableCollectionCreate"}]},"IPurchasableCollectionCreate":{"allOf":[{"type":"object","properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"]},{"properties":{"shopifyCollectionStorefrontId":{"type":"string"},"collectionName":{"type":"string"},"collectionImages":{"items":{"type":"string"},"type":"array"},"collectionSmallImages":{"items":{"type":"string"},"type":"array"},"isActiveInShopify":{"type":"boolean"},"isDraftOrArchived":{"type":"boolean"}},"required":["shopifyCollectionStorefrontId","collectionName","isActiveInShopify"],"additionalProperties":false,"type":"object"}]},"IPurchasable":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPurchasableCreate"}]},"IPurchasableCreate":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"properties":{"purchasableName":{"type":"string"},"purchasableImages":{"items":{"type":"string"},"type":"array"},"purchasableSmallImages":{"items":{"type":"string"},"type":"array"},"shopifyProductStorefrontId":{"type":"string"},"description":{"type":"string"},"isActiveInShopify":{"type":"boolean"},"isDraftOrArchived":{"type":"boolean"},"vnts":{"items":{"$ref":"#/components/schemas/IPurchasableVariant"},"type":"array"},"cols":{"items":{"$ref":"#/components/schemas/IPurchasableCollection"},"type":"array"}},"required":["purchasableName","description","isActiveInShopify"],"additionalProperties":false,"type":"object"}]},"IPurchasablePaginatedResponse":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IPurchasable"}}},"required":["data"]}]},"IPhoneDB":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPhone"}]},"IPhone":{"properties":{"phoneNumber":{"type":"string"},"twilioAccountSid":{"type":"string"},"sendUpcomingOrderSms":{"type":"boolean"}},"required":["phoneNumber","twilioAccountSid"],"additionalProperties":false,"type":"object"},"IPayoutMethod":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPayoutMethodCreate"}]},"IPayoutMethodCreate":{"properties":{"payoutMethodType":{"$ref":"#/components/schemas/PayoutMethodType"},"payoutMethodInternalOrganizationId":{"type":"string"},"publicKey":{"type":"string","nullable":true},"isTestPayoutMethod":{"type":"boolean"}},"required":["payoutMethodType","payoutMethodInternalOrganizationId","publicKey","isTestPayoutMethod"],"additionalProperties":false,"type":"object"},"PayoutMethodType":{"type":"string","enum":["stripe","paypal","chargeableShopify","dummyShopify"]},"IPaymentMethod":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPaymentMethodCreate"}]},"IPaymentMethodCreate":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"$ref":"#/components/schemas/IPaymentMethodJson"},{"properties":{"__paymentMethodKey__":{"type":"string"},"paymentMethodName":{"type":"string","nullable":true},"paymentMethodInternalCustomerId":{"type":"string"}},"required":["__paymentMethodKey__","paymentMethodInternalCustomerId"],"additionalProperties":false,"type":"object"}]},"IPaymentMethodJson":{"properties":{"maskedNumber":{"type":"string","nullable":true},"cardBrand":{"type":"string","nullable":true},"cardExpirationMonth":{"type":"number","nullable":true},"cardExpirationYear":{"type":"number","nullable":true},"lastDigits":{"type":"string","nullable":true}},"additionalProperties":false,"type":"object"},"IPaymentMethodResponse":{"properties":{"brand":{"type":"string","nullable":true},"cardExpirationDate":{"$ref":"#/components/schemas/Date"},"fingerprint":{"type":"string","nullable":true},"funding":{"enum":["credit","debit","prepaid","unknown"]},"isDefaultPaymentMethod":{"type":"boolean"},"lastFourDigits":{"type":"string","nullable":true}},"required":["brand","cardExpirationDate","funding","lastFourDigits"],"additionalProperties":false,"type":"object"},"IOrganizationBillingTime":{"properties":{"billingTime":{"$ref":"#/components/schemas/ISOTimeString"},"billingTimezone":{"$ref":"#/components/schemas/TZ"}},"required":["billingTime","billingTimezone"],"additionalProperties":false,"type":"object"},"ISetup":{"properties":{"selectedSellingPlanId":{"type":"string"},"hasProductSelected":{"type":"boolean"},"snippetsThemeId":{"type":"string"},"renderingThemeId":{"type":"string"},"isSetupFinished":{"type":"boolean"},"optimization":{"$ref":"#/components/schemas/ISetupOptimization"}},"required":["selectedSellingPlanId","hasProductSelected","snippetsThemeId","renderingThemeId","optimization"],"type":"object"},"ISetupOptimization":{"properties":{"shipping":{"type":"boolean"},"theming":{"type":"boolean"},"transaction":{"type":"boolean"},"integrations":{"type":"boolean"}},"required":["shipping","theming","transaction","integrations"],"type":"object"},"OutOfStockBehavior":{"type":"string","enum":["CREATE_ALWAYS","CREATE_ONLY_AVAILABLE_SKIP","CREATE_ONLY_AVAILABLE_PAUSE"]},"IOrganizationOutOfStockBehavior":{"properties":{"outOfStockBehavior":{"$ref":"#/components/schemas/OutOfStockBehavior"}},"required":["outOfStockBehavior"],"additionalProperties":false,"type":"object"},"IOrganizationAccount":{"properties":{"unlockedPlanNames":{"type":"array","items":{"type":"string"}}}},"IOrganizationBillingRetryConfig":{"properties":{"numBillingRetries":{"type":"number"},"delayBetweenRetries":{"type":"number"}},"additionalProperties":false,"type":"object"},"IOrganizationConfirmationDaysConfig":{"properties":{"billingConfirmationWaitingDays":{"type":"number"}},"additionalProperties":false,"type":"object"},"IOrganization":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IOrganizationCreate"}]},"IOrganizationCreate":{"allOf":[{"$ref":"#/components/schemas/IOrganizationShallowBase"},{"properties":{"vendorUsers":{"items":{"$ref":"#/components/schemas/IOrganizationVendorUserRole"},"type":"array"},"sts":{"items":{"$ref":"#/components/schemas/IPurchaseState"},"type":"array"},"shopifyStoreData":{"$ref":"#/components/schemas/IShopifyData"}},"required":["vendorUsers","sts"],"additionalProperties":false,"type":"object"}]},"IOrganizationShallowWithIDs":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IOrganizationShallowBase"}]},"IOrganizationShallowBase":{"allOf":[{"$ref":"#/components/schemas/IOrganizationBillingTime"},{"$ref":"#/components/schemas/IOrganizationBillingRetryConfig"},{"properties":{"orgName":{"type":"string"},"logo":{"type":"string"},"myShopifyDomain":{"type":"string"},"stripeAccessKey":{"type":"string"},"numBillingRetries":{"type":"number"},"delayBetweenRetries":{"type":"number"},"numFailedCyclesBeforeCancel":{"type":"number"},"initialSubscriptionImportComplete":{"type":"boolean"},"cancellationMessage":{"type":"string"},"billingTime":{"$ref":"#/components/schemas/ISOTimeString"},"billingTimezone":{"$ref":"#/components/schemas/TZ"},"account":{"$ref":"#/components/schemas/IOrganizationAccount"},"outOfStockItemRemovalEnabled":{"type":"boolean"},"instantDigitalItemFulfillmentEnabled":{"type":"boolean"}},"required":["orgName","initialSubscriptionImportComplete","billingTime","billingTimezone","account"],"additionalProperties":false,"type":"object"}]},"ISmartrrOrderLineItem":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"additionalProperties":false,"type":"object"},{"$ref":"#/components/schemas/ISmartrrOrderLineItemCreate"}]},"ISmartrrOrderLineItemCreate":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"properties":{"quantity":{"type":"number"},"shopIncome":{"$ref":"#/components/schemas/BigIntString"},"price":{"$ref":"#/components/schemas/BigIntString"},"priceCurrency":{"$ref":"#/components/schemas/CurrencyCode"},"discountAmount":{"$ref":"#/components/schemas/BigIntString"},"discountAllocations":{"items":{"$ref":"#/components/schemas/IOrderLineItemDiscount"},"type":"array"},"isAddOn":{"type":"boolean"},"shopifySubscriptionId":{"type":"string"},"vnt":{"$ref":"#/components/schemas/IPurchasableVariant"}},"required":["quantity","shopIncome","price","priceCurrency","discountAmount","discountAllocations","isAddOn"]}]},"ISmartrrOrderStatus":{"type":"string","description":"- `open`: being fulfilled / is fulfilled - `closed`: either fulfilled or \"archived\" by vendor - `cancelled`: cancelled by vendor","enum":["open","closed","cancelled"]},"ISmartrrFinancialStatus":{"description":"Shopify has all except `failed`","type":"string","enum":["failed","pending","authorized","paid","partially_paid","partially_refunded","refunded","voided"]},"ISmartrrFulfillmentStatus":{"description":"`partial` means partially shipped","type":"string","enum":["unshipped","partial","fulfilled","restocked"]},"OrderSource":{"type":"string","enum":["Shopify","Smartrr","Recharge","Other"]},"ISmartrrTrackingInfo":{"oneOf":[{"$ref":"#/components/schemas/ISmartrrCompanyAndNumberTrackingInfo"},{"$ref":"#/components/schemas/ISmartrrUrlTrackingInfo"}]},"ISmartrrTaxLineItem":{"properties":{"price":{"type":"number"},"rate":{"type":"number"},"title":{"type":"string"}},"required":["price","rate","title"],"additionalProperties":false,"type":"object"},"ISmartrrShippingLineItem":{"properties":{"price":{"type":"number"},"title":{"type":"string"},"shopifyHandle":{"type":"string"}},"required":["price","title"],"additionalProperties":false,"type":"object"},"ISmartrrRefundLineItem":{"properties":{"price":{"type":"number"},"lineItemId":{"type":"string"}},"required":["price"],"additionalProperties":false,"type":"object"},"ISmartrrOrderAdjustment":{"properties":{"price":{"type":"number"},"reason":{"type":"string"}},"required":["price","reason"],"additionalProperties":false,"type":"object"},"ISmartrrOrder":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ISmartrrOrderCreate"}]},"ISmartrrOrderFromDb":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ISmartrrOrder"},{"properties":{"sts":{"items":{"$ref":"#/components/schemas/IPurchaseState"},"type":"array"}},"required":["sts"],"additionalProperties":false,"type":"object"}]},"IPriceFieldsSharedWithOrderAndPurchSt":{"properties":{"totalFromLineItems":{"$ref":"#/components/schemas/BigIntString"},"totalLineItemsDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalLineItemsAfterDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalShipping":{"$ref":"#/components/schemas/BigIntString"},"totalDiscount":{"$ref":"#/components/schemas/BigIntString"}},"required":["totalFromLineItems","totalLineItemsDiscount","totalLineItemsAfterDiscount","totalShipping","totalDiscount"],"additionalProperties":false,"type":"object"},"ISmartrrOrderCreate":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"$ref":"#/components/schemas/IPriceFieldsSharedWithOrderAndPurchSt"},{"properties":{"shopifyOrderLabel":{"type":"string"},"orderProcessedDate":{"$ref":"#/components/schemas/ISODateString"},"orderStatus":{"$ref":"#/components/schemas/ISmartrrOrderStatus"},"financialStatus":{"$ref":"#/components/schemas/ISmartrrFinancialStatus"},"fulfillmentStatus":{"$ref":"#/components/schemas/ISmartrrFulfillmentStatus"},"deliveryAddress":{"$ref":"#/components/schemas/IMailingAddressJson"},"deliveryLatitude":{"type":"number"},"deliveryLongitude":{"type":"number"},"deliveryProvinceCode":{"type":"string"},"deliveryCountryCode":{"type":"string"},"orderSource":{"$ref":"#/components/schemas/OrderSource"},"orderCurrency":{"$ref":"#/components/schemas/CurrencyCode"},"shopIncome":{"$ref":"#/components/schemas/BigIntString"},"totalBeforeDiscountsAndRefunds":{"$ref":"#/components/schemas/BigIntString"},"totalNetBeforeRefunds":{"$ref":"#/components/schemas/BigIntString"},"totalTax":{"$ref":"#/components/schemas/BigIntString"},"totalTip":{"$ref":"#/components/schemas/BigIntString"},"totalRefund":{"$ref":"#/components/schemas/BigIntString"},"totalNet":{"$ref":"#/components/schemas/BigIntString"},"cancelReason":{"type":"string"},"cancelledAt":{"$ref":"#/components/schemas/ISODateString"},"totalOneTimeShopIncome":{"$ref":"#/components/schemas/BigIntString"},"totalSubscriptionShopIncome":{"$ref":"#/components/schemas/BigIntString"},"totalAddonShopIncome":{"$ref":"#/components/schemas/BigIntString"},"items":{"items":{"$ref":"#/components/schemas/ISmartrrOrderLineItem"},"type":"array"},"taxLineItems":{"items":{"$ref":"#/components/schemas/ISmartrrTaxLineItem"},"type":"array"},"shippingLineItems":{"items":{"$ref":"#/components/schemas/ISmartrrShippingLineItem"},"type":"array"},"discountApplications":{"items":{"$ref":"#/components/schemas/IOrderDiscount"},"type":"array"},"refundLineItems":{"items":{"$ref":"#/components/schemas/ISmartrrRefundLineItem"},"type":"array"},"refundOrderAdjustments":{"items":{"$ref":"#/components/schemas/ISmartrrOrderAdjustment"},"type":"array"},"trackingInfo":{"items":{"$ref":"#/components/schemas/ISmartrrTrackingInfo"},"type":"array"},"pmtMthJson":{"$ref":"#/components/schemas/IPaymentMethodJson"},"custRel":{"$ref":"#/components/schemas/ICustomerRelationship"}},"required":["orderProcessedDate","orderStatus","financialStatus","fulfillmentStatus","orderSource","orderCurrency","shopIncome","totalBeforeDiscountsAndRefunds","totalNetBeforeRefunds","totalTax","totalTip","totalRefund","totalNet","totalOneTimeShopIncome","totalSubscriptionShopIncome","totalAddonShopIncome","items","taxLineItems","shippingLineItems","discountApplications","refundLineItems","refundOrderAdjustments","trackingInfo"],"additionalProperties":false,"type":"object"}]},"ISmartrrOrderWithCustomerRelationship":{"allOf":[{"$ref":"#/components/schemas/ISmartrrOrderCreate"},{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"properties":{"custRel":{"$ref":"#/components/schemas/ICustomerRelationshipShallow"},"sts":{"items":{"$ref":"#/components/schemas/IPurchaseStateShallow"},"type":"array"}},"required":["sts"],"additionalProperties":false,"type":"object"}]},"ISmartrrOrderWithCustomerRelationshipPaginatedResponse":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrOrderWithCustomerRelationship"}}},"required":["data"]}]},"ISmartrrCompanyAndNumberTrackingInfo":{"properties":{"trackingCompany":{"type":"string"},"trackingNumbers":{"items":{"type":"string"},"type":"array"},"trackingUrls":{"items":{"type":"string"},"type":"array"}},"required":["trackingCompany","trackingNumbers"],"additionalProperties":false,"type":"object"},"ISmartrrUrlTrackingInfo":{"properties":{"trackingCompany":{"type":"string"},"trackingNumbers":{"items":{"type":"string"},"type":"array"},"trackingUrls":{"items":{"type":"string"},"type":"array"}},"required":["trackingUrls"],"additionalProperties":false,"type":"object"},"MailingAddressType":{"type":"string","description":"* FOR_CUSTOMER: this type is for both a billing and mailing address: https://shopify.dev/docs/admin-api/graphql/reference/common-objects/mailingaddress","enum":["FOR_CUSTOMER","GIFTING"]},"IMailingAddress":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IMailingAddressCreate"}]},"IMailingAddressJson":{"allOf":[{"$ref":"#/components/schemas/ISimpleAddress"},{"$ref":"#/components/schemas/IUninstantiatedCustomerRelationshipIdentifiers"},{"$ref":"#/components/schemas/MailingAddressInput"},{"properties":{"company":{"type":"string"},"shopifyId":{"type":"string"}},"additionalProperties":false,"type":"object"}]},"IMailingAddressCreate":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"$ref":"#/components/schemas/IMailingAddressJson"},{"type":"object","properties":{"addressType":{"$ref":"#/components/schemas/MailingAddressType"}},"required":["addressType"]}]},"IMailingAddressUpsert":{"allOf":[{"$ref":"#/components/schemas/IMailingAddressCreate"},{"type":"object","properties":{"id":{"type":"string"}}}]},"OrganizationIntegrationId":{"type":"string","enum":["klaviyo","loyalty_lion","recharge","postscript","attentive","shopify_flow","arpu","gorgias","savedBy"]},"IOrganizationIntegration":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IOrganizationIntegrationCreate"},{"type":"object","properties":{"organization":{"$ref":"#/components/schemas/IOrganization"}},"required":["organization"]}]},"IOrganizationIntegrationCreate":{"properties":{"integrationId":{"$ref":"#/components/schemas/OrganizationIntegrationId"},"apiKey":{"type":"string"},"secretApiKey":{"description":"some integrations (e.g. Klaviyo) may have a \"private\" API","type":"string"}},"required":["integrationId","apiKey","organization"],"additionalProperties":true,"type":"object"},"ISOTimeString":{"type":"string","description":"A time component in ISO format:\nHH:mm:ss"},"ISODateString":{"type":"string","description":"A string in ISO format (ISO 8601 Extended Format):\nYYYY-MM-DDTHH:mm:ss.sssZ"},"NullableISODateString":{"type":"string","description":"A string in ISO format (ISO 8601 Extended Format):\nYYYY-MM-DDTHH:mm:ss.sssZ","nullable":true},"ICreateGift":{"properties":{"to":{"$ref":"#/components/schemas/IShopifyLikeMailingAddress"},"stId":{"type":"string"},"skdIdx":{"type":"number"},"email":{"type":"string"},"phone":{"type":"string"},"note":{"type":"string"},"notifyBy":{"type":"string","enum":["email","text","email+text"]}},"required":["to","stId","skdIdx","notifyBy"],"additionalProperties":false,"type":"object"},"IGift":{"allOf":[{"$ref":"#/components/schemas/ICreateGift"},{"properties":{"id":{"type":"string"}},"required":["id"],"additionalProperties":false,"type":"object"}]},"Status":{"type":"string","description":"- 0: ready - 1: syncing - 2: succeeded - 3: failed","enum":[0,1,2,3]},"SourceType":{"type":"string","enum":["order","product","contract","rechargeSubscription"]},"IDataStream":{"type":"object","properties":{"id":{"type":"number"},"orgId":{"type":"string"},"status":{"$ref":"#/components/schemas/Status"},"sourceType":{"$ref":"#/components/schemas/SourceType"},"sourceDate":{"$ref":"#/components/schemas/ISODateString"},"source":{"type":"string","enum":["Shopify"]},"error":{"type":"string"},"retry":{"type":"number"},"createdDate":{"$ref":"#/components/schemas/ISODateString"}}},"CustomerUserRole":{"type":"string","enum":["individualCustomer","customerOrgAdmin","customerOrgEmployee"]},"ICustomerRelationship":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ICustomerRelationshipCreate"},{"type":"object","properties":{"sellingOrganization":{"$ref":"#/components/schemas/IOrganization"},"defaultAddress":{"$ref":"#/components/schemas/IMailingAddress"}},"required":["sellingOrganization"]}]},"ICustomerRelationshipCreate":{"allOf":[{"$ref":"#/components/schemas/ICustomerRelationshipShallowBase"},{"properties":{"shopifyId":{"type":"string"},"defaultAddress":{"$ref":"#/components/schemas/IMailingAddressUpsert"}},"additionalProperties":false,"type":"object"}]},"ICustomerRelationshipShallowBase":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"properties":{"shopifyId":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"inferredPhone":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"},"isSuperUser":{"type":"boolean"},"role":{"$ref":"#/components/schemas/CustomerUserRole"},"__stripeCustomerId__":{"type":"string"},"customerCurrency":{"$ref":"#/components/schemas/CurrencyCode"},"orderCount":{"type":"number"},"customAttributes":{"type":"object"},"totalSpent":{"$ref":"#/components/schemas/BigIntString"},"hasLoggedIn":{"type":"boolean"}},"required":["role","customerCurrency","orderCount","totalSpent"],"additionalProperties":false,"type":"object"}]},"ICustomerRelationshipShallow":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ICustomerRelationshipShallowBase"}]},"ICustomerRelationshipShallowWithTieredPoints":{"allOf":[{"$ref":"#/components/schemas/ICustomerRelationshipShallow"},{"type":"object","properties":{"tieredPoints":{"type":"number"}}}]},"ICustomerRelationshipSellingOrgShallow":{"allOf":[{"$ref":"#/components/schemas/ICustomerRelationshipShallow"},{"properties":{"sellingOrganization":{"$ref":"#/components/schemas/IOrganizationShallowWithIDs"}},"required":["sellingOrganization"],"additionalProperties":false,"type":"object"}]},"IUninstantiatedCustomerRelationshipIdentifiers":{"properties":{"shopifyId":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"}},"additionalProperties":false,"type":"object"},"IPaginatedCustomerRelationshipShallow":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ICustomerRelationshipShallow"}}},"required":["data"]}]},"ICustomerPortalThemeFromDb":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ICustomerPortalTheme"}]},"ICustomerPortalThemeUpdate":{"properties":{"overrideCSS":{"type":"string"},"modernOverrideCSS":{"type":"string"}}},"ICustomerPortalTheme":{"allOf":[{"$ref":"#/components/schemas/ICustomerPortalThemeUpdate"}]},"CancellationReasonType":{"type":"string","enum":["PRODUCT","PRICE","DELIVERY","SERVICE","ALTERNATIVES","OTHER"]},"CancellationAction":{"type":"string","enum":["GIFT","SWAP","SKIP","CANCEL","CHANGE_DATE","DISCOUNT","FREQUENCY_UPDATE","CHANGE_ADDRESS"]},"ICancellationReason":{"type":"object","properties":{"id":{"type":"string"},"reasonType":{"type":"string"},"text":{"$ref":"#/components/schemas/ITranslatable"},"action":{"type":"string"},"uiIdx":{"type":"number"},"discount":{"type":"number"},"hasCustomerPrompt":{"type":"boolean"},"isArchived":{"type":"boolean"}},"required":["id","reasonType","action","uiIdx","hasCustomerPrompt","isArchived"]},"IUserCancellation":{"type":"object","properties":{"reasonText":{"type":"string"},"action":{"$ref":"#/components/schemas/CancellationAction"},"stId":{"type":"string","title":"The purchase state id"},"cancellationReasonId":{"type":"string"}},"required":["reasonText","action","stId","cancellationReasonId"]},"ITranslatable":{"type":"object"},"BillStatus":{"type":"string","enum":["pending","processing","succeeded","failed","canceled"]},"IBill":{"allOf":[{"type":"object","properties":{"updatedDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["updatedDate"]},{"type":"object","properties":{"id":{"type":"number"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IBillWithoutUpdatedDate"},{"$ref":"#/components/schemas/IBillCreate"}]},"IBillWithoutUpdatedDate":{"allOf":[{"type":"object","properties":{"id":{"type":"number"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate"]},{"$ref":"#/components/schemas/IBillCreate"}]},"IBillCreate":{"allOf":[{"properties":{"uniqueId":{"type":"string"},"billPaymentExternalId":{"type":"string"},"billAmount":{"$ref":"#/components/schemas/BigIntString"},"billCurrency":{"type":"string"},"status":{"$ref":"#/components/schemas/BillStatus"},"metadata":{"type":"object"},"billingDate":{"$ref":"#/components/schemas/ISODateString"},"retryCount":{"type":"number"},"order":{"$ref":"#/components/schemas/ISmartrrOrder"},"error":{"nullable":true,"type":"string"}},"required":["uniqueId","billAmount","billCurrency","status","metadata","retryCount"],"additionalProperties":false,"type":"object"}]},"IBillWithPurchStAndCustomerRelationship":{"allOf":[{"$ref":"#/components/schemas/IBill"},{"properties":{"st":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}},"required":["st"],"additionalProperties":false,"type":"object"}]},"IBillWithPurchStAndCustomerRelationshipPaginatedResponse":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationship"}}},"required":["data"]}]},"IBillAudit":{"allOf":[{"$ref":"#/components/schemas/IBillWithoutUpdatedDate"},{"type":"object","properties":{"billId":{"type":"number"}}}]},"BigIntString":{"type":"string"},"AccountPlanStatus":{"type":"string","enum":["ACTIVE","CANCELLED","DECLINED","EXPIRED","FROZEN","PENDING","ACCEPTED","EXPIRED_TRIAL"]},"FeatureAccessMap":{"type":"object","additionalProperties":{"type":"boolean"},"description":"Maps feature to flag indicating whether feature is available."},"IAccountPlan":{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"},"planName":{"type":"string"},"status":{"$ref":"#/components/schemas/AccountPlanStatus"},"approvedAt":{"$ref":"#/components/schemas/ISODateString"},"trialPeriodStart":{"$ref":"#/components/schemas/ISODateString"},"trialPeriodEnd":{"$ref":"#/components/schemas/ISODateString"},"reportUsageAt":{"$ref":"#/components/schemas/ISODateString"},"trialDays":{"type":"integer"},"usageLineItemShopifyId":{"type":"string"},"planFee":{"type":"number"},"transactionFee":{"type":"number"},"percentageFee":{"type":"number"},"features":{"$ref":"#/components/schemas/FeatureAccessMap"}},"required":["id","createdDate","updatedDate","shopifyUpdateDate","planName","status","trialDays","planFee","transactionFee","percentageFee","features"],"additionalProperties":false},"IAccountPlanConfig":{"type":"object","properties":{"planName":{"type":"string"},"terms":{"type":"string"},"cappedAmount":{"type":"number"},"trialDays":{"type":"integer"},"planFee":{"type":"number"},"transactionFee":{"type":"number"},"percentageFee":{"type":"number"},"features":{"$ref":"#/components/schemas/FeatureAccessMap"}},"required":["id","createdDate","updatedDate","status","trialDays","planFee","transactionFee","percentageFee","features"],"additionalProperties":false},"ISharedEntityFields":{"properties":{"id":{"type":"string"}},"required":["id"],"additionalProperties":false,"type":"object"},"ISharedEntityFieldsWithNumeridId":{"properties":{"id":{"type":"number"}},"required":["id"],"additionalProperties":false,"type":"object"},"IShopifyMirroredEntityFields":{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},"ISmartrrSellingPlanGroupBase":{"properties":{"shopifyNumericId":{"type":"number"},"shopifyId":{"type":"string"},"name":{"type":"string"},"appId":{"nullable":true,"type":"string"},"description":{"nullable":true,"type":"string"},"merchantCode":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"productIds":{"items":{"type":"number"},"type":"array"},"variantIds":{"items":{"type":"number"},"type":"array"},"subscriptionCount":{"type":"number"},"summary":{"nullable":true,"type":"string"},"position":{"nullable":true,"type":"number"},"sellingPlanCount":{"type":"number"},"enabledProductIdToVariantIdMap":{"$ref":"#/components/schemas/IEnabledShopifyProductIdToShopifyVariantIdMap"}},"required":["shopifyNumericId","shopifyId","name","appId","description","merchantCode","options","productIds","variantIds","enabledProductIdToVariantIdMap","subscriptionCount","summary","position","sellingPlanCount"],"additionalProperties":false,"type":"object"},"ISmartrrSellingPlanGroup":{"allOf":[{"$ref":"#/components/schemas/ISmartrrSellingPlanGroupBase"},{"properties":{"sellingPlans":{"items":{"$ref":"#/components/schemas/ISmartrrSellingPlan"},"type":"array"}},"required":["sellingPlans"],"additionalProperties":false,"type":"object"}]},"ISmartrrAddOnsConfig":{"allOf":[{"$ref":"#/components/schemas/ISmartrrSellingPlanGroupBase"},{"properties":{"sellingPlans":{"items":{"$ref":"#/components/schemas/ISmartrrAddOnsConfigSellingPlan"},"type":"array"}},"required":["sellingPlans"],"additionalProperties":false,"type":"object"}]},"ISmartrrSellingPlan":{"properties":{"shopifyNumericId":{"type":"number"},"shopifyId":{"type":"string"},"name":{"type":"string"},"description":{"nullable":true,"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"billingPolicy":{"$ref":"#/components/schemas/ISmartrrBillingPolicy"},"deliveryPolicy":{"$ref":"#/components/schemas/ISmartrrDeliveryPolicy"},"recurringDeliveries":{"type":"boolean"},"pricingPolicies":{"items":{"$ref":"#/components/schemas/SmartrrSellingPlanPricingPolicy"},"type":"array"}},"required":["shopifyNumericId","shopifyId","name","description","options","billingPolicy","deliveryPolicy","recurringDeliveries","pricingPolicies"],"additionalProperties":false,"type":"object"},"ISmartrrAddOnsConfigSellingPlan":{"properties":{"shopifyNumericId":{"type":"number"},"shopifyId":{"type":"string"},"pricingPolicies":{"items":{"$ref":"#/components/schemas/SmartrrSellingPlanFixedPricingPolicy"},"type":"array"}},"required":["shopifyNumericId","shopifyId","pricingPolicies"],"additionalProperties":false,"type":"object"},"SmartrrSellingPlanPricingPolicy":{"oneOf":[{"$ref":"#/components/schemas/SmartrrSellingPlanFixedPricingPolicy"},{"$ref":"#/components/schemas/SmartrrSellingPlanRecurringPricingPolicy"}]},"SmartrrSellingPlanFixedPricingPolicy":{"allOf":[{"$ref":"#/components/schemas/SmartrrSellingPlanPricingPolicyAdjustmentType"},{"properties":{"pricingPolicyType":{"type":"string","enum":["SellingPlanFixedPricingPolicy"]}},"required":["pricingPolicyType"],"additionalProperties":false,"type":"object"}]},"SmartrrSellingPlanRecurringPricingPolicy":{"allOf":[{"$ref":"#/components/schemas/SmartrrSellingPlanPricingPolicyAdjustmentType"},{"properties":{"pricingPolicyType":{"type":"string","enum":["SellingPlanRecurringPricingPolicy"]},"afterCycle":{"title":"Cycle after which this pricing policy applies.","type":"number"}},"required":["pricingPolicyType","afterCycle"],"additionalProperties":false,"type":"object"}]},"SmartrrSellingPlanPricingPolicyAdjustmentTypePercentage":{"properties":{"adjustmentType":{"title":"The price adjustment type.","type":"string","enum":["PERCENTAGE"]},"adjustmentValue":{"properties":{"percentage":{"type":"number"}},"required":["percentage"],"additionalProperties":false,"title":"The price adjustment value.","type":"object"}},"required":["adjustmentType","adjustmentValue"],"additionalProperties":false,"type":"object"},"SmartrrSellingPlanPricingPolicyAdjustmentTypeFixedAmount":{"properties":{"adjustmentType":{"title":"The price adjustment type.","type":"string","enum":["FIXED_AMOUNT"]},"adjustmentValue":{"properties":{"amount":{"type":"number"},"currencyCode":{"$ref":"#/components/schemas/CurrencyCode"}},"required":["amount","currencyCode"],"additionalProperties":false,"title":"The price adjustment value.","type":"object"}},"required":["adjustmentType","adjustmentValue"],"additionalProperties":false,"type":"object"},"SmartrrSellingPlanPricingPolicyAdjustmentTypePrice":{"properties":{"adjustmentType":{"title":"The price adjustment type.","type":"string","enum":["PRICE"]},"adjustmentValue":{"properties":{"amount":{"type":"number"},"currencyCode":{"$ref":"#/components/schemas/CurrencyCode"}},"required":["amount","currencyCode"],"additionalProperties":false,"title":"The price adjustment value.","type":"object"}},"required":["adjustmentType","adjustmentValue"],"additionalProperties":false,"type":"object"},"IEnabledShopifyProductIdToShopifyVariantIdMap":{"additionalProperties":{"type":"array","items":{"type":"number"}},"type":"object","description":"``` [productShopifyId: number]: number[]; ```"},"ISmartrrBillingPolicy":{"properties":{"interval":{"$ref":"#/components/schemas/SellingPlanInterval"},"intervalCount":{"type":"number"},"maxCycles":{"nullable":true,"type":"number"},"minCycles":{"nullable":true,"type":"number"}},"required":["interval","intervalCount"],"additionalProperties":false,"type":"object"},"ISmartrrDeliveryPolicy":{"properties":{"interval":{"$ref":"#/components/schemas/SellingPlanInterval"},"intervalCount":{"type":"number"}},"required":["interval","intervalCount"],"additionalProperties":false,"type":"object"},"SmartrrSellingPlanPricingPolicyAdjustmentType":{"oneOf":[{"$ref":"#/components/schemas/SmartrrSellingPlanPricingPolicyAdjustmentTypePercentage"},{"$ref":"#/components/schemas/SmartrrSellingPlanPricingPolicyAdjustmentTypeFixedAmount"},{"$ref":"#/components/schemas/SmartrrSellingPlanPricingPolicyAdjustmentTypePrice"}]},"ISmartrrBundleSearchConfig":{"properties":{"displayTerm":{"type":"string"},"searchTag":{"type":"string"}},"required":["displayTerm","searchTag"],"additionalProperties":false,"type":"object"},"ISmartrrBundleFilter":{"properties":{"name":{"type":"string"},"searches":{"items":{"$ref":"#/components/schemas/ISmartrrBundleSearchConfig"},"type":"array"}},"required":["name","searches"],"additionalProperties":false,"type":"object"},"ISmartrrBundlePacks":{"properties":{"name":{"type":"string"},"description":{"type":"string"},"alert":{"type":"string"},"collectionString":{"type":"string"},"minProducts":{"type":"number"},"maxProducts":{"type":"number"},"variantSelection":{"type":"string"},"buyWithVariant":{"type":"string"}},"required":["name","description","alert","collectionString","minProducts","maxProducts","variantSelection","buyWithVariant"],"additionalProperties":false,"type":"object"},"ISchedule":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"},"anchor":{"type":"object"}},"required":["id","createdDate","updatedDate","anchor"]},{"$ref":"#/components/schemas/IScheduleCreate"}]},"IScheduleCreate":{"$ref":"#/components/schemas/IRRuleManagerJson"},"IRRuleManagerEventFeedbackConfig":{"properties":{"extendOnUserSkip":{"type":"boolean"},"extendOnHiddenSkip":{"type":"boolean"},"ignorePastIndicesWhenExtending":{"type":"boolean"}},"required":["extendOnUserSkip","extendOnHiddenSkip","ignorePastIndicesWhenExtending"],"additionalProperties":false,"type":"object"},"SkipArrValue":{"$ref":"#/components/schemas/ISkip"},"ISkip":{"properties":{"userSkipped":{"type":"boolean"},"hiddenSkipped":{"type":"boolean"}},"required":["userSkipped","hiddenSkipped"],"additionalProperties":false,"type":"object","nullable":true},"IStringifiableRRuleManagerFields":{"allOf":[{"$ref":"#/components/schemas/IRRuleManagerEventFeedbackConfig"},{"type":"object","properties":{"initialSequenceStartDate":{"$ref":"#/components/schemas/Date"},"billedCycleStartDate":{"$ref":"#/components/schemas/Date"},"billedDeliveriesCount":{"type":"number"},"totalOrdersCount":{"type":"number"},"totalBillingCycles":{"type":"number"},"deliveryFrequencyMultiple":{"type":"number"},"paymentFrequencyMultiple":{"type":"number"},"skips":{"type":"array","items":{"$ref":"#/components/schemas/SkipArrValue"}}},"required":["initialSequenceStartDate","deliveryFrequencyMultiple","paymentFrequencyMultiple","skips"]}]},"IRRuleManagerJson":{"allOf":[{"$ref":"#/components/schemas/IStringifiableRRuleManagerFields"},{"properties":{"deliveryRRuleString":{"type":"string"}},"required":["deliveryRRuleString"],"additionalProperties":false,"type":"object"}]},"IScheduleConfig":{"properties":{"deliveryFrequencyValue":{"type":"number"},"paymentFrequencyValue":{"type":"number"},"frequencyUnit":{"$ref":"#/components/schemas/PeriodUnit"},"deliveryUntilDate":{"$ref":"#/components/schemas/Date"},"deliveryUntilCount":{"type":"number"}},"required":["deliveryFrequencyValue","paymentFrequencyValue","frequencyUnit"],"additionalProperties":false,"type":"object"},"IPurchaseState":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPurchaseStateCreate"}]},"PurchaseStateExternalSubscriptionType":{"type":"string","enum":["RECHARGE"]},"IPurchaseStateTotals":{"properties":{"totalFromLineItems":{"$ref":"#/components/schemas/BigIntString"},"totalLineItemsDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalLineItemsAfterDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalShipping":{"$ref":"#/components/schemas/BigIntString"},"totalShippingDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalEstimatedNet":{"$ref":"#/components/schemas/BigIntString"}},"required":["totalFromLineItems","totalLineItemsDiscount","totalLineItemsAfterDiscount","totalShipping","totalDiscount","totalEstimatedNet"],"additionalProperties":false,"type":"object"},"IPurchaseStateTotalsWithIndex":{"allOf":[{"$ref":"#/components/schemas/IPurchaseStateTotals"},{"properties":{"skdIdx":{"type":"number"}},"required":["skdIdx"],"type":"object"}]},"IPurchaseStateWithCustomerRelationship":{"allOf":[{"$ref":"#/components/schemas/IPurchaseState"},{"properties":{"custRel":{"$ref":"#/components/schemas/ICustomerRelationshipSellingOrgShallow"}},"additionalProperties":false,"type":"object"}]},"IFailedPurchaseStateWithReason":{"type":"object","properties":{"reason":{"type":"string"},"subscription":{"allOf":[{"$ref":"#/components/schemas/IPurchaseState"},{"properties":{"custRel":{"$ref":"#/components/schemas/ICustomerRelationshipSellingOrgShallow"}},"additionalProperties":false}]}},"additionalProperties":false},"IPurchaseStatePost":{"type":"object","properties":{"startDate":{"$ref":"#/components/schemas/ISODateString"},"shippingInfo":{"$ref":"#/components/schemas/PurchaseStateCreateShippingInfoInput"},"lines":{"type":"array","items":{"type":"object","properties":{"quantity":{"type":"number"},"variantId":{"oneOf":[{"type":"string"},{"type":"number"}]},"currentPrice":{"type":"number"}},"required":["quantity","variantId"]}},"stripeCustomerId":{"type":"string"},"billingAddress":{"$ref":"#/components/schemas/MailingAddressInput"},"paypalBillingAgreementId":{"type":"string"},"shopifyPaymentMethodId":{"type":"string"},"deliveryPrice":{"type":"number"},"billingPolicy":{"$ref":"#/components/schemas/SubscriptionBillingPolicyInput"},"sellingPlanId":{"oneOf":[{"type":"string"},{"type":"number"}]},"status":{"$ref":"#/components/schemas/SubscriptionContractSubscriptionStatus"}},"required":["startDate","shippingInfo","lines"]},"IPurchaseStateCreate":{"allOf":[{"$ref":"#/components/schemas/IPurchaseStateShallow"},{"properties":{"schedule":{"$ref":"#/components/schemas/ISchedule"},"gifts":{"items":{"$ref":"#/components/schemas/IGift"},"type":"array"},"organization":{"$ref":"#/components/schemas/IOrganization"},"pmtMth":{"$ref":"#/components/schemas/IPaymentMethod"},"stLineItems":{"items":{"$ref":"#/components/schemas/IPurchaseStateLineItem"},"type":"array"}},"required":["schedule","organization","pmtMth","stLineItems"]}]},"IPurchaseStateShallow":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPriceFieldsSharedWithOrderAndPurchSt"},{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"$ref":"#/components/schemas/IPriceFieldsSharedWithOrderAndPurchSt"},{"properties":{"purchaseStateStatus":{"$ref":"#/components/schemas/PurchaseStateStatus"},"createdViaCustomerPortal":{"type":"boolean"},"initialSubmissionDate":{"$ref":"#/components/schemas/ISODateString"},"externalSubscriptionCreatedDate":{"$ref":"#/components/schemas/ISODateString","nullable":true},"cancelledAt":{"$ref":"#/components/schemas/ISODateString","nullable":true},"pausedAt":{"$ref":"#/components/schemas/ISODateString","nullable":true},"externalSubscriptionCancelledAt":{"$ref":"#/components/schemas/ISODateString","nullable":true},"nextBillingDate":{"$ref":"#/components/schemas/ISODateString","nullable":true},"isRepeatCustomer":{"type":"boolean"},"sellingPlanId":{"type":"string"},"currency":{"$ref":"#/components/schemas/CurrencyCode"},"totalEstimatedTax":{"$ref":"#/components/schemas/BigIntString"},"totalShippingDiscount":{"$ref":"#/components/schemas/BigIntString"},"totalEstimatedNet":{"$ref":"#/components/schemas/BigIntString"},"discounts":{"items":{"$ref":"#/components/schemas/IPurchaseStateDiscount"},"type":"array"},"shippingAddress":{"$ref":"#/components/schemas/IMailingAddressJson"},"externalSubscriptionId":{"type":"string"},"externalSubscriptionType":{"$ref":"#/components/schemas/PurchaseStateExternalSubscriptionType"},"externalSubscriptionStatus":{"$ref":"#/components/schemas/PurchaseStateStatus"},"originalExternalSubscriptionStatus":{"$ref":"#/components/schemas/PurchaseStateStatus"}},"required":["purchaseStateStatus","createdViaCustomerPortal","initialSubmissionDate","isRepeatCustomer","currency","totalEstimatedNet","discounts","shippingAddress","nextBillingDate","cancelledAt","pausedAt","externalSubscriptionCancelledAt","externalSubscriptionCreatedDate"],"additionalProperties":false,"type":"object"}]},"PurchaseStateCreateShippingInfoInput":{"type":"object","properties":{"email":{"type":"string"},"address1":{"type":"string","title":"The first line of the address. Typically the street address or PO Box number."},"address2":{"type":"string","title":"The second line of the address. Typically the number of the apartment, suite, or unit."},"city":{"type":"string","title":"The name of the city, district, village, or town."},"country":{"type":"string","title":"The name of the country. This argument is deprecated: Use `countryCode` instead."},"firstName":{"type":"string","title":"The first name of the customer."},"lastName":{"type":"string","title":"The last name of the customer."},"phone":{"type":"string","title":"A unique phone number for the customer.","description":"Formatted using E.164 standard. For example, _+16135551111_."},"province":{"type":"string","title":"The region of the address, such as the province, state, or district. This argument is deprecated: Use `provinceCode` instead."},"zip":{"type":"string","title":"The zip or postal code of the address."}}},"IPurchaseStateWithCustomerRelationshipPaginatedResponse":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}},"required":["data"]}]},"PurchaseStateStatus":{"$ref":"#/components/schemas/SubscriptionContractSubscriptionStatus"},"MoneyV2":{"type":"object","properties":{"amount":{"type":"number"},"currencyCode":{"$ref":"#/components/schemas/CurrencyCode"}},"required":["amount","currencyCode"]},"SellingPlanPricingPolicyAdjustmentValue":{"oneOf":[{"$ref":"#/components/schemas/MoneyV2"},{"type":"object","properties":{"percentage":{"type":"number"}}}]},"IPurchaseStateLineItemPricingPolicy":{"additionalProperties":false,"type":"object","properties":{"basePrice":{"$ref":"#/components/schemas/MoneyV2"},"cycleDiscounts":{"type":"array","items":{"type":"object","properties":{"adjustmentType":{"type":"string","enum":["PERCENTAGE","FIXED_AMOUNT","PRICE"]},"adjustmentValue":{"$ref":"#/components/schemas/SellingPlanPricingPolicyAdjustmentValue"},"afterCycle":{"type":"number"},"computedPrice":{"$ref":"#/components/schemas/MoneyV2"}},"required":["adjustmentType","adjustmentValue","afterCycle","computedPrice"]}}},"required":["basePrice","cycleDiscounts"]},"IPurchaseStateLineItem":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPurchaseStateLineItemCreate"}]},"IPurchaseStateLineItemCreate":{"allOf":[{"properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"],"type":"object"},{"properties":{"idempotencyKey":{"type":"string"},"discounts":{"items":{"$ref":"#/components/schemas/IPurchaseStateLineItemDiscount"},"type":"array"},"basePrice":{"$ref":"#/components/schemas/BigIntString"},"priceAfterDiscounts":{"$ref":"#/components/schemas/BigIntString"},"priceCurrency":{"$ref":"#/components/schemas/CurrencyCode"},"quantity":{"type":"number"},"pricingPolicy":{"$ref":"#/components/schemas/IPurchaseStateLineItemPricingPolicy"},"isAddOn":{"type":"boolean"},"attributionSource":{"type":"string"},"vnt":{"$ref":"#/components/schemas/IPurchasableVariant"},"sellingPlanId":{"type":"string"},"skdIdx":{"type":"number"}},"required":["discounts","basePrice","priceAfterDiscounts","priceCurrency","quantity","isAddOn","vnt"],"additionalProperties":false,"type":"object"}]},"IPurchaseStateLineItemWithAsymmetricMetadata":{"allOf":[{"$ref":"#/components/schemas/IPurchaseStateLineItem"},{"properties":{"cps":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"},"vnt":{"$ref":"#/components/schemas/IPurchasableVariantWithPurchasable"}},"additionalProperties":false,"type":"object"}]},"IPurchaseStateLineItemWithAsymmetricMetadataPaginatedResponse":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IPurchaseStateLineItemWithAsymmetricMetadata"}}},"required":["data"]}]},"IPurchasableVariantCreate":{"allOf":[{"type":"object","properties":{"shopifyId":{"type":"string"},"receivedFromShopifyDate":{"$ref":"#/components/schemas/ISODateString"},"shopifyUpdateDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["shopifyUpdateDate"]},{"properties":{"shopifyProductVariantStorefrontId":{"type":"string"},"purchasableVariantName":{"type":"string"},"purchasableVariantImages":{"items":{"type":"string"},"type":"array"},"purchasableVariantSmallImages":{"items":{"type":"string"},"type":"array"},"isActiveInShopify":{"type":"boolean"},"isDraftOrArchived":{"type":"boolean"},"shopifyInventoryId":{"type":"string"},"requiresShipping":{"type":"boolean"},"sku":{"type":"string"},"unitCost":{"type":"number"},"presentmentPrices":{"items":{"$ref":"#/components/schemas/PresentmentPrice"},"type":"array"},"inventoryQuantity":{"type":"number","nullable":true},"inventoryPolicy":{"$ref":"#/components/schemas/ProductVariantInventoryPolicy"}},"required":["isActiveInShopify","requiresShipping","presentmentPrices"],"type":"object"}]},"IPurchasableVariant":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/IPurchasableVariantCreate"}]},"IPurchasableVariantWithPurchasable":{"allOf":[{"$ref":"#/components/schemas/IPurchasableVariant"},{"properties":{"purchasable":{"$ref":"#/components/schemas/IPurchasable"}},"additionalProperties":false,"type":"object"}]},"PresentmentPrice":{"properties":{"price":{"$ref":"#/components/schemas/BigIntString"},"priceCurrency":{"$ref":"#/components/schemas/CurrencyCode"}},"required":["price","priceCurrency"],"additionalProperties":false,"type":"object"},"ICustomerEmailConfigDb":{"allOf":[{"type":"object","properties":{"id":{"type":"string"},"createdDate":{"$ref":"#/components/schemas/ISODateString"},"updatedDate":{"$ref":"#/components/schemas/ISODateString"},"deletedAt":{"$ref":"#/components/schemas/ISODateString"}},"required":["id","createdDate","updatedDate"]},{"$ref":"#/components/schemas/ICustomerEmailConfig"}]},"ICustomerEmailConfig":{"type":"object","properties":{"sendSubscriptionCreateSignupEmail":{"type":"boolean"},"sendSubscriptionCreateSignupEmailBcc":{"type":"boolean"},"subscriptionCreateSignupEmailSubject":{"type":"string"},"subscriptionCreateSignupEmailBody":{"type":"string"},"subscriptionCreateSignupEmailBccAddress":{"type":"string","nullable":true},"sendSubscriptionCreateEmail":{"type":"boolean"},"sendSubscriptionCreateEmailBcc":{"type":"boolean"},"subscriptionCreateEmailSubject":{"type":"string"},"subscriptionCreateEmailBody":{"type":"string"},"subscriptionCreateEmailBccAddress":{"type":"string","nullable":true},"sendCancelEmail":{"type":"boolean"},"sendCancelEmailBcc":{"type":"boolean"},"cancelEmailSubject":{"type":"string"},"cancelEmailBody":{"type":"string"},"cancelEmailBccAddress":{"type":"string","nullable":true},"sendUpcomingOrderEmail":{"type":"boolean"},"sendUpcomingOrderEmailBcc":{"type":"boolean"},"upcomingOrderEmailSubject":{"type":"string"},"upcomingOrderEmailBody":{"type":"string"},"upcomingOrderEmailBccAddress":{"type":"string","nullable":true},"upcomingOrderEmailDeliveryDelay":{"type":"number"},"sendExpiredPaymentMethodEmail":{"type":"boolean"},"sendExpiredPaymentMethodEmailBcc":{"type":"boolean"},"expiredPaymentMethodEmailSubject":{"type":"string"},"expiredPaymentMethodEmailBody":{"type":"string"},"expiredPaymentMethodEmailBccAddress":{"type":"string","nullable":true},"sendUpdatePaymentEmailOnFailedPayment":{"type":"boolean"},"sendUpcomingGiftEmail":{"type":"boolean"},"sendUpcomingGiftEmailBcc":{"type":"boolean"},"upcomingGiftEmailSubject":{"type":"string"},"upcomingGiftEmailBody":{"type":"string"},"upcomingGiftEmailBccAddress":{"type":"string","nullable":true},"sendGiftIsBeingSentEmail":{"type":"boolean"},"sendGiftIsBeingSentEmailBcc":{"type":"boolean"},"giftIsBeingSentEmailSubject":{"type":"string"},"giftIsBeingSentEmailBody":{"type":"string"},"giftIsBeingSentEmailBccAddress":{"type":"string","nullable":true},"sendGifterUpcomingGiftEmail":{"type":"boolean"},"gifterUpcomingGiftEmailSubject":{"type":"string"},"gifterUpcomingGiftEmailBody":{"type":"string"},"sendGifterUpcomingGiftEmailBcc":{"type":"boolean"},"gifterUpcomingGiftEmailBccAddress":{"type":"string","nullable":true},"itemOutOfStockEmail":{"type":"boolean"},"itemOutOfStockEmailBcc":{"type":"boolean"},"itemOutOfStockEmailSubject":{"type":"string"},"itemOutOfStockEmailBody":{"type":"string"},"itemOutOfStockEmailBccAddress":{"type":"string","nullable":true},"sendSubscriptionPausedEmail":{"type":"boolean"},"sendSubscriptionPausedEmailBcc":{"type":"boolean"},"subscriptionPausedEmailSubject":{"type":"string"},"subscriptionPausedEmailBody":{"type":"string"},"subscriptionPausedEmailBccAddress":{"type":"string","nullable":true},"sendSubscriptionAutoResumeEmail":{"type":"boolean"},"sendSubscriptionAutoResumeEmailBcc":{"type":"boolean"},"subscriptionAutoResumeEmailSubject":{"type":"string"},"subscriptionAutoResumeEmailBody":{"type":"string"},"subscriptionAutoResumeEmailBccAddress":{"type":"string","nullable":true},"sendSubscriptionResumedEmail":{"type":"boolean"},"sendSubscriptionResumedEmailBcc":{"type":"boolean"},"subscriptionResumedSubject":{"type":"string"},"subscriptionResumedEmailBody":{"type":"string"},"subscriptionResumedEmailBccAddress":{"type":"string","nullable":true},"emailHeader":{"type":"string"},"emailFooter":{"type":"string"},"emailTheming":{"type":"object","properties":{"logo":{"type":"string"},"logoWidth":{"type":"number"},"useHeaderAndFooter":{"type":"boolean"},"useStyling":{"type":"boolean"},"colors":{"type":"object","properties":{"backgroundColor":{"type":"string"},"primaryTextColor":{"type":"string"},"secondaryTextColor":{"type":"string"},"buttonBackgroundColor":{"type":"string"},"buttonTextColor":{"type":"string"}}}}},"isArpuEnabled":{"type":"boolean"},"oneTimeCodeEmailSubject":{"type":"string"},"oneTimeCodeEmailBody":{"type":"string"},"magicLinkEmailSubject":{"type":"string"},"magicLinkEmailBody":{"type":"string"},"sendSuccessfulReferralEmail":{"type":"boolean"},"sendSuccessfulReferralEmailBcc":{"type":"boolean"},"successfulReferralEmailSubject":{"type":"string"},"successfulReferralEmailBody":{"type":"string"},"successfulReferralEmailBccAddress":{"type":"string","nullable":true},"sendPaymentFailureEmail":{"type":"boolean"},"sendPaymentFailureEmailBcc":{"type":"boolean"},"paymentFailureEmailSubject":{"type":"string"},"paymentFailureEmailBody":{"type":"string"},"paymentFailureEmailBccAddress":{"type":"string","nullable":true},"sendAccountCreationReminderEmail":{"type":"boolean"},"sendAccountCreationReminderEmailBcc":{"type":"boolean"},"accountCreationReminderEmailSubject":{"type":"string"},"accountCreationReminderEmailBody":{"type":"string"},"accountCreationReminderEmailBccAddress":{"type":"string","nullable":true},"sendBonusEarnedEmail":{"type":"boolean"},"sendBonusEarnedEmailBcc":{"type":"boolean"},"bonusEarnedEmailSubject":{"type":"string"},"bonusEarnedEmailBody":{"type":"string"},"bonusEarnedEmailBccAddress":{"type":"string","nullable":true},"sendOtpCodeRedeemedEmail":{"type":"boolean"},"sendOtpCodeRedeemedEmailBcc":{"type":"boolean"},"otpCodeRedeemedEmailSubject":{"type":"string"},"otpCodeRedeemedEmailBody":{"type":"string"},"otpCodeRedeemedEmailBccAddress":{"type":"string","nullable":true},"sendRewardReminderEmail":{"type":"boolean"},"sendRewardReminderEmailBcc":{"type":"boolean"},"rewardReminderEmailSubject":{"type":"string"},"rewardReminderEmailBody":{"type":"string"},"rewardReminderEmailBccAddress":{"type":"string","nullable":true},"sendRewardOutOfStockEmail":{"type":"boolean"},"sendRewardOutOfStockEmailBcc":{"type":"boolean"},"rewardOutOfStockEmailSubject":{"type":"string"},"rewardOutOfStockEmailBody":{"type":"string"},"rewardOutOfStockEmailBccAddress":{"type":"string","nullable":true},"sendLoyaltyCurrencyReminder":{"type":"boolean"},"loyaltyCurrencyReminderEmailBody":{"type":"string"},"loyaltyCurrencyReminderEmailSubject":{"type":"string"},"sendMigrationSummaryEmail":{"type":"boolean"},"migrationSummaryEmailBody":{"type":"string"},"migrationSummaryEmailSubject":{"type":"string"},"sendInsightsEmail":{"type":"boolean"},"sendLoyaltyWelcomeEmail":{"type":"boolean"},"sendLoyaltyWelcomeEmailBcc":{"type":"boolean"},"loyaltyWelcomeEmailSubject":{"type":"string"},"loyaltyWelcomeEmailBody":{"type":"string"},"loyaltyWelcomeEmailBccAddress":{"type":"string","nullable":true},"sendLoyaltyTiersWelcomeEmail":{"type":"boolean"},"sendLoyaltyTiersWelcomeEmailBcc":{"type":"boolean"},"loyaltyTiersWelcomeEmailSubject":{"type":"string"},"loyaltyTiersWelcomeEmailBody":{"type":"string"},"loyaltyTiersWelcomeBccAddress":{"type":"string","nullable":true},"sendLoyaltyTierAdvancementEmail":{"type":"boolean"},"sendLoyaltyTierAdvancementEmailBcc":{"type":"boolean"},"loyaltyTierAdvancementEmailSubject":{"type":"string"},"loyaltyTierAdvancementEmailBody":{"type":"string"},"loyaltyTierAdvancementBccAddress":{"type":"string","nullable":true}},"additionalProperties":false},"Date":{"format":"date-time","type":"string"},"TZ":{"type":"string","enum":["Africa/Abidjan","Africa/Accra","Africa/Addis_Ababa","Africa/Algiers","Africa/Asmara","Africa/Asmera","Africa/Bamako","Africa/Bangui","Africa/Banjul","Africa/Blantyre","Africa/Brazzaville","Africa/Bujumbura","Africa/Cairo","Africa/Casablanca","Africa/Ceuta","Africa/Conakry","Africa/Dakar","Africa/Dar_es_Salaam","Africa/Djibouti","Africa/Douala","Africa/El_Aaiun","Africa/Freetown","Africa/Gaborone","Africa/Harare","Africa/Johannesburg","Africa/Juba","Africa/Kampala","Africa/Khartoum","Africa/Kigali","Africa/Kinshasa","Africa/Lagos","Africa/Libreville","Africa/Lome","Africa/Luanda","Africa/Lubumbashi","Africa/Lusaka","Africa/Malabo","Africa/Maputo","Africa/Maseru","Africa/Mbabane","Africa/Mogadishu","Africa/Monrovia","Africa/Nairobi","Africa/Ndjamena","Africa/Niamey","Africa/Nouakchott","Africa/Ouagadougou","Africa/Porto-Novo","Africa/Sao_Tome","Africa/Timbuktu","Africa/Tripoli","Africa/Tunis","Africa/Windhoek","America/Adak","America/Anchorage","America/Anguilla","America/Antigua","America/Araguaina","America/Argentina/Buenos_Aires","America/Argentina/Catamarca","America/Argentina/ComodRivadavia","America/Argentina/Cordoba","America/Argentina/Jujuy","America/Argentina/La_Rioja","America/Argentina/Mendoza","America/Argentina/Rio_Gallegos","America/Argentina/Salta","America/Argentina/San_Juan","America/Argentina/San_Luis","America/Argentina/Tucuman","America/Argentina/Ushuaia","America/Aruba","America/Asuncion","America/Atikokan","America/Atka","America/Bahia","America/Bahia_Banderas","America/Barbados","America/Belem","America/Belize","America/Blanc-Sablon","America/Boa_Vista","America/Bogota","America/Boise","America/Buenos_Aires","America/Cambridge_Bay","America/Campo_Grande","America/Cancun","America/Caracas","America/Catamarca","America/Cayenne","America/Cayman","America/Chicago","America/Chihuahua","America/Coral_Harbour","America/Cordoba","America/Costa_Rica","America/Creston","America/Cuiaba","America/Curacao","America/Danmarkshavn","America/Dawson","America/Dawson_Creek","America/Denver","America/Detroit","America/Dominica","America/Edmonton","America/Eirunepe","America/El_Salvador","America/Ensenada","America/Fort_Wayne","America/Fortaleza","America/Glace_Bay","America/Godthab","America/Goose_Bay","America/Grand_Turk","America/Grenada","America/Guadeloupe","America/Guatemala","America/Guayaquil","America/Guyana","America/Halifax","America/Havana","America/Hermosillo","America/Indiana/Indianapolis","America/Indiana/Knox","America/Indiana/Marengo","America/Indiana/Petersburg","America/Indiana/Tell_City","America/Indiana/Valparaiso","America/Indiana/Vevay","America/Indiana/Vincennes","America/Indiana/Winamac","America/Indianapolis","America/Inuvik","America/Iqaluit","America/Jamaica","America/Jujuy","America/Juneau","America/Kentucky/Louisville","America/Kentucky/Monticello","America/Knox_IN","America/Kralendijk","America/La_Paz","America/Lima","America/Los_Angeles","America/Louisville","America/Lower_Princes","America/Maceio","America/Managua","America/Manaus","America/Marigot","America/Martinique","America/Matamoros","America/Mazatlan","America/Mendoza","America/Menominee","America/Merida","America/Metlakatla","America/Mexico_City","America/Miquelon","America/Moncton","America/Monterrey","America/Montevideo","America/Montreal","America/Montserrat","America/Nassau","America/New_York","America/Nipigon","America/Nome","America/Noronha","America/North_Dakota/Beulah","America/North_Dakota/Center","America/North_Dakota/New_Salem","America/Ojinaga","America/Panama","America/Pangnirtung","America/Paramaribo","America/Phoenix","America/Port_of_Spain","America/Port-au-Prince","America/Porto_Acre","America/Porto_Velho","America/Puerto_Rico","America/Rainy_River","America/Rankin_Inlet","America/Recife","America/Regina","America/Resolute","America/Rio_Branco","America/Rosario","America/Santa_Isabel","America/Santarem","America/Santiago","America/Santo_Domingo","America/Sao_Paulo","America/Scoresbysund","America/Shiprock","America/Sitka","America/St_Barthelemy","America/St_Johns","America/St_Kitts","America/St_Lucia","America/St_Thomas","America/St_Vincent","America/Swift_Current","America/Tegucigalpa","America/Thule","America/Thunder_Bay","America/Tijuana","America/Toronto","America/Tortola","America/Vancouver","America/Virgin","America/Whitehorse","America/Winnipeg","America/Yakutat","America/Yellowknife","Antarctica/Casey","Antarctica/Davis","Antarctica/DumontDUrville","Antarctica/Macquarie","Antarctica/Mawson","Antarctica/McMurdo","Antarctica/Palmer","Antarctica/Rothera","Antarctica/South_Pole","Antarctica/Syowa","Antarctica/Troll","Antarctica/Vostok","Arctic/Longyearbyen","Asia/Aden","Asia/Almaty","Asia/Amman","Asia/Anadyr","Asia/Aqtau","Asia/Aqtobe","Asia/Ashgabat","Asia/Ashkhabad","Asia/Baghdad","Asia/Bahrain","Asia/Baku","Asia/Bangkok","Asia/Beirut","Asia/Bishkek","Asia/Brunei","Asia/Calcutta","Asia/Choibalsan","Asia/Chongqing","Asia/Chungking","Asia/Colombo","Asia/Dacca","Asia/Damascus","Asia/Dhaka","Asia/Dili","Asia/Dubai","Asia/Dushanbe","Asia/Gaza","Asia/Harbin","Asia/Hebron","Asia/Ho_Chi_Minh","Asia/Hong_Kong","Asia/Hovd","Asia/Irkutsk","Asia/Istanbul","Asia/Jakarta","Asia/Jayapura","Asia/Jerusalem","Asia/Kabul","Asia/Kamchatka","Asia/Karachi","Asia/Kashgar","Asia/Kathmandu","Asia/Katmandu","Asia/Khandyga","Asia/Kolkata","Asia/Krasnoyarsk","Asia/Kuala_Lumpur","Asia/Kuching","Asia/Kuwait","Asia/Macao","Asia/Macau","Asia/Magadan","Asia/Makassar","Asia/Manila","Asia/Muscat","Asia/Nicosia","Asia/Novokuznetsk","Asia/Novosibirsk","Asia/Omsk","Asia/Oral","Asia/Phnom_Penh","Asia/Pontianak","Asia/Pyongyang","Asia/Qatar","Asia/Qyzylorda","Asia/Rangoon","Asia/Riyadh","Asia/Saigon","Asia/Sakhalin","Asia/Samarkand","Asia/Seoul","Asia/Shanghai","Asia/Singapore","Asia/Taipei","Asia/Tashkent","Asia/Tbilisi","Asia/Tehran","Asia/Tel_Aviv","Asia/Thimbu","Asia/Thimphu","Asia/Tokyo","Asia/Ujung_Pandang","Asia/Ulaanbaatar","Asia/Ulan_Bator","Asia/Urumqi","Asia/Ust-Nera","Asia/Vientiane","Asia/Vladivostok","Asia/Yakutsk","Asia/Yekaterinburg","Asia/Yerevan","Atlantic/Azores","Atlantic/Bermuda","Atlantic/Canary","Atlantic/Cape_Verde","Atlantic/Faeroe","Atlantic/Faroe","Atlantic/Jan_Mayen","Atlantic/Madeira","Atlantic/Reykjavik","Atlantic/South_Georgia","Atlantic/St_Helena","Atlantic/Stanley","Australia/ACT","Australia/Adelaide","Australia/Brisbane","Australia/Broken_Hill","Australia/Canberra","Australia/Currie","Australia/Darwin","Australia/Eucla","Australia/Hobart","Australia/LHI","Australia/Lindeman","Australia/Lord_Howe","Australia/Melbourne","Australia/North","Australia/NSW","Australia/Perth","Australia/Queensland","Australia/South","Australia/Sydney","Australia/Tasmania","Australia/Victoria","Australia/West","Australia/Yancowinna","Brazil/Acre","Brazil/DeNoronha","Brazil/East","Brazil/West","Canada/Atlantic","Canada/Central","Canada/Eastern","Canada/East-Saskatchewan","Canada/Mountain","Canada/Newfoundland","Canada/Pacific","Canada/Saskatchewan","Canada/Yukon","Chile/Continental","Chile/EasterIsland","Cuba","Egypt","Eire","Etc/GMT","Etc/GMT+0","Etc/UCT","Etc/Universal","Etc/UTC","Etc/Zulu","Europe/Amsterdam","Europe/Andorra","Europe/Athens","Europe/Belfast","Europe/Belgrade","Europe/Berlin","Europe/Bratislava","Europe/Brussels","Europe/Bucharest","Europe/Budapest","Europe/Busingen","Europe/Chisinau","Europe/Copenhagen","Europe/Dublin","Europe/Gibraltar","Europe/Guernsey","Europe/Helsinki","Europe/Isle_of_Man","Europe/Istanbul","Europe/Jersey","Europe/Kaliningrad","Europe/Kiev","Europe/Lisbon","Europe/Ljubljana","Europe/London","Europe/Luxembourg","Europe/Madrid","Europe/Malta","Europe/Mariehamn","Europe/Minsk","Europe/Monaco","Europe/Moscow","Europe/Nicosia","Europe/Oslo","Europe/Paris","Europe/Podgorica","Europe/Prague","Europe/Riga","Europe/Rome","Europe/Samara","Europe/San_Marino","Europe/Sarajevo","Europe/Simferopol","Europe/Skopje","Europe/Sofia","Europe/Stockholm","Europe/Tallinn","Europe/Tirane","Europe/Tiraspol","Europe/Uzhgorod","Europe/Vaduz","Europe/Vatican","Europe/Vienna","Europe/Vilnius","Europe/Volgograd","Europe/Warsaw","Europe/Zagreb","Europe/Zaporozhye","Europe/Zurich","GB","GB-Eire","GMT","GMT+0","GMT0","GMT-0","Greenwich","Hongkong","Iceland","Indian/Antananarivo","Indian/Chagos","Indian/Christmas","Indian/Cocos","Indian/Comoro","Indian/Kerguelen","Indian/Mahe","Indian/Maldives","Indian/Mauritius","Indian/Mayotte","Indian/Reunion","Iran","Israel","Jamaica","Japan","Kwajalein","Libya","Mexico/BajaNorte","Mexico/BajaSur","Mexico/General","Navajo","NZ","NZ-CHAT","Pacific/Apia","Pacific/Auckland","Pacific/Chatham","Pacific/Chuuk","Pacific/Easter","Pacific/Efate","Pacific/Enderbury","Pacific/Fakaofo","Pacific/Fiji","Pacific/Funafuti","Pacific/Galapagos","Pacific/Gambier","Pacific/Guadalcanal","Pacific/Guam","Pacific/Honolulu","Pacific/Johnston","Pacific/Kiritimati","Pacific/Kosrae","Pacific/Kwajalein","Pacific/Majuro","Pacific/Marquesas","Pacific/Midway","Pacific/Nauru","Pacific/Niue","Pacific/Norfolk","Pacific/Noumea","Pacific/Pago_Pago","Pacific/Palau","Pacific/Pitcairn","Pacific/Pohnpei","Pacific/Ponape","Pacific/Port_Moresby","Pacific/Rarotonga","Pacific/Saipan","Pacific/Samoa","Pacific/Tahiti","Pacific/Tarawa","Pacific/Tongatapu","Pacific/Truk","Pacific/Wake","Pacific/Wallis","Pacific/Yap","Poland","Portugal","PRC","ROC","ROK","Singapore","Turkey","UCT","Universal","US/Alaska","US/Aleutian","US/Arizona","US/Central","US/Eastern","US/East-Indiana","US/Hawaii","US/Indiana-Starke","US/Michigan","US/Mountain","US/Pacific","US/Samoa","UTC","W-SU","Zulu"]},"IWebhooksListeningRes":{"type":"object","properties":{"isFullySubscribed":{"type":"boolean"},"subscribedTopics":{"type":"array","items":{"type":"string"}},"missingTopics":{"type":"array","items":{"type":"string"}}},"required":["isFullySubscribed","subscribedTopics"]},"IShopifyAsset":{"type":"object","properties":{"attachment":{"type":"string"},"content_type":{"type":"string"},"created_at":{"type":"string"},"key":{"type":"string"},"public_url":{"type":"string"},"size":{"type":"number"},"source_key":{"type":"string"},"src":{"type":"string"},"theme_id":{"type":"number"},"updated_at":{"type":"string"},"value":{"type":"string"}},"required":["content_type","created_at","key","public_url","size","source_key","src","theme_id","updated_at"]},"IShopifyAssetCreate":{"type":"object","properties":{"key":{"type":"string"},"value":{"type":"string"}},"required":["key","value"]},"ICustomerPortalThemePostReq":{"type":"object","properties":{"themeShopifyId":{"type":"number"},"updatedThemeProperties":{"$ref":"#/components/schemas/ICustomerPortalThemeUpdate"}},"required":["themeShopifyId","updatedThemeProperties"]},"ReplaceProductAction":{"type":"object","properties":{"actionType":{"type":"string","enum":["REPLACE_PRODUCT_VARIANT"]},"originalProductVariantId":{"type":"string"},"newProductVariantId":{"type":"string"},"newSellingPlanShopifyId":{"type":"string"},"sellingPlanGroupId":{"type":"string"}}},"RemoveProductVariantAction":{"type":"object","properties":{"actionType":{"type":"string","enum":["REMOVE_PRODUCT_VARIANT"]},"productVariantId":{"type":"string"}}},"TerminateSubscriptionAction":{"type":"object","properties":{"actionType":{"type":"string","enum":["TERMINATE_SUBSCRIPTION"]}}},"ScriptCondition":{"type":"object","properties":{"orderNumber":{"type":"number","minimum":1},"eventType":{"type":"string","enum":["BEFORE_BILLING_ATTEMPT","AFTER_ORDER_CREATED"]}}},"ScriptAction":{"type":"object","oneOf":[{"$ref":"#/components/schemas/ReplaceProductAction"},{"$ref":"#/components/schemas/RemoveProductVariantAction"},{"$ref":"#/components/schemas/TerminateSubscriptionAction"}]},"IScript":{"type":"object","properties":{"id":{"type":"string"},"priority":{"type":"number","minimum":1},"condition":{"$ref":"#/components/schemas/ScriptCondition"},"action":{"$ref":"#/components/schemas/ScriptAction"},"createdDate":{"type":"string"},"updatedDate":{"type":"string"}}},"IScriptCreate":{"type":"object","properties":{"priority":{"type":"number","minimum":1},"condition":{"$ref":"#/components/schemas/ScriptCondition"},"action":{"$ref":"#/components/schemas/ScriptAction"}},"required":["priority","condition","action"]},"ErrorResponse":{"type":"object","properties":{"message":{"type":"string"},"status":{"type":"number"},"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"}}}}},"RedeemIncentiveResponse":{"type":"object","properties":{"code":{"type":"string"},"cpsId":{"type":"string"},"orgPoints":{"type":"number"}}},"RedeemProductResponse":{"type":"object","properties":{"orgPoints":{"type":"number"},"updatedCPS":{"type":"object"}}},"IGetPurchasableResponse":{"type":"array","items":{"$ref":"#/components/schemas/IPurchasable"}},"IOrganizationBillingTimeReq":{"type":"object","properties":{"orgBillingTimeConfig":{"$ref":"#/components/schemas/IOrganizationBillingTime"}},"required":["orgBillingTimeConfig"]},"IOrganizationBillingRetryConfigReq":{"type":"object","properties":{"numBillingRetriesConfig":{"$ref":"#/components/schemas/IOrganizationBillingRetryConfig"}},"required":["numBillingRetriesConfig"]},"IOrganizationConfirmationDaysConfigReq":{"type":"object","properties":{"billingConfirmationWaitingDays":{"$ref":"#/components/schemas/IOrganizationConfirmationDaysConfig"}},"required":["billingConfirmationWaitingDays"]},"IPurchaseStateLineItemSwapPost":{"type":"object","properties":{"quantity":{"type":"number"},"variantId":{"type":"string"},"sellingPlanId":{"oneOf":[{"type":"string"},{"type":"number"}]},"skdIdx":{"type":"number"}},"required":["quantity","variantId","sellingPlanId"]},"IPurchaseStateLineItemPut":{"type":"object","properties":{"price":{"type":"number"},"quantity":{"type":"number"}},"required":["price","quantity"]},"IPurchaseStateBulkParam":{"oneOf":[{"type":"array","items":{"type":"string"}},{"type":"string","enum":["all"]}]},"IPurchaseStateBulk":{"type":"object","properties":{"customerPurchaseStateIds":{"$ref":"#/components/schemas/IPurchaseStateBulkParam"}},"required":["customerPurchaseStateIds"]},"IPurchaseStateBulkPause":{"type":"object","properties":{"customerPurchaseStateIds":{"$ref":"#/components/schemas/IPurchaseStateBulkParam"},"unpauseDate":{"$ref":"#/components/schemas/NullableISODateString"}},"required":["customerPurchaseStateIds","unpauseDate"]},"IPurchaseStateBulkNextDate":{"allOf":[{"$ref":"#/components/schemas/IPurchaseStateBulk"},{"type":"object","properties":{"date":{"$ref":"#/components/schemas/ISODateString"}},"required":["date"]}]},"IPurchaseStateDatesBulk":{"type":"object","properties":{"dates":{"type":"array","items":{"$ref":"#/components/schemas/ISODateString"}}},"required":["dates"]},"IPurchaseStateActivatePut":{"type":"object","properties":{"nextBillingDate":{"$ref":"#/components/schemas/ISODateString","nullable":true}},"required":["nextBillingDate"]},"IPurchaseStateSkipPut":{"type":"object","properties":{"date":{"$ref":"#/components/schemas/ISODateString"}}},"IPurchaseStateSellingPlanPut":{"type":"object","properties":{"sellingPlanId":{"oneOf":[{"type":"string"},{"type":"number"}]}},"required":["sellingPlanId"]},"ISellingPlanNextOrderDatePreviewResponse":{"type":"object","properties":{"nextOrderDate":{"type":"string","format":"date-time"}},"required":["nextOrderDate"]},"IPurchaseStateNextBillingDatePut":{"type":"object","properties":{"date":{"$ref":"#/components/schemas/ISODateString"}}},"IPurchaseStateDiscountPost":{"type":"object","properties":{"redeemCode":{"type":"string"}},"required":["redeemCode"]},"IPurchaseStateLineItemPost":{"type":"object","properties":{"price":{"type":"number"},"quantity":{"type":"number"},"variantId":{"type":"string"},"sellingPlanId":{"oneOf":[{"type":"string"},{"type":"number"}]},"skdIdx":{"type":"number"}},"required":["price","quantity","variantId","sellingPlanId"]},"ISubscriptionProperties":{"type":"object","properties":{"nextOrderDateChanged":{"type":"boolean"},"billingFailedMessage":{"type":"string"},"lastBilledOrderId":{"type":"string"},"orderNote":{"type":"string"},"billingFailedNotificationCount":{"type":"number"},"phoneCountryCode":{"type":"string"}}},"IPostAuthTicketsIssueRes":{"type":"object","properties":{"ticket":{"type":"string"},"expires":{"$ref":"#/components/schemas/ISODateString"}},"required":["ticket","expires"]},"IAnalyticsSimpleRes":{"type":"object","properties":{"activeSubsOverTime":{"type":"array","items":{"$ref":"#/components/schemas/IActiveSubsOverTime"}},"newSubscriptionsOverTime":{"type":"array","items":{"$ref":"#/components/schemas/INewSubscriptionsOverTime"}},"newSubscribersOverTime":{"type":"array","items":{"$ref":"#/components/schemas/INewSubscribersOverTime"}},"activeSubsTopVnts":{"type":"array","items":{"$ref":"#/components/schemas/RechartsPurchasableActiveSubsCountBaseObj"}},"activeSubsByFreq":{"type":"array","items":{"$ref":"#/components/schemas/IActiveCpsCountByDeliveryFrequency"}},"cancelledSubsOverTime":{"type":"array","items":{"$ref":"#/components/schemas/ICancelledSubsOverTime"}},"newOrdersOverTime":{"type":"array","items":{"$ref":"#/components/schemas/INewOrdersOverTime"}}},"required":["activeSubsOverTime","newSubscriptionsOverTime","newSubscribersOverTime","activeSubsTopVnts","activeSubsByFreq","cancelledSubsOverTime","newOrdersOverTime"]},"IActiveSubsOverTime":{"type":"object","properties":{"date":{"type":"string"},"activeSubscriptions":{"type":"string"},"activeSubscribers":{"type":"string"}},"required":["date","activeSubscriptions","activeSubscribers"],"additionalProperties":false},"INewSubscriptionsOverTime":{"type":"object","properties":{"aggPeriodStartDate":{"type":"string"},"newSubscriptions":{"type":"string"}},"required":["aggPeriodStartDate","newSubscriptions"],"additionalProperties":false},"INewSubscribersOverTime":{"type":"object","properties":{"aggPeriodStartDate":{"type":"string"},"newSubscribers":{"type":"string"}},"required":["aggPeriodStartDate","newSubscribers"],"additionalProperties":false},"RechartsPurchasableActiveSubsCountBaseObj":{"type":"object","properties":{"purchName":{"type":"string"},"children":{"type":"array","items":{"$ref":"#/components/schemas/RechartsVntActiveSubsCountBaseObj"}}},"required":["purchName","children"]},"RechartsVntActiveSubsCountBaseObj":{"type":"object","properties":{"purchNameAndVntName":{"type":"string"},"activeCpsCount":{"type":"number"},"activeCustRelCount":{"type":"number"}},"required":["purchNameAndVntName","activeCpsCount","activeCustRelCount"]},"IActiveCpsCountByDeliveryFrequency":{"type":"object","properties":{"frequencyString":{"type":"string"},"activeCpsCount":{"type":"number"}},"required":["frequencyString","activeCpsCount"]},"ICancelledSubsOverTime":{"type":"object","properties":{"date":{"type":"string"},"cancelledSubscriptions":{"type":"string"},"cancelledSubscribers":{"type":"string"}},"required":["date","cancelledSubscriptions","cancelledSubscribers"],"additionalProperties":false},"INewOrdersOverTime":{"type":"object","properties":{"date":{"type":"string"},"totalSubscriptionOrders":{"type":"string"},"totalOrders":{"type":"string"},"totalOrdersRevenueInCents":{"type":"string"},"totalSubscriptionRevenueInCents":{"type":"string"}},"required":["date","totalSubscriptionOrders","totalOrders","totalOrdersRevenueInCents","totalSubscriptionRevenueInCents"],"additionalProperties":false},"IAppPublicKeyResponse":{"type":"object","properties":{"publicApiKey":{"type":"string"}},"required":["publicApiKey"]},"IAuthSessionResponse":{"type":"object","properties":{"user":{"nullable":true,"oneOf":[{"$ref":"#/components/schemas/IVendorUser"}]},"auth_token":{"type":"string"}},"required":["user","auth_token"]},"IAuthVendorPortalResponse":{"type":"object","properties":{"user":{"nullable":true,"oneOf":[{"$ref":"#/components/schemas/IVendorUser"}]},"auth_token":{"type":"string"},"organization":{"nullable":true,"oneOf":[{"$ref":"#/components/schemas/IOrganization"}]},"accountPlan":{"nullable":true,"oneOf":[{"$ref":"#/components/schemas/IAccountPlan"}]},"purchasables":{"nullable":true,"oneOf":[{"$ref":"#/components/schemas/IPurchasablePaginatedResponse"}]}},"required":["user","auth_token","organization","purchasables"]}},"parameters":{"pageSizeParam":{"in":"query","name":"pageSize","schema":{"type":"string"}},"pageNumberParam":{"in":"query","name":"pageNumber","schema":{"type":"string"}},"orderByParam":{"in":"query","name":"orderBy","description":"``` Hashmap {  [property-name]: 'ASC',\n  [property-name-2]: 'DESC'\n} ```","schema":{"type":"object","additionalProperties":{"$ref":"#/components/schemas/SmartrrSortType"}}},"filterEqualsParam":{"in":"query","name":"filterEquals","schema":{"type":"object","additionalProperties":{"type":"string"}},"description":"``` Hashmap {  [property-name]: 'filter text',\n  [property-name-2]: 'filter text 2'\n} ```"},"filterInParam":{"in":"query","name":"filterIn","schema":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string"}}},"description":"``` Hashmap {  [property-name-1]: ['valueA', 'valueB'],\n  [property-name-2]: ['valueC']\n} ```"},"filterLikeParam":{"in":"query","name":"filterLike","schema":{"type":"object","additionalProperties":{"type":"string"}},"description":"``` Hashmap {  [property-name]: 'filter text',\n  [property-name-2]: 'filter text 2'\n} ```"},"filterBeforeParam":{"in":"query","name":"filterBefore","schema":{"type":"object","additionalProperties":{"type":"string"}},"description":"``` Hashmap {  [property-name]: \"2020-01-01T00:00:00.000Z\",\n  [property-name-2]: \"2020-02-01\"\n} ```"},"filterAfterParam":{"in":"query","name":"filterAfter","schema":{"type":"object","additionalProperties":{"type":"string"}},"description":"``` Hashmap {  [property-name]: \"2020-01-01T00:00:00.000Z\",\n  [property-name-2]: \"2020-02-01\"\n} ```"},"IntegrationIdParam":{"name":"integrationId","in":"path","schema":{"type":"string"},"required":true},"WebhookIdParam":{"in":"path","name":"webhookId","schema":{"type":"string"},"required":true},"WebhookUrl":{"in":"query","name":"url","schema":{"type":"string"}},"ThemeIdParam":{"in":"path","name":"themeId","schema":{"type":"string"},"required":true},"AssetKeyParam":{"in":"path","name":"assetKey","schema":{"type":"string"},"required":true},"ScriptId":{"in":"path","name":"scriptId","schema":{"type":"string"},"required":true},"SmartrrTokenIDParam":{"in":"path","name":"tokenId","schema":{"type":"string"},"required":true},"IncentiveIdParam":{"in":"path","name":"incentiveId","schema":{"type":"string"},"required":true},"CustomerPurchaseStateIdParam":{"in":"path","name":"customerPurchaseStateId","schema":{"type":"string"},"required":true},"ProductIdParam":{"in":"path","name":"productId","schema":{"type":"string"},"required":true},"CustomerRelationshipIdParam":{"in":"path","name":"customerRelationshipId","schema":{"type":"string"},"required":true},"LineItemIdParam":{"in":"path","name":"lineItemId","schema":{"type":"string"},"required":true},"ShopifySubscriptionIdParam":{"in":"path","name":"shopifySubscriptionId","schema":{"type":"string"},"required":true},"DiscountVendorIdParam":{"in":"path","name":"discountVendorId","schema":{"type":"string"},"required":true},"CacheParam":{"in":"query","name":"cache","schema":{"type":"string","enum":["true","false"]}},"PurchaseStateActiveParam":{"in":"query","name":"active","schema":{"type":"boolean"},"required":false},"SellingPlanNextOrderDatePreviewSellingPlanIdQueryParam":{"in":"query","name":"sellingPlanId","required":true,"description":"Target selling plan — Shopify GID or numeric id (as string)","schema":{"type":"string"}},"CancellationReasonIdParam":{"in":"path","name":"cancellationReasonId","schema":{"type":"string"},"required":true},"ShopifyDomainParam":{"in":"header","name":"x-shopify-shop-domain","schema":{"type":"string"},"description":"Shopify domain (example: smartrr-checkout.myshopify.com)"}},"securitySchemes":{"smartrrAccessToken":{"type":"apiKey","in":"header","name":"x-smartrr-access-token"}}},"openapi":"3.0.0","info":{"version":"1.0.0","title":"Smartrr API"},"servers":[{"url":"https://smartrr-dev.local.com"}],"security":[{"smartrrAccessToken":[]}],"paths":{"/vendor/integrations/stripe":{"get":{"tags":["Integrations"],"summary":"Get Stripe Integration","responses":{"200":{"description":"Payout method object","content":{"application/json":{"schema":{"nullable":true,"$ref":"#/components/schemas/IPayoutMethod"}}}}}}},"/vendor/integrations/stripe/publishable":{"get":{"tags":["Integrations"],"summary":"Get Stripe Public Key","responses":{"200":{"description":"Public key","content":{"application/json":{"schema":{"type":"object","properties":{"publicKey":{"type":"string"}}}}}}}}},"/vendor/integrations/stripe/authorize":{"get":{"tags":["Integrations"],"summary":"Get Stripe Authorize (Redirect URL)","parameters":[{"in":"query","name":"code","schema":{"type":"string"}},{"in":"query","name":"state","schema":{"type":"string"}}],"description":"Contacts Stripe Oauth to get token and saves payment method to DB\nHTML page is used to send a stripe authorization token back to the window opener.\n``` window.opener.postMessage({  \"access_token\":\"...\",\n  \"livemode\":false,\n  \"refresh_token\":\"...\",\n  \"token_type\":\"bearer\",\n  \"stripe_publishable_key\":\"...\",\n  \"stripe_user_id\":\"...\",\n  \"scope\":\"read_write\"\n}, \"*\") ```","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"string"}}}}}}},"/vendor/integrations/stripe/deauthorize":{"post":{"tags":["Integrations"],"summary":"Delete Stripe Authorization","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IPayoutMethod"}}}}}}}},"/vendor/integrations/recharge/customer-processed-count":{"get":{"tags":["Integrations"],"summary":"Get Recharge Customer Processed Count","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"processedCount":{"type":"number"}},"required":["processedCount"]}}}}}}},"/vendor/integrations/recharge/customers":{"get":{"tags":["Integrations"],"summary":"Get Recharge Customers","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IReChargeCustomerTableData"}}},"required":["data"]}]}}}}}}},"/vendor/integrations/recharge/purchase-states":{"get":{"tags":["Integrations"],"summary":"Get Recharge Purchase States","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/PaginationResult"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IReChargePurchaseStateTableData"}}},"required":["data"]}]}}}}}}},"/vendor/integrations/recharge/customers/{rechargeCustomerId}/retry":{"put":{"tags":["Integrations"],"summary":"Retry Recharge Integration","parameters":[{"in":"path","name":"rechargeCustomerId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/IDataStream"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/IReChargeStreamEmission"}}}}]}}}}}}},"/integrations/recharge/purchase-state/{customerPurchaseStateId}/migrate":{"put":{"tags":["Integrations"],"summary":"Migrate Recharge Purchase State","parameters":[{"in":"path","name":"customerPurchaseStateId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseState"}}}}}}},"/integrations/recharge/purchase-state/{customerPurchaseStateId}/rollback":{"put":{"tags":["Integrations"],"summary":"Rollback Recharge Purchase State","parameters":[{"in":"path","name":"customerPurchaseStateId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseState"}}}}}}},"/vendor/webhooks-listening":{"get":{"summary":"Get All Shopify Webhooks","tags":["Webhooks"],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IWebhooksListeningRes"}}}}}},"post":{"summary":"Listen to Shopify Webhooks","tags":["Webhooks"],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IWebhooksListeningRes"}}}}}},"delete":{"summary":"Stop Listening to Shopify Webhooks","tags":["Webhooks"],"responses":{"200":{"description":"Successful response"}}}},"/vendor/webhook":{"get":{"tags":["Webhooks"],"summary":"Get webhooks for current organization","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IWebhook"}}}}}}},"post":{"tags":["Webhooks"],"summary":"Create a new webhook","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IWebhookCreate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IWebhook"}}}}}},"delete":{"tags":["Webhooks"],"summary":"Delete existing webhooks by specified parameters","parameters":[{"$ref":"#/components/parameters/WebhookUrl"}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/webhook/{webhookId}":{"put":{"tags":["Webhooks"],"summary":"Edit existing webhook","parameters":[{"$ref":"#/components/parameters/WebhookIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IWebhookCreate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IWebhook"}}}}}},"delete":{"tags":["Webhooks"],"summary":"Delete existing webhook","parameters":[{"$ref":"#/components/parameters/WebhookIdParam"}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/theme/{themeId}/asset":{"get":{"summary":"Get Theme Assets","tags":["Theme"],"parameters":[{"$ref":"#/components/parameters/ThemeIdParam"},{"in":"query","name":"contentTypes","description":"Comma separated list of content types","schema":{"type":"string"}}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IShopifyAsset"}}}}}}},"put":{"summary":"Modify Theme Asset","tags":["Theme"],"parameters":[{"$ref":"#/components/parameters/ThemeIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IShopifyAssetCreate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IShopifyAsset"}}}}}}},"/vendor/theme/{themeId}/portal-token":{"put":{"summary":"Create Portal Token Asset","tags":["Theme"],"parameters":[{"$ref":"#/components/parameters/ThemeIdParam"}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/theme/{themeId}/asset/{assetKey}":{"delete":{"summary":"Delete Theme Asset","tags":["Theme"],"parameters":[{"$ref":"#/components/parameters/ThemeIdParam"},{"in":"path","name":"assetKey","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/customer-portal-theme":{"get":{"summary":"Get Customer Portal Theme","tags":["Theme"],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"nullable":true,"$ref":"#/components/schemas/ICustomerPortalTheme"}}}}}},"post":{"summary":"Modify Customer Portal Theme","tags":["Theme"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICustomerPortalThemePostReq"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICustomerPortalThemeFromDb"}}}}}}},"/vendor/sms-addons":{"get":{"summary":"Get SMS Addons","tags":["SMS Addon"],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ISmsAddon"}}}}}}},"post":{"summary":"Create SMS Addon","tags":["SMS Addon"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmsAddonCreate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmsAddon"}}}}}}},"/vendor/smartrr-script":{"get":{"tags":["Smartrr Script"],"summary":"Get all Smartrr Script","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IScript"}}}}}}},"post":{"tags":["Smartrr Script"],"summary":"Add new Smartrr Script","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IScriptCreate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IScript"}}}}}}},"/vendor/smartrr-script/{scriptId}":{"put":{"tags":["Smartrr Script"],"summary":"Update existing Smartrr Script","parameters":[{"$ref":"#/components/parameters/ScriptId"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IScriptCreate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IScript"}}}}}},"delete":{"tags":["Smartrr Script delete"],"summary":"Delete Smartrr Script","parameters":[{"$ref":"#/components/parameters/ScriptId"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"boolean"}}}}}}},"/vendor/smartrr-api-token":{"get":{"summary":"Get API Tokens","tags":["Smartrr API Token"],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"tokens":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrApiToken"}}},"required":["tokens"]}}}}}},"post":{"summary":"Create API Token","tags":["Smartrr API Token"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"smartrrApiTokenConfig":{"$ref":"#/components/schemas/ICreateSmartrrApiToken"}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"token":{"$ref":"#/components/schemas/ISmartrrApiToken"}},"required":["token"]}}}}}}},"/vendor/smartrr-api-token/{tokenId}":{"put":{"summary":"Modify API Token","tags":["Smartrr API Token"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"smartrrApiTokenConfig":{"$ref":"#/components/schemas/ICreateSmartrrApiToken"}}}}}},"parameters":[{"$ref":"#/components/parameters/SmartrrTokenIDParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"token":{"$ref":"#/components/schemas/ISmartrrApiToken"}}}}}}}},"delete":{"summary":"Delete API Token","tags":["Smartrr API Token"],"parameters":[{"$ref":"#/components/parameters/SmartrrTokenIDParam"}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/shopify-historical-orders-sync/complete":{"post":{"tags":["Shopify Stream"],"summary":"Complete Historical Orders Sync","responses":{"200":{"description":"Successful response"}}}},"/vendor/shopify-subscription-contract-sync":{"post":{"tags":["Shopify Stream"],"summary":"Start subscription Contract Sync","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"syncDate":{"$ref":"#/components/schemas/ISODateString"},"shopifySubscriptionContractEmission":{}},"required":["syncDate","shopifySubscriptionContractEmission"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{}}}}}}},"/vendor/shopify-subscription-contract-sync/complete":{"post":{"tags":["Shopify Stream"],"summary":"Complete Subscription Contract Sync","responses":{"200":{"description":"Successful response"}}}},"/vendor/rewards/redeem/incentive/{incentiveId}/purchase-state/{customerPurchaseStateId}":{"post":{"tags":["Rewards"],"summary":"Redeem incentive","parameters":[{"$ref":"#/components/parameters/IncentiveIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedeemIncentiveResponse"}}}},"404":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/rewards/redeem/product/{productId}/purchase-state/{customerPurchaseStateId}":{"post":{"tags":["Rewards"],"summary":"Redeem product","parameters":[{"$ref":"#/components/parameters/ProductIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedeemIncentiveResponse"}}}},"404":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/purchasable-collection":{"get":{"tags":["Purchasable Collection"],"description":"Get all Purchasable Collections","responses":{"200":{"description":"Successful response, list of collections","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IPurchasableCollection"}}}}}}}},"/vendor/purchasable":{"get":{"tags":["Purchasables"],"description":"Get all Purchasables","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response, list of purchases with pagination data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchasablePaginatedResponse"}}}}}},"put":{"tags":["Purchasables"],"description":"Update a purchasable","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"purchasable":{"$ref":"#/components/schemas/IPurchasable"}},"required":["purchasable"]}}}},"responses":{"200":{"description":"Successful response, list of purchases","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchasable"}}}}}}},"/vendor/purchasable/{id}":{"get":{"tags":["Purchasables"],"description":"Get a Single Purchasable","parameters":[{"in":"path","name":"id","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response, list of purchases","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchasable"}}}}}}},"/vendor/oldest-product-processed-date":{"get":{"tags":["Purchasables"],"summary":"Get Oldest Product Processed Date","responses":{"200":{"description":"Successful response, list of purchases","content":{"application/json":{"schema":{"type":"object","properties":{"oldestProductProcessedDate":{"$ref":"#/components/schemas/ISODateString"}}}}}}}}},"/vendor/phone":{"get":{"tags":["Phone"],"summary":"Get Phone","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPhoneDB"}}}}}},"post":{"tags":["Phone"],"summary":"Add Phone Details","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPhone"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPhoneDB"}}}}}}},"/vendor/organizations":{"get":{"tags":["Organization"],"summary":"Get list of organization the user is a part of","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IOrganization"}}}}}}}},"/vendor/billing-time":{"post":{"tags":["Organization"],"summary":"Config Billing Time","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganizationBillingTimeReq"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}}}}},"/vendor/billing-retry-config":{"post":{"tags":["Organization"],"summary":"Config Billing Retry","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganizationBillingRetryConfigReq"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}}}}},"/vendor/out-of-stock-config":{"post":{"tags":["Organization"],"summary":"Config Out of Stock Behavior","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganizationOutOfStockBehavior"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}}}}},"/vendor/confirmation-days-config":{"post":{"tags":["Organization"],"summary":"Config Org Confirmation Days","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganizationConfirmationDaysConfigReq"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}}}}},"/vendor/cancellation-reason-message":{"post":{"tags":["Organization"],"summary":"Cancellation Reason Message","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}}}}},"/vendor/out-of-stock-item-removal/update":{"put":{"tags":["Organization"],"summary":"Out of stock item removal update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outOfStockItemRemovalEnabled":{"type":"boolean"}},"required":["outOfStockItemRemovalEnabled"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/billing-recovery-method/update":{"put":{"tags":["Organization"],"summary":"Billing recovery method update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"billingRecoveryMethod":{"type":"string","enum":["location_safe_payment_methods","all_payment_methods"]}},"required":["billingRecoveryMethod"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IOrganization"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/order":{"get":{"tags":["Order"],"summary":"Get Orders","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmartrrOrderWithCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/order/formatted":{"get":{"tags":["Order"],"summary":"Get Formatted Orders","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmartrrOrderWithCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/orders/{shopifyId}":{"get":{"tags":["Order"],"summary":"Get Order by Shopify order ID","parameters":[{"in":"path","name":"shopifyId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmartrrOrderWithCustomerRelationship"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/order/{orderId}/open":{"post":{"tags":["Order"],"summary":"Open Order","parameters":[{"in":"path","name":"orderId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/order/{orderId}":{"delete":{"tags":["Order"],"summary":"Close Order","parameters":[{"in":"path","name":"orderId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/integrations":{"get":{"tags":["Integrations"],"summary":"Get Integrations","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IOrganizationIntegration"}}}}}}}},"/vendor/integration":{"put":{"tags":["Integrations"],"summary":"Edit Integration","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"integrationId":{"$ref":"#/components/schemas/OrganizationIntegrationId"},"publicApiKey":{"type":"string"},"secretApiKey":{"type":"string"}},"required":["integrationId","publicApiKey"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IOrganizationIntegration"}}}}}}}},"/vendor/integration/{integrationId}":{"delete":{"tags":["Integrations"],"summary":"Delete An Integration","parameters":[{"$ref":"#/components/parameters/IntegrationIdParam"}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/extensions/api-token":{"get":{"tags":["Extensions API"],"summary":"Retrieve the customer portal token for the auth shop","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"customerPortalApiToken":{"type":"string"}},"required":["customerPortalApiToken"]}}}}}}},"/vendor/extensions/update-shop":{"post":{"tags":["Extensions API"],"summary":"Updates the shop with the tokens required for extensions API","responses":{"200":{"description":"Successful response"}}}},"/vendor/customer-email-config":{"get":{"tags":["Customer Email Config"],"summary":"Get Email Config","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"nullable":true,"$ref":"#/components/schemas/ICustomerEmailConfigDb"}}}}}},"post":{"tags":["Customer Email Config"],"summary":"Set Email Config","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"updatedEmailConfigProperties":{"$ref":"#/components/schemas/ICustomerEmailConfig"}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICustomerEmailConfigDb"}}}}}}},"/vendor/purchase-state":{"get":{"tags":["Purchase State"],"summary":"Get Purchase States","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationshipPaginatedResponse"}}}}}},"post":{"tags":["Purchase State"],"summary":"Create Purchase State","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStatePost"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/purchase-state-line-item":{"get":{"tags":["Purchase State Line Item"],"summary":"Get Purchase State Line Items","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateLineItemWithAsymmetricMetadataPaginatedResponse"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/line-item/{lineItemId}":{"put":{"tags":["Purchase State Line Item"],"summary":"Update Line Item on Purchase State","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"},{"$ref":"#/components/parameters/LineItemIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateLineItemPut"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/bulk-update-line-items":{"put":{"tags":["Purchase State Line Item"],"summary":"Bulk Update Line Items on Purchase State","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"lineItems":{"type":"array","items":{"$ref":"#/components/schemas/IPurchaseStateLineItemPut"}}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/line-item/{lineItemId}/swap":{"post":{"tags":["Purchase State Line Item"],"summary":"Swap purchase state line items","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"},{"$ref":"#/components/parameters/LineItemIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateLineItemSwapPost"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/line-item/{lineItemId}/remove":{"put":{"tags":["Purchase State Line Item"],"summary":"Remove Line Item from Purchase State","description":"for the deletion of line items by vendor (only allow if the cps has more than one line item)","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"},{"$ref":"#/components/parameters/LineItemIdParam"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/bulk-remove-line-items":{"put":{"tags":["Purchase State Line Item"],"summary":"Bulk Remove Line Items from Purchase State","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"lineItemIds":{"type":"array","items":{"type":"string"}}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/shipping-price":{"put":{"tags":["Purchase State"],"summary":"Update shipping price on Purchase State","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"price":{"oneOf":[{"type":"number"},{"type":"string"}]}},"required":["price"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/update-external-subscription-dates":{"put":{"tags":["Purchase State"],"summary":"Update external subscription dates on purchase state","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"externalSubscriptionCreatedDate":{"type":"string"},"externalSubscriptionCancelledAt":{"type":"string"}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/address":{"put":{"tags":["Purchase State"],"summary":"Update Address on Purchase State","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IMailingAddressJson"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/pause":{"put":{"tags":["Purchase State"],"summary":"Pause Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"unpauseDate":{"$ref":"#/components/schemas/ISODateString"}},"required":["unpauseDate"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/purchase-state/bulk-pause":{"put":{"tags":["Purchase State"],"summary":"Bulk Pause Purchases","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateBulk"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationshipPaginatedResponse"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/cancel":{"put":{"tags":["Purchase State"],"summary":"Cancel Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"reasonId":{"type":"string"}},"required":["reasonId"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/purchase-state/bulk-cancel":{"put":{"tags":["Purchase State"],"summary":"Bulk Cancel Purchases","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateBulk"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationshipPaginatedResponse"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/activate":{"put":{"tags":["Purchase State"],"summary":"Activate Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateActivatePut"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/purchase-state/bulk-unpause":{"put":{"tags":["Purchase State"],"summary":"Bulk Activate Purchases","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateBulk"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationshipPaginatedResponse"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/skip":{"put":{"tags":["Purchase State"],"summary":"Skip Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateSkipPut"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/bulk-skip":{"put":{"tags":["Purchase State"],"summary":"Bulk Skip Purchases","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateDatesBulk"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/unskip":{"put":{"tags":["Purchase State"],"summary":"Unskip Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateSkipPut"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/bulk-unskip":{"put":{"tags":["Purchase State"],"summary":"Bulk Unskip Purchases","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateDatesBulk"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/next-billing-date":{"put":{"tags":["Purchase State"],"summary":"Set Next Billing Date on Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"},{"in":"query","name":"sendNow","schema":{"type":"string"},"required":false,"description":"Optional query parameter to immediately send the next order"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateNextBillingDatePut"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/purchase-state/bulk-set-nextBillingDate":{"put":{"tags":["Purchase State"],"summary":"Bulk Set Next Billing Date on Purchases","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateBulkNextDate"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"newCustomerPurchaseState":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationshipPaginatedResponse"}},"required":["newCustomerPurchaseState"]}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/selling-plan":{"put":{"tags":["Purchase State"],"summary":"Set Selling Plan on Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateSellingPlanPut"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/selling-plan-next-order-date-preview":{"get":{"tags":["Purchase State"],"summary":"Preview next order date for a selling plan (read-only)","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"},{"$ref":"#/components/parameters/SellingPlanNextOrderDatePreviewSellingPlanIdQueryParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISellingPlanNextOrderDatePreviewResponse"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/discount":{"post":{"tags":["Purchase State"],"summary":"Apply Discount on Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateDiscountPost"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/line-item":{"post":{"tags":["Purchase State Line Item"],"summary":"Add Line Item to Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateLineItemPost"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/bulk-add-line-items":{"post":{"tags":["Purchase State Line Item"],"summary":"Bulk Add Line Items to Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"lineItems":{"type":"array","items":{"$ref":"#/components/schemas/IPurchaseStateLineItemPost"}}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/{customerPurchaseStateId}/discount/{discountVendorId}":{"delete":{"tags":["Purchase State"],"summary":"Delete Discount on Purchase","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/CustomerPurchaseStateIdParam"},{"$ref":"#/components/parameters/DiscountVendorIdParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/customer/{customerRelationshipId}/purchase-state/":{"get":{"tags":["Purchase State"],"summary":"Get Purchase States By Customer ID","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"},{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"},{"$ref":"#/components/parameters/filterInParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationshipPaginatedResponse"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/purchase-state/{shopifySubscriptionId}":{"get":{"tags":["Purchase State"],"summary":"Get Purchase State By Shopify Subscription ID","parameters":[{"$ref":"#/components/parameters/ShopifySubscriptionIdParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPurchaseStateWithCustomerRelationship"}}}}}}},"/vendor/purchase-state/{shopifySubscriptionId}/orders":{"get":{"tags":["Purchase State"],"summary":"Get Orders By Shopify Subscription ID","parameters":[{"$ref":"#/components/parameters/ShopifySubscriptionIdParam"},{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmartrrOrderWithCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/purchase-state/{shopifySubscriptionId}/events":{"get":{"tags":["Purchase State"],"summary":"Get Events by Shopify Subscription ID. Returns up to 250 most recent events","parameters":[{"$ref":"#/components/parameters/ShopifySubscriptionIdParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ISubscriptionEvent"}}}}}}}},"/vendor/purchase-state/{shopifySubscriptionId}/bills":{"get":{"tags":["Purchase State"],"summary":"Get Bills By Shopify Subscription ID","parameters":[{"$ref":"#/components/parameters/ShopifySubscriptionIdParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/oldest-subscription-contract-processed-date":{"get":{"tags":["Purchase State"],"summary":"Get Oldest Contract Processed Date","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"oldestContractProcessedDate":{"$ref":"#/components/schemas/ISODateString"}}}}}}}}},"/vendor/countries/data":{"get":{"tags":["Purchase State"],"summary":"Get List of Countries","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrCountry"}}}}}}}},"/vendor/selling-plan-group":{"get":{"tags":["Purchase State"],"summary":"Get Selling Plan Groups","parameters":[{"$ref":"#/components/parameters/CacheParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrSellingPlanGroup"}}}}}}}},"/vendor/add-ons-config":{"get":{"tags":["Purchase State"],"summary":"Get Addons Config","parameters":[{"$ref":"#/components/parameters/CacheParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrAddOnsConfig"}}}}}}}},"/vendor/selling-plan-configs":{"get":{"tags":["Purchase State"],"summary":"Get all programs for a shop","parameters":[{"$ref":"#/components/parameters/CacheParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"sellingPlanGroups":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrSellingPlanGroup"}},"addOnConfigs":{"type":"array","items":{"$ref":"#/components/schemas/ISmartrrAddOnsConfig"}},"sequentialGroupIds":{"type":"array","items":{"type":"string"},"description":"Array of selling plan group IDs that have sequential configurations"}},"required":["sellingPlanGroups","addOnConfigs","sequentialGroupIds"]}}}}}}},"/vendor/customer-relationship":{"get":{"tags":["Customer"],"summary":"Get Customer Relationship","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterEqualsParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPaginatedCustomerRelationshipShallow"}}}}}}},"/vendor/customer-relationship/:customerShopifyId":{"get":{"tags":["Customer"],"summary":"Get Customer Relationship by Shopify ID","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICustomerRelationshipShallowWithTieredPoints"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/customer-relationship/import":{"post":{"tags":["Customer"],"summary":"Import Customer Relationship from Shopify Customer","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"currency":{"$ref":"#/components/schemas/CurrencyCode"},"stripeCustomerId":{"type":"string"}},"required":["email","currency"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICustomerRelationshipShallow"}}}}}}},"/vendor/customer-relationship/payment-methods/import":{"post":{"tags":["Customer"],"summary":"Import Customer's payment methods from Shopify","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"customerShopifyId":{"type":"string"}},"required":["customerShopifyId"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IPaymentMethod"}}}}}}}},"/vendor/customer-relationship/{customerRelationshipId}/custom-attributes":{"patch":{"tags":["Customer"],"summary":"Update Custom Attribute","parameters":[{"$ref":"#/components/parameters/CustomerRelationshipIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"newAttribute":{"type":"object","description":"``` Hashmap {  [property-name]: 'value',\n  [property-name-2]: 'value'\n} ```","additionalProperties":{"type":"string"}}},"required":["newAttribute"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"}}}}}}}},"/vendor/customer-relationship/{customerRelationshipId}/payment-methods":{"get":{"tags":["Customer"],"summary":"Get Payment methods","parameters":[{"in":"path","name":"customerRelationshipId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IPaymentMethod"}}}}}}}},"/vendor/customer/{customerRelationshipId}/ccpa":{"get":{"tags":["Customer"],"summary":"Remove customer data from Smartrr","parameters":[{"in":"path","name":"customerRelationshipId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/customer/:custRelId/orders":{"get":{"tags":["Customer"],"summary":"Get Orders by customer ID","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/filterLikeParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISmartrrOrderWithCustomerRelationshipPaginatedResponse"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/customer-relationship/{customerShopifyId}/referral-link":{"get":{"tags":["Customer"],"summary":"Get customer referral code and link","parameters":[{"in":"path","name":"customerShopifyId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","example":"SMARTRR-REFERRAL0000795774045835182890"},"link":{"type":"string","example":"https://example-store.myshopify.com/discount/SMARTRR-REFERRAL0000795774045835182890"}}}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/vendor/customer-relationship/{customerRelationshipId}/orgPoints":{"put":{"tags":["Customer"],"summary":"Add loyalty points to customer","parameters":[{"in":"path","name":"customerRelationshipId","schema":{"type":"string"},"required":true}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"points":{"type":"number"},"reason":{"type":"string"}},"required":["points"]}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"number"}}}}}}},"/vendor/cancellation-reason":{"post":{"tags":["Cancellation Reason"],"summary":"Add Cancellation Reason","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICancellationReason"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICancellationReason"}}}}}}},"/vendor/cancellation-reasons":{"get":{"tags":["Cancellation Reason"],"summary":"Get Cancellation Reasons","responses":{"200":{"description":"Successful response, list of cancellation reasons","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ICancellationReason"}}}}}}}},"/vendor/cancellation-reason/{cancellationReasonId}":{"put":{"tags":["Cancellation Reason"],"summary":"Update Cancellation Reason","parameters":[{"$ref":"#/components/parameters/CancellationReasonIdParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICancellationReason"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ICancellationReason"}}}}}},"delete":{"tags":["Cancellation Reason"],"summary":"Delete Cancellation Reason","parameters":[{"$ref":"#/components/parameters/CancellationReasonIdParam"}],"responses":{"200":{"description":"Successful response"}}}},"/vendor/user-cancellation":{"post":{"tags":["Cancellation Reason"],"summary":"Add User Cancellation Reason","description":"For tracking user cancellation reasons retention data","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IUserCancellation"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IUserCancellation"}}}}}}},"/vendor/bill":{"get":{"tags":["Bill"],"summary":"Get Bills","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/bill/{billId}/retry":{"post":{"tags":["Bill"],"summary":"Retry a bill","parameters":[{"in":"path","name":"billId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationship"}}}}}}},"/vendor/bill/bulk-retry":{"put":{"tags":["Bill"],"summary":"Bulk Retry the Bills","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"billIds":{"type":"array","items":{"type":"string"}}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/bill/bulk-cancel":{"put":{"tags":["Bill"],"summary":"Bulk Cancel the Bills","parameters":[{"$ref":"#/components/parameters/pageSizeParam"},{"$ref":"#/components/parameters/pageNumberParam"},{"$ref":"#/components/parameters/orderByParam"},{"$ref":"#/components/parameters/filterLikeParam"},{"$ref":"#/components/parameters/filterBeforeParam"},{"$ref":"#/components/parameters/filterAfterParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"billIds":{"type":"array","items":{"type":"string"}}}}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationshipPaginatedResponse"}}}}}}},"/vendor/bill/{billId}/cancel":{"post":{"tags":["Bill"],"summary":"Cancels a bill","parameters":[{"in":"path","name":"billId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IBillWithPurchStAndCustomerRelationship"}}}}}}},"/vendor/bill/{billId}/history":{"get":{"tags":["Bill"],"summary":"Gets bill audit history","parameters":[{"in":"path","name":"billId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/IBillAudit"}}}}}}}},"/vendor/auth-tickets/issue":{"post":{"tags":["Auth"],"description":"Issues an Auth Ticket","responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IPostAuthTicketsIssueRes"}}}}}}},"/vendor/analytics-simple":{"get":{"tags":["Analytics Simple"],"summary":"Get Analytics Simple","description":"Get all Simple Analytics for org.  <br/><br/>\nYou will pass in a `startDate` and `endDate` to filter for subscriptions active in that date range.\n<br/><br/> The response will contain active subscription count and active subscriber count for each day in the date range.","parameters":[{"in":"query","name":"startDate","schema":{"$ref":"#/components/schemas/ISODateString"},"description":"Include orders only after this date. See endpoint description for more info on how filters work."},{"in":"query","name":"endDate","schema":{"$ref":"#/components/schemas/ISODateString"},"description":"Include orders only after this date. See endpoint description for more info on how filters work."}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IAnalyticsSimpleRes"}}}}}}},"/vendor/setup":{"get":{"tags":["Setup"],"description":"Get Setup status for organization","responses":{"200":{"description":"Successful response, Status object","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISetup"}}}}}},"put":{"tags":["Setup"],"description":"Update Setup status for organization","responses":{"200":{"description":"Successful response, Status object","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ISetup"}}}}}}},"/vendor/auth/app-public-key":{"get":{"tags":["Auth"],"summary":"Get Public Key","description":"Gets Public Key using shop domain","parameters":[{"$ref":"#/components/parameters/ShopifyDomainParam"}],"responses":{"200":{"description":"Successful response, list of purchases","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IAppPublicKeyResponse"}}}}}}},"/vendor/auth/session":{"get":{"tags":["Auth"],"summary":"Get Auth Session","description":"Gets user auth session if logged in (checked upon initial get request)","parameters":[{"$ref":"#/components/parameters/ShopifyDomainParam"}],"responses":{"200":{"description":"Successful response, list of purchases","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IAuthSessionResponse"}}}}}}},"/vendor/auth/portal-session":{"get":{"tags":["Auth"],"summary":"Get Vendor Portal Session","description":"Gets vendor portal session if logged in (checked upon initial get request)","parameters":[{"$ref":"#/components/parameters/ShopifyDomainParam"}],"responses":{"200":{"description":"Successful response, list of information needed by vendor portal for initial setup","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IAuthVendorPortalResponse"}}}}}}},"/vendor/auth/logout":{"get":{"tags":["Auth"],"summary":"Logout","description":"Logs out and wipes auth state","responses":{"200":{"description":"Success","content":{"application/json":{"schema":{}}}}}}}}}