types-magic-api 0.1.41 → 0.1.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -61,7 +61,7 @@ export interface CreateCustomerCheckoutReq {
61
61
  * API Name: /api/customer/checkout/create
62
62
  */
63
63
  export interface CreateCustomerCheckoutRes {
64
- checkout: Model.ShopifyCheckoutRes;
64
+ checkout: Model.ICart;
65
65
  }
66
66
  export interface ReorderReq {
67
67
  orderId: string;
@@ -170,7 +170,7 @@ export interface CustomerCreateReq {
170
170
  email: string;
171
171
  firstName?: string;
172
172
  lastName?: string;
173
- password: string;
173
+ password?: string;
174
174
  phone?: string;
175
175
  language: string;
176
176
  }
@@ -185,7 +185,7 @@ export interface CustomerCreateRes {
185
185
  */
186
186
  export interface addCartDeliveryAddressReq {
187
187
  cartId: string;
188
- addresses: Array<{
188
+ addresses: {
189
189
  selected: boolean;
190
190
  address: {
191
191
  deliveryAddress: {
@@ -201,7 +201,7 @@ export interface addCartDeliveryAddressReq {
201
201
  countryCode: string;
202
202
  };
203
203
  };
204
- }>;
204
+ };
205
205
  }
206
206
  /**
207
207
  * API Name: /api/customer/get
@@ -188,6 +188,7 @@ export interface ICustomerProduct {
188
188
  description: string;
189
189
  descriptionHtml: string;
190
190
  featuredImage: Image | null;
191
+ image: Image | null;
191
192
  handle: string;
192
193
  id: string;
193
194
  priceRangeV2: PriceRange;
@@ -240,7 +241,7 @@ export interface ICustomerProductsVariant {
240
241
  unitPrice: Money | null;
241
242
  weight: number | null;
242
243
  sku?: string;
243
- weightUnit: WeightUnit;
244
+ weightUnit: WeightUnit | null;
244
245
  }
245
246
  export interface MailingAddress {
246
247
  address1: string | null;
@@ -314,7 +315,7 @@ export interface ShopifyCustomerRes {
314
315
  }
315
316
  export interface cartDeliveryAddressReq {
316
317
  id: string;
317
- addresses: Array<{
318
+ addresses: {
318
319
  selected: boolean;
319
320
  address: {
320
321
  deliveryAddress: {
@@ -330,7 +331,7 @@ export interface cartDeliveryAddressReq {
330
331
  countryCode: string;
331
332
  };
332
333
  };
333
- }>;
334
+ };
334
335
  }
335
336
  export interface cartDeliveryFrontAddressRes {
336
337
  data: {
@@ -355,8 +356,8 @@ export interface cartDeliveryAddressRes {
355
356
  */
356
357
  export interface CustomerProviderLoginReq {
357
358
  email: string;
358
- password?: string | null;
359
- otp?: string | null;
359
+ password?: string;
360
+ otp?: string;
360
361
  }
361
362
  /**
362
363
  * API Name: /api/customer/login
@@ -603,6 +604,7 @@ export interface CustomerOrder {
603
604
  email: string | null;
604
605
  financialStatus: string | null;
605
606
  fulfillmentStatus: string | null;
607
+ paymentGatewayNames: string[];
606
608
  name: string | null;
607
609
  orderNumber: string | null;
608
610
  phone: string | null;
@@ -618,6 +620,7 @@ export interface CustomerOrder {
618
620
  }[];
619
621
  totalPrice: Money;
620
622
  totalRefunded: Money;
623
+ subtotalPrice: Money;
621
624
  totalShippingPrice: Money;
622
625
  totalTax: Money;
623
626
  lineItems: {
@@ -641,200 +644,54 @@ export interface CustomerOrder {
641
644
  }[];
642
645
  };
643
646
  }
644
- export interface ShopifyCheckoutAddress {
645
- address1: string | null;
646
- address2: string | null;
647
- city: string | null;
648
- company: string | null;
649
- country: string | null;
650
- first_name: string | null;
651
- last_name: string | null;
652
- phone: string | null;
653
- province: string | null;
654
- zip: string | null;
655
- }
656
- export interface ShopifyCheckoutLine {
657
- variant_id: string;
658
- quantity: number;
659
- requires_shipping: boolean;
660
- }
661
647
  export interface ShopifyCheckoutReq {
662
- storeId: string;
663
- line_items: Array<ShopifyCheckoutLine>;
664
- customer_id: string;
665
- email: string | null;
666
- shipping_line: {
667
- handle: string;
668
- } | null;
669
- applied_discount: {
670
- amount: string;
671
- title: string;
672
- description: null;
673
- value: string;
674
- value_type: string;
675
- } | null;
676
- customer_address: ShopifyCheckoutAddress;
677
- token: string | null;
648
+ buyerIdentity: {
649
+ email: string | null;
650
+ };
678
651
  note: string;
652
+ delivery: {
653
+ addresses: {
654
+ selected: boolean;
655
+ address: {
656
+ deliveryAddress: {
657
+ address1: string | null;
658
+ address2?: string | null;
659
+ city: string | null;
660
+ company?: string | null;
661
+ firstName?: string | null;
662
+ lastName?: string | null;
663
+ phone?: string | null;
664
+ provinceCode: string | null;
665
+ zip: string | null;
666
+ countryCode: string | null;
667
+ };
668
+ };
669
+ }[];
670
+ };
671
+ lines: {
672
+ merchandiseId: string;
673
+ quantity: number;
674
+ }[];
679
675
  }
680
676
  export interface ShopifyCheckoutRes {
681
- line_items: Array<{
682
- id: string;
683
- key: string;
684
- product_id: number;
685
- variant_id: number;
686
- sku: string;
687
- vendor: string;
688
- title: string;
689
- variant_title: string;
690
- image_url: string;
691
- taxable: boolean;
692
- requires_shipping: boolean;
693
- gift_card: boolean;
694
- price: string;
695
- compare_at_price: string;
696
- line_price: string;
697
- properties: object;
698
- quantity: number;
699
- grams: number;
700
- fulfillment_service: string;
701
- applied_discounts: Array<string>;
702
- discount_allocations: Array<{
703
- id: string;
677
+ id: string;
678
+ invoiceUrl: string;
679
+ note2: string;
680
+ currencyCode: string;
681
+ lineItems: ICartLine[];
682
+ totalQuantityOfLineItems: number;
683
+ totalPriceSet: {
684
+ shopMoney: {
704
685
  amount: string;
705
- description: string;
706
- created_at: string;
707
- application_type: string;
708
- }>;
709
- tax_lines: Array<{
710
- price: string;
711
- rate: number;
712
- title: string;
713
- channel_liable: boolean;
714
- }>;
715
- }>;
716
- buyer_accepts_marketing: boolean;
717
- customer_id: number | string;
718
- requires_shipping: boolean;
719
- billing_address: {
720
- id: number;
721
- first_name: string;
722
- last_name: string;
723
- phone: string;
724
- compstring: string;
725
- address1: string;
726
- address2: string;
727
- city: string;
728
- province: string;
729
- province_code: string;
730
- country: string;
731
- country_code: string;
732
- zip: string;
733
- };
734
- shipping_address: {
735
- id: number;
736
- first_name: string;
737
- last_name: string;
738
- phone: string;
739
- compstring: string;
740
- address1: string;
741
- address2: string;
742
- city: string;
743
- province: string;
744
- province_code: string;
745
- country: string;
746
- country_code: string;
747
- zip: string;
748
- };
749
- email: string | null;
750
- applied_discount: {
751
- amount: string;
752
- title: string;
753
- description: string;
754
- value: string;
755
- value_type: string;
756
- non_applicable_reason: string;
757
- applicable: boolean;
758
- application_type: string;
759
- };
760
- shipping_line: {
761
- handle: string;
762
- price: string;
763
- title: string;
764
- tax_lines: Array<string>;
686
+ currencyCode: string;
687
+ };
765
688
  };
766
- completed_at: string;
767
- created_at: string;
768
- currency: string;
769
- presentment_currency: string;
770
- customer_locale: string;
771
- device_id: string;
772
- discount_code: object;
773
- discount_codes: Array<string>;
774
- legal_notice_url: string;
775
- location_id: string;
776
- name: string;
777
- note: string;
778
- note_attributes: object;
779
- order_id: string;
780
- order_status_url: string;
781
- order: object;
782
- payment_due: string;
783
- payment_url: string;
784
- payments: Array<string>;
785
- phone: string;
786
- shopify_payments_account_id: string;
787
- privacy_policy_url: string;
788
- refund_policy_url: string;
789
- reservation_time_left: number;
790
- reservation_time: string;
791
- source_identifier: string;
792
- source_name: string;
793
- source_url: string;
794
- subscription_policy_url: string;
795
- subtotal_price: string;
796
- shipping_policy_url: string;
797
- tax_exempt: boolean;
798
- taxes_included: boolean;
799
- terms_of_sale_url: string;
800
- terms_of_service_url: string;
801
- token: string;
802
- total_price: string;
803
- total_tax: string;
804
- total_tip_received: string;
805
- total_line_items_price: string;
806
- updated_at: string;
807
- user_id: string;
808
- web_url: string;
809
- gift_cards: Array<string>;
810
- tax_lines: Array<{
811
- price: string;
812
- rate: number;
813
- title: string;
814
- compare_at: number;
815
- }>;
816
- tax_manipulations: Array<string>;
817
- shipping_rate: {
818
- id: string;
819
- price: string;
820
- title: string;
689
+ subtotalPriceSet: {
690
+ shopMoney: {
691
+ amount: string;
692
+ currencyCode: string;
693
+ };
821
694
  };
822
- credit_card: string;
823
- applied_discounts: Array<{
824
- amount: string;
825
- title: string;
826
- description: string;
827
- value: string;
828
- value_type: string;
829
- non_applicable_reason: string;
830
- applicable: boolean;
831
- application_type: string;
832
- discount_class: string;
833
- non_applicable_code: string;
834
- }>;
835
- discount_violations: Array<string>;
836
- allowedShippingRates: ShopifyShippingRates[];
837
- discount: null | ShopifyDiscount;
838
695
  }
839
696
  export interface ShopifyShippingRates {
840
697
  id: number;
@@ -1011,17 +868,19 @@ export interface ShopifyLoginRes {
1011
868
  redirectUrl: string;
1012
869
  }
1013
870
  export interface getLogoImage {
1014
- shop: {
1015
- brand: {
1016
- logo: {
1017
- image: {
1018
- url: string;
871
+ data: {
872
+ shop: {
873
+ brand: {
874
+ logo: {
875
+ image: {
876
+ url: string;
877
+ };
1019
878
  };
1020
879
  };
1021
- };
1022
- name: string;
1023
- primaryDomain: {
1024
- url: string;
880
+ name: string;
881
+ primaryDomain: {
882
+ url: string;
883
+ };
1025
884
  };
1026
885
  };
1027
886
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "types-magic-api",
3
- "version": "0.1.41",
3
+ "version": "0.1.50",
4
4
  "scripts": {
5
5
  "build": "rimraf dist && tsc",
6
6
  "prepare": "npm run build"