@commercelayer/sdk 7.0.0-rc.10 → 7.0.0-rc.12
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.
- package/lib/{api-DF66S5Gh.d.ts → api-BIiVfx1G.d.ts} +66 -47
- package/lib/{api-2OqdnITp.d.cts → api-xIgvzFhW.d.cts} +66 -47
- package/lib/api.cjs +24 -24
- package/lib/api.d.cts +1 -1
- package/lib/api.d.ts +1 -1
- package/lib/api.js +12 -12
- package/lib/bundle.cjs +26 -26
- package/lib/bundle.cjs.map +1 -1
- package/lib/bundle.d.cts +1 -1
- package/lib/bundle.d.ts +1 -1
- package/lib/bundle.js +13 -13
- package/lib/bundle.js.map +1 -1
- package/lib/chunk-2AFNQJXP.cjs.map +1 -1
- package/lib/chunk-2AMKJ6V7.cjs.map +1 -1
- package/lib/chunk-2HLQW5MF.cjs.map +1 -1
- package/lib/chunk-2HPO4UZA.cjs.map +1 -1
- package/lib/chunk-2JOYLKTP.cjs.map +1 -1
- package/lib/chunk-2KKHO6QF.js.map +1 -1
- package/lib/chunk-2L2ZM3VD.js.map +1 -1
- package/lib/chunk-2P6AFRJL.js.map +1 -1
- package/lib/chunk-2PYM3QGA.js.map +1 -1
- package/lib/chunk-2THU5NEW.cjs.map +1 -1
- package/lib/{chunk-BF7OPORP.js → chunk-2UUZHL2R.js} +2 -2
- package/lib/{chunk-BF7OPORP.js.map → chunk-2UUZHL2R.js.map} +1 -1
- package/lib/chunk-2XGMKMF5.cjs.map +1 -1
- package/lib/chunk-34H2NFDA.js.map +1 -1
- package/lib/chunk-35OHXDG3.cjs.map +1 -1
- package/lib/chunk-3ADITMLN.cjs.map +1 -1
- package/lib/chunk-3ANXNJ6U.cjs.map +1 -1
- package/lib/chunk-3AOPII3W.js.map +1 -1
- package/lib/chunk-3DFZ5QLR.js.map +1 -1
- package/lib/chunk-3I5BJF3J.js.map +1 -1
- package/lib/chunk-3N2MNKA3.js.map +1 -1
- package/lib/chunk-3NWQH32A.js.map +1 -1
- package/lib/chunk-3OBFBFUV.js.map +1 -1
- package/lib/chunk-3PVKJIA3.js.map +1 -1
- package/lib/chunk-3RR27O3T.js.map +1 -1
- package/lib/chunk-3TGZNMLP.cjs.map +1 -1
- package/lib/chunk-3URHH3S6.js.map +1 -1
- package/lib/chunk-3WKN5OCU.cjs.map +1 -1
- package/lib/chunk-3XWE56FL.cjs.map +1 -1
- package/lib/chunk-42DT6ZET.cjs.map +1 -1
- package/lib/chunk-432EXURP.js.map +1 -1
- package/lib/chunk-4IH4EHXT.cjs.map +1 -1
- package/lib/chunk-4KFJUIFD.js.map +1 -1
- package/lib/chunk-4KO5LZ7F.js.map +1 -1
- package/lib/chunk-4L4MGCUZ.js.map +1 -1
- package/lib/chunk-4L73LJKG.js.map +1 -1
- package/lib/{chunk-RWPFE3LF.cjs → chunk-4NI5SICY.cjs} +2 -2
- package/lib/chunk-4NI5SICY.cjs.map +1 -0
- package/lib/chunk-4SCFKFIM.cjs.map +1 -1
- package/lib/chunk-57XXD3GQ.cjs.map +1 -1
- package/lib/chunk-5EXCGVF2.cjs.map +1 -1
- package/lib/chunk-5FZNBGAF.cjs.map +1 -1
- package/lib/{chunk-NMVACSMG.js → chunk-5NMDIVXH.js} +2 -2
- package/lib/chunk-5NMDIVXH.js.map +1 -0
- package/lib/chunk-5OQQBNVB.js.map +1 -1
- package/lib/chunk-5P5Z7NXC.js.map +1 -1
- package/lib/chunk-5R76TU4I.cjs.map +1 -1
- package/lib/chunk-627I2FYX.cjs.map +1 -1
- package/lib/chunk-66JDSPFD.cjs.map +1 -1
- package/lib/chunk-67QVA2J3.cjs.map +1 -1
- package/lib/chunk-6AJSOS56.cjs.map +1 -1
- package/lib/chunk-6B66AQKB.cjs.map +1 -1
- package/lib/chunk-6OHA2TO3.cjs.map +1 -1
- package/lib/chunk-6PWK52UZ.cjs.map +1 -1
- package/lib/chunk-6SCAIB4K.cjs.map +1 -1
- package/lib/chunk-6SOWFGBP.cjs.map +1 -1
- package/lib/chunk-7CQTUOR4.cjs.map +1 -1
- package/lib/chunk-7ISS2FDY.js.map +1 -1
- package/lib/chunk-7JLRB7QH.js.map +1 -1
- package/lib/chunk-7SG4WU7W.js.map +1 -1
- package/lib/chunk-7SZY5BWE.js.map +1 -1
- package/lib/chunk-7VSYXEXL.js.map +1 -1
- package/lib/chunk-7Z2U4MHU.cjs.map +1 -1
- package/lib/chunk-A6BT5FSV.cjs.map +1 -1
- package/lib/chunk-A7BEMDVP.cjs.map +1 -1
- package/lib/chunk-AD73LDFJ.cjs.map +1 -1
- package/lib/{chunk-P3NADEGE.cjs → chunk-AGNIOGQC.cjs} +2 -2
- package/lib/chunk-AGNIOGQC.cjs.map +1 -0
- package/lib/chunk-AIGQRBCY.cjs.map +1 -1
- package/lib/chunk-ANCLAYJV.cjs.map +1 -1
- package/lib/chunk-AQFAND5D.cjs.map +1 -1
- package/lib/chunk-ARIBIRKF.cjs.map +1 -1
- package/lib/{chunk-EJSNNH47.js → chunk-AVJX4OEZ.js} +3 -3
- package/lib/{chunk-EJSNNH47.js.map → chunk-AVJX4OEZ.js.map} +1 -1
- package/lib/chunk-AW3TRBZ7.js.map +1 -1
- package/lib/chunk-AYTBSAHY.js.map +1 -1
- package/lib/chunk-B72FREUL.cjs.map +1 -1
- package/lib/chunk-BBEMCANC.cjs.map +1 -1
- package/lib/{chunk-JN4JL4WT.cjs → chunk-BJYOKKGX.cjs} +2 -2
- package/lib/{chunk-JN4JL4WT.cjs.map → chunk-BJYOKKGX.cjs.map} +1 -1
- package/lib/chunk-BN6XJAZH.cjs.map +1 -1
- package/lib/chunk-BTAKU6V5.cjs.map +1 -1
- package/lib/chunk-CG2ACHGS.js.map +1 -1
- package/lib/chunk-CHYP5F26.js.map +1 -1
- package/lib/chunk-CK6RZLVM.cjs.map +1 -1
- package/lib/chunk-CNCZCBI3.js.map +1 -1
- package/lib/chunk-CRRYP7ZN.js.map +1 -1
- package/lib/chunk-CTXBUDGO.cjs.map +1 -1
- package/lib/chunk-CUNOMS5N.js.map +1 -1
- package/lib/chunk-D26KDUDM.cjs.map +1 -1
- package/lib/chunk-D5E4OGXU.js.map +1 -1
- package/lib/chunk-D7KNSKNJ.js.map +1 -1
- package/lib/chunk-DAXKXBA3.js.map +1 -1
- package/lib/{chunk-465K3KVE.js → chunk-DGW3ZSW6.js} +2 -2
- package/lib/chunk-DGW3ZSW6.js.map +1 -0
- package/lib/chunk-DJ572MZB.cjs.map +1 -1
- package/lib/chunk-DOFPDQMJ.cjs.map +1 -1
- package/lib/chunk-DOGEZ6XX.cjs.map +1 -1
- package/lib/chunk-DSKZRVXS.js.map +1 -1
- package/lib/chunk-DTGODPCN.js.map +1 -1
- package/lib/chunk-DYZGWPZ6.js.map +1 -1
- package/lib/chunk-E3FDHGI7.js.map +1 -1
- package/lib/chunk-E4DYW6HB.cjs.map +1 -1
- package/lib/{chunk-ZFG533LP.js → chunk-E65GENXB.js} +2 -2
- package/lib/{chunk-ZFG533LP.js.map → chunk-E65GENXB.js.map} +1 -1
- package/lib/chunk-E6TBQVLK.cjs.map +1 -1
- package/lib/chunk-EADFDBOR.cjs.map +1 -1
- package/lib/chunk-ECMCBU3N.js.map +1 -1
- package/lib/chunk-EEFOL62K.js.map +1 -1
- package/lib/chunk-EHWAGYNX.js.map +1 -1
- package/lib/chunk-ELBOXOTA.js.map +1 -1
- package/lib/chunk-EP22KKHR.js.map +1 -1
- package/lib/chunk-EP7MAEQH.cjs.map +1 -1
- package/lib/chunk-EQD223JW.cjs.map +1 -1
- package/lib/{chunk-LCLXLB2R.cjs → chunk-ESMKOP42.cjs} +5 -2
- package/lib/chunk-ESMKOP42.cjs.map +1 -0
- package/lib/chunk-F6MSHDB7.cjs.map +1 -1
- package/lib/chunk-FAU5EILL.js.map +1 -1
- package/lib/{chunk-HLCGKY7R.js → chunk-FO7WBEPF.js} +2 -2
- package/lib/chunk-FO7WBEPF.js.map +1 -0
- package/lib/chunk-FSFXOZ35.cjs.map +1 -1
- package/lib/chunk-FTAZDUH6.js.map +1 -1
- package/lib/chunk-FVJDRHG7.js.map +1 -1
- package/lib/chunk-FXE62CPP.cjs.map +1 -1
- package/lib/chunk-FYKIHWAM.cjs.map +1 -1
- package/lib/chunk-G74OZ4M6.js.map +1 -1
- package/lib/chunk-GD4WRDF2.js.map +1 -1
- package/lib/chunk-GE6OHQR6.cjs.map +1 -1
- package/lib/chunk-GHLCA7BX.js.map +1 -1
- package/lib/chunk-GLSPCG3M.cjs.map +1 -1
- package/lib/chunk-H2USYPU6.js.map +1 -1
- package/lib/chunk-H4PUXGNI.cjs.map +1 -1
- package/lib/chunk-H4SVEI6E.js.map +1 -1
- package/lib/chunk-HAAE23MQ.js.map +1 -1
- package/lib/chunk-HBUDZOK7.cjs.map +1 -1
- package/lib/chunk-HCBXRHD7.js.map +1 -1
- package/lib/chunk-HDYENVKD.js.map +1 -1
- package/lib/{chunk-LEWK7QET.cjs → chunk-HERQULAV.cjs} +2 -2
- package/lib/chunk-HERQULAV.cjs.map +1 -0
- package/lib/chunk-HNHF6T2I.cjs.map +1 -1
- package/lib/{chunk-HQ35KQFG.cjs → chunk-HNONYIDO.cjs} +2 -2
- package/lib/chunk-HNONYIDO.cjs.map +1 -0
- package/lib/chunk-HQ5STEMD.js.map +1 -1
- package/lib/chunk-HQ6TJSB7.cjs.map +1 -1
- package/lib/chunk-HSILJQCD.js.map +1 -1
- package/lib/chunk-I3SKGXTB.cjs.map +1 -1
- package/lib/chunk-IDAOX5RB.cjs.map +1 -1
- package/lib/chunk-IITNQS6D.js.map +1 -1
- package/lib/chunk-IKENWSRH.cjs.map +1 -1
- package/lib/chunk-IKHD5UQP.cjs.map +1 -1
- package/lib/chunk-INJ7FRDA.cjs.map +1 -1
- package/lib/chunk-INZD34YD.cjs.map +1 -1
- package/lib/chunk-J4CTOHX6.cjs.map +1 -1
- package/lib/chunk-J6NBJHWL.cjs.map +1 -1
- package/lib/chunk-J6PTNG3D.js.map +1 -1
- package/lib/chunk-J7ZSBB35.js.map +1 -1
- package/lib/chunk-JAQECLCE.js.map +1 -1
- package/lib/chunk-JECYKPCC.cjs.map +1 -1
- package/lib/chunk-JPUF5YXX.js.map +1 -1
- package/lib/chunk-JRTJ6LWK.js.map +1 -1
- package/lib/chunk-JT7HVLLW.cjs.map +1 -1
- package/lib/chunk-JVF5KY2J.cjs.map +1 -1
- package/lib/chunk-JWC2GSYH.cjs.map +1 -1
- package/lib/chunk-JYOFP6BM.js.map +1 -1
- package/lib/chunk-JYXAF775.js.map +1 -1
- package/lib/chunk-K2CU5HIV.js.map +1 -1
- package/lib/chunk-K6WSCQKS.cjs.map +1 -1
- package/lib/chunk-KH5OQRQL.js.map +1 -1
- package/lib/{chunk-7X36B7N6.js → chunk-KITKWF6F.js} +2 -2
- package/lib/chunk-KITKWF6F.js.map +1 -0
- package/lib/{chunk-KBN3FFXD.cjs → chunk-KPRWSW6P.cjs} +2 -2
- package/lib/chunk-KPRWSW6P.cjs.map +1 -0
- package/lib/{chunk-7GVHCOUC.js → chunk-KU5U6DTU.js} +2 -2
- package/lib/{chunk-7GVHCOUC.js.map → chunk-KU5U6DTU.js.map} +1 -1
- package/lib/chunk-KWRDUU7K.js.map +1 -1
- package/lib/chunk-L4LPS3DV.cjs.map +1 -1
- package/lib/chunk-L4TDKOAC.js.map +1 -1
- package/lib/chunk-L5NEDGXK.js.map +1 -1
- package/lib/chunk-L6IGO47T.js.map +1 -1
- package/lib/chunk-LCNT6GY3.js.map +1 -1
- package/lib/chunk-LIT4FEIU.cjs.map +1 -1
- package/lib/chunk-LJ2EP6AL.cjs.map +1 -1
- package/lib/chunk-LNMY5BDT.js.map +1 -1
- package/lib/chunk-LTLMRGB7.js.map +1 -1
- package/lib/chunk-M2ZERG2X.cjs.map +1 -1
- package/lib/chunk-MADGMICB.js.map +1 -1
- package/lib/{chunk-VDZUWCIN.cjs → chunk-MCGX2ZDC.cjs} +2 -2
- package/lib/{chunk-VDZUWCIN.cjs.map → chunk-MCGX2ZDC.cjs.map} +1 -1
- package/lib/chunk-MJRMRWP3.js.map +1 -1
- package/lib/chunk-MPSHBMZS.js.map +1 -1
- package/lib/chunk-MQZSDICO.cjs.map +1 -1
- package/lib/chunk-MUPRLXGP.js.map +1 -1
- package/lib/chunk-MWYBER5I.cjs.map +1 -1
- package/lib/chunk-MZNHRIXE.js.map +1 -1
- package/lib/chunk-N4P7A3RY.js.map +1 -1
- package/lib/chunk-N6MHUHGE.cjs.map +1 -1
- package/lib/chunk-N753UD4K.cjs.map +1 -1
- package/lib/chunk-NAWKHFBZ.js.map +1 -1
- package/lib/chunk-NBYV35R4.cjs.map +1 -1
- package/lib/chunk-NDPDO54G.js.map +1 -1
- package/lib/chunk-NEC22ZSI.cjs.map +1 -1
- package/lib/{chunk-OPQJPXLM.cjs → chunk-NIHOABAW.cjs} +2 -2
- package/lib/chunk-NIHOABAW.cjs.map +1 -0
- package/lib/chunk-NJYMO7FP.cjs.map +1 -1
- package/lib/chunk-NODKE6P4.js.map +1 -1
- package/lib/chunk-OGLS27LJ.js.map +1 -1
- package/lib/chunk-OYFNK2SE.cjs.map +1 -1
- package/lib/chunk-PEU5GGGE.js.map +1 -1
- package/lib/chunk-PNSVP3KP.cjs.map +1 -1
- package/lib/chunk-PQS6KXZ2.cjs.map +1 -1
- package/lib/chunk-PV7MUP5Z.js.map +1 -1
- package/lib/chunk-PZZLLHJP.js.map +1 -1
- package/lib/chunk-Q2ZSQM7I.js.map +1 -1
- package/lib/chunk-Q66HILUF.js.map +1 -1
- package/lib/chunk-Q66JEOCJ.cjs.map +1 -1
- package/lib/chunk-Q7YHSPJL.js.map +1 -1
- package/lib/chunk-QGE4ELJO.cjs.map +1 -1
- package/lib/chunk-QK5MFD4L.js.map +1 -1
- package/lib/chunk-QK7D6L3W.js.map +1 -1
- package/lib/chunk-QYDOENWU.cjs.map +1 -1
- package/lib/chunk-QZTNLPOD.cjs.map +1 -1
- package/lib/chunk-QZWQNPKC.js.map +1 -1
- package/lib/chunk-R2LRLUUY.js.map +1 -1
- package/lib/chunk-R755X3AG.cjs.map +1 -1
- package/lib/chunk-RHARO4TQ.cjs.map +1 -1
- package/lib/{chunk-QHRQCFDB.js → chunk-RL7Y22OT.js} +2 -2
- package/lib/chunk-RL7Y22OT.js.map +1 -0
- package/lib/chunk-ROPOLXIV.js.map +1 -1
- package/lib/chunk-RT7XLEV6.js.map +1 -1
- package/lib/chunk-RTDD2NRL.cjs.map +1 -1
- package/lib/chunk-RTGW34KX.cjs.map +1 -1
- package/lib/{chunk-RTLW5O74.cjs → chunk-S3MCPCGR.cjs} +4 -4
- package/lib/{chunk-RTLW5O74.cjs.map → chunk-S3MCPCGR.cjs.map} +1 -1
- package/lib/chunk-SGOUEVJ3.cjs.map +1 -1
- package/lib/chunk-SGWRNEJB.cjs.map +1 -1
- package/lib/chunk-SKFA2ZIK.js.map +1 -1
- package/lib/chunk-SN6BP777.js.map +1 -1
- package/lib/chunk-SOXJJRL2.js.map +1 -1
- package/lib/chunk-SPLHKBWG.cjs.map +1 -1
- package/lib/chunk-SRW7OWVS.cjs.map +1 -1
- package/lib/chunk-SUJCEUOZ.cjs.map +1 -1
- package/lib/chunk-SWWPX4V4.cjs.map +1 -1
- package/lib/chunk-THO6KQJZ.js.map +1 -1
- package/lib/chunk-THVPSJTK.cjs.map +1 -1
- package/lib/chunk-TIJIXGNJ.cjs.map +1 -1
- package/lib/chunk-TM5OCFYV.cjs.map +1 -1
- package/lib/{chunk-VLLLEX5J.js → chunk-TOV6ECTA.js} +2 -2
- package/lib/chunk-TOV6ECTA.js.map +1 -0
- package/lib/chunk-TQFODT4D.cjs.map +1 -1
- package/lib/chunk-TSD2PK6H.js.map +1 -1
- package/lib/chunk-TSLXKI72.js.map +1 -1
- package/lib/chunk-U5FTZYJJ.js.map +1 -1
- package/lib/chunk-U6PW4AZV.js.map +1 -1
- package/lib/chunk-UB6JC3W7.js.map +1 -1
- package/lib/chunk-UBXNH6J3.js.map +1 -1
- package/lib/chunk-UP7FR6HD.cjs.map +1 -1
- package/lib/chunk-VNWOCO65.cjs.map +1 -1
- package/lib/chunk-VPXMI42G.cjs.map +1 -1
- package/lib/chunk-VRFSITD3.js.map +1 -1
- package/lib/chunk-VUCYIRSC.cjs.map +1 -1
- package/lib/{chunk-NJQDJCFB.cjs → chunk-W6AL2GJ4.cjs} +2 -2
- package/lib/{chunk-NJQDJCFB.cjs.map → chunk-W6AL2GJ4.cjs.map} +1 -1
- package/lib/{chunk-EKGR3EB3.js → chunk-W6YJDUYD.js} +2 -2
- package/lib/chunk-W6YJDUYD.js.map +1 -0
- package/lib/chunk-WAL76UPE.cjs.map +1 -1
- package/lib/chunk-WBPEFNL7.cjs.map +1 -1
- package/lib/{chunk-NKJBVNTV.cjs → chunk-WC4Z7ENS.cjs} +2 -2
- package/lib/chunk-WC4Z7ENS.cjs.map +1 -0
- package/lib/{chunk-BOPK7T5K.js → chunk-WI5IVLYL.js} +2 -2
- package/lib/chunk-WI5IVLYL.js.map +1 -0
- package/lib/chunk-WKN5RLNR.js.map +1 -1
- package/lib/chunk-WP3L72CW.js.map +1 -1
- package/lib/chunk-WTHX574O.js.map +1 -1
- package/lib/{chunk-IIR3UVU2.js → chunk-WVAW33XQ.js} +3 -3
- package/lib/chunk-WVAW33XQ.js.map +1 -0
- package/lib/{chunk-JENLN6VJ.js → chunk-WVKEXOIY.js} +5 -2
- package/lib/chunk-WVKEXOIY.js.map +1 -0
- package/lib/chunk-WXD4O4UY.js.map +1 -1
- package/lib/{chunk-RIMDGLIA.cjs → chunk-WXE5KXJC.cjs} +3 -3
- package/lib/chunk-WXE5KXJC.cjs.map +1 -0
- package/lib/chunk-X2D47UM7.cjs.map +1 -1
- package/lib/chunk-X6PHZA6P.cjs.map +1 -1
- package/lib/chunk-XD7GS4QW.js.map +1 -1
- package/lib/chunk-XMDDYWH5.js.map +1 -1
- package/lib/chunk-XPF5Z2WY.js.map +1 -1
- package/lib/chunk-XR3KEV7U.js.map +1 -1
- package/lib/chunk-XUC3BYL2.cjs.map +1 -1
- package/lib/chunk-Y2IGLW5N.js.map +1 -1
- package/lib/chunk-Y3BFYVWA.js.map +1 -1
- package/lib/{chunk-VMJUXZ67.cjs → chunk-Y5BP4C42.cjs} +2 -2
- package/lib/chunk-Y5BP4C42.cjs.map +1 -0
- package/lib/chunk-YAKNUPNE.cjs.map +1 -1
- package/lib/chunk-YAVHAWTZ.js.map +1 -1
- package/lib/chunk-YBXRC6MC.js.map +1 -1
- package/lib/chunk-YHYBOXVX.cjs.map +1 -1
- package/lib/chunk-YIDX7HVR.cjs.map +1 -1
- package/lib/chunk-YN4M5CNJ.js.map +1 -1
- package/lib/chunk-YOHBJHTH.cjs.map +1 -1
- package/lib/chunk-YUGZUUAU.js.map +1 -1
- package/lib/chunk-YY5ENJSH.cjs.map +1 -1
- package/lib/chunk-Z2QVXW6T.cjs.map +1 -1
- package/lib/chunk-Z667GAZJ.js.map +1 -1
- package/lib/chunk-Z7DKPFKZ.js.map +1 -1
- package/lib/chunk-ZAISVVBE.cjs.map +1 -1
- package/lib/chunk-ZASD6IUL.js.map +1 -1
- package/lib/chunk-ZEEB5YAU.js.map +1 -1
- package/lib/chunk-ZQSCFH5J.cjs.map +1 -1
- package/lib/chunk-ZTVQSWSD.cjs.map +1 -1
- package/lib/chunk-ZU7GFVQ6.js.map +1 -1
- package/lib/chunk-ZZF34M2E.cjs.map +1 -1
- package/lib/client.d.cts +3 -1
- package/lib/commercelayer.cjs +5 -5
- package/lib/commercelayer.d.cts +6 -4
- package/lib/commercelayer.d.ts +3 -3
- package/lib/commercelayer.js +1 -1
- package/lib/enum.d.cts +1 -1
- package/lib/enum.d.ts +1 -1
- package/lib/index.cjs +29 -29
- package/lib/index.d.cts +5 -2
- package/lib/index.d.ts +1 -1
- package/lib/index.js +14 -14
- package/lib/jsonapi.d.cts +1 -1
- package/lib/jsonapi.d.ts +1 -1
- package/lib/model.d.cts +1 -1
- package/lib/model.d.ts +1 -1
- package/lib/query.d.cts +1 -1
- package/lib/query.d.ts +1 -1
- package/lib/resource.d.cts +1 -1
- package/lib/resource.d.ts +1 -1
- package/lib/resources/addresses.d.cts +4 -1
- package/lib/resources/addresses.d.ts +1 -1
- package/lib/resources/adjustments.d.cts +4 -1
- package/lib/resources/adjustments.d.ts +1 -1
- package/lib/resources/adyen_gateways.d.cts +4 -1
- package/lib/resources/adyen_gateways.d.ts +1 -1
- package/lib/resources/adyen_payments.cjs +2 -2
- package/lib/resources/adyen_payments.d.cts +4 -1
- package/lib/resources/adyen_payments.d.ts +1 -1
- package/lib/resources/adyen_payments.js +1 -1
- package/lib/resources/applications.cjs +2 -2
- package/lib/resources/applications.d.cts +4 -1
- package/lib/resources/applications.d.ts +1 -1
- package/lib/resources/applications.js +1 -1
- package/lib/resources/attachments.d.cts +4 -1
- package/lib/resources/attachments.d.ts +1 -1
- package/lib/resources/authorizations.d.cts +4 -1
- package/lib/resources/authorizations.d.ts +1 -1
- package/lib/resources/avalara_accounts.d.cts +4 -1
- package/lib/resources/avalara_accounts.d.ts +1 -1
- package/lib/resources/axerve_gateways.d.cts +4 -1
- package/lib/resources/axerve_gateways.d.ts +1 -1
- package/lib/resources/axerve_payments.d.cts +4 -1
- package/lib/resources/axerve_payments.d.ts +1 -1
- package/lib/resources/bing_geocoders.d.cts +4 -1
- package/lib/resources/bing_geocoders.d.ts +1 -1
- package/lib/resources/braintree_gateways.d.cts +4 -1
- package/lib/resources/braintree_gateways.d.ts +1 -1
- package/lib/resources/braintree_payments.d.cts +4 -1
- package/lib/resources/braintree_payments.d.ts +1 -1
- package/lib/resources/bundles.d.cts +4 -1
- package/lib/resources/bundles.d.ts +1 -1
- package/lib/resources/buy_x_pay_y_promotions.d.cts +4 -1
- package/lib/resources/buy_x_pay_y_promotions.d.ts +1 -1
- package/lib/resources/captures.d.cts +4 -1
- package/lib/resources/captures.d.ts +1 -1
- package/lib/resources/carrier_accounts.d.cts +4 -1
- package/lib/resources/carrier_accounts.d.ts +1 -1
- package/lib/resources/checkout_com_gateways.d.cts +4 -1
- package/lib/resources/checkout_com_gateways.d.ts +1 -1
- package/lib/resources/checkout_com_payments.cjs +2 -2
- package/lib/resources/checkout_com_payments.d.cts +4 -1
- package/lib/resources/checkout_com_payments.d.ts +1 -1
- package/lib/resources/checkout_com_payments.js +1 -1
- package/lib/resources/cleanups.d.cts +4 -1
- package/lib/resources/cleanups.d.ts +1 -1
- package/lib/resources/coupon_codes_promotion_rules.d.cts +4 -1
- package/lib/resources/coupon_codes_promotion_rules.d.ts +1 -1
- package/lib/resources/coupon_recipients.d.cts +4 -1
- package/lib/resources/coupon_recipients.d.ts +1 -1
- package/lib/resources/coupons.d.cts +4 -1
- package/lib/resources/coupons.d.ts +1 -1
- package/lib/resources/custom_promotion_rules.d.cts +4 -1
- package/lib/resources/custom_promotion_rules.d.ts +1 -1
- package/lib/resources/customer_addresses.d.cts +4 -1
- package/lib/resources/customer_addresses.d.ts +1 -1
- package/lib/resources/customer_groups.d.cts +4 -1
- package/lib/resources/customer_groups.d.ts +1 -1
- package/lib/resources/customer_password_resets.d.cts +4 -1
- package/lib/resources/customer_password_resets.d.ts +1 -1
- package/lib/resources/customer_payment_sources.d.cts +4 -1
- package/lib/resources/customer_payment_sources.d.ts +1 -1
- package/lib/resources/customer_subscriptions.d.cts +4 -1
- package/lib/resources/customer_subscriptions.d.ts +1 -1
- package/lib/resources/customers.cjs +2 -2
- package/lib/resources/customers.d.cts +4 -1
- package/lib/resources/customers.d.ts +1 -1
- package/lib/resources/customers.js +1 -1
- package/lib/resources/delivery_lead_times.d.cts +4 -1
- package/lib/resources/delivery_lead_times.d.ts +1 -1
- package/lib/resources/discount_engine_items.d.cts +4 -1
- package/lib/resources/discount_engine_items.d.ts +1 -1
- package/lib/resources/discount_engines.d.cts +4 -1
- package/lib/resources/discount_engines.d.ts +1 -1
- package/lib/resources/easypost_pickups.d.cts +4 -1
- package/lib/resources/easypost_pickups.d.ts +1 -1
- package/lib/resources/event_callbacks.d.cts +4 -1
- package/lib/resources/event_callbacks.d.ts +1 -1
- package/lib/resources/events.d.cts +4 -1
- package/lib/resources/events.d.ts +1 -1
- package/lib/resources/exports.d.cts +4 -1
- package/lib/resources/exports.d.ts +1 -1
- package/lib/resources/external_gateways.d.cts +4 -1
- package/lib/resources/external_gateways.d.ts +1 -1
- package/lib/resources/external_payments.d.cts +4 -1
- package/lib/resources/external_payments.d.ts +1 -1
- package/lib/resources/external_promotions.d.cts +4 -1
- package/lib/resources/external_promotions.d.ts +1 -1
- package/lib/resources/external_tax_calculators.d.cts +4 -1
- package/lib/resources/external_tax_calculators.d.ts +1 -1
- package/lib/resources/fixed_amount_promotions.d.cts +4 -1
- package/lib/resources/fixed_amount_promotions.d.ts +1 -1
- package/lib/resources/fixed_price_promotions.d.cts +4 -1
- package/lib/resources/fixed_price_promotions.d.ts +1 -1
- package/lib/resources/flex_promotions.cjs +2 -2
- package/lib/resources/flex_promotions.d.cts +4 -1
- package/lib/resources/flex_promotions.d.ts +1 -1
- package/lib/resources/flex_promotions.js +1 -1
- package/lib/resources/free_gift_promotions.d.cts +4 -1
- package/lib/resources/free_gift_promotions.d.ts +1 -1
- package/lib/resources/free_shipping_promotions.d.cts +4 -1
- package/lib/resources/free_shipping_promotions.d.ts +1 -1
- package/lib/resources/geocoders.d.cts +4 -1
- package/lib/resources/geocoders.d.ts +1 -1
- package/lib/resources/gift_card_recipients.d.cts +4 -1
- package/lib/resources/gift_card_recipients.d.ts +1 -1
- package/lib/resources/gift_cards.d.cts +4 -1
- package/lib/resources/gift_cards.d.ts +1 -1
- package/lib/resources/google_geocoders.d.cts +4 -1
- package/lib/resources/google_geocoders.d.ts +1 -1
- package/lib/resources/imports.d.cts +4 -1
- package/lib/resources/imports.d.ts +1 -1
- package/lib/resources/in_stock_subscriptions.d.cts +4 -1
- package/lib/resources/in_stock_subscriptions.d.ts +1 -1
- package/lib/resources/inventory_models.d.cts +4 -1
- package/lib/resources/inventory_models.d.ts +1 -1
- package/lib/resources/inventory_return_locations.d.cts +4 -1
- package/lib/resources/inventory_return_locations.d.ts +1 -1
- package/lib/resources/inventory_stock_locations.d.cts +4 -1
- package/lib/resources/inventory_stock_locations.d.ts +1 -1
- package/lib/resources/klarna_gateways.d.cts +4 -1
- package/lib/resources/klarna_gateways.d.ts +1 -1
- package/lib/resources/klarna_payments.d.cts +4 -1
- package/lib/resources/klarna_payments.d.ts +1 -1
- package/lib/resources/line_item_options.d.cts +4 -1
- package/lib/resources/line_item_options.d.ts +1 -1
- package/lib/resources/line_items.cjs +2 -2
- package/lib/resources/line_items.d.cts +4 -1
- package/lib/resources/line_items.d.ts +1 -1
- package/lib/resources/line_items.js +1 -1
- package/lib/resources/links.d.cts +4 -1
- package/lib/resources/links.d.ts +1 -1
- package/lib/resources/manual_gateways.d.cts +4 -1
- package/lib/resources/manual_gateways.d.ts +1 -1
- package/lib/resources/manual_tax_calculators.d.cts +4 -1
- package/lib/resources/manual_tax_calculators.d.ts +1 -1
- package/lib/resources/markets.d.cts +4 -1
- package/lib/resources/markets.d.ts +1 -1
- package/lib/resources/merchants.d.cts +4 -1
- package/lib/resources/merchants.d.ts +1 -1
- package/lib/resources/notifications.d.cts +4 -1
- package/lib/resources/notifications.d.ts +1 -1
- package/lib/resources/order_amount_promotion_rules.d.cts +4 -1
- package/lib/resources/order_amount_promotion_rules.d.ts +1 -1
- package/lib/resources/order_copies.d.cts +4 -1
- package/lib/resources/order_copies.d.ts +1 -1
- package/lib/resources/order_factories.d.cts +4 -1
- package/lib/resources/order_factories.d.ts +1 -1
- package/lib/resources/order_subscription_items.d.cts +4 -1
- package/lib/resources/order_subscription_items.d.ts +1 -1
- package/lib/resources/order_subscriptions.d.cts +4 -1
- package/lib/resources/order_subscriptions.d.ts +1 -1
- package/lib/resources/orders.d.cts +4 -1
- package/lib/resources/orders.d.ts +1 -1
- package/lib/resources/organizations.d.cts +4 -1
- package/lib/resources/organizations.d.ts +1 -1
- package/lib/resources/packages.d.cts +4 -1
- package/lib/resources/packages.d.ts +1 -1
- package/lib/resources/parcel_line_items.d.cts +4 -1
- package/lib/resources/parcel_line_items.d.ts +1 -1
- package/lib/resources/parcels.d.cts +4 -1
- package/lib/resources/parcels.d.ts +1 -1
- package/lib/resources/payment_gateways.d.cts +4 -1
- package/lib/resources/payment_gateways.d.ts +1 -1
- package/lib/resources/payment_methods.cjs +2 -2
- package/lib/resources/payment_methods.d.cts +4 -1
- package/lib/resources/payment_methods.d.ts +1 -1
- package/lib/resources/payment_methods.js +1 -1
- package/lib/resources/payment_options.cjs +2 -2
- package/lib/resources/payment_options.d.cts +4 -1
- package/lib/resources/payment_options.d.ts +1 -1
- package/lib/resources/payment_options.js +1 -1
- package/lib/resources/paypal_gateways.d.cts +4 -1
- package/lib/resources/paypal_gateways.d.ts +1 -1
- package/lib/resources/paypal_payments.d.cts +4 -1
- package/lib/resources/paypal_payments.d.ts +1 -1
- package/lib/resources/percentage_discount_promotions.d.cts +4 -1
- package/lib/resources/percentage_discount_promotions.d.ts +1 -1
- package/lib/resources/pickups.d.cts +4 -1
- package/lib/resources/pickups.d.ts +1 -1
- package/lib/resources/price_frequency_tiers.d.cts +4 -1
- package/lib/resources/price_frequency_tiers.d.ts +1 -1
- package/lib/resources/price_list_schedulers.d.cts +4 -1
- package/lib/resources/price_list_schedulers.d.ts +1 -1
- package/lib/resources/price_lists.cjs +2 -2
- package/lib/resources/price_lists.d.cts +4 -1
- package/lib/resources/price_lists.d.ts +1 -1
- package/lib/resources/price_lists.js +1 -1
- package/lib/resources/price_tiers.d.cts +4 -1
- package/lib/resources/price_tiers.d.ts +1 -1
- package/lib/resources/price_volume_tiers.d.cts +4 -1
- package/lib/resources/price_volume_tiers.d.ts +1 -1
- package/lib/resources/prices.cjs +2 -2
- package/lib/resources/prices.d.cts +4 -1
- package/lib/resources/prices.d.ts +1 -1
- package/lib/resources/prices.js +1 -1
- package/lib/resources/promotion_rules.d.cts +4 -1
- package/lib/resources/promotion_rules.d.ts +1 -1
- package/lib/resources/promotions.d.cts +4 -1
- package/lib/resources/promotions.d.ts +1 -1
- package/lib/resources/recurring_order_copies.d.cts +4 -1
- package/lib/resources/recurring_order_copies.d.ts +1 -1
- package/lib/resources/refunds.d.cts +4 -1
- package/lib/resources/refunds.d.ts +1 -1
- package/lib/resources/reserved_stocks.d.cts +4 -1
- package/lib/resources/reserved_stocks.d.ts +1 -1
- package/lib/resources/resource_errors.d.cts +4 -1
- package/lib/resources/resource_errors.d.ts +1 -1
- package/lib/resources/return_line_items.d.cts +4 -1
- package/lib/resources/return_line_items.d.ts +1 -1
- package/lib/resources/returns.d.cts +4 -1
- package/lib/resources/returns.d.ts +1 -1
- package/lib/resources/satispay_gateways.d.cts +4 -1
- package/lib/resources/satispay_gateways.d.ts +1 -1
- package/lib/resources/satispay_payments.d.cts +4 -1
- package/lib/resources/satispay_payments.d.ts +1 -1
- package/lib/resources/shipments.d.cts +4 -1
- package/lib/resources/shipments.d.ts +1 -1
- package/lib/resources/shipping_categories.d.cts +4 -1
- package/lib/resources/shipping_categories.d.ts +1 -1
- package/lib/resources/shipping_method_tiers.d.cts +4 -1
- package/lib/resources/shipping_method_tiers.d.ts +1 -1
- package/lib/resources/shipping_methods.cjs +2 -2
- package/lib/resources/shipping_methods.d.cts +4 -1
- package/lib/resources/shipping_methods.d.ts +1 -1
- package/lib/resources/shipping_methods.js +1 -1
- package/lib/resources/shipping_weight_tiers.d.cts +4 -1
- package/lib/resources/shipping_weight_tiers.d.ts +1 -1
- package/lib/resources/shipping_zones.d.cts +4 -1
- package/lib/resources/shipping_zones.d.ts +1 -1
- package/lib/resources/sku_list_items.d.cts +4 -1
- package/lib/resources/sku_list_items.d.ts +1 -1
- package/lib/resources/sku_list_promotion_rules.d.cts +4 -1
- package/lib/resources/sku_list_promotion_rules.d.ts +1 -1
- package/lib/resources/sku_lists.d.cts +4 -1
- package/lib/resources/sku_lists.d.ts +1 -1
- package/lib/resources/sku_options.d.cts +4 -1
- package/lib/resources/sku_options.d.ts +1 -1
- package/lib/resources/skus.d.cts +4 -1
- package/lib/resources/skus.d.ts +1 -1
- package/lib/resources/stock_items.d.cts +4 -1
- package/lib/resources/stock_items.d.ts +1 -1
- package/lib/resources/stock_line_items.d.cts +4 -1
- package/lib/resources/stock_line_items.d.ts +1 -1
- package/lib/resources/stock_locations.d.cts +4 -1
- package/lib/resources/stock_locations.d.ts +1 -1
- package/lib/resources/stock_reservations.d.cts +4 -1
- package/lib/resources/stock_reservations.d.ts +1 -1
- package/lib/resources/stock_transfers.d.cts +4 -1
- package/lib/resources/stock_transfers.d.ts +1 -1
- package/lib/resources/stores.d.cts +4 -1
- package/lib/resources/stores.d.ts +1 -1
- package/lib/resources/stripe_gateways.d.cts +4 -1
- package/lib/resources/stripe_gateways.d.ts +1 -1
- package/lib/resources/stripe_payments.d.cts +4 -1
- package/lib/resources/stripe_payments.d.ts +1 -1
- package/lib/resources/stripe_tax_accounts.d.cts +4 -1
- package/lib/resources/stripe_tax_accounts.d.ts +1 -1
- package/lib/resources/subscription_models.d.cts +4 -1
- package/lib/resources/subscription_models.d.ts +1 -1
- package/lib/resources/tags.d.cts +4 -1
- package/lib/resources/tags.d.ts +1 -1
- package/lib/resources/talon_one_accounts.cjs +2 -2
- package/lib/resources/talon_one_accounts.d.cts +4 -1
- package/lib/resources/talon_one_accounts.d.ts +1 -1
- package/lib/resources/talon_one_accounts.js +1 -1
- package/lib/resources/tax_calculators.d.cts +4 -1
- package/lib/resources/tax_calculators.d.ts +1 -1
- package/lib/resources/tax_categories.d.cts +4 -1
- package/lib/resources/tax_categories.d.ts +1 -1
- package/lib/resources/tax_rules.d.cts +4 -1
- package/lib/resources/tax_rules.d.ts +1 -1
- package/lib/resources/taxjar_accounts.d.cts +4 -1
- package/lib/resources/taxjar_accounts.d.ts +1 -1
- package/lib/resources/transactions.d.cts +4 -1
- package/lib/resources/transactions.d.ts +1 -1
- package/lib/resources/versions.d.cts +4 -1
- package/lib/resources/versions.d.ts +1 -1
- package/lib/resources/vertex_accounts.d.cts +4 -1
- package/lib/resources/vertex_accounts.d.ts +1 -1
- package/lib/resources/voids.d.cts +4 -1
- package/lib/resources/voids.d.ts +1 -1
- package/lib/resources/webhooks.d.cts +4 -1
- package/lib/resources/webhooks.d.ts +1 -1
- package/lib/resources/wire_transfers.d.cts +4 -1
- package/lib/resources/wire_transfers.d.ts +1 -1
- package/lib/static.cjs +3 -3
- package/lib/static.d.cts +1 -1
- package/lib/static.d.ts +1 -1
- package/lib/static.js +2 -2
- package/package.json +8 -8
- package/lib/chunk-465K3KVE.js.map +0 -1
- package/lib/chunk-7X36B7N6.js.map +0 -1
- package/lib/chunk-BOPK7T5K.js.map +0 -1
- package/lib/chunk-EKGR3EB3.js.map +0 -1
- package/lib/chunk-HLCGKY7R.js.map +0 -1
- package/lib/chunk-HQ35KQFG.cjs.map +0 -1
- package/lib/chunk-IIR3UVU2.js.map +0 -1
- package/lib/chunk-JENLN6VJ.js.map +0 -1
- package/lib/chunk-KBN3FFXD.cjs.map +0 -1
- package/lib/chunk-LCLXLB2R.cjs.map +0 -1
- package/lib/chunk-LEWK7QET.cjs.map +0 -1
- package/lib/chunk-NKJBVNTV.cjs.map +0 -1
- package/lib/chunk-NMVACSMG.js.map +0 -1
- package/lib/chunk-OPQJPXLM.cjs.map +0 -1
- package/lib/chunk-P3NADEGE.cjs.map +0 -1
- package/lib/chunk-QHRQCFDB.js.map +0 -1
- package/lib/chunk-RIMDGLIA.cjs.map +0 -1
- package/lib/chunk-RWPFE3LF.cjs.map +0 -1
- package/lib/chunk-VLLLEX5J.js.map +0 -1
- package/lib/chunk-VMJUXZ67.cjs.map +0 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/return_line_items.ts"],"names":["ApiResource"],"mappings":";;;;;AAuHA,IAAM,eAAA,GAAN,MAAM,gBAAA,SAAwBA,
|
1
|
+
{"version":3,"sources":["../src/resources/return_line_items.ts"],"names":["ApiResource"],"mappings":";;;;;AAuHA,IAAM,eAAA,GAAN,MAAM,gBAAA,SAAwBA,6BAAA,CAA4B;A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AM,YAAA,EAAa,EAAG,CAAA,kBAAA,EAAqB,iBAAiB,CAAA,UAAA,CAAA,EAAc,MAAA,EAAQ,OAAO,CAAA;AAAA;AAClI,EAEA,MAAM,QAAA,CAAS,EAAA,EAA6B,MAAA,EAA8C,OAAA,EAAoD;AAC7I,IAAA,OAAO,KAAK,SAAA,CAAU,MAAA,CAA6C,EAAE,EAAA,EAAK,OAAO,OAAO,QAAA,GAAW,EAAA,GAAI,EAAA,CAAG,EAAA,EAAI,MAAM,gBAAA,CAAgB,IAAA,EAAM,UAAU,IAAA,EAAK,EAAG,QAAQ,OAAO,CAAA;AAAA;AAC5K,EAGA,iBAAiB,QAAA,EAA2C;AAC3D,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,gBAAA,CAAgB,IAAA;AAAA;AAC5D,EAGA,aAAa,EAAA,EAAmD;AAC/D,IAAA,OAAO,KAAA,CAAM,qBAAwC,EAAE,CAAA;AAAA;AACxD,EAEA,sBAAsB,GAAA,EAAoC;AACzD,IAAA,OAAO,KAAA,CAAM,qBAAA,CAAyC,GAAG,GAAG,CAAA;AAAA;AAC7D,EAGA,IAAA,GAA2B;AAC1B,IAAA,OAAO,gBAAA,CAAgB,IAAA;AAAA;AAGzB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,eAAA,EAAgB;AACrC,IAAO,yBAAA,GAAQ","file":"chunk-EADFDBOR.cjs","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve } from '../query'\n\nimport type { Return, ReturnType } from './returns'\nimport type { LineItem, LineItemType } from './line_items'\n\n\ntype ReturnLineItemType = 'return_line_items'\ntype ReturnLineItemRel = ResourceRel & { type: ReturnLineItemType }\ntype ReturnRel = ResourceRel & { type: ReturnType }\ntype LineItemRel = ResourceRel & { type: LineItemType }\n\n\nexport type ReturnLineItemSort = Pick<ReturnLineItem, 'id' | 'quantity' | 'total_amount_cents' | 'restocked_at'> & ResourceSort\n// export type ReturnLineItemFilter = Pick<ReturnLineItem, 'id' | 'quantity' | 'total_amount_cents' | 'return_reason' | 'restocked_at'> & ResourceFilter\n\n\ninterface ReturnLineItem extends Resource {\n\t\n\treadonly type: ReturnLineItemType\n\n\t/** \n\t * The code of the associated SKU.\n\t * @example ```\"TSHIRTMM000000FFFFFFXLXX\"```\n\t */\n\tsku_code?: string | null\n\t/** \n\t * The code of the associated bundle.\n\t * @example ```\"BUNDLEMM000000FFFFFFXLXX\"```\n\t */\n\tbundle_code?: string | null\n\t/** \n\t * The return line item quantity.\n\t * @example ```4```\n\t */\n\tquantity: number\n\t/** \n\t * The name of the line item.\n\t * @example ```\"Men's Black T-shirt with White Logo (XL)\"```\n\t */\n\tname?: string | null\n\t/** \n\t * The image_url of the associated line item.\n\t * @example ```\"https://img.yourdomain.com/skus/xYZkjABcde.png\"```\n\t */\n\timage_url?: string | null\n\t/** \n\t * Calculated as line item unit amount x returned quantity and applied discounts, if any.\n\t * @example ```8800```\n\t */\n\ttotal_amount_cents?: number | null\n\t/** \n\t * The return line item total amount, float. This can be useful to track the purchase on thrid party systems, e.g Google Analyitcs Enhanced Ecommerce.\n\t * @example ```88```\n\t */\n\ttotal_amount_float: number\n\t/** \n\t * The return line item total amount, formatted. This can be useful to display the amount with currency in you views.\n\t * @example ```\"€88,00\"```\n\t */\n\tformatted_total_amount?: string | null\n\t/** \n\t * Set of key-value pairs that you can use to add details about return reason.\n\t * @example ```{\"size\":\"was wrong\"}```\n\t */\n\treturn_reason?: Record<string, any> | null\n\t/** \n\t * Time at which the return line item was restocked.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\trestocked_at?: string | null\n\n\treturn?: Return | null\n\tline_item?: LineItem | null\n\n}\n\n\ninterface ReturnLineItemCreate extends ResourceCreate {\n\t\n\t/** \n\t * The return line item quantity.\n\t * @example ```4```\n\t */\n\tquantity: number\n\t/** \n\t * Set of key-value pairs that you can use to add details about return reason.\n\t * @example ```{\"size\":\"was wrong\"}```\n\t */\n\treturn_reason?: Record<string, any> | null\n\n\treturn: ReturnRel\n\tline_item: LineItemRel\n\n}\n\n\ninterface ReturnLineItemUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The return line item quantity.\n\t * @example ```4```\n\t */\n\tquantity?: number | null\n\t/** \n\t * Send this attribute if you want to restock the line item.\n\t * @example ```true```\n\t */\n\t_restock?: boolean | null\n\t/** \n\t * Set of key-value pairs that you can use to add details about return reason.\n\t * @example ```{\"size\":\"was wrong\"}```\n\t */\n\treturn_reason?: Record<string, any> | null\n\t\n}\n\n\nclass ReturnLineItems extends ApiResource<ReturnLineItem> {\n\n\tstatic readonly TYPE: ReturnLineItemType = 'return_line_items' as const\n\n\tasync create(resource: ReturnLineItemCreate, params?: QueryParamsRetrieve<ReturnLineItem>, options?: ResourcesConfig): Promise<ReturnLineItem> {\n\t\treturn this.resources.create<ReturnLineItemCreate, ReturnLineItem>({ ...resource, type: ReturnLineItems.TYPE }, params, options)\n\t}\n\n\tasync update(resource: ReturnLineItemUpdate, params?: QueryParamsRetrieve<ReturnLineItem>, options?: ResourcesConfig): Promise<ReturnLineItem> {\n\t\treturn this.resources.update<ReturnLineItemUpdate, ReturnLineItem>({ ...resource, type: ReturnLineItems.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: ReturnLineItems.TYPE } : id, options)\n\t}\n\n\tasync return(returnLineItemId: string | ReturnLineItem, params?: QueryParamsRetrieve<Return>, options?: ResourcesConfig): Promise<Return> {\n\t\tconst _returnLineItemId = (returnLineItemId as ReturnLineItem).id || returnLineItemId as string\n\t\treturn this.resources.fetch<Return>({ type: 'returns' }, `return_line_items/${_returnLineItemId}/return`, params, options) as unknown as Return\n\t}\n\n\tasync line_item(returnLineItemId: string | ReturnLineItem, params?: QueryParamsRetrieve<LineItem>, options?: ResourcesConfig): Promise<LineItem> {\n\t\tconst _returnLineItemId = (returnLineItemId as ReturnLineItem).id || returnLineItemId as string\n\t\treturn this.resources.fetch<LineItem>({ type: 'line_items' }, `return_line_items/${_returnLineItemId}/line_item`, params, options) as unknown as LineItem\n\t}\n\n\tasync _restock(id: string | ReturnLineItem, params?: QueryParamsRetrieve<ReturnLineItem>, options?: ResourcesConfig): Promise<ReturnLineItem> {\n\t\treturn this.resources.update<ReturnLineItemUpdate, ReturnLineItem>({ id: (typeof id === 'string')? id: id.id, type: ReturnLineItems.TYPE, _restock: true }, params, options)\n\t}\n\n\n\tisReturnLineItem(resource: any): resource is ReturnLineItem {\n\t\treturn resource.type && (resource.type === ReturnLineItems.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): ReturnLineItemRel {\n\t\treturn super.relationshipOneToOne<ReturnLineItemRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): ReturnLineItemRel[] {\n\t\treturn super.relationshipOneToMany<ReturnLineItemRel>(...ids)\n\t}\n\n\n\ttype(): ReturnLineItemType {\n\t\treturn ReturnLineItems.TYPE\n\t}\n\n}\n\n\nconst instance = new ReturnLineItems()\nexport default instance\n\nexport type { ReturnLineItems, ReturnLineItem, ReturnLineItemCreate, ReturnLineItemUpdate, ReturnLineItemType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/avalara_accounts.ts"],"names":[],"mappings":";;;AAuIA,IAAM,eAAA,GAAN,MAAM,gBAAA,SAAwB,
|
1
|
+
{"version":3,"sources":["../src/resources/avalara_accounts.ts"],"names":[],"mappings":";;;AAuIA,IAAM,eAAA,GAAN,MAAM,gBAAA,SAAwB,WAAA,CAA4B;AAAA,EAEzD,OAAgB,IAAA,GAA2B,kBAAA;AAAA,EAE3C,MAAM,MAAA,CAAO,QAAA,EAAgC,MAAA,EAA8C,OAAA,EAAoD;AAC9I,IAAA,OAAO,IAAA,CA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AA,GAA2B;AAC1B,IAAA,OAAO,gBAAA,CAAgB,IAAA;AAAA;AAGzB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,eAAA,EAAgB;AACrC,IAAO,wBAAA,GAAQ","file":"chunk-ECMCBU3N.js","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Market } from './markets'\nimport type { Attachment } from './attachments'\nimport type { Event } from './events'\nimport type { Version } from './versions'\nimport type { TaxCategory, TaxCategoryType } from './tax_categories'\n\n\ntype AvalaraAccountType = 'avalara_accounts'\ntype AvalaraAccountRel = ResourceRel & { type: AvalaraAccountType }\ntype TaxCategoryRel = ResourceRel & { type: TaxCategoryType }\n\n\nexport type AvalaraAccountSort = Pick<AvalaraAccount, 'id' | 'name'> & ResourceSort\n// export type AvalaraAccountFilter = Pick<AvalaraAccount, 'id' | 'name'> & ResourceFilter\n\n\ninterface AvalaraAccount extends Resource {\n\t\n\treadonly type: AvalaraAccountType\n\n\t/** \n\t * The tax calculator's internal name.\n\t * @example ```\"Personal tax calculator\"```\n\t */\n\tname: string\n\t/** \n\t * The Avalara account username.\n\t * @example ```\"user@mydomain.com\"```\n\t */\n\tusername: string\n\t/** \n\t * The Avalara company code.\n\t * @example ```\"MYCOMPANY\"```\n\t */\n\tcompany_code: string\n\t/** \n\t * Indicates if the transaction will be recorded and visible on the Avalara website.\n\t * @example ```true```\n\t */\n\tcommit_invoice?: boolean | null\n\t/** \n\t * Indicates if the seller is responsible for paying/remitting the customs duty & import tax to the customs authorities.\n\t * @example ```true```\n\t */\n\tddp?: boolean | null\n\n\tmarkets?: Market[] | null\n\tattachments?: Attachment[] | null\n\tevents?: Event[] | null\n\tversions?: Version[] | null\n\ttax_categories?: TaxCategory[] | null\n\n}\n\n\ninterface AvalaraAccountCreate extends ResourceCreate {\n\t\n\t/** \n\t * The tax calculator's internal name.\n\t * @example ```\"Personal tax calculator\"```\n\t */\n\tname: string\n\t/** \n\t * The Avalara account username.\n\t * @example ```\"user@mydomain.com\"```\n\t */\n\tusername: string\n\t/** \n\t * The Avalara account password.\n\t * @example ```\"secret\"```\n\t */\n\tpassword: string\n\t/** \n\t * The Avalara company code.\n\t * @example ```\"MYCOMPANY\"```\n\t */\n\tcompany_code: string\n\t/** \n\t * Indicates if the transaction will be recorded and visible on the Avalara website.\n\t * @example ```true```\n\t */\n\tcommit_invoice?: boolean | null\n\t/** \n\t * Indicates if the seller is responsible for paying/remitting the customs duty & import tax to the customs authorities.\n\t * @example ```true```\n\t */\n\tddp?: boolean | null\n\n\ttax_categories?: TaxCategoryRel[] | null\n\n}\n\n\ninterface AvalaraAccountUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The tax calculator's internal name.\n\t * @example ```\"Personal tax calculator\"```\n\t */\n\tname?: string | null\n\t/** \n\t * The Avalara account username.\n\t * @example ```\"user@mydomain.com\"```\n\t */\n\tusername?: string | null\n\t/** \n\t * The Avalara account password.\n\t * @example ```\"secret\"```\n\t */\n\tpassword?: string | null\n\t/** \n\t * The Avalara company code.\n\t * @example ```\"MYCOMPANY\"```\n\t */\n\tcompany_code?: string | null\n\t/** \n\t * Indicates if the transaction will be recorded and visible on the Avalara website.\n\t * @example ```true```\n\t */\n\tcommit_invoice?: boolean | null\n\t/** \n\t * Indicates if the seller is responsible for paying/remitting the customs duty & import tax to the customs authorities.\n\t * @example ```true```\n\t */\n\tddp?: boolean | null\n\n\ttax_categories?: TaxCategoryRel[] | null\n\n}\n\n\nclass AvalaraAccounts extends ApiResource<AvalaraAccount> {\n\n\tstatic readonly TYPE: AvalaraAccountType = 'avalara_accounts' as const\n\n\tasync create(resource: AvalaraAccountCreate, params?: QueryParamsRetrieve<AvalaraAccount>, options?: ResourcesConfig): Promise<AvalaraAccount> {\n\t\treturn this.resources.create<AvalaraAccountCreate, AvalaraAccount>({ ...resource, type: AvalaraAccounts.TYPE }, params, options)\n\t}\n\n\tasync update(resource: AvalaraAccountUpdate, params?: QueryParamsRetrieve<AvalaraAccount>, options?: ResourcesConfig): Promise<AvalaraAccount> {\n\t\treturn this.resources.update<AvalaraAccountUpdate, AvalaraAccount>({ ...resource, type: AvalaraAccounts.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: AvalaraAccounts.TYPE } : id, options)\n\t}\n\n\tasync markets(avalaraAccountId: string | AvalaraAccount, params?: QueryParamsList<Market>, options?: ResourcesConfig): Promise<ListResponse<Market>> {\n\t\tconst _avalaraAccountId = (avalaraAccountId as AvalaraAccount).id || avalaraAccountId as string\n\t\treturn this.resources.fetch<Market>({ type: 'markets' }, `avalara_accounts/${_avalaraAccountId}/markets`, params, options) as unknown as ListResponse<Market>\n\t}\n\n\tasync attachments(avalaraAccountId: string | AvalaraAccount, params?: QueryParamsList<Attachment>, options?: ResourcesConfig): Promise<ListResponse<Attachment>> {\n\t\tconst _avalaraAccountId = (avalaraAccountId as AvalaraAccount).id || avalaraAccountId as string\n\t\treturn this.resources.fetch<Attachment>({ type: 'attachments' }, `avalara_accounts/${_avalaraAccountId}/attachments`, params, options) as unknown as ListResponse<Attachment>\n\t}\n\n\tasync events(avalaraAccountId: string | AvalaraAccount, params?: QueryParamsList<Event>, options?: ResourcesConfig): Promise<ListResponse<Event>> {\n\t\tconst _avalaraAccountId = (avalaraAccountId as AvalaraAccount).id || avalaraAccountId as string\n\t\treturn this.resources.fetch<Event>({ type: 'events' }, `avalara_accounts/${_avalaraAccountId}/events`, params, options) as unknown as ListResponse<Event>\n\t}\n\n\tasync versions(avalaraAccountId: string | AvalaraAccount, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _avalaraAccountId = (avalaraAccountId as AvalaraAccount).id || avalaraAccountId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `avalara_accounts/${_avalaraAccountId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\tasync tax_categories(avalaraAccountId: string | AvalaraAccount, params?: QueryParamsList<TaxCategory>, options?: ResourcesConfig): Promise<ListResponse<TaxCategory>> {\n\t\tconst _avalaraAccountId = (avalaraAccountId as AvalaraAccount).id || avalaraAccountId as string\n\t\treturn this.resources.fetch<TaxCategory>({ type: 'tax_categories' }, `avalara_accounts/${_avalaraAccountId}/tax_categories`, params, options) as unknown as ListResponse<TaxCategory>\n\t}\n\n\n\tisAvalaraAccount(resource: any): resource is AvalaraAccount {\n\t\treturn resource.type && (resource.type === AvalaraAccounts.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): AvalaraAccountRel {\n\t\treturn super.relationshipOneToOne<AvalaraAccountRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): AvalaraAccountRel[] {\n\t\treturn super.relationshipOneToMany<AvalaraAccountRel>(...ids)\n\t}\n\n\n\ttype(): AvalaraAccountType {\n\t\treturn AvalaraAccounts.TYPE\n\t}\n\n}\n\n\nconst instance = new AvalaraAccounts()\nexport default instance\n\nexport type { AvalaraAccounts, AvalaraAccount, AvalaraAccountCreate, AvalaraAccountUpdate, AvalaraAccountType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/order_factories.ts"],"names":[],"mappings":";;;AAoEA,IAAM,cAAA,GAAN,MAAM,eAAA,SAAuB,
|
1
|
+
{"version":3,"sources":["../src/resources/order_factories.ts"],"names":[],"mappings":";;;AAoEA,IAAM,cAAA,GAAN,MAAM,eAAA,SAAuB,WAAA,CAA0B;AAAA,EAEtD,OAAgB,IAAA,GAAyB,iBAAA;AAAA,EAEzC,MAAM,YAAA,CAAa,cAAA,EAAuC,MAAA,EAAqC,OAAA,EAA2C;AACzI,IAAA,MAAM,eAAA,GAAmB,eAAgC,EAAA,IAAM,cAAA;AAC/D,IAAA,OAAO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-EEFOL62K.js","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Order } from './orders'\nimport type { Event } from './events'\n\n\ntype OrderFactoryType = 'order_factories'\ntype OrderFactoryRel = ResourceRel & { type: OrderFactoryType }\n\n\nexport type OrderFactorySort = Pick<OrderFactory, 'id' | 'status' | 'started_at' | 'completed_at' | 'failed_at' | 'errors_count'> & ResourceSort\n// export type OrderFactoryFilter = Pick<OrderFactory, 'id' | 'status' | 'started_at' | 'completed_at' | 'failed_at' | 'errors_count'> & ResourceFilter\n\n\ninterface OrderFactory extends Resource {\n\t\n\treadonly type: OrderFactoryType\n\n\t/** \n\t * The order factory status. One of 'pending' (default), 'in_progress', 'aborted', 'failed', or 'completed'.\n\t * @example ```\"in_progress\"```\n\t */\n\tstatus: 'pending' | 'in_progress' | 'aborted' | 'failed' | 'completed'\n\t/** \n\t * Time at which the order copy was started.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarted_at?: string | null\n\t/** \n\t * Time at which the order copy was completed.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tcompleted_at?: string | null\n\t/** \n\t * Time at which the order copy has failed.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tfailed_at?: string | null\n\t/** \n\t * Contains the order copy errors, if any.\n\t * @example ```{\"status\":[\"cannot transition from draft to placed\"]}```\n\t */\n\terrors_log?: Record<string, any> | null\n\t/** \n\t * Indicates the number of copy errors, if any.\n\t * @example ```2```\n\t */\n\terrors_count?: number | null\n\t/** \n\t * Indicates if the target order must be placed upon copy.\n\t * @example ```true```\n\t */\n\tplace_target_order?: boolean | null\n\t/** \n\t * Indicates if the payment source within the source order customer's wallet must be copied.\n\t * @example ```true```\n\t */\n\treuse_wallet?: boolean | null\n\n\tsource_order?: Order | null\n\ttarget_order?: Order | null\n\tevents?: Event[] | null\n\n}\n\n\nclass OrderFactories extends ApiResource<OrderFactory> {\n\n\tstatic readonly TYPE: OrderFactoryType = 'order_factories' as const\n\n\tasync source_order(orderFactoryId: string | OrderFactory, params?: QueryParamsRetrieve<Order>, options?: ResourcesConfig): Promise<Order> {\n\t\tconst _orderFactoryId = (orderFactoryId as OrderFactory).id || orderFactoryId as string\n\t\treturn this.resources.fetch<Order>({ type: 'orders' }, `order_factories/${_orderFactoryId}/source_order`, params, options) as unknown as Order\n\t}\n\n\tasync target_order(orderFactoryId: string | OrderFactory, params?: QueryParamsRetrieve<Order>, options?: ResourcesConfig): Promise<Order> {\n\t\tconst _orderFactoryId = (orderFactoryId as OrderFactory).id || orderFactoryId as string\n\t\treturn this.resources.fetch<Order>({ type: 'orders' }, `order_factories/${_orderFactoryId}/target_order`, params, options) as unknown as Order\n\t}\n\n\tasync events(orderFactoryId: string | OrderFactory, params?: QueryParamsList<Event>, options?: ResourcesConfig): Promise<ListResponse<Event>> {\n\t\tconst _orderFactoryId = (orderFactoryId as OrderFactory).id || orderFactoryId as string\n\t\treturn this.resources.fetch<Event>({ type: 'events' }, `order_factories/${_orderFactoryId}/events`, params, options) as unknown as ListResponse<Event>\n\t}\n\n\n\tisOrderFactory(resource: any): resource is OrderFactory {\n\t\treturn resource.type && (resource.type === OrderFactories.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): OrderFactoryRel {\n\t\treturn super.relationshipOneToOne<OrderFactoryRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): OrderFactoryRel[] {\n\t\treturn super.relationshipOneToMany<OrderFactoryRel>(...ids)\n\t}\n\n\n\ttype(): OrderFactoryType {\n\t\treturn OrderFactories.TYPE\n\t}\n\n}\n\n\nconst instance = new OrderFactories()\nexport default instance\n\nexport type { OrderFactories, OrderFactory, OrderFactoryType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/promotions.ts"],"names":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AAoC,CAAA,GAAG,GAAG,CAAA;AAAA;AACxD,EAGA,IAAsB,GAAA;AACrB,IAAA,OAAO,WAAW,CAAA,IAAA;AAAA;AAGpB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,UAAW,EAAA;AAChC,IAAO,kBAAQ,GAAA","file":"chunk-EHWAGYNX.js","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Market } from './markets'\nimport type { OrderAmountPromotionRule } from './order_amount_promotion_rules'\nimport type { SkuListPromotionRule } from './sku_list_promotion_rules'\nimport type { CouponCodesPromotionRule } from './coupon_codes_promotion_rules'\nimport type { CustomPromotionRule } from './custom_promotion_rules'\nimport type { SkuList } from './sku_lists'\nimport type { Coupon } from './coupons'\nimport type { Attachment } from './attachments'\nimport type { Event } from './events'\nimport type { Tag } from './tags'\nimport type { Version } from './versions'\nimport type { PromotionRule } from './promotion_rules'\n\n\ntype PromotionType = 'promotions'\ntype PromotionRel = ResourceRel & { type: PromotionType }\n\n\nexport type PromotionSort = Pick<Promotion, 'id' | 'name' | 'currency_code' | 'exclusive' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceSort\n// export type PromotionFilter = Pick<Promotion, 'id' | 'name' | 'currency_code' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceFilter\n\n\ninterface Promotion extends Resource {\n\t\n\treadonly type: PromotionType\n\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname: string\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at: string\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at: string\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * The number of times this promotion has been applied.\n\t * @example ```2```\n\t */\n\ttotal_usage_count?: number | null\n\t/** \n\t * Indicates if the promotion is active (enabled and not expired).\n\t * @example ```true```\n\t */\n\tactive?: boolean | null\n\t/** \n\t * The promotion status. One of 'disabled', 'expired', 'pending', 'active', or 'inactive'.\n\t * @example ```\"pending\"```\n\t */\n\tstatus?: 'disabled' | 'expired' | 'pending' | 'active' | 'inactive' | null\n\t/** \n\t * Time at which this resource was disabled.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tdisabled_at?: string | null\n\n\tmarket?: Market | null\n\tpromotion_rules?: PromotionRule[] | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRule | null\n\tsku_list_promotion_rule?: SkuListPromotionRule | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRule | null\n\tcustom_promotion_rule?: CustomPromotionRule | null\n\tsku_list?: SkuList | null\n\tcoupons?: Coupon[] | null\n\tattachments?: Attachment[] | null\n\tevents?: Event[] | null\n\ttags?: Tag[] | null\n\tversions?: Version[] | null\n\n}\n\n\nclass Promotions extends ApiResource<Promotion> {\n\n\tstatic readonly TYPE: PromotionType = 'promotions' as const\n\n\tasync market(promotionId: string | Promotion, params?: QueryParamsRetrieve<Market>, options?: ResourcesConfig): Promise<Market> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Market>({ type: 'markets' }, `promotions/${_promotionId}/market`, params, options) as unknown as Market\n\t}\n\n\tasync order_amount_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<OrderAmountPromotionRule>, options?: ResourcesConfig): Promise<OrderAmountPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<OrderAmountPromotionRule>({ type: 'order_amount_promotion_rules' }, `promotions/${_promotionId}/order_amount_promotion_rule`, params, options) as unknown as OrderAmountPromotionRule\n\t}\n\n\tasync sku_list_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<SkuListPromotionRule>, options?: ResourcesConfig): Promise<SkuListPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<SkuListPromotionRule>({ type: 'sku_list_promotion_rules' }, `promotions/${_promotionId}/sku_list_promotion_rule`, params, options) as unknown as SkuListPromotionRule\n\t}\n\n\tasync coupon_codes_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<CouponCodesPromotionRule>, options?: ResourcesConfig): Promise<CouponCodesPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<CouponCodesPromotionRule>({ type: 'coupon_codes_promotion_rules' }, `promotions/${_promotionId}/coupon_codes_promotion_rule`, params, options) as unknown as CouponCodesPromotionRule\n\t}\n\n\tasync custom_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<CustomPromotionRule>, options?: ResourcesConfig): Promise<CustomPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<CustomPromotionRule>({ type: 'custom_promotion_rules' }, `promotions/${_promotionId}/custom_promotion_rule`, params, options) as unknown as CustomPromotionRule\n\t}\n\n\tasync sku_list(promotionId: string | Promotion, params?: QueryParamsRetrieve<SkuList>, options?: ResourcesConfig): Promise<SkuList> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<SkuList>({ type: 'sku_lists' }, `promotions/${_promotionId}/sku_list`, params, options) as unknown as SkuList\n\t}\n\n\tasync coupons(promotionId: string | Promotion, params?: QueryParamsList<Coupon>, options?: ResourcesConfig): Promise<ListResponse<Coupon>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Coupon>({ type: 'coupons' }, `promotions/${_promotionId}/coupons`, params, options) as unknown as ListResponse<Coupon>\n\t}\n\n\tasync attachments(promotionId: string | Promotion, params?: QueryParamsList<Attachment>, options?: ResourcesConfig): Promise<ListResponse<Attachment>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Attachment>({ type: 'attachments' }, `promotions/${_promotionId}/attachments`, params, options) as unknown as ListResponse<Attachment>\n\t}\n\n\tasync events(promotionId: string | Promotion, params?: QueryParamsList<Event>, options?: ResourcesConfig): Promise<ListResponse<Event>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Event>({ type: 'events' }, `promotions/${_promotionId}/events`, params, options) as unknown as ListResponse<Event>\n\t}\n\n\tasync tags(promotionId: string | Promotion, params?: QueryParamsList<Tag>, options?: ResourcesConfig): Promise<ListResponse<Tag>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Tag>({ type: 'tags' }, `promotions/${_promotionId}/tags`, params, options) as unknown as ListResponse<Tag>\n\t}\n\n\tasync versions(promotionId: string | Promotion, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `promotions/${_promotionId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\n\tisPromotion(resource: any): resource is Promotion {\n\t\treturn resource.type && (resource.type === Promotions.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): PromotionRel {\n\t\treturn super.relationshipOneToOne<PromotionRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): PromotionRel[] {\n\t\treturn super.relationshipOneToMany<PromotionRel>(...ids)\n\t}\n\n\n\ttype(): PromotionType {\n\t\treturn Promotions.TYPE\n\t}\n\n}\n\n\nconst instance = new Promotions()\nexport default instance\n\nexport type { Promotions, Promotion, PromotionType }\n"]}
|
1
|
+
{"version":3,"sources":["../src/resources/promotions.ts"],"names":[],"mappings":";;;AAsGA,IAAM,UAAA,GAAN,MAAM,WAAA,SAAmB,WAAA,CAAuB;AAAA,EAE/C,OAAgB,IAAA,GAAsB,YAAA;AAAA,EAEtC,MAAM,MAAA,CAAO,WAAA,EAAiC,MAAA,EAAsC,OAAA,EAA4C;AAC/H,IAAA,MAAM,YAAA,GAAgB,YAA0B,EAAA,IAAM,WAAA;AACtD,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,KAAA,CAAc,EAAE,IAAA,EAAM,SAAA,EAAU,EAAG,CAAA,WAAA,EAAc,YAAY,CAAA,OAAA,CAAA,EAAW,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC9G,EAEA,MAAM,2BAAA,CAA4B,WAAA,EAAiC,MAAA,EAAwD,OAAA,EAA8D;AACxL,IAAA,MAAM,YAAA,GAAgB,YAA0B,EAAA,IAAM,WAAA;AACtD,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,KAAA,CAAgC,EAAE,IAAA,EAAM,8BAAA,EAA+B,EAAG,CAAA,WAAA,EAAc,YAAY,CAAA,4BAAA,CAAA,EAAgC,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC1K,EAEA,MAAM,uBAAA,CAAwB,WAAA,EAAiC,MAAA,EAAoD,OAAA,EAA0D;AAC5K,IAAA,MAAM,YAAA,GAAgB,YAA0B,EAAA,IAAM,WAAA;AACtD,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,KAAA,CAA4B,EAAE,IAAA,EAAM,0BAAA,EAA2B,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AQ,OAAO,CAAA;AAAA;AAClH,EAGA,YAAY,QAAA,EAAsC;AACjD,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,WAAA,CAAW,IAAA;AAAA;AACvD,EAGA,aAAa,EAAA,EAA8C;AAC1D,IAAA,OAAO,KAAA,CAAM,qBAAmC,EAAE,CAAA;AAAA;AACnD,EAEA,sBAAsB,GAAA,EAA+B;AACpD,IAAA,OAAO,KAAA,CAAM,qBAAA,CAAoC,GAAG,GAAG,CAAA;AAAA;AACxD,EAGA,IAAA,GAAsB;AACrB,IAAA,OAAO,WAAA,CAAW,IAAA;AAAA;AAGpB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,UAAA,EAAW;AAChC,IAAO,kBAAA,GAAQ","file":"chunk-EHWAGYNX.js","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Market } from './markets'\nimport type { OrderAmountPromotionRule } from './order_amount_promotion_rules'\nimport type { SkuListPromotionRule } from './sku_list_promotion_rules'\nimport type { CouponCodesPromotionRule } from './coupon_codes_promotion_rules'\nimport type { CustomPromotionRule } from './custom_promotion_rules'\nimport type { SkuList } from './sku_lists'\nimport type { Coupon } from './coupons'\nimport type { Attachment } from './attachments'\nimport type { Event } from './events'\nimport type { Tag } from './tags'\nimport type { Version } from './versions'\nimport type { PromotionRule } from './promotion_rules'\n\n\ntype PromotionType = 'promotions'\ntype PromotionRel = ResourceRel & { type: PromotionType }\n\n\nexport type PromotionSort = Pick<Promotion, 'id' | 'name' | 'currency_code' | 'exclusive' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceSort\n// export type PromotionFilter = Pick<Promotion, 'id' | 'name' | 'currency_code' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceFilter\n\n\ninterface Promotion extends Resource {\n\t\n\treadonly type: PromotionType\n\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname: string\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at: string\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at: string\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * The number of times this promotion has been applied.\n\t * @example ```2```\n\t */\n\ttotal_usage_count?: number | null\n\t/** \n\t * Indicates if the promotion is active (enabled and not expired).\n\t * @example ```true```\n\t */\n\tactive?: boolean | null\n\t/** \n\t * The promotion status. One of 'disabled', 'expired', 'pending', 'active', or 'inactive'.\n\t * @example ```\"pending\"```\n\t */\n\tstatus?: 'disabled' | 'expired' | 'pending' | 'active' | 'inactive' | null\n\t/** \n\t * Time at which this resource was disabled.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tdisabled_at?: string | null\n\n\tmarket?: Market | null\n\tpromotion_rules?: PromotionRule[] | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRule | null\n\tsku_list_promotion_rule?: SkuListPromotionRule | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRule | null\n\tcustom_promotion_rule?: CustomPromotionRule | null\n\tsku_list?: SkuList | null\n\tcoupons?: Coupon[] | null\n\tattachments?: Attachment[] | null\n\tevents?: Event[] | null\n\ttags?: Tag[] | null\n\tversions?: Version[] | null\n\n}\n\n\nclass Promotions extends ApiResource<Promotion> {\n\n\tstatic readonly TYPE: PromotionType = 'promotions' as const\n\n\tasync market(promotionId: string | Promotion, params?: QueryParamsRetrieve<Market>, options?: ResourcesConfig): Promise<Market> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Market>({ type: 'markets' }, `promotions/${_promotionId}/market`, params, options) as unknown as Market\n\t}\n\n\tasync order_amount_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<OrderAmountPromotionRule>, options?: ResourcesConfig): Promise<OrderAmountPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<OrderAmountPromotionRule>({ type: 'order_amount_promotion_rules' }, `promotions/${_promotionId}/order_amount_promotion_rule`, params, options) as unknown as OrderAmountPromotionRule\n\t}\n\n\tasync sku_list_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<SkuListPromotionRule>, options?: ResourcesConfig): Promise<SkuListPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<SkuListPromotionRule>({ type: 'sku_list_promotion_rules' }, `promotions/${_promotionId}/sku_list_promotion_rule`, params, options) as unknown as SkuListPromotionRule\n\t}\n\n\tasync coupon_codes_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<CouponCodesPromotionRule>, options?: ResourcesConfig): Promise<CouponCodesPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<CouponCodesPromotionRule>({ type: 'coupon_codes_promotion_rules' }, `promotions/${_promotionId}/coupon_codes_promotion_rule`, params, options) as unknown as CouponCodesPromotionRule\n\t}\n\n\tasync custom_promotion_rule(promotionId: string | Promotion, params?: QueryParamsRetrieve<CustomPromotionRule>, options?: ResourcesConfig): Promise<CustomPromotionRule> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<CustomPromotionRule>({ type: 'custom_promotion_rules' }, `promotions/${_promotionId}/custom_promotion_rule`, params, options) as unknown as CustomPromotionRule\n\t}\n\n\tasync sku_list(promotionId: string | Promotion, params?: QueryParamsRetrieve<SkuList>, options?: ResourcesConfig): Promise<SkuList> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<SkuList>({ type: 'sku_lists' }, `promotions/${_promotionId}/sku_list`, params, options) as unknown as SkuList\n\t}\n\n\tasync coupons(promotionId: string | Promotion, params?: QueryParamsList<Coupon>, options?: ResourcesConfig): Promise<ListResponse<Coupon>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Coupon>({ type: 'coupons' }, `promotions/${_promotionId}/coupons`, params, options) as unknown as ListResponse<Coupon>\n\t}\n\n\tasync attachments(promotionId: string | Promotion, params?: QueryParamsList<Attachment>, options?: ResourcesConfig): Promise<ListResponse<Attachment>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Attachment>({ type: 'attachments' }, `promotions/${_promotionId}/attachments`, params, options) as unknown as ListResponse<Attachment>\n\t}\n\n\tasync events(promotionId: string | Promotion, params?: QueryParamsList<Event>, options?: ResourcesConfig): Promise<ListResponse<Event>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Event>({ type: 'events' }, `promotions/${_promotionId}/events`, params, options) as unknown as ListResponse<Event>\n\t}\n\n\tasync tags(promotionId: string | Promotion, params?: QueryParamsList<Tag>, options?: ResourcesConfig): Promise<ListResponse<Tag>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Tag>({ type: 'tags' }, `promotions/${_promotionId}/tags`, params, options) as unknown as ListResponse<Tag>\n\t}\n\n\tasync versions(promotionId: string | Promotion, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _promotionId = (promotionId as Promotion).id || promotionId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `promotions/${_promotionId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\n\tisPromotion(resource: any): resource is Promotion {\n\t\treturn resource.type && (resource.type === Promotions.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): PromotionRel {\n\t\treturn super.relationshipOneToOne<PromotionRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): PromotionRel[] {\n\t\treturn super.relationshipOneToMany<PromotionRel>(...ids)\n\t}\n\n\n\ttype(): PromotionType {\n\t\treturn Promotions.TYPE\n\t}\n\n}\n\n\nconst instance = new Promotions()\nexport default instance\n\nexport type { Promotions, Promotion, PromotionType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/event_callbacks.ts"],"names":[],"mappings":";;;AA6CA,IAAM,cAAA,GAAN,MAAM,eAAA,SAAuB,
|
1
|
+
{"version":3,"sources":["../src/resources/event_callbacks.ts"],"names":[],"mappings":";;;AA6CA,IAAM,cAAA,GAAN,MAAM,eAAA,SAAuB,WAAA,CAA2B;AAAA,EAEvD,OAAgB,IAAA,GAA0B,iBAAA;AAAA,EAE1C,MAAM,OAAA,CAAQ,eAAA,EAAyC,MAAA,EAAuC,OAAA,EAA6C;AAC1I,IAAA,MAAM,gBAAA,GAAoB,gBAAkC,EAAA,IAAM,eAAA;AAClE,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,KAAA,CAAe,EAAE,IAAA,EAAM,UAAA,EAAW,EAAG,CAAA,gBAAA,EAAmB,gBAAgB,CAAA,QAAA,CAAA,EAAY,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC1H,EAGA,gBAAgB,QAAA,EAA0C;AACzD,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,eAAA,CAAe,IAAA;AAAA;AAC3D,EAGA,aAAa,EAAA,EAAkD;AAC9D,IAAA,OAAO,KAAA,CAAM,qBAAuC,EAAE,CAAA;AAAA;AACvD,EAEA,sBAAsB,GAAA,EAAmC;AACxD,IAAA,OAAO,KAAA,CAAM,qBAAA,CAAwC,GAAG,GAAG,CAAA;AAAA;AAC5D,EAGA,IAAA,GAA0B;AACzB,IAAA,OAAO,eAAA,CAAe,IAAA;AAAA;AAGxB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,cAAA,EAAe;AACpC,IAAO,uBAAA,GAAQ","file":"chunk-ELBOXOTA.js","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceId, ResourcesConfig, ResourceRel, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve } from '../query'\n\nimport type { Webhook } from './webhooks'\n\n\ntype EventCallbackType = 'event_callbacks'\ntype EventCallbackRel = ResourceRel & { type: EventCallbackType }\n\n\nexport type EventCallbackSort = Pick<EventCallback, 'id' | 'response_code' | 'response_message'> & ResourceSort\n// export type EventCallbackFilter = Pick<EventCallback, 'id' | 'callback_url' | 'response_code' | 'response_message'> & ResourceFilter\n\n\ninterface EventCallback extends Resource {\n\t\n\treadonly type: EventCallbackType\n\n\t/** \n\t * The URI of the callback, inherited by the associated webhook.\n\t * @example ```\"https://yourapp.com/webhooks\"```\n\t */\n\tcallback_url: string\n\t/** \n\t * The payload sent to the callback endpoint, including the event affected resource and the specified includes.\n\t * @example ```{\"data\":{\"attributes\":{\"id\":\"PYWehaoXJj\",\"type\":\"orders\"}}}```\n\t */\n\tpayload?: Record<string, any> | null\n\t/** \n\t * The HTTP response code of the callback endpoint.\n\t * @example ```\"200\"```\n\t */\n\tresponse_code?: string | null\n\t/** \n\t * The HTTP response message of the callback endpoint.\n\t * @example ```\"OK\"```\n\t */\n\tresponse_message?: string | null\n\n\twebhook?: Webhook | null\n\n}\n\n\nclass EventCallbacks extends ApiResource<EventCallback> {\n\n\tstatic readonly TYPE: EventCallbackType = 'event_callbacks' as const\n\n\tasync webhook(eventCallbackId: string | EventCallback, params?: QueryParamsRetrieve<Webhook>, options?: ResourcesConfig): Promise<Webhook> {\n\t\tconst _eventCallbackId = (eventCallbackId as EventCallback).id || eventCallbackId as string\n\t\treturn this.resources.fetch<Webhook>({ type: 'webhooks' }, `event_callbacks/${_eventCallbackId}/webhook`, params, options) as unknown as Webhook\n\t}\n\n\n\tisEventCallback(resource: any): resource is EventCallback {\n\t\treturn resource.type && (resource.type === EventCallbacks.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): EventCallbackRel {\n\t\treturn super.relationshipOneToOne<EventCallbackRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): EventCallbackRel[] {\n\t\treturn super.relationshipOneToMany<EventCallbackRel>(...ids)\n\t}\n\n\n\ttype(): EventCallbackType {\n\t\treturn EventCallbacks.TYPE\n\t}\n\n}\n\n\nconst instance = new EventCallbacks()\nexport default instance\n\nexport type { EventCallbacks, EventCallback, EventCallbackType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/klarna_payments.ts"],"names":[],"mappings":";;;AAoFA,IAAM,cAAA,GAAN,MAAM,eAAA,SAAuB,
|
1
|
+
{"version":3,"sources":["../src/resources/klarna_payments.ts"],"names":[],"mappings":";;;AAoFA,IAAM,cAAA,GAAN,MAAM,eAAA,SAAuB,WAAA,CAA2B;AAAA,EAEvD,OAAgB,IAAA,GAA0B,iBAAA;AAAA,EAE1C,MAAM,MAAA,CAAO,QAAA,EAA+B,MAAA,EAA6C,OAAA,EAAmD;AAC3I,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,MAAA,CAA2C,EAAE,GAAG,QAAA,EAAU,IAAA,EAAM,eAAA,CAAe,IAAA,EAAK,EAAG,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC7H,EAEA,MAAM,MAAA,CAAO,QAAA,EAA+B,MAAA,EA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AG,CAAA,gBAAA,EAAmB,gBAAgB,CAAA,SAAA,CAAA,EAAa,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC3H,EAEA,MAAM,OAAA,CAAQ,EAAA,EAA4B,MAAA,EAA6C,OAAA,EAAmD;AACzI,IAAA,OAAO,KAAK,SAAA,CAAU,MAAA,CAA2C,EAAE,EAAA,EAAK,OAAO,OAAO,QAAA,GAAW,EAAA,GAAI,EAAA,CAAG,EAAA,EAAI,MAAM,eAAA,CAAe,IAAA,EAAM,SAAS,IAAA,EAAK,EAAG,QAAQ,OAAO,CAAA;AAAA;AACxK,EAGA,gBAAgB,QAAA,EAA0C;AACzD,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,eAAA,CAAe,IAAA;AAAA;AAC3D,EAGA,aAAa,EAAA,EAAkD;AAC9D,IAAA,OAAO,KAAA,CAAM,qBAAuC,EAAE,CAAA;AAAA;AACvD,EAEA,sBAAsB,GAAA,EAAmC;AACxD,IAAA,OAAO,KAAA,CAAM,qBAAA,CAAwC,GAAG,GAAG,CAAA;AAAA;AAC5D,EAGA,IAAA,GAA0B;AACzB,IAAA,OAAO,eAAA,CAAe,IAAA;AAAA;AAGxB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,cAAA,EAAe;AACpC,IAAO,uBAAA,GAAQ","file":"chunk-EP22KKHR.js","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Order, OrderType } from './orders'\nimport type { PaymentGateway } from './payment_gateways'\nimport type { Version } from './versions'\n\n\ntype KlarnaPaymentType = 'klarna_payments'\ntype KlarnaPaymentRel = ResourceRel & { type: KlarnaPaymentType }\ntype OrderRel = ResourceRel & { type: OrderType }\n\n\nexport type KlarnaPaymentSort = Pick<KlarnaPayment, 'id'> & ResourceSort\n// export type KlarnaPaymentFilter = Pick<KlarnaPayment, 'id' | 'mismatched_amounts'> & ResourceFilter\n\n\ninterface KlarnaPayment extends Resource {\n\t\n\treadonly type: KlarnaPaymentType\n\n\t/** \n\t * The identifier of the payment session.\n\t * @example ```\"xxxx-yyyy-zzzz\"```\n\t */\n\tsession_id?: string | null\n\t/** \n\t * The public token linked to your API credential. Available upon session creation.\n\t * @example ```\"xxxx-yyyy-zzzz\"```\n\t */\n\tclient_token?: string | null\n\t/** \n\t * The merchant available payment methods for the assoiated order. Available upon session creation.\n\t * @example ```[{\"foo\":\"bar\"}]```\n\t */\n\tpayment_methods: Array<Record<string, any>>\n\t/** \n\t * The token returned by a successful client authorization, mandatory to place the order.\n\t * @example ```\"xxxx-yyyy-zzzz\"```\n\t */\n\tauth_token?: string | null\n\t/** \n\t * Indicates if the order current amount differs form the one of the created payment intent.\n\t */\n\tmismatched_amounts?: boolean | null\n\t/** \n\t * Information about the payment instrument used in the transaction.\n\t * @example ```{\"issuer\":\"cl bank\",\"card_type\":\"visa\"}```\n\t */\n\tpayment_instrument?: Record<string, any> | null\n\n\torder?: Order | null\n\tpayment_gateway?: PaymentGateway | null\n\tversions?: Version[] | null\n\n}\n\n\ninterface KlarnaPaymentCreate extends ResourceCreate {\n\t\n\torder: OrderRel\n\n}\n\n\ninterface KlarnaPaymentUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The token returned by a successful client authorization, mandatory to place the order.\n\t * @example ```\"xxxx-yyyy-zzzz\"```\n\t */\n\tauth_token?: string | null\n\t/** \n\t * Send this attribute if you want to update the payment session with fresh order data.\n\t * @example ```true```\n\t */\n\t_update?: boolean | null\n\n\torder?: OrderRel | null\n\n}\n\n\nclass KlarnaPayments extends ApiResource<KlarnaPayment> {\n\n\tstatic readonly TYPE: KlarnaPaymentType = 'klarna_payments' as const\n\n\tasync create(resource: KlarnaPaymentCreate, params?: QueryParamsRetrieve<KlarnaPayment>, options?: ResourcesConfig): Promise<KlarnaPayment> {\n\t\treturn this.resources.create<KlarnaPaymentCreate, KlarnaPayment>({ ...resource, type: KlarnaPayments.TYPE }, params, options)\n\t}\n\n\tasync update(resource: KlarnaPaymentUpdate, params?: QueryParamsRetrieve<KlarnaPayment>, options?: ResourcesConfig): Promise<KlarnaPayment> {\n\t\treturn this.resources.update<KlarnaPaymentUpdate, KlarnaPayment>({ ...resource, type: KlarnaPayments.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: KlarnaPayments.TYPE } : id, options)\n\t}\n\n\tasync order(klarnaPaymentId: string | KlarnaPayment, params?: QueryParamsRetrieve<Order>, options?: ResourcesConfig): Promise<Order> {\n\t\tconst _klarnaPaymentId = (klarnaPaymentId as KlarnaPayment).id || klarnaPaymentId as string\n\t\treturn this.resources.fetch<Order>({ type: 'orders' }, `klarna_payments/${_klarnaPaymentId}/order`, params, options) as unknown as Order\n\t}\n\n\tasync payment_gateway(klarnaPaymentId: string | KlarnaPayment, params?: QueryParamsRetrieve<PaymentGateway>, options?: ResourcesConfig): Promise<PaymentGateway> {\n\t\tconst _klarnaPaymentId = (klarnaPaymentId as KlarnaPayment).id || klarnaPaymentId as string\n\t\treturn this.resources.fetch<PaymentGateway>({ type: 'payment_gateways' }, `klarna_payments/${_klarnaPaymentId}/payment_gateway`, params, options) as unknown as PaymentGateway\n\t}\n\n\tasync versions(klarnaPaymentId: string | KlarnaPayment, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _klarnaPaymentId = (klarnaPaymentId as KlarnaPayment).id || klarnaPaymentId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `klarna_payments/${_klarnaPaymentId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\tasync _update(id: string | KlarnaPayment, params?: QueryParamsRetrieve<KlarnaPayment>, options?: ResourcesConfig): Promise<KlarnaPayment> {\n\t\treturn this.resources.update<KlarnaPaymentUpdate, KlarnaPayment>({ id: (typeof id === 'string')? id: id.id, type: KlarnaPayments.TYPE, _update: true }, params, options)\n\t}\n\n\n\tisKlarnaPayment(resource: any): resource is KlarnaPayment {\n\t\treturn resource.type && (resource.type === KlarnaPayments.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): KlarnaPaymentRel {\n\t\treturn super.relationshipOneToOne<KlarnaPaymentRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): KlarnaPaymentRel[] {\n\t\treturn super.relationshipOneToMany<KlarnaPaymentRel>(...ids)\n\t}\n\n\n\ttype(): KlarnaPaymentType {\n\t\treturn KlarnaPayments.TYPE\n\t}\n\n}\n\n\nconst instance = new KlarnaPayments()\nexport default instance\n\nexport type { KlarnaPayments, KlarnaPayment, KlarnaPaymentCreate, KlarnaPaymentUpdate, KlarnaPaymentType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/merchants.ts"],"names":["ApiResource"],"mappings":";;;;;AA6DA,IAAM,SAAA,GAAN,MAAM,UAAA,SAAkBA,
|
1
|
+
{"version":3,"sources":["../src/resources/merchants.ts"],"names":["ApiResource"],"mappings":";;;;;AA6DA,IAAM,SAAA,GAAN,MAAM,UAAA,SAAkBA,6BAAA,CAAsB;AAAA,EAE7C,OAAgB,IAAA,GAAqB,WAAA;AAAA,EAErC,MAAM,MAAA,CAAO,QAAA,EAA0B,MAAA,EAAwC,OAAA,EAA8C;AAC5H,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,MAAA,CAAiC,EAAE,GAAG,QAAA,EAAU,IAAA,EAAM,UAAA,CAAU,IAAA,EAAK,EAAG,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC9G,EAEA,MAAM,MAAA,CAAO,QAAA,EAA0B,MAAA,EAAwC,OAAA,EAA8C;AAC5H,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,MAAA,CAAiC,EAAE,GAAG,QAAA,EA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C,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,UAAA,CAAU,IAAA;AAAA;AACtD,EAGA,aAAa,EAAA,EAA6C;AACzD,IAAA,OAAO,KAAA,CAAM,qBAAkC,EAAE,CAAA;AAAA;AAClD,EAEA,sBAAsB,GAAA,EAA8B;AACnD,IAAA,OAAO,KAAA,CAAM,qBAAA,CAAmC,GAAG,GAAG,CAAA;AAAA;AACvD,EAGA,IAAA,GAAqB;AACpB,IAAA,OAAO,UAAA,CAAU,IAAA;AAAA;AAGnB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,SAAA,EAAU;AAC/B,IAAO,iBAAA,GAAQ","file":"chunk-EP7MAEQH.cjs","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Address, AddressType } from './addresses'\nimport type { Attachment } from './attachments'\nimport type { Version } from './versions'\n\n\ntype MerchantType = 'merchants'\ntype MerchantRel = ResourceRel & { type: MerchantType }\ntype AddressRel = ResourceRel & { type: AddressType }\n\n\nexport type MerchantSort = Pick<Merchant, 'id' | 'name'> & ResourceSort\n// export type MerchantFilter = Pick<Merchant, 'id' | 'name'> & ResourceFilter\n\n\ninterface Merchant extends Resource {\n\t\n\treadonly type: MerchantType\n\n\t/** \n\t * The merchant's internal name.\n\t * @example ```\"The Brand Inc.\"```\n\t */\n\tname: string\n\n\taddress?: Address | null\n\tattachments?: Attachment[] | null\n\tversions?: Version[] | null\n\n}\n\n\ninterface MerchantCreate extends ResourceCreate {\n\t\n\t/** \n\t * The merchant's internal name.\n\t * @example ```\"The Brand Inc.\"```\n\t */\n\tname: string\n\n\taddress: AddressRel\n\n}\n\n\ninterface MerchantUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The merchant's internal name.\n\t * @example ```\"The Brand Inc.\"```\n\t */\n\tname?: string | null\n\n\taddress?: AddressRel | null\n\n}\n\n\nclass Merchants extends ApiResource<Merchant> {\n\n\tstatic readonly TYPE: MerchantType = 'merchants' as const\n\n\tasync create(resource: MerchantCreate, params?: QueryParamsRetrieve<Merchant>, options?: ResourcesConfig): Promise<Merchant> {\n\t\treturn this.resources.create<MerchantCreate, Merchant>({ ...resource, type: Merchants.TYPE }, params, options)\n\t}\n\n\tasync update(resource: MerchantUpdate, params?: QueryParamsRetrieve<Merchant>, options?: ResourcesConfig): Promise<Merchant> {\n\t\treturn this.resources.update<MerchantUpdate, Merchant>({ ...resource, type: Merchants.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: Merchants.TYPE } : id, options)\n\t}\n\n\tasync address(merchantId: string | Merchant, params?: QueryParamsRetrieve<Address>, options?: ResourcesConfig): Promise<Address> {\n\t\tconst _merchantId = (merchantId as Merchant).id || merchantId as string\n\t\treturn this.resources.fetch<Address>({ type: 'addresses' }, `merchants/${_merchantId}/address`, params, options) as unknown as Address\n\t}\n\n\tasync attachments(merchantId: string | Merchant, params?: QueryParamsList<Attachment>, options?: ResourcesConfig): Promise<ListResponse<Attachment>> {\n\t\tconst _merchantId = (merchantId as Merchant).id || merchantId as string\n\t\treturn this.resources.fetch<Attachment>({ type: 'attachments' }, `merchants/${_merchantId}/attachments`, params, options) as unknown as ListResponse<Attachment>\n\t}\n\n\tasync versions(merchantId: string | Merchant, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _merchantId = (merchantId as Merchant).id || merchantId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `merchants/${_merchantId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\n\tisMerchant(resource: any): resource is Merchant {\n\t\treturn resource.type && (resource.type === Merchants.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): MerchantRel {\n\t\treturn super.relationshipOneToOne<MerchantRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): MerchantRel[] {\n\t\treturn super.relationshipOneToMany<MerchantRel>(...ids)\n\t}\n\n\n\ttype(): MerchantType {\n\t\treturn Merchants.TYPE\n\t}\n\n}\n\n\nconst instance = new Merchants()\nexport default instance\n\nexport type { Merchants, Merchant, MerchantCreate, MerchantUpdate, MerchantType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/fixed_price_promotions.ts"],"names":["ApiResource"],"mappings":";;;;;AAsQA,IAAM,oBAAA,GAAN,MAAM,qBAAA,SAA6BA,6BAAiC,CAAA;AAAA,EAEnE,OAAgB,IAAgC,GAAA,wBAAA;AAAA,EAEhD,MAAM,MAAA,CAAO,QAAqC,EAAA,MAAA,EAAmD,OAAyD,EAAA;AAC7J,IAAO,OAAA,IAAA,CAAK,SAAU,CAAA,MAAA,CAAuD,EAAE,GAAG,QAAU,EAAA,IAAA,EAAM,qBAAqB,CAAA,IAAA,EAAQ,EAAA,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC/I,EAEA,MAAM,MAAA,CAAO,QAAqC,EAAA,MAAA,EAAmD,OAAyD,EAAA;AAC7J,IAAO,OAAA,IAAA,CAAK,SAAU,CAAA,MAAA,CAAuD,EAAE,GAAG,QAAU,EAAA,IAAA,EAAM,qBAAqB,CAAA,IAAA,EAAQ,EAAA,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC/I,EAEA,MAAM,MAAO,CAAA,EAAA,EAAyB,OAA0C,EAAA;AAC/E,IAAA,MAAM,IAAK,CAAA,SAAA,CAAU,MAAQ,CAAA,OAAO,EAAO,KAAA,QAAA,GAAW,EAAE,EAAA,EAAI,IAAM,EAAA,qBAAA,CAAqB,IAAK,EAAA,GAAI,IAAI,OAAO,CAAA;AAAA;AAC5G,EAEA,MAAM,MAAA,CAAO,qBAAqD,EAAA,MAAA,EAAsC,OAA4C,E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A,aAAa,EAAwD,EAAA;AACpE,IAAO,OAAA,KAAA,CAAM,qBAA6C,EAAE,CAAA;AAAA;AAC7D,EAEA,sBAAsB,GAAyC,EAAA;AAC9D,IAAO,OAAA,KAAA,CAAM,qBAA8C,CAAA,GAAG,GAAG,CAAA;AAAA;AAClE,EAGA,IAAgC,GAAA;AAC/B,IAAA,OAAO,qBAAqB,CAAA,IAAA;AAAA;AAG9B,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,oBAAqB,EAAA;AAC1C,IAAO,8BAAQ,GAAA","file":"chunk-EQD223JW.cjs","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Market, MarketType } from './markets'\nimport type { OrderAmountPromotionRule, OrderAmountPromotionRuleType } from './order_amount_promotion_rules'\nimport type { SkuListPromotionRule, SkuListPromotionRuleType } from './sku_list_promotion_rules'\nimport type { CouponCodesPromotionRule, CouponCodesPromotionRuleType } from './coupon_codes_promotion_rules'\nimport type { CustomPromotionRule, CustomPromotionRuleType } from './custom_promotion_rules'\nimport type { SkuList, SkuListType } from './sku_lists'\nimport type { Coupon } from './coupons'\nimport type { Attachment } from './attachments'\nimport type { Event } from './events'\nimport type { Tag, TagType } from './tags'\nimport type { Version } from './versions'\nimport type { Sku } from './skus'\nimport type { PromotionRule } from './promotion_rules'\n\n\ntype FixedPricePromotionType = 'fixed_price_promotions'\ntype FixedPricePromotionRel = ResourceRel & { type: FixedPricePromotionType }\ntype MarketRel = ResourceRel & { type: MarketType }\ntype OrderAmountPromotionRuleRel = ResourceRel & { type: OrderAmountPromotionRuleType }\ntype SkuListPromotionRuleRel = ResourceRel & { type: SkuListPromotionRuleType }\ntype CouponCodesPromotionRuleRel = ResourceRel & { type: CouponCodesPromotionRuleType }\ntype CustomPromotionRuleRel = ResourceRel & { type: CustomPromotionRuleType }\ntype SkuListRel = ResourceRel & { type: SkuListType }\ntype TagRel = ResourceRel & { type: TagType }\n\n\nexport type FixedPricePromotionSort = Pick<FixedPricePromotion, 'id' | 'name' | 'currency_code' | 'exclusive' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceSort\n// export type FixedPricePromotionFilter = Pick<FixedPricePromotion, 'id' | 'name' | 'currency_code' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceFilter\n\n\ninterface FixedPricePromotion extends Resource {\n\t\n\treadonly type: FixedPricePromotionType\n\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname: string\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at: string\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at: string\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * The number of times this promotion has been applied.\n\t * @example ```2```\n\t */\n\ttotal_usage_count?: number | null\n\t/** \n\t * Indicates if the promotion is active (enabled and not expired).\n\t * @example ```true```\n\t */\n\tactive?: boolean | null\n\t/** \n\t * The promotion status. One of 'disabled', 'expired', 'pending', 'active', or 'inactive'.\n\t * @example ```\"pending\"```\n\t */\n\tstatus?: 'disabled' | 'expired' | 'pending' | 'active' | 'inactive' | null\n\t/** \n\t * Time at which this resource was disabled.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tdisabled_at?: string | null\n\t/** \n\t * The price fixed amount to be applied on matching SKUs, in cents.\n\t * @example ```1000```\n\t */\n\tfixed_amount_cents: number\n\t/** \n\t * The discount fixed amount to be applied, float.\n\t * @example ```10```\n\t */\n\tfixed_amount_float?: number | null\n\t/** \n\t * The discount fixed amount to be applied, formatted.\n\t * @example ```\"€10,00\"```\n\t */\n\tformatted_fixed_amount?: string | null\n\n\tmarket?: Market | null\n\tpromotion_rules?: PromotionRule[] | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRule | null\n\tsku_list_promotion_rule?: SkuListPromotionRule | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRule | null\n\tcustom_promotion_rule?: CustomPromotionRule | null\n\tsku_list?: SkuList | null\n\tcoupons?: Coupon[] | null\n\tattachments?: Attachment[] | null\n\tevents?: Event[] | null\n\ttags?: Tag[] | null\n\tversions?: Version[] | null\n\tskus?: Sku[] | null\n\n}\n\n\ninterface FixedPricePromotionCreate extends ResourceCreate {\n\t\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname: string\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at: string\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at: string\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * Send this attribute if you want to mark this resource as disabled.\n\t * @example ```true```\n\t */\n\t_disable?: boolean | null\n\t/** \n\t * Send this attribute if you want to mark this resource as enabled.\n\t * @example ```true```\n\t */\n\t_enable?: boolean | null\n\t/** \n\t * The price fixed amount to be applied on matching SKUs, in cents.\n\t * @example ```1000```\n\t */\n\tfixed_amount_cents: number\n\n\tmarket?: MarketRel | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRuleRel | null\n\tsku_list_promotion_rule?: SkuListPromotionRuleRel | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRuleRel | null\n\tcustom_promotion_rule?: CustomPromotionRuleRel | null\n\tsku_list: SkuListRel\n\ttags?: TagRel[] | null\n\n}\n\n\ninterface FixedPricePromotionUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname?: string | null\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at?: string | null\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at?: string | null\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * Send this attribute if you want to mark this resource as disabled.\n\t * @example ```true```\n\t */\n\t_disable?: boolean | null\n\t/** \n\t * Send this attribute if you want to mark this resource as enabled.\n\t * @example ```true```\n\t */\n\t_enable?: boolean | null\n\t/** \n\t * Comma separated list of tags to be added. Duplicates, invalid and non existing ones are discarded. Cannot be passed by sales channels.\n\t */\n\t_add_tags?: string | null\n\t/** \n\t * Comma separated list of tags to be removed. Duplicates, invalid and non existing ones are discarded. Cannot be passed by sales channels.\n\t */\n\t_remove_tags?: string | null\n\t/** \n\t * The price fixed amount to be applied on matching SKUs, in cents.\n\t * @example ```1000```\n\t */\n\tfixed_amount_cents?: number | null\n\n\tmarket?: MarketRel | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRuleRel | null\n\tsku_list_promotion_rule?: SkuListPromotionRuleRel | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRuleRel | null\n\tcustom_promotion_rule?: CustomPromotionRuleRel | null\n\tsku_list?: SkuListRel | null\n\ttags?: TagRel[] | null\n\n}\n\n\nclass FixedPricePromotions extends ApiResource<FixedPricePromotion> {\n\n\tstatic readonly TYPE: FixedPricePromotionType = 'fixed_price_promotions' as const\n\n\tasync create(resource: FixedPricePromotionCreate, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.create<FixedPricePromotionCreate, FixedPricePromotion>({ ...resource, type: FixedPricePromotions.TYPE }, params, options)\n\t}\n\n\tasync update(resource: FixedPricePromotionUpdate, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ ...resource, type: FixedPricePromotions.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: FixedPricePromotions.TYPE } : id, options)\n\t}\n\n\tasync market(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<Market>, options?: ResourcesConfig): Promise<Market> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Market>({ type: 'markets' }, `fixed_price_promotions/${_fixedPricePromotionId}/market`, params, options) as unknown as Market\n\t}\n\n\tasync order_amount_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<OrderAmountPromotionRule>, options?: ResourcesConfig): Promise<OrderAmountPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<OrderAmountPromotionRule>({ type: 'order_amount_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/order_amount_promotion_rule`, params, options) as unknown as OrderAmountPromotionRule\n\t}\n\n\tasync sku_list_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<SkuListPromotionRule>, options?: ResourcesConfig): Promise<SkuListPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<SkuListPromotionRule>({ type: 'sku_list_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/sku_list_promotion_rule`, params, options) as unknown as SkuListPromotionRule\n\t}\n\n\tasync coupon_codes_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<CouponCodesPromotionRule>, options?: ResourcesConfig): Promise<CouponCodesPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<CouponCodesPromotionRule>({ type: 'coupon_codes_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/coupon_codes_promotion_rule`, params, options) as unknown as CouponCodesPromotionRule\n\t}\n\n\tasync custom_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<CustomPromotionRule>, options?: ResourcesConfig): Promise<CustomPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<CustomPromotionRule>({ type: 'custom_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/custom_promotion_rule`, params, options) as unknown as CustomPromotionRule\n\t}\n\n\tasync sku_list(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<SkuList>, options?: ResourcesConfig): Promise<SkuList> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<SkuList>({ type: 'sku_lists' }, `fixed_price_promotions/${_fixedPricePromotionId}/sku_list`, params, options) as unknown as SkuList\n\t}\n\n\tasync coupons(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Coupon>, options?: ResourcesConfig): Promise<ListResponse<Coupon>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Coupon>({ type: 'coupons' }, `fixed_price_promotions/${_fixedPricePromotionId}/coupons`, params, options) as unknown as ListResponse<Coupon>\n\t}\n\n\tasync attachments(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Attachment>, options?: ResourcesConfig): Promise<ListResponse<Attachment>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Attachment>({ type: 'attachments' }, `fixed_price_promotions/${_fixedPricePromotionId}/attachments`, params, options) as unknown as ListResponse<Attachment>\n\t}\n\n\tasync events(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Event>, options?: ResourcesConfig): Promise<ListResponse<Event>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Event>({ type: 'events' }, `fixed_price_promotions/${_fixedPricePromotionId}/events`, params, options) as unknown as ListResponse<Event>\n\t}\n\n\tasync tags(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Tag>, options?: ResourcesConfig): Promise<ListResponse<Tag>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Tag>({ type: 'tags' }, `fixed_price_promotions/${_fixedPricePromotionId}/tags`, params, options) as unknown as ListResponse<Tag>\n\t}\n\n\tasync versions(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `fixed_price_promotions/${_fixedPricePromotionId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\tasync skus(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Sku>, options?: ResourcesConfig): Promise<ListResponse<Sku>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Sku>({ type: 'skus' }, `fixed_price_promotions/${_fixedPricePromotionId}/skus`, params, options) as unknown as ListResponse<Sku>\n\t}\n\n\tasync _disable(id: string | FixedPricePromotion, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _disable: true }, params, options)\n\t}\n\n\tasync _enable(id: string | FixedPricePromotion, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _enable: true }, params, options)\n\t}\n\n\tasync _add_tags(id: string | FixedPricePromotion, triggerValue: string, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _add_tags: triggerValue }, params, options)\n\t}\n\n\tasync _remove_tags(id: string | FixedPricePromotion, triggerValue: string, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _remove_tags: triggerValue }, params, options)\n\t}\n\n\n\tisFixedPricePromotion(resource: any): resource is FixedPricePromotion {\n\t\treturn resource.type && (resource.type === FixedPricePromotions.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): FixedPricePromotionRel {\n\t\treturn super.relationshipOneToOne<FixedPricePromotionRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): FixedPricePromotionRel[] {\n\t\treturn super.relationshipOneToMany<FixedPricePromotionRel>(...ids)\n\t}\n\n\n\ttype(): FixedPricePromotionType {\n\t\treturn FixedPricePromotions.TYPE\n\t}\n\n}\n\n\nconst instance = new FixedPricePromotions()\nexport default instance\n\nexport type { FixedPricePromotions, FixedPricePromotion, FixedPricePromotionCreate, FixedPricePromotionUpdate, FixedPricePromotionType }\n"]}
|
1
|
+
{"version":3,"sources":["../src/resources/fixed_price_promotions.ts"],"names":["ApiResource"],"mappings":";;;;;AAsQA,IAAM,oBAAA,GAAN,MAAM,qBAAA,SAA6BA,6BAAA,CAAiC;AAAA,EAEnE,OAAgB,IAAA,GAAgC,wBAAA;AAAA,EAEhD,MAAM,MAAA,CAAO,QAAA,EAAqC,MAAA,EAAmD,OAAA,EAAyD;AAC7J,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,MAAA,CAAuD,EAAE,GAAG,QAAA,EAAU,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CAAU,MAAA,CAAuD,EAAE,EAAA,EAAK,OAAO,OAAO,QAAA,GAAW,EAAA,GAAI,EAAA,CAAG,EAAA,EAAI,MAAM,qBAAA,CAAqB,IAAA,EAAM,WAAW,YAAA,EAAa,EAAG,QAAQ,OAAO,CAAA;AAAA;AACpM,EAEA,MAAM,YAAA,CAAa,EAAA,EAAkC,YAAA,EAAsB,QAAmD,OAAA,EAAyD;AACtL,IAAA,OAAO,KAAK,SAAA,CAAU,MAAA,CAAuD,EAAE,EAAA,EAAK,OAAO,OAAO,QAAA,GAAW,EAAA,GAAI,EAAA,CAAG,EAAA,EAAI,MAAM,qBAAA,CAAqB,IAAA,EAAM,cAAc,YAAA,EAAa,EAAG,QAAQ,OAAO,CAAA;AAAA;AACvM,EAGA,sBAAsB,QAAA,EAAgD;AACrE,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,qBAAA,CAAqB,IAAA;AAAA;AACjE,EAGA,aAAa,EAAA,EAAwD;AACpE,IAAA,OAAO,KAAA,CAAM,qBAA6C,EAAE,CAAA;AAAA;AAC7D,EAEA,sBAAsB,GAAA,EAAyC;AAC9D,IAAA,OAAO,KAAA,CAAM,qBAAA,CAA8C,GAAG,GAAG,CAAA;AAAA;AAClE,EAGA,IAAA,GAAgC;AAC/B,IAAA,OAAO,qBAAA,CAAqB,IAAA;AAAA;AAG9B,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,oBAAA,EAAqB;AAC1C,IAAO,8BAAA,GAAQ","file":"chunk-EQD223JW.cjs","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Market, MarketType } from './markets'\nimport type { OrderAmountPromotionRule, OrderAmountPromotionRuleType } from './order_amount_promotion_rules'\nimport type { SkuListPromotionRule, SkuListPromotionRuleType } from './sku_list_promotion_rules'\nimport type { CouponCodesPromotionRule, CouponCodesPromotionRuleType } from './coupon_codes_promotion_rules'\nimport type { CustomPromotionRule, CustomPromotionRuleType } from './custom_promotion_rules'\nimport type { SkuList, SkuListType } from './sku_lists'\nimport type { Coupon } from './coupons'\nimport type { Attachment } from './attachments'\nimport type { Event } from './events'\nimport type { Tag, TagType } from './tags'\nimport type { Version } from './versions'\nimport type { Sku } from './skus'\nimport type { PromotionRule } from './promotion_rules'\n\n\ntype FixedPricePromotionType = 'fixed_price_promotions'\ntype FixedPricePromotionRel = ResourceRel & { type: FixedPricePromotionType }\ntype MarketRel = ResourceRel & { type: MarketType }\ntype OrderAmountPromotionRuleRel = ResourceRel & { type: OrderAmountPromotionRuleType }\ntype SkuListPromotionRuleRel = ResourceRel & { type: SkuListPromotionRuleType }\ntype CouponCodesPromotionRuleRel = ResourceRel & { type: CouponCodesPromotionRuleType }\ntype CustomPromotionRuleRel = ResourceRel & { type: CustomPromotionRuleType }\ntype SkuListRel = ResourceRel & { type: SkuListType }\ntype TagRel = ResourceRel & { type: TagType }\n\n\nexport type FixedPricePromotionSort = Pick<FixedPricePromotion, 'id' | 'name' | 'currency_code' | 'exclusive' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceSort\n// export type FixedPricePromotionFilter = Pick<FixedPricePromotion, 'id' | 'name' | 'currency_code' | 'priority' | 'starts_at' | 'expires_at' | 'total_usage_limit' | 'total_usage_count' | 'disabled_at'> & ResourceFilter\n\n\ninterface FixedPricePromotion extends Resource {\n\t\n\treadonly type: FixedPricePromotionType\n\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname: string\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at: string\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at: string\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * The number of times this promotion has been applied.\n\t * @example ```2```\n\t */\n\ttotal_usage_count?: number | null\n\t/** \n\t * Indicates if the promotion is active (enabled and not expired).\n\t * @example ```true```\n\t */\n\tactive?: boolean | null\n\t/** \n\t * The promotion status. One of 'disabled', 'expired', 'pending', 'active', or 'inactive'.\n\t * @example ```\"pending\"```\n\t */\n\tstatus?: 'disabled' | 'expired' | 'pending' | 'active' | 'inactive' | null\n\t/** \n\t * Time at which this resource was disabled.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tdisabled_at?: string | null\n\t/** \n\t * The price fixed amount to be applied on matching SKUs, in cents.\n\t * @example ```1000```\n\t */\n\tfixed_amount_cents: number\n\t/** \n\t * The discount fixed amount to be applied, float.\n\t * @example ```10```\n\t */\n\tfixed_amount_float?: number | null\n\t/** \n\t * The discount fixed amount to be applied, formatted.\n\t * @example ```\"€10,00\"```\n\t */\n\tformatted_fixed_amount?: string | null\n\n\tmarket?: Market | null\n\tpromotion_rules?: PromotionRule[] | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRule | null\n\tsku_list_promotion_rule?: SkuListPromotionRule | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRule | null\n\tcustom_promotion_rule?: CustomPromotionRule | null\n\tsku_list?: SkuList | null\n\tcoupons?: Coupon[] | null\n\tattachments?: Attachment[] | null\n\tevents?: Event[] | null\n\ttags?: Tag[] | null\n\tversions?: Version[] | null\n\tskus?: Sku[] | null\n\n}\n\n\ninterface FixedPricePromotionCreate extends ResourceCreate {\n\t\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname: string\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at: string\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at: string\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * Send this attribute if you want to mark this resource as disabled.\n\t * @example ```true```\n\t */\n\t_disable?: boolean | null\n\t/** \n\t * Send this attribute if you want to mark this resource as enabled.\n\t * @example ```true```\n\t */\n\t_enable?: boolean | null\n\t/** \n\t * The price fixed amount to be applied on matching SKUs, in cents.\n\t * @example ```1000```\n\t */\n\tfixed_amount_cents: number\n\n\tmarket?: MarketRel | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRuleRel | null\n\tsku_list_promotion_rule?: SkuListPromotionRuleRel | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRuleRel | null\n\tcustom_promotion_rule?: CustomPromotionRuleRel | null\n\tsku_list: SkuListRel\n\ttags?: TagRel[] | null\n\n}\n\n\ninterface FixedPricePromotionUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The promotion's internal name.\n\t * @example ```\"Personal promotion\"```\n\t */\n\tname?: string | null\n\t/** \n\t * The international 3-letter currency code as defined by the ISO 4217 standard.\n\t * @example ```\"EUR\"```\n\t */\n\tcurrency_code?: string | null\n\t/** \n\t * Indicates if the promotion will be applied exclusively, based on its priority score.\n\t * @example ```true```\n\t */\n\texclusive?: boolean | null\n\t/** \n\t * The priority assigned to the promotion (lower means higher priority).\n\t * @example ```2```\n\t */\n\tpriority?: number | null\n\t/** \n\t * The activation date/time of this promotion.\n\t * @example ```\"2018-01-01T12:00:00.000Z\"```\n\t */\n\tstarts_at?: string | null\n\t/** \n\t * The expiration date/time of this promotion (must be after starts_at).\n\t * @example ```\"2018-01-02T12:00:00.000Z\"```\n\t */\n\texpires_at?: string | null\n\t/** \n\t * The total number of times this promotion can be applied. When 'null' it means promotion can be applied infinite times.\n\t * @example ```5```\n\t */\n\ttotal_usage_limit?: number | null\n\t/** \n\t * Send this attribute if you want to mark this resource as disabled.\n\t * @example ```true```\n\t */\n\t_disable?: boolean | null\n\t/** \n\t * Send this attribute if you want to mark this resource as enabled.\n\t * @example ```true```\n\t */\n\t_enable?: boolean | null\n\t/** \n\t * Comma separated list of tags to be added. Duplicates, invalid and non existing ones are discarded. Cannot be passed by sales channels.\n\t */\n\t_add_tags?: string | null\n\t/** \n\t * Comma separated list of tags to be removed. Duplicates, invalid and non existing ones are discarded. Cannot be passed by sales channels.\n\t */\n\t_remove_tags?: string | null\n\t/** \n\t * The price fixed amount to be applied on matching SKUs, in cents.\n\t * @example ```1000```\n\t */\n\tfixed_amount_cents?: number | null\n\n\tmarket?: MarketRel | null\n\torder_amount_promotion_rule?: OrderAmountPromotionRuleRel | null\n\tsku_list_promotion_rule?: SkuListPromotionRuleRel | null\n\tcoupon_codes_promotion_rule?: CouponCodesPromotionRuleRel | null\n\tcustom_promotion_rule?: CustomPromotionRuleRel | null\n\tsku_list?: SkuListRel | null\n\ttags?: TagRel[] | null\n\n}\n\n\nclass FixedPricePromotions extends ApiResource<FixedPricePromotion> {\n\n\tstatic readonly TYPE: FixedPricePromotionType = 'fixed_price_promotions' as const\n\n\tasync create(resource: FixedPricePromotionCreate, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.create<FixedPricePromotionCreate, FixedPricePromotion>({ ...resource, type: FixedPricePromotions.TYPE }, params, options)\n\t}\n\n\tasync update(resource: FixedPricePromotionUpdate, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ ...resource, type: FixedPricePromotions.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: FixedPricePromotions.TYPE } : id, options)\n\t}\n\n\tasync market(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<Market>, options?: ResourcesConfig): Promise<Market> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Market>({ type: 'markets' }, `fixed_price_promotions/${_fixedPricePromotionId}/market`, params, options) as unknown as Market\n\t}\n\n\tasync order_amount_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<OrderAmountPromotionRule>, options?: ResourcesConfig): Promise<OrderAmountPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<OrderAmountPromotionRule>({ type: 'order_amount_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/order_amount_promotion_rule`, params, options) as unknown as OrderAmountPromotionRule\n\t}\n\n\tasync sku_list_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<SkuListPromotionRule>, options?: ResourcesConfig): Promise<SkuListPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<SkuListPromotionRule>({ type: 'sku_list_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/sku_list_promotion_rule`, params, options) as unknown as SkuListPromotionRule\n\t}\n\n\tasync coupon_codes_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<CouponCodesPromotionRule>, options?: ResourcesConfig): Promise<CouponCodesPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<CouponCodesPromotionRule>({ type: 'coupon_codes_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/coupon_codes_promotion_rule`, params, options) as unknown as CouponCodesPromotionRule\n\t}\n\n\tasync custom_promotion_rule(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<CustomPromotionRule>, options?: ResourcesConfig): Promise<CustomPromotionRule> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<CustomPromotionRule>({ type: 'custom_promotion_rules' }, `fixed_price_promotions/${_fixedPricePromotionId}/custom_promotion_rule`, params, options) as unknown as CustomPromotionRule\n\t}\n\n\tasync sku_list(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsRetrieve<SkuList>, options?: ResourcesConfig): Promise<SkuList> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<SkuList>({ type: 'sku_lists' }, `fixed_price_promotions/${_fixedPricePromotionId}/sku_list`, params, options) as unknown as SkuList\n\t}\n\n\tasync coupons(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Coupon>, options?: ResourcesConfig): Promise<ListResponse<Coupon>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Coupon>({ type: 'coupons' }, `fixed_price_promotions/${_fixedPricePromotionId}/coupons`, params, options) as unknown as ListResponse<Coupon>\n\t}\n\n\tasync attachments(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Attachment>, options?: ResourcesConfig): Promise<ListResponse<Attachment>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Attachment>({ type: 'attachments' }, `fixed_price_promotions/${_fixedPricePromotionId}/attachments`, params, options) as unknown as ListResponse<Attachment>\n\t}\n\n\tasync events(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Event>, options?: ResourcesConfig): Promise<ListResponse<Event>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Event>({ type: 'events' }, `fixed_price_promotions/${_fixedPricePromotionId}/events`, params, options) as unknown as ListResponse<Event>\n\t}\n\n\tasync tags(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Tag>, options?: ResourcesConfig): Promise<ListResponse<Tag>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Tag>({ type: 'tags' }, `fixed_price_promotions/${_fixedPricePromotionId}/tags`, params, options) as unknown as ListResponse<Tag>\n\t}\n\n\tasync versions(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `fixed_price_promotions/${_fixedPricePromotionId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\tasync skus(fixedPricePromotionId: string | FixedPricePromotion, params?: QueryParamsList<Sku>, options?: ResourcesConfig): Promise<ListResponse<Sku>> {\n\t\tconst _fixedPricePromotionId = (fixedPricePromotionId as FixedPricePromotion).id || fixedPricePromotionId as string\n\t\treturn this.resources.fetch<Sku>({ type: 'skus' }, `fixed_price_promotions/${_fixedPricePromotionId}/skus`, params, options) as unknown as ListResponse<Sku>\n\t}\n\n\tasync _disable(id: string | FixedPricePromotion, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _disable: true }, params, options)\n\t}\n\n\tasync _enable(id: string | FixedPricePromotion, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _enable: true }, params, options)\n\t}\n\n\tasync _add_tags(id: string | FixedPricePromotion, triggerValue: string, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _add_tags: triggerValue }, params, options)\n\t}\n\n\tasync _remove_tags(id: string | FixedPricePromotion, triggerValue: string, params?: QueryParamsRetrieve<FixedPricePromotion>, options?: ResourcesConfig): Promise<FixedPricePromotion> {\n\t\treturn this.resources.update<FixedPricePromotionUpdate, FixedPricePromotion>({ id: (typeof id === 'string')? id: id.id, type: FixedPricePromotions.TYPE, _remove_tags: triggerValue }, params, options)\n\t}\n\n\n\tisFixedPricePromotion(resource: any): resource is FixedPricePromotion {\n\t\treturn resource.type && (resource.type === FixedPricePromotions.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): FixedPricePromotionRel {\n\t\treturn super.relationshipOneToOne<FixedPricePromotionRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): FixedPricePromotionRel[] {\n\t\treturn super.relationshipOneToMany<FixedPricePromotionRel>(...ids)\n\t}\n\n\n\ttype(): FixedPricePromotionType {\n\t\treturn FixedPricePromotions.TYPE\n\t}\n\n}\n\n\nconst instance = new FixedPricePromotions()\nexport default instance\n\nexport type { FixedPricePromotions, FixedPricePromotion, FixedPricePromotionCreate, FixedPricePromotionUpdate, FixedPricePromotionType }\n"]}
|
@@ -32,6 +32,9 @@ var AdyenPayments = class _AdyenPayments extends chunkQYDOENWU_cjs.ApiResource {
|
|
32
32
|
async _details(id, params, options) {
|
33
33
|
return this.resources.update({ id: typeof id === "string" ? id : id.id, type: _AdyenPayments.TYPE, _details: true }, params, options);
|
34
34
|
}
|
35
|
+
async _balance(id, params, options) {
|
36
|
+
return this.resources.update({ id: typeof id === "string" ? id : id.id, type: _AdyenPayments.TYPE, _balance: true }, params, options);
|
37
|
+
}
|
35
38
|
isAdyenPayment(resource) {
|
36
39
|
return resource.type && resource.type === _AdyenPayments.TYPE;
|
37
40
|
}
|
@@ -49,5 +52,5 @@ var instance = new AdyenPayments();
|
|
49
52
|
var adyen_payments_default = instance;
|
50
53
|
|
51
54
|
exports.adyen_payments_default = adyen_payments_default;
|
52
|
-
//# sourceMappingURL=chunk-
|
53
|
-
//# sourceMappingURL=chunk-
|
55
|
+
//# sourceMappingURL=chunk-ESMKOP42.cjs.map
|
56
|
+
//# sourceMappingURL=chunk-ESMKOP42.cjs.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../src/resources/adyen_payments.ts"],"names":["ApiResource"],"mappings":";;;;;AA6GA,IAAM,aAAA,GAAN,MAAM,cAAA,SAAsBA,6BAAA,CAA0B;AAAA,EAErD,OAAgB,IAAA,GAAyB,gBAAA;AAAA,EAEzC,MAAM,MAAA,CAAO,QAAA,EAA8B,MAAA,EAA4C,OAAA,EAAkD;AACxI,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,MAAA,CAAyC,EAA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AM,qBAAsC,EAAE,CAAA;AAAA;AACtD,EAEA,sBAAsB,GAAA,EAAkC;AACvD,IAAA,OAAO,KAAA,CAAM,qBAAA,CAAuC,GAAG,GAAG,CAAA;AAAA;AAC3D,EAGA,IAAA,GAAyB;AACxB,IAAA,OAAO,cAAA,CAAc,IAAA;AAAA;AAGvB,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,aAAA,EAAc;AACnC,IAAO,sBAAA,GAAQ","file":"chunk-ESMKOP42.cjs","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Order, OrderType } from './orders'\nimport type { PaymentGateway } from './payment_gateways'\nimport type { Version } from './versions'\n\n\ntype AdyenPaymentType = 'adyen_payments'\ntype AdyenPaymentRel = ResourceRel & { type: AdyenPaymentType }\ntype OrderRel = ResourceRel & { type: OrderType }\n\n\nexport type AdyenPaymentSort = Pick<AdyenPayment, 'id'> & ResourceSort\n// export type AdyenPaymentFilter = Pick<AdyenPayment, 'id'> & ResourceFilter\n\n\ninterface AdyenPayment extends Resource {\n\t\n\treadonly type: AdyenPaymentType\n\n\t/** \n\t * The public key linked to your API credential.\n\t * @example ```\"xxxx-yyyy-zzzz\"```\n\t */\n\tpublic_key?: string | null\n\t/** \n\t * The merchant available payment methods for the assoiated order (i.e. country and amount). Required by the Adyen JS SDK.\n\t * @example ```{\"foo\":\"bar\"}```\n\t */\n\tpayment_methods: Record<string, any>\n\t/** \n\t * The Adyen payment request data, collected by client.\n\t * @example ```{\"foo\":\"bar\"}```\n\t */\n\tpayment_request_data?: Record<string, any> | null\n\t/** \n\t * The Adyen additional details request data, collected by client.\n\t * @example ```{\"foo\":\"bar\"}```\n\t */\n\tpayment_request_details?: Record<string, any> | null\n\t/** \n\t * The Adyen payment response, used by client (includes 'resultCode' and 'action').\n\t * @example ```{\"foo\":\"bar\"}```\n\t */\n\tpayment_response?: Record<string, any> | null\n\t/** \n\t * Indicates if the order current amount differs form the one of the associated authorization.\n\t */\n\tmismatched_amounts?: boolean | null\n\t/** \n\t * The balance remaining on a shopper's gift card, must be computed by using its related trigger attribute.\n\t * @example ```1000```\n\t */\n\tbalance?: number | null\n\t/** \n\t * Information about the payment instrument used in the transaction.\n\t * @example ```{\"issuer\":\"cl bank\",\"card_type\":\"visa\"}```\n\t */\n\tpayment_instrument?: Record<string, any> | null\n\n\torder?: Order | null\n\tpayment_gateway?: PaymentGateway | null\n\tversions?: Version[] | null\n\n}\n\n\ninterface AdyenPaymentCreate extends ResourceCreate {\n\t\n\torder: OrderRel\n\n}\n\n\ninterface AdyenPaymentUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * The Adyen payment request data, collected by client.\n\t * @example ```{\"foo\":\"bar\"}```\n\t */\n\tpayment_request_data?: Record<string, any> | null\n\t/** \n\t * The Adyen additional details request data, collected by client.\n\t * @example ```{\"foo\":\"bar\"}```\n\t */\n\tpayment_request_details?: Record<string, any> | null\n\t/** \n\t * Send this attribute if you want to authorize the payment.\n\t * @example ```true```\n\t */\n\t_authorize?: boolean | null\n\t/** \n\t * Send this attribute if you want to send additional details the payment request.\n\t * @example ```true```\n\t */\n\t_details?: boolean | null\n\t/** \n\t * Send this attribute if you want retrieve the balance remaining on a shopper's gift card.\n\t * @example ```true```\n\t */\n\t_balance?: boolean | null\n\n\torder?: OrderRel | null\n\n}\n\n\nclass AdyenPayments extends ApiResource<AdyenPayment> {\n\n\tstatic readonly TYPE: AdyenPaymentType = 'adyen_payments' as const\n\n\tasync create(resource: AdyenPaymentCreate, params?: QueryParamsRetrieve<AdyenPayment>, options?: ResourcesConfig): Promise<AdyenPayment> {\n\t\treturn this.resources.create<AdyenPaymentCreate, AdyenPayment>({ ...resource, type: AdyenPayments.TYPE }, params, options)\n\t}\n\n\tasync update(resource: AdyenPaymentUpdate, params?: QueryParamsRetrieve<AdyenPayment>, options?: ResourcesConfig): Promise<AdyenPayment> {\n\t\treturn this.resources.update<AdyenPaymentUpdate, AdyenPayment>({ ...resource, type: AdyenPayments.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: AdyenPayments.TYPE } : id, options)\n\t}\n\n\tasync order(adyenPaymentId: string | AdyenPayment, params?: QueryParamsRetrieve<Order>, options?: ResourcesConfig): Promise<Order> {\n\t\tconst _adyenPaymentId = (adyenPaymentId as AdyenPayment).id || adyenPaymentId as string\n\t\treturn this.resources.fetch<Order>({ type: 'orders' }, `adyen_payments/${_adyenPaymentId}/order`, params, options) as unknown as Order\n\t}\n\n\tasync payment_gateway(adyenPaymentId: string | AdyenPayment, params?: QueryParamsRetrieve<PaymentGateway>, options?: ResourcesConfig): Promise<PaymentGateway> {\n\t\tconst _adyenPaymentId = (adyenPaymentId as AdyenPayment).id || adyenPaymentId as string\n\t\treturn this.resources.fetch<PaymentGateway>({ type: 'payment_gateways' }, `adyen_payments/${_adyenPaymentId}/payment_gateway`, params, options) as unknown as PaymentGateway\n\t}\n\n\tasync versions(adyenPaymentId: string | AdyenPayment, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _adyenPaymentId = (adyenPaymentId as AdyenPayment).id || adyenPaymentId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `adyen_payments/${_adyenPaymentId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\tasync _authorize(id: string | AdyenPayment, params?: QueryParamsRetrieve<AdyenPayment>, options?: ResourcesConfig): Promise<AdyenPayment> {\n\t\treturn this.resources.update<AdyenPaymentUpdate, AdyenPayment>({ id: (typeof id === 'string')? id: id.id, type: AdyenPayments.TYPE, _authorize: true }, params, options)\n\t}\n\n\tasync _details(id: string | AdyenPayment, params?: QueryParamsRetrieve<AdyenPayment>, options?: ResourcesConfig): Promise<AdyenPayment> {\n\t\treturn this.resources.update<AdyenPaymentUpdate, AdyenPayment>({ id: (typeof id === 'string')? id: id.id, type: AdyenPayments.TYPE, _details: true }, params, options)\n\t}\n\n\tasync _balance(id: string | AdyenPayment, params?: QueryParamsRetrieve<AdyenPayment>, options?: ResourcesConfig): Promise<AdyenPayment> {\n\t\treturn this.resources.update<AdyenPaymentUpdate, AdyenPayment>({ id: (typeof id === 'string')? id: id.id, type: AdyenPayments.TYPE, _balance: true }, params, options)\n\t}\n\n\n\tisAdyenPayment(resource: any): resource is AdyenPayment {\n\t\treturn resource.type && (resource.type === AdyenPayments.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): AdyenPaymentRel {\n\t\treturn super.relationshipOneToOne<AdyenPaymentRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): AdyenPaymentRel[] {\n\t\treturn super.relationshipOneToMany<AdyenPaymentRel>(...ids)\n\t}\n\n\n\ttype(): AdyenPaymentType {\n\t\treturn AdyenPayments.TYPE\n\t}\n\n}\n\n\nconst instance = new AdyenPayments()\nexport default instance\n\nexport type { AdyenPayments, AdyenPayment, AdyenPaymentCreate, AdyenPaymentUpdate, AdyenPaymentType }\n"]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/resources/sku_list_promotion_rules.ts"],"names":["ApiResource"],"mappings":";;;;;AA+FA,IAAM,qBAAA,GAAN,MAAM,sBAAA,SAA8BA,
|
1
|
+
{"version":3,"sources":["../src/resources/sku_list_promotion_rules.ts"],"names":["ApiResource"],"mappings":";;;;;AA+FA,IAAM,qBAAA,GAAN,MAAM,sBAAA,SAA8BA,6BAAA,CAAkC;AAAA,EAErE,OAAgB,IAAA,GAAiC,0BAAA;AAAA,EAEjD,MAAM,MAAA,CAAO,QAAA,EAAsC,MAAA,EAAoD,OAAA,EAA0D;AAChK,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,MAAA,CAAyD,EAAE,GAAG,QAAA,EAAU,IAAA,E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uBAAA,GAA2B,uBAAgD,EAAA,IAAM,sBAAA;AACvF,IAAA,OAAO,IAAA,CAAK,SAAA,CAAU,KAAA,CAAW,EAAE,IAAA,EAAM,MAAA,EAAO,EAAG,CAAA,yBAAA,EAA4B,uBAAuB,CAAA,KAAA,CAAA,EAAS,MAAA,EAAQ,OAAO,CAAA;AAAA;AAC/H,EAGA,uBAAuB,QAAA,EAAiD;AACvE,IAAA,OAAO,QAAA,CAAS,IAAA,IAAS,QAAA,CAAS,IAAA,KAAS,sBAAA,CAAsB,IAAA;AAAA;AAClE,EAGA,aAAa,EAAA,EAAyD;AACrE,IAAA,OAAO,KAAA,CAAM,qBAA8C,EAAE,CAAA;AAAA;AAC9D,EAEA,sBAAsB,GAAA,EAA0C;AAC/D,IAAA,OAAO,KAAA,CAAM,qBAAA,CAA+C,GAAG,GAAG,CAAA;AAAA;AACnE,EAGA,IAAA,GAAiC;AAChC,IAAA,OAAO,sBAAA,CAAsB,IAAA;AAAA;AAG/B,CAAA;AAGA,IAAM,QAAA,GAAW,IAAI,qBAAA,EAAsB;AAC3C,IAAO,gCAAA,GAAQ","file":"chunk-F6MSHDB7.cjs","sourcesContent":["import { ApiResource } from '../resource'\nimport type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse, ResourceSort, /* ResourceFilter */ } from '../resource'\nimport type { QueryParamsRetrieve, QueryParamsList } from '../query'\n\nimport type { Version } from './versions'\nimport type { SkuList, SkuListType } from './sku_lists'\nimport type { Sku } from './skus'\nimport type { PercentageDiscountPromotion, PercentageDiscountPromotionType } from './percentage_discount_promotions'\nimport type { FreeShippingPromotion, FreeShippingPromotionType } from './free_shipping_promotions'\nimport type { BuyXPayYPromotion, BuyXPayYPromotionType } from './buy_x_pay_y_promotions'\nimport type { FreeGiftPromotion, FreeGiftPromotionType } from './free_gift_promotions'\nimport type { FixedPricePromotion, FixedPricePromotionType } from './fixed_price_promotions'\nimport type { ExternalPromotion, ExternalPromotionType } from './external_promotions'\nimport type { FixedAmountPromotion, FixedAmountPromotionType } from './fixed_amount_promotions'\nimport type { FlexPromotion, FlexPromotionType } from './flex_promotions'\n\n\ntype SkuListPromotionRuleType = 'sku_list_promotion_rules'\ntype SkuListPromotionRuleRel = ResourceRel & { type: SkuListPromotionRuleType }\ntype PercentageDiscountPromotionRel = ResourceRel & { type: PercentageDiscountPromotionType }\ntype FreeShippingPromotionRel = ResourceRel & { type: FreeShippingPromotionType }\ntype BuyXPayYPromotionRel = ResourceRel & { type: BuyXPayYPromotionType }\ntype FreeGiftPromotionRel = ResourceRel & { type: FreeGiftPromotionType }\ntype FixedPricePromotionRel = ResourceRel & { type: FixedPricePromotionType }\ntype ExternalPromotionRel = ResourceRel & { type: ExternalPromotionType }\ntype FixedAmountPromotionRel = ResourceRel & { type: FixedAmountPromotionType }\ntype FlexPromotionRel = ResourceRel & { type: FlexPromotionType }\ntype SkuListRel = ResourceRel & { type: SkuListType }\n\n\nexport type SkuListPromotionRuleSort = Pick<SkuListPromotionRule, 'id'> & ResourceSort\n// export type SkuListPromotionRuleFilter = Pick<SkuListPromotionRule, 'id'> & ResourceFilter\n\n\ninterface SkuListPromotionRule extends Resource {\n\t\n\treadonly type: SkuListPromotionRuleType\n\n\t/** \n\t * Indicates if the rule is activated only when all of the SKUs of the list is also part of the order.\n\t * @example ```true```\n\t */\n\tall_skus?: boolean | null\n\t/** \n\t * The min quantity of SKUs of the list that must be also part of the order. If positive, overwrites the 'all_skus' option. When the SKU list is manual, its items quantities are honoured.\n\t * @example ```3```\n\t */\n\tmin_quantity?: number | null\n\n\tpromotion?: PercentageDiscountPromotion | FreeShippingPromotion | BuyXPayYPromotion | FreeGiftPromotion | FixedPricePromotion | ExternalPromotion | FixedAmountPromotion | FlexPromotion | null\n\tversions?: Version[] | null\n\tsku_list?: SkuList | null\n\tskus?: Sku[] | null\n\n}\n\n\ninterface SkuListPromotionRuleCreate extends ResourceCreate {\n\t\n\t/** \n\t * Indicates if the rule is activated only when all of the SKUs of the list is also part of the order.\n\t * @example ```true```\n\t */\n\tall_skus?: boolean | null\n\t/** \n\t * The min quantity of SKUs of the list that must be also part of the order. If positive, overwrites the 'all_skus' option. When the SKU list is manual, its items quantities are honoured.\n\t * @example ```3```\n\t */\n\tmin_quantity?: number | null\n\n\tpromotion: PercentageDiscountPromotionRel | FreeShippingPromotionRel | BuyXPayYPromotionRel | FreeGiftPromotionRel | FixedPricePromotionRel | ExternalPromotionRel | FixedAmountPromotionRel | FlexPromotionRel\n\tsku_list?: SkuListRel | null\n\n}\n\n\ninterface SkuListPromotionRuleUpdate extends ResourceUpdate {\n\t\n\t/** \n\t * Indicates if the rule is activated only when all of the SKUs of the list is also part of the order.\n\t * @example ```true```\n\t */\n\tall_skus?: boolean | null\n\t/** \n\t * The min quantity of SKUs of the list that must be also part of the order. If positive, overwrites the 'all_skus' option. When the SKU list is manual, its items quantities are honoured.\n\t * @example ```3```\n\t */\n\tmin_quantity?: number | null\n\n\tpromotion?: PercentageDiscountPromotionRel | FreeShippingPromotionRel | BuyXPayYPromotionRel | FreeGiftPromotionRel | FixedPricePromotionRel | ExternalPromotionRel | FixedAmountPromotionRel | FlexPromotionRel | null\n\tsku_list?: SkuListRel | null\n\n}\n\n\nclass SkuListPromotionRules extends ApiResource<SkuListPromotionRule> {\n\n\tstatic readonly TYPE: SkuListPromotionRuleType = 'sku_list_promotion_rules' as const\n\n\tasync create(resource: SkuListPromotionRuleCreate, params?: QueryParamsRetrieve<SkuListPromotionRule>, options?: ResourcesConfig): Promise<SkuListPromotionRule> {\n\t\treturn this.resources.create<SkuListPromotionRuleCreate, SkuListPromotionRule>({ ...resource, type: SkuListPromotionRules.TYPE }, params, options)\n\t}\n\n\tasync update(resource: SkuListPromotionRuleUpdate, params?: QueryParamsRetrieve<SkuListPromotionRule>, options?: ResourcesConfig): Promise<SkuListPromotionRule> {\n\t\treturn this.resources.update<SkuListPromotionRuleUpdate, SkuListPromotionRule>({ ...resource, type: SkuListPromotionRules.TYPE }, params, options)\n\t}\n\n\tasync delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void> {\n\t\tawait this.resources.delete((typeof id === 'string')? { id, type: SkuListPromotionRules.TYPE } : id, options)\n\t}\n\n\tasync versions(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsList<Version>, options?: ResourcesConfig): Promise<ListResponse<Version>> {\n\t\tconst _skuListPromotionRuleId = (skuListPromotionRuleId as SkuListPromotionRule).id || skuListPromotionRuleId as string\n\t\treturn this.resources.fetch<Version>({ type: 'versions' }, `sku_list_promotion_rules/${_skuListPromotionRuleId}/versions`, params, options) as unknown as ListResponse<Version>\n\t}\n\n\tasync sku_list(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsRetrieve<SkuList>, options?: ResourcesConfig): Promise<SkuList> {\n\t\tconst _skuListPromotionRuleId = (skuListPromotionRuleId as SkuListPromotionRule).id || skuListPromotionRuleId as string\n\t\treturn this.resources.fetch<SkuList>({ type: 'sku_lists' }, `sku_list_promotion_rules/${_skuListPromotionRuleId}/sku_list`, params, options) as unknown as SkuList\n\t}\n\n\tasync skus(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsList<Sku>, options?: ResourcesConfig): Promise<ListResponse<Sku>> {\n\t\tconst _skuListPromotionRuleId = (skuListPromotionRuleId as SkuListPromotionRule).id || skuListPromotionRuleId as string\n\t\treturn this.resources.fetch<Sku>({ type: 'skus' }, `sku_list_promotion_rules/${_skuListPromotionRuleId}/skus`, params, options) as unknown as ListResponse<Sku>\n\t}\n\n\n\tisSkuListPromotionRule(resource: any): resource is SkuListPromotionRule {\n\t\treturn resource.type && (resource.type === SkuListPromotionRules.TYPE)\n\t}\n\n\n\trelationship(id: string | ResourceId | null): SkuListPromotionRuleRel {\n\t\treturn super.relationshipOneToOne<SkuListPromotionRuleRel>(id)\n\t}\n\n\trelationshipToMany(...ids: string[]): SkuListPromotionRuleRel[] {\n\t\treturn super.relationshipOneToMany<SkuListPromotionRuleRel>(...ids)\n\t}\n\n\n\ttype(): SkuListPromotionRuleType {\n\t\treturn SkuListPromotionRules.TYPE\n\t}\n\n}\n\n\nconst instance = new SkuListPromotionRules()\nexport default instance\n\nexport type { SkuListPromotionRules, SkuListPromotionRule, SkuListPromotionRuleCreate, SkuListPromotionRuleUpdate, SkuListPromotionRuleType }\n"]}
|