@nodaro/sdk 2.29.0 → 2.32.0
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/README.md +31 -0
- package/dist/chunk-2DZWWIJ4.cjs +32 -0
- package/dist/chunk-2DZWWIJ4.cjs.map +1 -0
- package/dist/chunk-34PU2DAT.cjs +118 -0
- package/dist/chunk-34PU2DAT.cjs.map +1 -0
- package/dist/chunk-37Y5QAVA.js +3 -0
- package/dist/chunk-37Y5QAVA.js.map +1 -0
- package/dist/chunk-37YCKZX4.cjs +4 -0
- package/dist/chunk-37YCKZX4.cjs.map +1 -0
- package/dist/chunk-3B47IHB3.cjs +65 -0
- package/dist/chunk-3B47IHB3.cjs.map +1 -0
- package/dist/chunk-3BELHJBN.cjs +4 -0
- package/dist/chunk-3BELHJBN.cjs.map +1 -0
- package/dist/chunk-3PPSGM5X.js +3 -0
- package/dist/chunk-3PPSGM5X.js.map +1 -0
- package/dist/chunk-3QBH2VE2.cjs +80 -0
- package/dist/chunk-3QBH2VE2.cjs.map +1 -0
- package/dist/chunk-3QFTP5P5.js +102 -0
- package/dist/chunk-3QFTP5P5.js.map +1 -0
- package/dist/chunk-43FVH6LJ.cjs +123 -0
- package/dist/chunk-43FVH6LJ.cjs.map +1 -0
- package/dist/chunk-43NO4SGC.cjs +4 -0
- package/dist/chunk-43NO4SGC.cjs.map +1 -0
- package/dist/chunk-45CK55BH.cjs +4 -0
- package/dist/chunk-45CK55BH.cjs.map +1 -0
- package/dist/chunk-4CXB7RA6.js +104 -0
- package/dist/chunk-4CXB7RA6.js.map +1 -0
- package/dist/chunk-4NLVBYMW.js +280 -0
- package/dist/chunk-4NLVBYMW.js.map +1 -0
- package/dist/chunk-4WRDR4GN.js +102 -0
- package/dist/chunk-4WRDR4GN.js.map +1 -0
- package/dist/chunk-4WWSHV5G.cjs +4 -0
- package/dist/chunk-4WWSHV5G.cjs.map +1 -0
- package/dist/chunk-53SXNN3A.js +80 -0
- package/dist/chunk-53SXNN3A.js.map +1 -0
- package/dist/chunk-5ALNFATQ.cjs +27 -0
- package/dist/chunk-5ALNFATQ.cjs.map +1 -0
- package/dist/chunk-5UQNMNUE.cjs +4 -0
- package/dist/chunk-5UQNMNUE.cjs.map +1 -0
- package/dist/chunk-65E3JBFZ.js +52 -0
- package/dist/chunk-65E3JBFZ.js.map +1 -0
- package/dist/chunk-6ECW23GA.js +214 -0
- package/dist/chunk-6ECW23GA.js.map +1 -0
- package/dist/chunk-6JFNBAKV.js +3 -0
- package/dist/chunk-6JFNBAKV.js.map +1 -0
- package/dist/chunk-6OC6OKLY.cjs +4 -0
- package/dist/chunk-6OC6OKLY.cjs.map +1 -0
- package/dist/chunk-6OGGJQVA.js +25 -0
- package/dist/chunk-6OGGJQVA.js.map +1 -0
- package/dist/chunk-7A7HYFGM.js +3 -0
- package/dist/chunk-7A7HYFGM.js.map +1 -0
- package/dist/chunk-7CK6I4CT.cjs +16 -0
- package/dist/chunk-7CK6I4CT.cjs.map +1 -0
- package/dist/chunk-7LSFG2AF.js +194 -0
- package/dist/chunk-7LSFG2AF.js.map +1 -0
- package/dist/chunk-7MYKT2L4.cjs +4 -0
- package/dist/chunk-7MYKT2L4.cjs.map +1 -0
- package/dist/chunk-7QOCWJKD.cjs +25 -0
- package/dist/chunk-7QOCWJKD.cjs.map +1 -0
- package/dist/chunk-A2ZAFAWC.cjs +4 -0
- package/dist/chunk-A2ZAFAWC.cjs.map +1 -0
- package/dist/chunk-A3S55XGF.cjs +54 -0
- package/dist/chunk-A3S55XGF.cjs.map +1 -0
- package/dist/chunk-A3THLBFG.js +3 -0
- package/dist/chunk-A3THLBFG.js.map +1 -0
- package/dist/chunk-AJVSMNPZ.js +78 -0
- package/dist/chunk-AJVSMNPZ.js.map +1 -0
- package/dist/chunk-ALSLZG3U.js +124 -0
- package/dist/chunk-ALSLZG3U.js.map +1 -0
- package/dist/chunk-ALUUBPDG.cjs +4 -0
- package/dist/chunk-ALUUBPDG.cjs.map +1 -0
- package/dist/chunk-AO3W45LT.cjs +4 -0
- package/dist/chunk-AO3W45LT.cjs.map +1 -0
- package/dist/chunk-AUDHV3OE.js +3 -0
- package/dist/chunk-AUDHV3OE.js.map +1 -0
- package/dist/chunk-B7RG6AUQ.cjs +216 -0
- package/dist/chunk-B7RG6AUQ.cjs.map +1 -0
- package/dist/chunk-BAL576G2.cjs +4 -0
- package/dist/chunk-BAL576G2.cjs.map +1 -0
- package/dist/chunk-BKP6F2IX.js +3 -0
- package/dist/chunk-BKP6F2IX.js.map +1 -0
- package/dist/chunk-BLA44UCM.js +32 -0
- package/dist/chunk-BLA44UCM.js.map +1 -0
- package/dist/chunk-BPWUWUZ3.cjs +20 -0
- package/dist/chunk-BPWUWUZ3.cjs.map +1 -0
- package/dist/chunk-BRV7Z4GD.cjs +17 -0
- package/dist/chunk-BRV7Z4GD.cjs.map +1 -0
- package/dist/chunk-BU5A6K4C.js +122 -0
- package/dist/chunk-BU5A6K4C.js.map +1 -0
- package/dist/chunk-C22RJDW3.js +3 -0
- package/dist/chunk-C22RJDW3.js.map +1 -0
- package/dist/chunk-CGNVHN4V.js +3 -0
- package/dist/chunk-CGNVHN4V.js.map +1 -0
- package/dist/chunk-CJFIOVBA.js +3 -0
- package/dist/chunk-CJFIOVBA.js.map +1 -0
- package/dist/chunk-CJLLIVSB.cjs +4 -0
- package/dist/chunk-CJLLIVSB.cjs.map +1 -0
- package/dist/chunk-CK3AMMSC.js +194 -0
- package/dist/chunk-CK3AMMSC.js.map +1 -0
- package/dist/chunk-COCKKMNP.cjs +205 -0
- package/dist/chunk-COCKKMNP.cjs.map +1 -0
- package/dist/chunk-CR5E2SF3.cjs +212 -0
- package/dist/chunk-CR5E2SF3.cjs.map +1 -0
- package/dist/chunk-CRCPRZFN.js +3 -0
- package/dist/chunk-CRCPRZFN.js.map +1 -0
- package/dist/chunk-CYRFD6KR.cjs +4 -0
- package/dist/chunk-CYRFD6KR.cjs.map +1 -0
- package/dist/chunk-D3PW7AHZ.js +3 -0
- package/dist/chunk-D3PW7AHZ.js.map +1 -0
- package/dist/chunk-DKEYSJCE.cjs +82 -0
- package/dist/chunk-DKEYSJCE.cjs.map +1 -0
- package/dist/chunk-DPSMVOM3.js +15 -0
- package/dist/chunk-DPSMVOM3.js.map +1 -0
- package/dist/chunk-E2ZXHS6E.js +20 -0
- package/dist/chunk-E2ZXHS6E.js.map +1 -0
- package/dist/chunk-E37CVHWW.js +33 -0
- package/dist/chunk-E37CVHWW.js.map +1 -0
- package/dist/chunk-E5BM4BLO.js +78 -0
- package/dist/chunk-E5BM4BLO.js.map +1 -0
- package/dist/chunk-EHRWTYGR.cjs +4 -0
- package/dist/chunk-EHRWTYGR.cjs.map +1 -0
- package/dist/chunk-EJSGJDZY.js +212 -0
- package/dist/chunk-EJSGJDZY.js.map +1 -0
- package/dist/chunk-ELSOVJPF.js +3 -0
- package/dist/chunk-ELSOVJPF.js.map +1 -0
- package/dist/chunk-ERLXU47J.js +29 -0
- package/dist/chunk-ERLXU47J.js.map +1 -0
- package/dist/chunk-ES2E65HT.js +3 -0
- package/dist/chunk-ES2E65HT.js.map +1 -0
- package/dist/chunk-EXLAHZKF.js +3 -0
- package/dist/chunk-EXLAHZKF.js.map +1 -0
- package/dist/chunk-FB3S2FON.cjs +233 -0
- package/dist/chunk-FB3S2FON.cjs.map +1 -0
- package/dist/chunk-FHEYAW5H.js +3 -0
- package/dist/chunk-FHEYAW5H.js.map +1 -0
- package/dist/chunk-GA4LZZKQ.cjs +104 -0
- package/dist/chunk-GA4LZZKQ.cjs.map +1 -0
- package/dist/chunk-GAZJ2PA3.js +3 -0
- package/dist/chunk-GAZJ2PA3.js.map +1 -0
- package/dist/chunk-GB6C5OEZ.cjs +32 -0
- package/dist/chunk-GB6C5OEZ.cjs.map +1 -0
- package/dist/chunk-GB724HW2.cjs +106 -0
- package/dist/chunk-GB724HW2.cjs.map +1 -0
- package/dist/chunk-GD24ZRFD.js +3 -0
- package/dist/chunk-GD24ZRFD.js.map +1 -0
- package/dist/chunk-GI7LROLL.cjs +4 -0
- package/dist/chunk-GI7LROLL.cjs.map +1 -0
- package/dist/chunk-GRFLPEM2.cjs +16 -0
- package/dist/chunk-GRFLPEM2.cjs.map +1 -0
- package/dist/chunk-GVIFLUYZ.cjs +40 -0
- package/dist/chunk-GVIFLUYZ.cjs.map +1 -0
- package/dist/chunk-GWCOKNST.js +228 -0
- package/dist/chunk-GWCOKNST.js.map +1 -0
- package/dist/chunk-H7VQTG4M.js +35 -0
- package/dist/chunk-H7VQTG4M.js.map +1 -0
- package/dist/chunk-HAKYPZLB.cjs +242 -0
- package/dist/chunk-HAKYPZLB.cjs.map +1 -0
- package/dist/chunk-HFBR6G36.js +3 -0
- package/dist/chunk-HFBR6G36.js.map +1 -0
- package/dist/chunk-HGCVWOGK.cjs +209 -0
- package/dist/chunk-HGCVWOGK.cjs.map +1 -0
- package/dist/chunk-HLHR3R4P.js +3 -0
- package/dist/chunk-HLHR3R4P.js.map +1 -0
- package/dist/chunk-HRXXGGSJ.js +3 -0
- package/dist/chunk-HRXXGGSJ.js.map +1 -0
- package/dist/chunk-I3TYBAOX.js +3 -0
- package/dist/chunk-I3TYBAOX.js.map +1 -0
- package/dist/chunk-I4A5VJRL.js +352 -0
- package/dist/chunk-I4A5VJRL.js.map +1 -0
- package/dist/chunk-I6CXC345.js +102 -0
- package/dist/chunk-I6CXC345.js.map +1 -0
- package/dist/chunk-IGOPUMEX.cjs +4 -0
- package/dist/chunk-IGOPUMEX.cjs.map +1 -0
- package/dist/chunk-IHKIYVZQ.js +30 -0
- package/dist/chunk-IHKIYVZQ.js.map +1 -0
- package/dist/chunk-IMC2M5YM.cjs +12 -0
- package/dist/chunk-IMC2M5YM.cjs.map +1 -0
- package/dist/chunk-IQ6KWSXP.js +3 -0
- package/dist/chunk-IQ6KWSXP.js.map +1 -0
- package/dist/chunk-IS26FJO7.cjs +4 -0
- package/dist/chunk-IS26FJO7.cjs.map +1 -0
- package/dist/chunk-J4WFSKY6.js +50 -0
- package/dist/chunk-J4WFSKY6.js.map +1 -0
- package/dist/chunk-J5LGGCAS.cjs +126 -0
- package/dist/chunk-J5LGGCAS.cjs.map +1 -0
- package/dist/chunk-JDEZHITT.js +43 -0
- package/dist/chunk-JDEZHITT.js.map +1 -0
- package/dist/chunk-JGS6YBDW.js +260 -0
- package/dist/chunk-JGS6YBDW.js.map +1 -0
- package/dist/chunk-JMOKD6ZP.js +46 -0
- package/dist/chunk-JMOKD6ZP.js.map +1 -0
- package/dist/chunk-JOX5BJ6K.cjs +4 -0
- package/dist/chunk-JOX5BJ6K.cjs.map +1 -0
- package/dist/chunk-JTAW54UM.js +116 -0
- package/dist/chunk-JTAW54UM.js.map +1 -0
- package/dist/chunk-K4RQOSJH.js +203 -0
- package/dist/chunk-K4RQOSJH.js.map +1 -0
- package/dist/chunk-KAIE6WJB.cjs +4 -0
- package/dist/chunk-KAIE6WJB.cjs.map +1 -0
- package/dist/chunk-KEDPGWIK.cjs +4 -0
- package/dist/chunk-KEDPGWIK.cjs.map +1 -0
- package/dist/chunk-KG4R454Z.js +18 -0
- package/dist/chunk-KG4R454Z.js.map +1 -0
- package/dist/chunk-KGKCAGRD.cjs +22 -0
- package/dist/chunk-KGKCAGRD.cjs.map +1 -0
- package/dist/chunk-KNMW722T.cjs +48 -0
- package/dist/chunk-KNMW722T.cjs.map +1 -0
- package/dist/chunk-KTTL7BND.cjs +4 -0
- package/dist/chunk-KTTL7BND.cjs.map +1 -0
- package/dist/chunk-KXEWTYS4.cjs +80 -0
- package/dist/chunk-KXEWTYS4.cjs.map +1 -0
- package/dist/chunk-KZQKFBRN.js +3 -0
- package/dist/chunk-KZQKFBRN.js.map +1 -0
- package/dist/chunk-LAWYFC4G.cjs +37 -0
- package/dist/chunk-LAWYFC4G.cjs.map +1 -0
- package/dist/chunk-LHRQXWI5.js +3 -0
- package/dist/chunk-LHRQXWI5.js.map +1 -0
- package/dist/chunk-LKH5M44B.cjs +114 -0
- package/dist/chunk-LKH5M44B.cjs.map +1 -0
- package/dist/chunk-LLNNHLCE.cjs +4 -0
- package/dist/chunk-LLNNHLCE.cjs.map +1 -0
- package/dist/chunk-LWZLWSXD.cjs +4 -0
- package/dist/chunk-LWZLWSXD.cjs.map +1 -0
- package/dist/chunk-M6Y5TOYE.js +3 -0
- package/dist/chunk-M6Y5TOYE.js.map +1 -0
- package/dist/chunk-MBFUMWI5.cjs +31 -0
- package/dist/chunk-MBFUMWI5.cjs.map +1 -0
- package/dist/chunk-MEKI37WI.js +3 -0
- package/dist/chunk-MEKI37WI.js.map +1 -0
- package/dist/chunk-MQ74AKA2.cjs +200 -0
- package/dist/chunk-MQ74AKA2.cjs.map +1 -0
- package/dist/chunk-N6GLZOE4.cjs +282 -0
- package/dist/chunk-N6GLZOE4.cjs.map +1 -0
- package/dist/chunk-NBVARNVA.cjs +38 -0
- package/dist/chunk-NBVARNVA.cjs.map +1 -0
- package/dist/chunk-NCCBS6GU.js +42 -0
- package/dist/chunk-NCCBS6GU.js.map +1 -0
- package/dist/chunk-NGKODS3J.cjs +52 -0
- package/dist/chunk-NGKODS3J.cjs.map +1 -0
- package/dist/chunk-NJVSKUL2.cjs +4 -0
- package/dist/chunk-NJVSKUL2.cjs.map +1 -0
- package/dist/chunk-NLQQHJ25.cjs +104 -0
- package/dist/chunk-NLQQHJ25.cjs.map +1 -0
- package/dist/chunk-NNHWH7ER.js +181 -0
- package/dist/chunk-NNHWH7ER.js.map +1 -0
- package/dist/chunk-NX67YIF3.js +3 -0
- package/dist/chunk-NX67YIF3.js.map +1 -0
- package/dist/chunk-OA6FWYZF.cjs +4 -0
- package/dist/chunk-OA6FWYZF.cjs.map +1 -0
- package/dist/chunk-OJDBSKC2.js +3 -0
- package/dist/chunk-OJDBSKC2.js.map +1 -0
- package/dist/chunk-OLPA44QJ.js +3 -0
- package/dist/chunk-OLPA44QJ.js.map +1 -0
- package/dist/chunk-OMH7ATOQ.js +3 -0
- package/dist/chunk-OMH7ATOQ.js.map +1 -0
- package/dist/chunk-OPR4TULG.js +3 -0
- package/dist/chunk-OPR4TULG.js.map +1 -0
- package/dist/chunk-OSX2GVZ2.cjs +34 -0
- package/dist/chunk-OSX2GVZ2.cjs.map +1 -0
- package/dist/chunk-OXQKE5EG.cjs +282 -0
- package/dist/chunk-OXQKE5EG.cjs.map +1 -0
- package/dist/chunk-P6E4QDJN.js +30 -0
- package/dist/chunk-P6E4QDJN.js.map +1 -0
- package/dist/chunk-PEMLIAPZ.cjs +64 -0
- package/dist/chunk-PEMLIAPZ.cjs.map +1 -0
- package/dist/chunk-PGYQ754I.js +3 -0
- package/dist/chunk-PGYQ754I.js.map +1 -0
- package/dist/chunk-PHEA6FVQ.js +184 -0
- package/dist/chunk-PHEA6FVQ.js.map +1 -0
- package/dist/chunk-PMTM26LL.js +3 -0
- package/dist/chunk-PMTM26LL.js.map +1 -0
- package/dist/chunk-PY4OEKNX.cjs +4 -0
- package/dist/chunk-PY4OEKNX.cjs.map +1 -0
- package/dist/chunk-PZS2EXDR.cjs +4 -0
- package/dist/chunk-PZS2EXDR.cjs.map +1 -0
- package/dist/chunk-QRHJEITQ.cjs +4 -0
- package/dist/chunk-QRHJEITQ.cjs.map +1 -0
- package/dist/chunk-QUFU5RJ7.cjs +4 -0
- package/dist/chunk-QUFU5RJ7.cjs.map +1 -0
- package/dist/chunk-QVQCKOBM.js +3 -0
- package/dist/chunk-QVQCKOBM.js.map +1 -0
- package/dist/chunk-R63TTR35.cjs +200 -0
- package/dist/chunk-R63TTR35.cjs.map +1 -0
- package/dist/chunk-RA42NMWV.cjs +4 -0
- package/dist/chunk-RA42NMWV.cjs.map +1 -0
- package/dist/chunk-RAZN6C5R.cjs +12 -0
- package/dist/chunk-RAZN6C5R.cjs.map +1 -0
- package/dist/chunk-RHETJOUM.cjs +4 -0
- package/dist/chunk-RHETJOUM.cjs.map +1 -0
- package/dist/chunk-RJIJVVXS.js +3 -0
- package/dist/chunk-RJIJVVXS.js.map +1 -0
- package/dist/chunk-RKVRCNMB.js +3 -0
- package/dist/chunk-RKVRCNMB.js.map +1 -0
- package/dist/chunk-S7JQKNVT.cjs +187 -0
- package/dist/chunk-S7JQKNVT.cjs.map +1 -0
- package/dist/chunk-SBV5MWEL.cjs +53 -0
- package/dist/chunk-SBV5MWEL.cjs.map +1 -0
- package/dist/chunk-SFB4YLCS.js +121 -0
- package/dist/chunk-SFB4YLCS.js.map +1 -0
- package/dist/chunk-SLPD47SR.js +3 -0
- package/dist/chunk-SLPD47SR.js.map +1 -0
- package/dist/chunk-SS3B6PHT.cjs +35 -0
- package/dist/chunk-SS3B6PHT.cjs.map +1 -0
- package/dist/chunk-SUCHGNYT.js +3 -0
- package/dist/chunk-SUCHGNYT.js.map +1 -0
- package/dist/chunk-SYVNY3AH.cjs +44 -0
- package/dist/chunk-SYVNY3AH.cjs.map +1 -0
- package/dist/chunk-T3SYREY4.js +29 -0
- package/dist/chunk-T3SYREY4.js.map +1 -0
- package/dist/chunk-T7N7DFQJ.js +198 -0
- package/dist/chunk-T7N7DFQJ.js.map +1 -0
- package/dist/chunk-TRCENAIY.cjs +4 -0
- package/dist/chunk-TRCENAIY.cjs.map +1 -0
- package/dist/chunk-TVENC6PH.js +186 -0
- package/dist/chunk-TVENC6PH.js.map +1 -0
- package/dist/chunk-U4T3Z3K7.cjs +325 -0
- package/dist/chunk-U4T3Z3K7.cjs.map +1 -0
- package/dist/chunk-UIFFNTUX.js +3 -0
- package/dist/chunk-UIFFNTUX.js.map +1 -0
- package/dist/chunk-V4GPQ6Y2.js +3 -0
- package/dist/chunk-V4GPQ6Y2.js.map +1 -0
- package/dist/chunk-VGTRKXF2.js +93 -0
- package/dist/chunk-VGTRKXF2.js.map +1 -0
- package/dist/chunk-VGWOIWRQ.cjs +202 -0
- package/dist/chunk-VGWOIWRQ.cjs.map +1 -0
- package/dist/chunk-VLCNNA76.cjs +4 -0
- package/dist/chunk-VLCNNA76.cjs.map +1 -0
- package/dist/chunk-VPAUN75Q.js +3 -0
- package/dist/chunk-VPAUN75Q.js.map +1 -0
- package/dist/chunk-VT237QF2.js +3 -0
- package/dist/chunk-VT237QF2.js.map +1 -0
- package/dist/chunk-VV4TZG5S.js +321 -0
- package/dist/chunk-VV4TZG5S.js.map +1 -0
- package/dist/chunk-VYK6MBL4.cjs +4 -0
- package/dist/chunk-VYK6MBL4.cjs.map +1 -0
- package/dist/chunk-W33CKW6Q.cjs +4 -0
- package/dist/chunk-W33CKW6Q.cjs.map +1 -0
- package/dist/chunk-W5VHATSR.cjs +31 -0
- package/dist/chunk-W5VHATSR.cjs.map +1 -0
- package/dist/chunk-WEQWU2IC.js +34 -0
- package/dist/chunk-WEQWU2IC.js.map +1 -0
- package/dist/chunk-WK4VXPPZ.cjs +104 -0
- package/dist/chunk-WK4VXPPZ.cjs.map +1 -0
- package/dist/chunk-WSA4LMWR.cjs +96 -0
- package/dist/chunk-WSA4LMWR.cjs.map +1 -0
- package/dist/chunk-WUIEZ6Z4.cjs +360 -0
- package/dist/chunk-WUIEZ6Z4.cjs.map +1 -0
- package/dist/chunk-WUKIJJG2.cjs +45 -0
- package/dist/chunk-WUKIJJG2.cjs.map +1 -0
- package/dist/chunk-WVFAQBS7.js +29 -0
- package/dist/chunk-WVFAQBS7.js.map +1 -0
- package/dist/chunk-X7RDNMN7.js +3 -0
- package/dist/chunk-X7RDNMN7.js.map +1 -0
- package/dist/chunk-X7XP5WBP.cjs +4 -0
- package/dist/chunk-X7XP5WBP.cjs.map +1 -0
- package/dist/chunk-XWKNE6DH.cjs +4 -0
- package/dist/chunk-XWKNE6DH.cjs.map +1 -0
- package/dist/chunk-Y6V6CBY5.js +23 -0
- package/dist/chunk-Y6V6CBY5.js.map +1 -0
- package/dist/chunk-Y6VDCZPB.js +62 -0
- package/dist/chunk-Y6VDCZPB.js.map +1 -0
- package/dist/chunk-YDRXBRW2.cjs +184 -0
- package/dist/chunk-YDRXBRW2.cjs.map +1 -0
- package/dist/chunk-YFS2LMG4.cjs +124 -0
- package/dist/chunk-YFS2LMG4.cjs.map +1 -0
- package/dist/chunk-YN6CBIIB.js +63 -0
- package/dist/chunk-YN6CBIIB.js.map +1 -0
- package/dist/chunk-YOJ2XNQX.cjs +4 -0
- package/dist/chunk-YOJ2XNQX.cjs.map +1 -0
- package/dist/chunk-YOOZB4RL.js +3 -0
- package/dist/chunk-YOOZB4RL.js.map +1 -0
- package/dist/chunk-YVU2M7MI.js +34 -0
- package/dist/chunk-YVU2M7MI.js.map +1 -0
- package/dist/chunk-YXBZRB5H.cjs +4 -0
- package/dist/chunk-YXBZRB5H.cjs.map +1 -0
- package/dist/chunk-Z3ZKFI2M.js +43 -0
- package/dist/chunk-Z3ZKFI2M.js.map +1 -0
- package/dist/chunk-Z5GLY4R3.js +112 -0
- package/dist/chunk-Z5GLY4R3.js.map +1 -0
- package/dist/chunk-Z5OMWAQX.js +3 -0
- package/dist/chunk-Z5OMWAQX.js.map +1 -0
- package/dist/chunk-Z7LGWNI7.js +38 -0
- package/dist/chunk-Z7LGWNI7.js.map +1 -0
- package/dist/chunk-ZCWKX4V6.cjs +38 -0
- package/dist/chunk-ZCWKX4V6.cjs.map +1 -0
- package/dist/chunk-ZE5RISBZ.cjs +4 -0
- package/dist/chunk-ZE5RISBZ.cjs.map +1 -0
- package/dist/chunk-ZH4F2P2G.js +3 -0
- package/dist/chunk-ZH4F2P2G.js.map +1 -0
- package/dist/chunk-ZJGFLJ2Z.cjs +4 -0
- package/dist/chunk-ZJGFLJ2Z.cjs.map +1 -0
- package/dist/chunk-ZKBHD27K.cjs +4 -0
- package/dist/chunk-ZKBHD27K.cjs.map +1 -0
- package/dist/chunk-ZQPLRNKX.cjs +4 -0
- package/dist/chunk-ZQPLRNKX.cjs.map +1 -0
- package/dist/chunk-ZQQABQMH.cjs +31 -0
- package/dist/chunk-ZQQABQMH.cjs.map +1 -0
- package/dist/chunk-ZXJQSFIA.js +200 -0
- package/dist/chunk-ZXJQSFIA.js.map +1 -0
- package/dist/chunk-ZYPH2FPT.js +3 -0
- package/dist/chunk-ZYPH2FPT.js.map +1 -0
- package/dist/developer-apps-zSQXWmEG.d.cts +294 -0
- package/dist/developer-apps-zSQXWmEG.d.ts +294 -0
- package/dist/entries/apps.cjs +13 -0
- package/dist/entries/apps.cjs.map +1 -0
- package/dist/entries/apps.d.cts +300 -0
- package/dist/entries/apps.d.ts +300 -0
- package/dist/entries/apps.js +4 -0
- package/dist/entries/apps.js.map +1 -0
- package/dist/entries/audio.cjs +13 -0
- package/dist/entries/audio.cjs.map +1 -0
- package/dist/entries/audio.d.cts +200 -0
- package/dist/entries/audio.d.ts +200 -0
- package/dist/entries/audio.js +4 -0
- package/dist/entries/audio.js.map +1 -0
- package/dist/entries/billing.cjs +13 -0
- package/dist/entries/billing.cjs.map +1 -0
- package/dist/entries/billing.d.cts +208 -0
- package/dist/entries/billing.d.ts +208 -0
- package/dist/entries/billing.js +4 -0
- package/dist/entries/billing.js.map +1 -0
- package/dist/entries/catalogs.cjs +13 -0
- package/dist/entries/catalogs.cjs.map +1 -0
- package/dist/entries/catalogs.d.cts +82 -0
- package/dist/entries/catalogs.d.ts +82 -0
- package/dist/entries/catalogs.js +4 -0
- package/dist/entries/catalogs.js.map +1 -0
- package/dist/entries/characters.cjs +45 -0
- package/dist/entries/characters.cjs.map +1 -0
- package/dist/entries/characters.d.cts +741 -0
- package/dist/entries/characters.d.ts +741 -0
- package/dist/entries/characters.js +4 -0
- package/dist/entries/characters.js.map +1 -0
- package/dist/entries/client.cjs +78 -0
- package/dist/entries/client.cjs.map +1 -0
- package/dist/entries/client.d.cts +147 -0
- package/dist/entries/client.d.ts +147 -0
- package/dist/entries/client.js +53 -0
- package/dist/entries/client.js.map +1 -0
- package/dist/entries/collections.cjs +13 -0
- package/dist/entries/collections.cjs.map +1 -0
- package/dist/entries/collections.d.cts +77 -0
- package/dist/entries/collections.d.ts +77 -0
- package/dist/entries/collections.js +4 -0
- package/dist/entries/collections.js.map +1 -0
- package/dist/entries/community.cjs +13 -0
- package/dist/entries/community.cjs.map +1 -0
- package/dist/entries/community.d.cts +87 -0
- package/dist/entries/community.d.ts +87 -0
- package/dist/entries/community.js +4 -0
- package/dist/entries/community.js.map +1 -0
- package/dist/entries/competitors.cjs +13 -0
- package/dist/entries/competitors.cjs.map +1 -0
- package/dist/entries/competitors.d.cts +96 -0
- package/dist/entries/competitors.d.ts +96 -0
- package/dist/entries/competitors.js +4 -0
- package/dist/entries/competitors.js.map +1 -0
- package/dist/entries/copilot.cjs +15 -0
- package/dist/entries/copilot.cjs.map +1 -0
- package/dist/entries/copilot.d.cts +296 -0
- package/dist/entries/copilot.d.ts +296 -0
- package/dist/entries/copilot.js +6 -0
- package/dist/entries/copilot.js.map +1 -0
- package/dist/entries/core.cjs +26 -0
- package/dist/entries/core.cjs.map +1 -0
- package/dist/entries/core.d.cts +3 -0
- package/dist/entries/core.d.ts +3 -0
- package/dist/entries/core.js +5 -0
- package/dist/entries/core.js.map +1 -0
- package/dist/entries/creatures.cjs +29 -0
- package/dist/entries/creatures.cjs.map +1 -0
- package/dist/entries/creatures.d.cts +594 -0
- package/dist/entries/creatures.d.ts +594 -0
- package/dist/entries/creatures.js +4 -0
- package/dist/entries/creatures.js.map +1 -0
- package/dist/entries/credits.cjs +13 -0
- package/dist/entries/credits.cjs.map +1 -0
- package/dist/entries/credits.d.cts +237 -0
- package/dist/entries/credits.d.ts +237 -0
- package/dist/entries/credits.js +4 -0
- package/dist/entries/credits.js.map +1 -0
- package/dist/entries/developer-apps.cjs +13 -0
- package/dist/entries/developer-apps.cjs.map +1 -0
- package/dist/entries/developer-apps.d.cts +3 -0
- package/dist/entries/developer-apps.d.ts +3 -0
- package/dist/entries/developer-apps.js +4 -0
- package/dist/entries/developer-apps.js.map +1 -0
- package/dist/entries/edit.cjs +34 -0
- package/dist/entries/edit.cjs.map +1 -0
- package/dist/entries/edit.d.cts +705 -0
- package/dist/entries/edit.d.ts +705 -0
- package/dist/entries/edit.js +5 -0
- package/dist/entries/edit.js.map +1 -0
- package/dist/entries/errors.cjs +93 -0
- package/dist/entries/errors.cjs.map +1 -0
- package/dist/entries/errors.d.cts +338 -0
- package/dist/entries/errors.d.ts +338 -0
- package/dist/entries/errors.js +4 -0
- package/dist/entries/errors.js.map +1 -0
- package/dist/entries/executions.cjs +21 -0
- package/dist/entries/executions.cjs.map +1 -0
- package/dist/entries/executions.d.cts +120 -0
- package/dist/entries/executions.d.ts +120 -0
- package/dist/entries/executions.js +4 -0
- package/dist/entries/executions.js.map +1 -0
- package/dist/entries/gallery.cjs +13 -0
- package/dist/entries/gallery.cjs.map +1 -0
- package/dist/entries/gallery.d.cts +85 -0
- package/dist/entries/gallery.d.ts +85 -0
- package/dist/entries/gallery.js +4 -0
- package/dist/entries/gallery.js.map +1 -0
- package/dist/entries/jobs.cjs +13 -0
- package/dist/entries/jobs.cjs.map +1 -0
- package/dist/entries/jobs.d.cts +252 -0
- package/dist/entries/jobs.d.ts +252 -0
- package/dist/entries/jobs.js +4 -0
- package/dist/entries/jobs.js.map +1 -0
- package/dist/entries/library.cjs +13 -0
- package/dist/entries/library.cjs.map +1 -0
- package/dist/entries/library.d.cts +109 -0
- package/dist/entries/library.d.ts +109 -0
- package/dist/entries/library.js +4 -0
- package/dist/entries/library.js.map +1 -0
- package/dist/entries/llm.cjs +13 -0
- package/dist/entries/llm.cjs.map +1 -0
- package/dist/entries/llm.d.cts +98 -0
- package/dist/entries/llm.d.ts +98 -0
- package/dist/entries/llm.js +4 -0
- package/dist/entries/llm.js.map +1 -0
- package/dist/entries/locations.cjs +25 -0
- package/dist/entries/locations.cjs.map +1 -0
- package/dist/entries/locations.d.cts +573 -0
- package/dist/entries/locations.d.ts +573 -0
- package/dist/entries/locations.js +4 -0
- package/dist/entries/locations.js.map +1 -0
- package/dist/entries/media.cjs +15 -0
- package/dist/entries/media.cjs.map +1 -0
- package/dist/entries/media.d.cts +548 -0
- package/dist/entries/media.d.ts +548 -0
- package/dist/entries/media.js +6 -0
- package/dist/entries/media.js.map +1 -0
- package/dist/entries/models.cjs +13 -0
- package/dist/entries/models.cjs.map +1 -0
- package/dist/entries/models.d.cts +92 -0
- package/dist/entries/models.d.ts +92 -0
- package/dist/entries/models.js +4 -0
- package/dist/entries/models.js.map +1 -0
- package/dist/entries/moodboards.cjs +21 -0
- package/dist/entries/moodboards.cjs.map +1 -0
- package/dist/entries/moodboards.d.cts +77 -0
- package/dist/entries/moodboards.d.ts +77 -0
- package/dist/entries/moodboards.js +4 -0
- package/dist/entries/moodboards.js.map +1 -0
- package/dist/entries/node-presets.cjs +13 -0
- package/dist/entries/node-presets.cjs.map +1 -0
- package/dist/entries/node-presets.d.cts +217 -0
- package/dist/entries/node-presets.d.ts +217 -0
- package/dist/entries/node-presets.js +4 -0
- package/dist/entries/node-presets.js.map +1 -0
- package/dist/entries/nodes.cjs +22 -0
- package/dist/entries/nodes.cjs.map +1 -0
- package/dist/entries/nodes.d.cts +18 -0
- package/dist/entries/nodes.d.ts +18 -0
- package/dist/entries/nodes.js +5 -0
- package/dist/entries/nodes.js.map +1 -0
- package/dist/entries/oauth.cjs +13 -0
- package/dist/entries/oauth.cjs.map +1 -0
- package/dist/entries/oauth.d.cts +69 -0
- package/dist/entries/oauth.d.ts +69 -0
- package/dist/entries/oauth.js +4 -0
- package/dist/entries/oauth.js.map +1 -0
- package/dist/entries/objects.cjs +29 -0
- package/dist/entries/objects.cjs.map +1 -0
- package/dist/entries/objects.d.cts +544 -0
- package/dist/entries/objects.d.ts +544 -0
- package/dist/entries/objects.js +4 -0
- package/dist/entries/objects.js.map +1 -0
- package/dist/entries/organizations.cjs +21 -0
- package/dist/entries/organizations.cjs.map +1 -0
- package/dist/entries/organizations.d.cts +164 -0
- package/dist/entries/organizations.d.ts +164 -0
- package/dist/entries/organizations.js +4 -0
- package/dist/entries/organizations.js.map +1 -0
- package/dist/entries/palettes.cjs +21 -0
- package/dist/entries/palettes.cjs.map +1 -0
- package/dist/entries/palettes.d.cts +69 -0
- package/dist/entries/palettes.d.ts +69 -0
- package/dist/entries/palettes.js +4 -0
- package/dist/entries/palettes.js.map +1 -0
- package/dist/entries/picker-catalogs.cjs +13 -0
- package/dist/entries/picker-catalogs.cjs.map +1 -0
- package/dist/entries/picker-catalogs.d.cts +148 -0
- package/dist/entries/picker-catalogs.d.ts +148 -0
- package/dist/entries/picker-catalogs.js +4 -0
- package/dist/entries/picker-catalogs.js.map +1 -0
- package/dist/entries/pipelines.cjs +13 -0
- package/dist/entries/pipelines.cjs.map +1 -0
- package/dist/entries/pipelines.d.cts +255 -0
- package/dist/entries/pipelines.d.ts +255 -0
- package/dist/entries/pipelines.js +4 -0
- package/dist/entries/pipelines.js.map +1 -0
- package/dist/entries/projects.cjs +13 -0
- package/dist/entries/projects.cjs.map +1 -0
- package/dist/entries/projects.d.cts +49 -0
- package/dist/entries/projects.d.ts +49 -0
- package/dist/entries/projects.js +4 -0
- package/dist/entries/projects.js.map +1 -0
- package/dist/entries/prompt-helper.cjs +13 -0
- package/dist/entries/prompt-helper.cjs.map +1 -0
- package/dist/entries/prompt-helper.d.cts +73 -0
- package/dist/entries/prompt-helper.d.ts +73 -0
- package/dist/entries/prompt-helper.js +4 -0
- package/dist/entries/prompt-helper.js.map +1 -0
- package/dist/entries/recast.cjs +17 -0
- package/dist/entries/recast.cjs.map +1 -0
- package/dist/entries/recast.d.cts +229 -0
- package/dist/entries/recast.d.ts +229 -0
- package/dist/entries/recast.js +4 -0
- package/dist/entries/recast.js.map +1 -0
- package/dist/entries/reduce.cjs +13 -0
- package/dist/entries/reduce.cjs.map +1 -0
- package/dist/entries/reduce.d.cts +56 -0
- package/dist/entries/reduce.d.ts +56 -0
- package/dist/entries/reduce.js +4 -0
- package/dist/entries/reduce.js.map +1 -0
- package/dist/entries/saved-posts.cjs +13 -0
- package/dist/entries/saved-posts.cjs.map +1 -0
- package/dist/entries/saved-posts.d.cts +33 -0
- package/dist/entries/saved-posts.d.ts +33 -0
- package/dist/entries/saved-posts.js +4 -0
- package/dist/entries/saved-posts.js.map +1 -0
- package/dist/entries/scene3d.cjs +17 -0
- package/dist/entries/scene3d.cjs.map +1 -0
- package/dist/entries/scene3d.d.cts +131 -0
- package/dist/entries/scene3d.d.ts +131 -0
- package/dist/entries/scene3d.js +4 -0
- package/dist/entries/scene3d.js.map +1 -0
- package/dist/entries/sessions.cjs +13 -0
- package/dist/entries/sessions.cjs.map +1 -0
- package/dist/entries/sessions.d.cts +122 -0
- package/dist/entries/sessions.d.ts +122 -0
- package/dist/entries/sessions.js +4 -0
- package/dist/entries/sessions.js.map +1 -0
- package/dist/entries/shots.cjs +13 -0
- package/dist/entries/shots.cjs.map +1 -0
- package/dist/entries/shots.d.cts +78 -0
- package/dist/entries/shots.d.ts +78 -0
- package/dist/entries/shots.js +4 -0
- package/dist/entries/shots.js.map +1 -0
- package/dist/entries/studio.cjs +22 -0
- package/dist/entries/studio.cjs.map +1 -0
- package/dist/entries/studio.d.cts +281 -0
- package/dist/entries/studio.d.ts +281 -0
- package/dist/entries/studio.js +5 -0
- package/dist/entries/studio.js.map +1 -0
- package/dist/entries/templates.cjs +13 -0
- package/dist/entries/templates.cjs.map +1 -0
- package/dist/entries/templates.d.cts +110 -0
- package/dist/entries/templates.d.ts +110 -0
- package/dist/entries/templates.js +4 -0
- package/dist/entries/templates.js.map +1 -0
- package/dist/entries/tutorials.cjs +13 -0
- package/dist/entries/tutorials.cjs.map +1 -0
- package/dist/entries/tutorials.d.cts +63 -0
- package/dist/entries/tutorials.d.ts +63 -0
- package/dist/entries/tutorials.js +4 -0
- package/dist/entries/tutorials.js.map +1 -0
- package/dist/entries/uploads.cjs +13 -0
- package/dist/entries/uploads.cjs.map +1 -0
- package/dist/entries/uploads.d.cts +44 -0
- package/dist/entries/uploads.d.ts +44 -0
- package/dist/entries/uploads.js +4 -0
- package/dist/entries/uploads.js.map +1 -0
- package/dist/entries/video-pro.cjs +13 -0
- package/dist/entries/video-pro.cjs.map +1 -0
- package/dist/entries/video-pro.d.cts +60 -0
- package/dist/entries/video-pro.d.ts +60 -0
- package/dist/entries/video-pro.js +4 -0
- package/dist/entries/video-pro.js.map +1 -0
- package/dist/entries/voices.cjs +13 -0
- package/dist/entries/voices.cjs.map +1 -0
- package/dist/entries/voices.d.cts +498 -0
- package/dist/entries/voices.d.ts +498 -0
- package/dist/entries/voices.js +4 -0
- package/dist/entries/voices.js.map +1 -0
- package/dist/entries/webhooks.cjs +21 -0
- package/dist/entries/webhooks.cjs.map +1 -0
- package/dist/entries/webhooks.d.cts +64 -0
- package/dist/entries/webhooks.d.ts +64 -0
- package/dist/entries/webhooks.js +4 -0
- package/dist/entries/webhooks.js.map +1 -0
- package/dist/entries/workflows.cjs +13 -0
- package/dist/entries/workflows.cjs.map +1 -0
- package/dist/entries/workflows.d.cts +393 -0
- package/dist/entries/workflows.d.ts +393 -0
- package/dist/entries/workflows.js +4 -0
- package/dist/entries/workflows.js.map +1 -0
- package/dist/entries/workspaces.cjs +13 -0
- package/dist/entries/workspaces.cjs.map +1 -0
- package/dist/entries/workspaces.d.cts +124 -0
- package/dist/entries/workspaces.d.ts +124 -0
- package/dist/entries/workspaces.js +4 -0
- package/dist/entries/workspaces.js.map +1 -0
- package/dist/index.cjs +501 -5192
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +67 -10895
- package/dist/index.d.ts +67 -10895
- package/dist/index.js +100 -5074
- package/dist/index.js.map +1 -1
- package/dist/nodes-C-wrO6Sg.d.ts +1364 -0
- package/dist/nodes-J8ByUN8z.d.cts +1364 -0
- package/dist/studio-productions-DUHvdSvk.d.cts +572 -0
- package/dist/studio-productions-vbCNSbtf.d.ts +572 -0
- package/dist/webhooks-BJawEIz8.d.ts +198 -0
- package/dist/webhooks-Dn_DtNTD.d.cts +198 -0
- package/package.json +253 -3
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
// src/resources/palettes.ts
|
|
4
|
+
var PALETTE_DIRECTION_PREFIX = "palette:";
|
|
5
|
+
function paletteDirectionId(id) {
|
|
6
|
+
return `${PALETTE_DIRECTION_PREFIX}${id}`;
|
|
7
|
+
}
|
|
8
|
+
var PalettesResource = class {
|
|
9
|
+
constructor(client) {
|
|
10
|
+
this.client = client;
|
|
11
|
+
}
|
|
12
|
+
client;
|
|
13
|
+
/** Your palettes, newest first. Page with `nextCursor`. */
|
|
14
|
+
list(params = {}) {
|
|
15
|
+
return this.client.request("GET", "/v1/palettes", {
|
|
16
|
+
query: { limit: params.limit, cursor: params.cursor }
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
get(id) {
|
|
20
|
+
return this.client.request("GET", `/v1/palettes/${encodeURIComponent(id)}`);
|
|
21
|
+
}
|
|
22
|
+
create(input) {
|
|
23
|
+
return this.client.request("POST", "/v1/palettes", { body: input });
|
|
24
|
+
}
|
|
25
|
+
update(id, input) {
|
|
26
|
+
return this.client.request("PATCH", `/v1/palettes/${encodeURIComponent(id)}`, { body: input });
|
|
27
|
+
}
|
|
28
|
+
/** A run that still names the palette answers 404 `direction_not_found`. */
|
|
29
|
+
async delete(id) {
|
|
30
|
+
await this.client.request("DELETE", `/v1/palettes/${encodeURIComponent(id)}`);
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
exports.PALETTE_DIRECTION_PREFIX = PALETTE_DIRECTION_PREFIX;
|
|
35
|
+
exports.PalettesResource = PalettesResource;
|
|
36
|
+
exports.paletteDirectionId = paletteDirectionId;
|
|
37
|
+
//# sourceMappingURL=chunk-NBVARNVA.cjs.map
|
|
38
|
+
//# sourceMappingURL=chunk-NBVARNVA.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/resources/palettes.ts"],"names":[],"mappings":";;;AA4CO,IAAM,wBAAA,GAA2B;AAQjC,SAAS,mBAAmB,EAAA,EAAiC;AAClE,EAAA,OAAO,CAAA,EAAG,wBAAwB,CAAA,EAAG,EAAE,CAAA,CAAA;AACzC;AASO,IAAM,mBAAN,MAAuB;AAAA,EAC5B,YAAoB,MAAA,EAA0B;AAA1B,IAAA,IAAA,CAAA,MAAA,GAAA,MAAA;AAAA,EAA2B;AAAA,EAA3B,MAAA;AAAA;AAAA,EAGpB,IAAA,CAAK,MAAA,GAA6B,EAAC,EAAyB;AAC1D,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAAqB,KAAA,EAAO,cAAA,EAAgB;AAAA,MAC7D,OAAO,EAAE,KAAA,EAAO,OAAO,KAAA,EAAO,MAAA,EAAQ,OAAO,MAAA;AAAO,KACrD,CAAA;AAAA,EACH;AAAA,EAEA,IAAI,EAAA,EAAmC;AACrC,IAAA,OAAO,IAAA,CAAK,OAAO,OAAA,CAAsB,KAAA,EAAO,gBAAgB,kBAAA,CAAmB,EAAE,CAAC,CAAA,CAAE,CAAA;AAAA,EAC1F;AAAA,EAEA,OAAO,KAAA,EAAkD;AACvD,IAAA,OAAO,IAAA,CAAK,OAAO,OAAA,CAAsB,MAAA,EAAQ,gBAAgB,EAAE,IAAA,EAAM,OAAO,CAAA;AAAA,EAClF;AAAA,EAEA,MAAA,CAAO,IAAY,KAAA,EAAkD;AACnE,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAAsB,OAAA,EAAS,CAAA,aAAA,EAAgB,kBAAA,CAAmB,EAAE,CAAC,CAAA,CAAA,EAAI,EAAE,IAAA,EAAM,KAAA,EAAO,CAAA;AAAA,EAC7G;AAAA;AAAA,EAGA,MAAM,OAAO,EAAA,EAA2B;AACtC,IAAA,MAAM,IAAA,CAAK,OAAO,OAAA,CAA2B,QAAA,EAAU,gBAAgB,kBAAA,CAAmB,EAAE,CAAC,CAAA,CAAE,CAAA;AAAA,EACjG;AACF","file":"chunk-NBVARNVA.cjs","sourcesContent":["import type { NodaroClientCore } from \"../core.js\"\n\n/** One of your colour palettes. */\nexport interface ColorPalette {\n id: string\n name: string\n /** 2–12 colours, `#RRGGBB`, upper case. */\n colors: string[]\n /** Your own note. It is not put into the prompt. */\n description: string | null\n createdAt: string\n updatedAt: string\n}\n\nexport interface CreatePaletteInput {\n /** 1–80 characters. */\n name: string\n /** 2–12 colours, `#RRGGBB` (any case; stored upper case). */\n colors: string[]\n /** Up to 500 characters. */\n description?: string | null\n}\n\n/** Only the fields you send are written; `description: null` clears it. */\nexport interface UpdatePaletteInput {\n name?: string\n colors?: string[]\n description?: string | null\n}\n\nexport interface ListPalettesParams {\n /** Page size, 1–100 (server default 50). */\n limit?: number\n /** The previous page's `nextCursor`. */\n cursor?: string\n}\n\nexport interface PalettePage {\n data: ColorPalette[]\n /** Pass back as `cursor` for the next page; `null` on the last one. */\n nextCursor: string | null\n}\n\n/** The prefix of a palette's generate-image direction id (`direction.colorLook`). */\nexport const PALETTE_DIRECTION_PREFIX = \"palette:\" as const\n\n/**\n * A palette as a generate-image direction value — put it on\n * `direction.colorLook`. The run names each colour (an everyday name and its\n * hex) in the prompt; the job keeps the id, so a re-run uses the palette as it\n * is then.\n */\nexport function paletteDirectionId(id: string): `palette:${string}` {\n return `${PALETTE_DIRECTION_PREFIX}${id}`\n}\n\n/**\n * Colour palettes — `GET/POST /v1/palettes`, `GET/PATCH/DELETE /v1/palettes/:id`.\n *\n * Yours only (another person's id answers 404). Use one on generate-image as\n * `direction: { colorLook: paletteDirectionId(id) }`. OAuth app tokens need\n * `assets:read` for reads and `assets:write` for writes.\n */\nexport class PalettesResource {\n constructor(private client: NodaroClientCore) {}\n\n /** Your palettes, newest first. Page with `nextCursor`. */\n list(params: ListPalettesParams = {}): Promise<PalettePage> {\n return this.client.request<PalettePage>(\"GET\", \"/v1/palettes\", {\n query: { limit: params.limit, cursor: params.cursor },\n })\n }\n\n get(id: string): Promise<ColorPalette> {\n return this.client.request<ColorPalette>(\"GET\", `/v1/palettes/${encodeURIComponent(id)}`)\n }\n\n create(input: CreatePaletteInput): Promise<ColorPalette> {\n return this.client.request<ColorPalette>(\"POST\", \"/v1/palettes\", { body: input })\n }\n\n update(id: string, input: UpdatePaletteInput): Promise<ColorPalette> {\n return this.client.request<ColorPalette>(\"PATCH\", `/v1/palettes/${encodeURIComponent(id)}`, { body: input })\n }\n\n /** A run that still names the palette answers 404 `direction_not_found`. */\n async delete(id: string): Promise<void> {\n await this.client.request<{ success: true }>(\"DELETE\", `/v1/palettes/${encodeURIComponent(id)}`)\n }\n}\n"]}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
// src/resources/saved-posts.ts
|
|
2
|
+
var SavedPostsResource = class {
|
|
3
|
+
constructor(client) {
|
|
4
|
+
this.client = client;
|
|
5
|
+
}
|
|
6
|
+
client;
|
|
7
|
+
/** `GET /v1/saved-posts` → your saves, newest first. Page with `nextCursor`. */
|
|
8
|
+
list(params = {}) {
|
|
9
|
+
return this.client.request("GET", "/v1/saved-posts", {
|
|
10
|
+
query: {
|
|
11
|
+
platform: params.platform,
|
|
12
|
+
tag: params.tag,
|
|
13
|
+
q: params.q,
|
|
14
|
+
cursor: params.cursor,
|
|
15
|
+
limit: params.limit
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* `POST /v1/saved-posts` → save a post. Saving a post that is already saved
|
|
21
|
+
* updates its note and tags (when given) and returns the existing save.
|
|
22
|
+
*/
|
|
23
|
+
save(input) {
|
|
24
|
+
return this.client.request("POST", "/v1/saved-posts", { body: input });
|
|
25
|
+
}
|
|
26
|
+
/** `POST /v1/saved-posts/lookup` → which of these post ids (`SocialPost.id`) you saved. */
|
|
27
|
+
lookup(postIds) {
|
|
28
|
+
return this.client.request("POST", "/v1/saved-posts/lookup", { body: { postIds } });
|
|
29
|
+
}
|
|
30
|
+
/** `PATCH /v1/saved-posts/:id` → change a save's note or tags. */
|
|
31
|
+
update(id, input) {
|
|
32
|
+
return this.client.request("PATCH", `/v1/saved-posts/${encodeURIComponent(id)}`, { body: input });
|
|
33
|
+
}
|
|
34
|
+
/** `DELETE /v1/saved-posts/:id` → remove a save and its copied still. */
|
|
35
|
+
async delete(id) {
|
|
36
|
+
await this.client.request("DELETE", `/v1/saved-posts/${encodeURIComponent(id)}`);
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
export { SavedPostsResource };
|
|
41
|
+
//# sourceMappingURL=chunk-NCCBS6GU.js.map
|
|
42
|
+
//# sourceMappingURL=chunk-NCCBS6GU.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/resources/saved-posts.ts"],"names":[],"mappings":";AAkBO,IAAM,qBAAN,MAAyB;AAAA,EAC9B,YAAoB,MAAA,EAA0B;AAA1B,IAAA,IAAA,CAAA,MAAA,GAAA,MAAA;AAAA,EAA2B;AAAA,EAA3B,MAAA;AAAA;AAAA,EAGpB,IAAA,CAAK,MAAA,GAA+B,EAAC,EAAkC;AACrE,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAA8B,KAAA,EAAO,iBAAA,EAAmB;AAAA,MACzE,KAAA,EAAO;AAAA,QACL,UAAU,MAAA,CAAO,QAAA;AAAA,QACjB,KAAK,MAAA,CAAO,GAAA;AAAA,QACZ,GAAG,MAAA,CAAO,CAAA;AAAA,QACV,QAAQ,MAAA,CAAO,MAAA;AAAA,QACf,OAAO,MAAA,CAAO;AAAA;AAChB,KACD,CAAA;AAAA,EACH;AAAA;AAAA;AAAA;AAAA;AAAA,EAMA,KAAK,KAAA,EAA0C;AAC7C,IAAA,OAAO,IAAA,CAAK,OAAO,OAAA,CAAmB,MAAA,EAAQ,mBAAmB,EAAE,IAAA,EAAM,OAAO,CAAA;AAAA,EAClF;AAAA;AAAA,EAGA,OAAO,OAAA,EAA6D;AAClE,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAAgC,MAAA,EAAQ,wBAAA,EAA0B,EAAE,IAAA,EAAM,EAAE,OAAA,EAAQ,EAAG,CAAA;AAAA,EAC5G;AAAA;AAAA,EAGA,MAAA,CAAO,IAAY,KAAA,EAAiD;AAClE,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAAmB,OAAA,EAAS,CAAA,gBAAA,EAAmB,kBAAA,CAAmB,EAAE,CAAC,CAAA,CAAA,EAAI,EAAE,IAAA,EAAM,KAAA,EAAO,CAAA;AAAA,EAC7G;AAAA;AAAA,EAGA,MAAM,OAAO,EAAA,EAA2B;AACtC,IAAA,MAAM,IAAA,CAAK,OAAO,OAAA,CAA2B,QAAA,EAAU,mBAAmB,kBAAA,CAAmB,EAAE,CAAC,CAAA,CAAE,CAAA;AAAA,EACpG;AACF","file":"chunk-NCCBS6GU.js","sourcesContent":["import type { NodaroClientCore } from \"../core.js\"\nimport type {\n ListSavedPostsParams,\n ListSavedPostsResult,\n SavePostInput,\n SavedPost,\n SavedPostsLookupResult,\n UpdateSavedPostInput,\n} from \"@nodaro/shared/social\"\n\n/**\n * Saved posts — the inspiration wall.\n *\n * Save a post you found (a Social Search result, `nodes.run(\"social-search\")`)\n * with a note and tags, list and filter your saves, and change or remove them.\n * A save keeps a snapshot of the post and a copy of its still in your storage.\n * OAuth app tokens need `assets:read` for reads and `assets:write` for writes.\n */\nexport class SavedPostsResource {\n constructor(private client: NodaroClientCore) {}\n\n /** `GET /v1/saved-posts` → your saves, newest first. Page with `nextCursor`. */\n list(params: ListSavedPostsParams = {}): Promise<ListSavedPostsResult> {\n return this.client.request<ListSavedPostsResult>(\"GET\", \"/v1/saved-posts\", {\n query: {\n platform: params.platform,\n tag: params.tag,\n q: params.q,\n cursor: params.cursor,\n limit: params.limit,\n },\n })\n }\n\n /**\n * `POST /v1/saved-posts` → save a post. Saving a post that is already saved\n * updates its note and tags (when given) and returns the existing save.\n */\n save(input: SavePostInput): Promise<SavedPost> {\n return this.client.request<SavedPost>(\"POST\", \"/v1/saved-posts\", { body: input })\n }\n\n /** `POST /v1/saved-posts/lookup` → which of these post ids (`SocialPost.id`) you saved. */\n lookup(postIds: readonly string[]): Promise<SavedPostsLookupResult> {\n return this.client.request<SavedPostsLookupResult>(\"POST\", \"/v1/saved-posts/lookup\", { body: { postIds } })\n }\n\n /** `PATCH /v1/saved-posts/:id` → change a save's note or tags. */\n update(id: string, input: UpdateSavedPostInput): Promise<SavedPost> {\n return this.client.request<SavedPost>(\"PATCH\", `/v1/saved-posts/${encodeURIComponent(id)}`, { body: input })\n }\n\n /** `DELETE /v1/saved-posts/:id` → remove a save and its copied still. */\n async delete(id: string): Promise<void> {\n await this.client.request<{ success: true }>(\"DELETE\", `/v1/saved-posts/${encodeURIComponent(id)}`)\n }\n}\n"]}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
// src/resources/billing.ts
|
|
4
|
+
var BillingResource = class {
|
|
5
|
+
constructor(client) {
|
|
6
|
+
this.client = client;
|
|
7
|
+
}
|
|
8
|
+
client;
|
|
9
|
+
/**
|
|
10
|
+
* `GET /v1/billing/plans` → the plans and credit packs on sale, with their
|
|
11
|
+
* prices. Public: works with no credential, the same for every caller.
|
|
12
|
+
* Nodaro Cloud only — a self-hosted instance answers 404. Throws on `403
|
|
13
|
+
* self_serve_disabled` (this deployment does not sell to its users) and on
|
|
14
|
+
* `503` (`stripe_not_configured`, or prices briefly unavailable).
|
|
15
|
+
*/
|
|
16
|
+
plans() {
|
|
17
|
+
return this.client.request("GET", "/v1/billing/plans");
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* `GET /v1/billing/subscription` → the account's latest subscription
|
|
21
|
+
* (`null` when it never subscribed) and the tier its entitlements follow.
|
|
22
|
+
* Match `effectiveTier` to a {@link BillingPlan} `id` to mark the current
|
|
23
|
+
* plan (no match: pay-as-you-go, or a tier not on sale). Needs a signed-in
|
|
24
|
+
* session, a personal API token without a workflow limit, or an app's OAuth
|
|
25
|
+
* token. Nodaro Cloud only — a self-hosted instance answers 404.
|
|
26
|
+
*/
|
|
27
|
+
subscription() {
|
|
28
|
+
return this.client.request("GET", "/v1/billing/subscription");
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* `GET /v1/billing/surface` → how this deployment bills: whether it meters
|
|
32
|
+
* at all (`providerId !== "none"`) and in which unit costs display. Public,
|
|
33
|
+
* every edition.
|
|
34
|
+
*/
|
|
35
|
+
async surface() {
|
|
36
|
+
const res = await this.client.request("GET", "/v1/billing/surface");
|
|
37
|
+
return res.data;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* `GET /v1/billing/account` → the caller's plan and balance as the
|
|
41
|
+
* deployment's billing provider reports them, in its display unit. `null`
|
|
42
|
+
* when the provider could not answer — not a zero balance. Every edition.
|
|
43
|
+
*/
|
|
44
|
+
async account() {
|
|
45
|
+
const res = await this.client.request("GET", "/v1/billing/account");
|
|
46
|
+
return res.data;
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
exports.BillingResource = BillingResource;
|
|
51
|
+
//# sourceMappingURL=chunk-NGKODS3J.cjs.map
|
|
52
|
+
//# sourceMappingURL=chunk-NGKODS3J.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/resources/billing.ts"],"names":[],"mappings":";;;AA6KO,IAAM,kBAAN,MAAsB;AAAA,EAC3B,YAAoB,MAAA,EAA0B;AAA1B,IAAA,IAAA,CAAA,MAAA,GAAA,MAAA;AAAA,EAA2B;AAAA,EAA3B,MAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EASpB,KAAA,GAAqC;AACnC,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAA4B,KAAA,EAAO,mBAAmB,CAAA;AAAA,EAC3E;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAUA,YAAA,GAAmD;AACjD,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO,OAAA,CAAmC,KAAA,EAAO,0BAA0B,CAAA;AAAA,EACzF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,OAAA,GAAmC;AACvC,IAAA,MAAM,MAAM,MAAM,IAAA,CAAK,MAAA,CAAO,OAAA,CAAkC,OAAO,qBAAqB,CAAA;AAC5F,IAAA,OAAO,GAAA,CAAI,IAAA;AAAA,EACb;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,OAAA,GAAiD;AACrD,IAAA,MAAM,MAAM,MAAM,IAAA,CAAK,MAAA,CAAO,OAAA,CAAgD,OAAO,qBAAqB,CAAA;AAC1G,IAAA,OAAO,GAAA,CAAI,IAAA;AAAA,EACb;AACF","file":"chunk-NGKODS3J.cjs","sourcesContent":["import type { NodaroClientCore } from \"../core.js\"\n\n/**\n * Plans and prices, the subscription, and the billing surface — the shapes of\n * the `/v1/billing/*` routes an app may call. Mirrors the backend routes\n * (`backend/src/ee/routes/billing.ts`, `backend/src/routes/billing-surface.ts`),\n * the source of truth: keep these in sync if they change.\n *\n * Buying, changing the plan and the payment settings stay in the Nodaro app:\n * those routes refuse API and app tokens, so they have no method here.\n */\n\n/** A sum of money in its currency's major unit (`12` = 12.00), with its ISO-4217 code (`\"USD\"`). */\nexport interface BillingMoney {\n amount: number\n currency: string\n}\n\n/** The credits a price grants, and how often. */\nexport interface BillingPriceCredits {\n amount: number\n per: \"month\" | \"year\"\n}\n\n/** A monthly price, and what it grants. */\nexport interface BillingMonthlyPrice extends BillingMoney {\n /** `null` when the price does not state it. */\n credits: BillingPriceCredits | null\n}\n\n/** A yearly price, what it comes to per month, and what it grants. */\nexport interface BillingYearlyPrice extends BillingMoney {\n /** The yearly amount spread over the months it pays for; `null` when that cannot be said. */\n perMonth: number | null\n /** What the price grants — the plan's credits every month, as a monthly price; `null` when the price does not state it. */\n credits: BillingPriceCredits | null\n}\n\nexport interface BillingPlanPrices {\n /** `null` = Stripe cannot sell this price right now: show it as unavailable, never as free. */\n monthly: BillingMonthlyPrice | null\n yearly: BillingYearlyPrice | null\n}\n\n/** One plan on sale. */\nexport interface BillingPlan {\n /** `\"free\"`, `\"basic\"`, `\"standard\"`, … — the stable id. */\n id: string\n name: string\n /** `null` for the free plan: there is nothing to pay. */\n prices: BillingPlanPrices | null\n /** The free plan's one-time grant at sign-up; `null` on a paid plan, whose credits come with each price. */\n signupCredits: number | null\n /** How many nodes of one workflow run at once. */\n parallelism: number\n /** Storage for your media, in bytes. */\n storageBytes: number\n}\n\n/** A credit pack: this many credits for this price. */\nexport interface BillingTopUp {\n id: string\n credits: number\n /** `null` when the pack's price cannot be stated right now: show it as unavailable. */\n price: BillingMoney | null\n}\n\n/** The answer of `GET /v1/billing/plans`. */\nexport interface BillingPlansResult {\n /** The free plan first, then each paid plan from the smallest. */\n data: BillingPlan[]\n /** The credit packs, from the smallest. */\n topUps: BillingTopUp[]\n /** Any whole amount in this range can be loaded as credits, at the same rate as the packs. */\n topUpRange: { min: number; max: number; currency: string }\n}\n\n/** The account's latest subscription record. */\nexport interface BillingSubscription {\n id: string\n stripe_subscription_id: string | null\n /** The plan id: `\"basic\"`, `\"standard\"`, … */\n tier: string\n /** `\"active\"`, `\"trialing\"`, `\"past_due\"`, `\"paused\"`, `\"canceled\"`, `\"incomplete\"` or `\"expired\"`. */\n status: string\n stripe_price_id: string | null\n /** ISO-8601. */\n current_period_start: string | null\n /** ISO-8601: when the current period ends (and renews, unless cancelled). */\n current_period_end: string | null\n /** True when the subscription ends at `current_period_end` instead of renewing. */\n cancel_at_period_end: boolean\n /** ISO-8601: when a scheduled cancellation takes effect. */\n cancel_at: string | null\n /** ISO-8601: when it was cancelled. */\n canceled_at: string | null\n}\n\n/** The answer of `GET /v1/billing/subscription`. */\nexport interface BillingSubscriptionResult {\n /** `null` when the account never subscribed. */\n data: BillingSubscription | null\n /**\n * The tier the account's entitlements follow: usually a plan id from\n * `plans()` (`\"free\"` included); `\"payg\"` — no subscription, but credits\n * bought (every model, no watermark); or a tier that is not on sale, such\n * as `\"enterprise\"`.\n */\n effectiveTier: string\n}\n\n/** How this deployment bills, the same for every caller (`GET /v1/billing/surface`). */\nexport interface BillingSurface {\n /** The billing-surface contract version (an integer). */\n contract: number\n /** The registered billing provider; `\"none\"` = this deployment meters nothing. */\n providerId: string\n /** The unit costs display in by default (`\"credits\"`, `\"usd\"`, or a deployment's own label). */\n displayUnit: string\n canReport: boolean\n canQuote: boolean\n canAccount: boolean\n /** Whether a cost view belongs on this deployment. */\n mountCostTab: boolean\n /** One billing account pays for every user here. */\n deploymentPayer: boolean\n}\n\n/** One row of {@link BillingAccountSummary.byCategory}. */\nexport interface BillingUsageCategory {\n category: string\n count: number\n /** Spend in the display unit; `null` = unavailable, never 0. */\n amount: number | null\n spent: BillingMoney | null\n}\n\n/**\n * The caller's account as the deployment's billing provider sees it\n * (`GET /v1/billing/account`). Money and amounts are `null` when the provider\n * could not say: show that distinctly, never as 0. A field the provider leaves\n * out is a concept it does not have.\n */\nexport interface BillingAccountSummary {\n /** A plain string; `\"unknown\"` is a real answer. */\n plan: string\n balance: number | null\n dailyAllowance: number | null\n unit: string\n /** `\"external_wallet\"` when the balance comes from a wallet outside Nodaro. */\n balanceSource?: \"external_wallet\"\n /** ISO-8601 start of the current usage period. */\n periodStart?: string | null\n /** Generations this period. */\n generations?: number | null\n /** Money spent this period. */\n spent?: BillingMoney | null\n /** Pay-as-you-go state. */\n payg?: {\n enabled: boolean\n reserve: number | null\n rate: { creditsPerUnit: number; currency: string } | null\n monthlyCap: BillingMoney | null\n } | null\n /** The daily cap and when it resets; prefer it over `dailyAllowance` when present. `limit: 0` means blocked. */\n daily?: { limit: number; used: number; remaining: number; resetsAt: string } | null\n /** Money value of the pay-as-you-go reserve. */\n reserveValue?: BillingMoney | null\n byCategory?: BillingUsageCategory[] | null\n /** The total the balance is drawn from, where the provider grants each user an allocation. */\n allocated?: number | null\n}\n\nexport class BillingResource {\n constructor(private client: NodaroClientCore) {}\n\n /**\n * `GET /v1/billing/plans` → the plans and credit packs on sale, with their\n * prices. Public: works with no credential, the same for every caller.\n * Nodaro Cloud only — a self-hosted instance answers 404. Throws on `403\n * self_serve_disabled` (this deployment does not sell to its users) and on\n * `503` (`stripe_not_configured`, or prices briefly unavailable).\n */\n plans(): Promise<BillingPlansResult> {\n return this.client.request<BillingPlansResult>(\"GET\", \"/v1/billing/plans\")\n }\n\n /**\n * `GET /v1/billing/subscription` → the account's latest subscription\n * (`null` when it never subscribed) and the tier its entitlements follow.\n * Match `effectiveTier` to a {@link BillingPlan} `id` to mark the current\n * plan (no match: pay-as-you-go, or a tier not on sale). Needs a signed-in\n * session, a personal API token without a workflow limit, or an app's OAuth\n * token. Nodaro Cloud only — a self-hosted instance answers 404.\n */\n subscription(): Promise<BillingSubscriptionResult> {\n return this.client.request<BillingSubscriptionResult>(\"GET\", \"/v1/billing/subscription\")\n }\n\n /**\n * `GET /v1/billing/surface` → how this deployment bills: whether it meters\n * at all (`providerId !== \"none\"`) and in which unit costs display. Public,\n * every edition.\n */\n async surface(): Promise<BillingSurface> {\n const res = await this.client.request<{ data: BillingSurface }>(\"GET\", \"/v1/billing/surface\")\n return res.data\n }\n\n /**\n * `GET /v1/billing/account` → the caller's plan and balance as the\n * deployment's billing provider reports them, in its display unit. `null`\n * when the provider could not answer — not a zero balance. Every edition.\n */\n async account(): Promise<BillingAccountSummary | null> {\n const res = await this.client.request<{ data: BillingAccountSummary | null }>(\"GET\", \"/v1/billing/account\")\n return res.data\n }\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk-NJVSKUL2.cjs"}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkKNMW722T_cjs = require('./chunk-KNMW722T.cjs');
|
|
4
|
+
|
|
5
|
+
// src/resources/copilot.ts
|
|
6
|
+
var COPILOT_FRAME_TYPES = /* @__PURE__ */ new Set([
|
|
7
|
+
"metadata",
|
|
8
|
+
"token",
|
|
9
|
+
"tool_call",
|
|
10
|
+
"workflow_updated",
|
|
11
|
+
"workflow_created",
|
|
12
|
+
"run_proposed",
|
|
13
|
+
"memory_saved",
|
|
14
|
+
"usage",
|
|
15
|
+
"done",
|
|
16
|
+
"error"
|
|
17
|
+
]);
|
|
18
|
+
function isCopilotFrame(value) {
|
|
19
|
+
if (typeof value !== "object" || value === null) return false;
|
|
20
|
+
const type = value.type;
|
|
21
|
+
return typeof type === "string" && COPILOT_FRAME_TYPES.has(type);
|
|
22
|
+
}
|
|
23
|
+
var CopilotResource = class {
|
|
24
|
+
constructor(client) {
|
|
25
|
+
this.client = client;
|
|
26
|
+
}
|
|
27
|
+
client;
|
|
28
|
+
/**
|
|
29
|
+
* Open a conversation (`POST /v1/copilot/threads`) — on `workflowId`, or on
|
|
30
|
+
* a workflow the server creates from `prompt`. Re-opening a workflow that
|
|
31
|
+
* already has an active thread answers THAT thread rather than a second one.
|
|
32
|
+
*/
|
|
33
|
+
create(input) {
|
|
34
|
+
return this.client.request("POST", "/v1/copilot/threads", { body: input });
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* The active thread for a workflow (`GET /v1/copilot/threads?workflowId=…`),
|
|
38
|
+
* or `null` when the user has none open on it.
|
|
39
|
+
*/
|
|
40
|
+
list(params) {
|
|
41
|
+
return this.client.request("GET", "/v1/copilot/threads", { query: { workflowId: params.workflowId } });
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* One thread with its messages (`GET /v1/copilot/threads/:id`). `after` reads
|
|
45
|
+
* only what followed that sequence number (the panel's catch-up); `limit`
|
|
46
|
+
* caps the page at the server's own ceiling.
|
|
47
|
+
*/
|
|
48
|
+
get(id, opts = {}) {
|
|
49
|
+
return this.client.request("GET", `/v1/copilot/threads/${encodeURIComponent(id)}`, {
|
|
50
|
+
query: { ...opts.after !== void 0 ? { after: opts.after } : {}, ...opts.limit !== void 0 ? { limit: opts.limit } : {} }
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Close a conversation (`DELETE /v1/copilot/threads/:id`). Archival, not
|
|
55
|
+
* deletion — the messages stay readable. Refused while a turn is running.
|
|
56
|
+
*/
|
|
57
|
+
archive(id) {
|
|
58
|
+
return this.client.request("DELETE", `/v1/copilot/threads/${encodeURIComponent(id)}`);
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Stop the running turn (`POST /v1/copilot/threads/:id/cancel`). Answers the
|
|
62
|
+
* turn it asked to stop; the turn's own stream ends with a `done` frame.
|
|
63
|
+
*/
|
|
64
|
+
cancel(id) {
|
|
65
|
+
return this.client.request("POST", `/v1/copilot/threads/${encodeURIComponent(id)}/cancel`);
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Send one message and iterate the turn's frames
|
|
69
|
+
* (`POST /v1/copilot/threads/:id/messages`, server-sent events).
|
|
70
|
+
*
|
|
71
|
+
* Deliberately NOT routed through `client.request`: that path arms an abort
|
|
72
|
+
* timer around the whole exchange, and a turn legitimately runs for minutes —
|
|
73
|
+
* inheriting `timeoutMs` would cut the assistant off mid-answer. The caller
|
|
74
|
+
* owns the lifetime instead: pass `signal` to end the stream, or stop
|
|
75
|
+
* iterating (the reader cancels the body, which ends the request).
|
|
76
|
+
*
|
|
77
|
+
* A frame kind this package does not model is skipped rather than thrown, so
|
|
78
|
+
* a newer server cannot break an older caller.
|
|
79
|
+
*/
|
|
80
|
+
async *stream(threadId, opts) {
|
|
81
|
+
const url = `${this.client.baseUrl}/v1/copilot/threads/${encodeURIComponent(threadId)}/messages`;
|
|
82
|
+
const token = await this.client.auth.getToken();
|
|
83
|
+
const res = await this.client.fetch(url, {
|
|
84
|
+
method: "POST",
|
|
85
|
+
headers: {
|
|
86
|
+
"Content-Type": "application/json",
|
|
87
|
+
...token ? { Authorization: `Bearer ${token}` } : {}
|
|
88
|
+
},
|
|
89
|
+
body: JSON.stringify({
|
|
90
|
+
message: opts.message,
|
|
91
|
+
...opts.baseVersion !== void 0 ? { baseVersion: opts.baseVersion } : {},
|
|
92
|
+
...opts.tier ? { tier: opts.tier } : {}
|
|
93
|
+
}),
|
|
94
|
+
signal: opts.signal
|
|
95
|
+
});
|
|
96
|
+
for await (const value of chunkKNMW722T_cjs.readSseStream(res, { label: "copilot stream" })) {
|
|
97
|
+
if (isCopilotFrame(value)) yield value;
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
exports.CopilotResource = CopilotResource;
|
|
103
|
+
//# sourceMappingURL=chunk-NLQQHJ25.cjs.map
|
|
104
|
+
//# sourceMappingURL=chunk-NLQQHJ25.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/resources/copilot.ts"],"names":["readSseStream"],"mappings":"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","file":"chunk-NLQQHJ25.cjs","sourcesContent":["import type { NodaroClientCore } from \"../core.js\"\nimport { readSseStream } from \"../sse.js\"\n\n/**\n * The assistant's conversation surface (`/v1/copilot/*`) — threads, and one\n * turn as a live stream.\n *\n * A thread is the conversation; a TURN is one message and everything the\n * assistant does in answer to it. `stream` is the only method that spends: it\n * POSTs the message and yields the turn's frames as they arrive, so a caller\n * renders prose, tool activity and proposals live instead of waiting for a\n * finished answer.\n *\n * Two shapes here are deliberately TOLERANT of a deployment that predates a\n * field, because the SDK ships ahead of every instance it talks to:\n * - `surface` is optional on both {@link CopilotThread} and the `metadata`\n * frame — absent is a value (\"this deployment does not say\"), never a\n * default this package invents.\n * - An event kind this package does not model is IGNORED, not thrown: a\n * newer server may emit frames a caller was built before.\n */\n\n/** How this thread runs what it proposes: ask first, or run within a budget. */\nexport type CopilotRunMode = \"ask\" | \"auto\"\n\n/** The thread's model rung. Absent from a server that predates it. */\nexport type CopilotModelTier = \"economy\" | \"standard\" | \"premium\"\n\n/**\n * Which product the conversation belongs to.\n *\n * NO deployment sends this today — nothing in the platform emits it yet — and\n * it is typed here so that the day one does, a caller reads what the server\n * said. That is why it is OPTIONAL everywhere it appears: absent is a value\n * (\"this deployment does not say\"), never a default this package invents.\n */\nexport type CopilotSurface = \"studio\" | \"workflow\"\n\nexport interface CopilotThread {\n id: string\n workflowId: string\n runMode: CopilotRunMode\n /** See {@link CopilotSurface} — absent means the server did not say. */\n surface?: CopilotSurface\n /** Whether this thread may build nodes that publish to connected accounts. */\n allowPublishing?: boolean\n modelTier?: CopilotModelTier\n autoRunLimitCredits: number\n userTurnCount: number\n lastMessageAt: string | null\n createdAt: string\n /** Only on {@link CopilotResource.get} — derived from a live turn. */\n status?: \"running\" | \"idle\"\n activeTurnId?: string | null\n}\n\n/** The workflow a thread was opened on, as `create` answers it. */\nexport interface CopilotThreadWorkflow {\n id: string\n projectId: string\n name: string\n version: number\n}\n\nexport type CopilotMessagePart =\n | { kind: \"text\"; text: string }\n | { kind: \"tool_call\"; id: string; name: string; label: string; status: \"finished\" | \"failed\" }\n\nexport interface CopilotMessage {\n id: string\n seq: number\n turnId: string\n role: \"user\" | \"assistant\"\n createdAt: string\n parts: CopilotMessagePart[]\n}\n\n/** Open a thread on an existing workflow, or on one this call creates. */\nexport interface CreateCopilotThreadInput {\n /** The workflow to work on. Give this OR `prompt`. */\n workflowId?: string\n /** Start from nothing: the server creates a workflow seeded by this prompt. */\n prompt?: string\n /** Name for a workflow created by `prompt` (defaults to the prompt's head). */\n name?: string\n}\n\nexport interface CopilotStreamOptions {\n /** The user's turn. */\n message: string\n /** The workflow version this message was composed against — a newer one 409s. */\n baseVersion?: number\n /** The composer's echo of the thread's rung; the thread row stays authoritative. */\n tier?: CopilotModelTier\n /**\n * Ends the stream. The client's request timeout is NOT applied to a turn.\n *\n * Aborting REJECTS the iteration — with the platform's raw `AbortError`, not\n * a `NodaroError` — whether it fires before the first frame or between two of\n * them. Wrap the loop in `try`/`catch` if a cancelled turn is an ordinary\n * ending in your UI. (`media.downloadVideoProgress` behaves the same way.)\n */\n signal?: AbortSignal\n}\n\nexport interface CopilotToolCallFrameData {\n id: string\n name: string\n label: string\n status: \"started\" | \"finished\" | \"failed\"\n summary?: string\n}\n\nexport interface CopilotWorkflowUpdateFrameData {\n workflowId: string\n version: number\n updatedAt?: string\n note?: string | null\n addedNodeIds: string[]\n updatedNodeIds: string[]\n removedNodeIds: string[]\n addedNodeTypes: string[]\n nodeCount: number\n edgeCount: number\n adjustments: string[]\n}\n\n/** A file the turn wired onto a node — named on the run card, never counted. */\nexport interface CopilotWiredAsset {\n id: string\n kind: string\n filename: string\n nodeId: string\n}\n\nexport interface CopilotRunProposalNode {\n id: string\n type: string\n graphVersion: number\n label: string\n}\n\nexport interface CopilotRunProposalFrameData {\n workflowId: string\n addedNodeTypes: string[]\n wiredAssets?: CopilotWiredAsset[]\n note: string | null\n /** Present when ONE node was proposed rather than the whole graph. */\n node?: CopilotRunProposalNode | null\n}\n\n/** A workflow the turn created — a different one from the open canvas. */\nexport interface CopilotWorkflowCreatedFrameData {\n workflowId: string\n name: string\n projectId: string\n}\n\n/** One thing the assistant saved to memory this turn. */\nexport interface CopilotMemorySavedFrameData {\n id: string\n content: string\n}\n\nexport interface CopilotMetadataFrameData {\n threadId: string\n turnId: string\n jobId: string\n model: string\n baseVersion: number | null\n runMode: CopilotRunMode\n autoRunLimitCredits: number\n allowPublishing?: boolean\n modelTier?: CopilotModelTier\n /** See {@link CopilotSurface} — absent means the server did not say. */\n surface?: CopilotSurface\n}\n\n/**\n * One frame of a turn.\n *\n * The union covers the frame KINDS; a frame's `data` is passed through\n * untouched, so a field this package does not model still reaches the caller\n * rather than being stripped on the way.\n */\nexport type CopilotStreamFrame =\n | { type: \"metadata\"; data: CopilotMetadataFrameData }\n | { type: \"token\"; data: { text: string } }\n | { type: \"tool_call\"; data: CopilotToolCallFrameData }\n | { type: \"workflow_updated\"; data: CopilotWorkflowUpdateFrameData }\n | { type: \"workflow_created\"; data: CopilotWorkflowCreatedFrameData }\n | { type: \"run_proposed\"; data: CopilotRunProposalFrameData }\n | { type: \"memory_saved\"; data: CopilotMemorySavedFrameData }\n | { type: \"usage\"; data: { inputTokens: number; outputTokens: number; cacheReadTokens: number; creditsCharged: number | null } }\n | { type: \"done\"; data: { turnId: string; messageId: string | null; status: \"completed\" | \"capped\" | \"cancelled\"; finalVersion: number | null } }\n | { type: \"error\"; data: { code: string; message: string } }\n\n/** The kinds above, as the wire spells them — the whole of what `stream` yields. */\nconst COPILOT_FRAME_TYPES: ReadonlySet<string> = new Set([\n \"metadata\",\n \"token\",\n \"tool_call\",\n \"workflow_updated\",\n \"workflow_created\",\n \"run_proposed\",\n \"memory_saved\",\n \"usage\",\n \"done\",\n \"error\",\n])\n\nfunction isCopilotFrame(value: unknown): value is CopilotStreamFrame {\n if (typeof value !== \"object\" || value === null) return false\n const type = (value as { type?: unknown }).type\n return typeof type === \"string\" && COPILOT_FRAME_TYPES.has(type)\n}\n\nexport class CopilotResource {\n constructor(private client: NodaroClientCore) {}\n\n /**\n * Open a conversation (`POST /v1/copilot/threads`) — on `workflowId`, or on\n * a workflow the server creates from `prompt`. Re-opening a workflow that\n * already has an active thread answers THAT thread rather than a second one.\n */\n create(input: CreateCopilotThreadInput): Promise<{ data: { thread: CopilotThread; workflow: CopilotThreadWorkflow } }> {\n return this.client.request(\"POST\", \"/v1/copilot/threads\", { body: input })\n }\n\n /**\n * The active thread for a workflow (`GET /v1/copilot/threads?workflowId=…`),\n * or `null` when the user has none open on it.\n */\n list(params: { workflowId: string }): Promise<{ data: { thread: CopilotThread | null } }> {\n return this.client.request(\"GET\", \"/v1/copilot/threads\", { query: { workflowId: params.workflowId } })\n }\n\n /**\n * One thread with its messages (`GET /v1/copilot/threads/:id`). `after` reads\n * only what followed that sequence number (the panel's catch-up); `limit`\n * caps the page at the server's own ceiling.\n */\n get(\n id: string,\n opts: { after?: number; limit?: number } = {},\n ): Promise<{ data: { thread: CopilotThread; messages: CopilotMessage[] } }> {\n return this.client.request(\"GET\", `/v1/copilot/threads/${encodeURIComponent(id)}`, {\n query: { ...(opts.after !== undefined ? { after: opts.after } : {}), ...(opts.limit !== undefined ? { limit: opts.limit } : {}) },\n })\n }\n\n /**\n * Close a conversation (`DELETE /v1/copilot/threads/:id`). Archival, not\n * deletion — the messages stay readable. Refused while a turn is running.\n */\n archive(id: string): Promise<{ data: { archived: true } }> {\n return this.client.request(\"DELETE\", `/v1/copilot/threads/${encodeURIComponent(id)}`)\n }\n\n /**\n * Stop the running turn (`POST /v1/copilot/threads/:id/cancel`). Answers the\n * turn it asked to stop; the turn's own stream ends with a `done` frame.\n */\n cancel(id: string): Promise<{ data: { cancelling: true; turnId: string } }> {\n return this.client.request(\"POST\", `/v1/copilot/threads/${encodeURIComponent(id)}/cancel`)\n }\n\n /**\n * Send one message and iterate the turn's frames\n * (`POST /v1/copilot/threads/:id/messages`, server-sent events).\n *\n * Deliberately NOT routed through `client.request`: that path arms an abort\n * timer around the whole exchange, and a turn legitimately runs for minutes —\n * inheriting `timeoutMs` would cut the assistant off mid-answer. The caller\n * owns the lifetime instead: pass `signal` to end the stream, or stop\n * iterating (the reader cancels the body, which ends the request).\n *\n * A frame kind this package does not model is skipped rather than thrown, so\n * a newer server cannot break an older caller.\n */\n async *stream(threadId: string, opts: CopilotStreamOptions): AsyncGenerator<CopilotStreamFrame, void, undefined> {\n const url = `${this.client.baseUrl}/v1/copilot/threads/${encodeURIComponent(threadId)}/messages`\n const token = await this.client.auth.getToken()\n const res = await this.client.fetch(url, {\n method: \"POST\",\n headers: {\n \"Content-Type\": \"application/json\",\n ...(token ? { Authorization: `Bearer ${token}` } : {}),\n },\n body: JSON.stringify({\n message: opts.message,\n ...(opts.baseVersion !== undefined ? { baseVersion: opts.baseVersion } : {}),\n ...(opts.tier ? { tier: opts.tier } : {}),\n }),\n signal: opts.signal,\n })\n for await (const value of readSseStream<unknown>(res, { label: \"copilot stream\" })) {\n if (isCopilotFrame(value)) yield value\n }\n }\n}\n"]}
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
import { SCENE3D_V2_LIMITS } from '@nodaro/shared/scene3d';
|
|
2
|
+
|
|
3
|
+
// src/resources/scene3d-types.ts
|
|
4
|
+
var SCENE3D_DELIVERY_ASSET_USAGE = {
|
|
5
|
+
poster: "poster",
|
|
6
|
+
"validation-report": "validation",
|
|
7
|
+
"shot-still": "shot-still",
|
|
8
|
+
/** The recipe a run that never compiled was refused for. See {@link Scene3DDeliveryAsset}. */
|
|
9
|
+
"source-json": "checkpoint"
|
|
10
|
+
};
|
|
11
|
+
function newIdempotencyKey() {
|
|
12
|
+
const random = globalThis.crypto?.randomUUID?.();
|
|
13
|
+
return `sdk-pro3d-${random ?? `${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 12)}`}`;
|
|
14
|
+
}
|
|
15
|
+
var Scene3DResource = class {
|
|
16
|
+
/** Every operation runs a platform node, so the client must carry `nodes` too. */
|
|
17
|
+
constructor(client) {
|
|
18
|
+
this.client = client;
|
|
19
|
+
}
|
|
20
|
+
client;
|
|
21
|
+
capabilities() {
|
|
22
|
+
return this.client.request("GET", "/v1/3d-scene/capabilities");
|
|
23
|
+
}
|
|
24
|
+
/** Current access to both the delivery and its source is required on every read. */
|
|
25
|
+
getDelivery(jobId) {
|
|
26
|
+
return this.client.request("GET", `/v1/3d-scene/deliveries/${encodeURIComponent(jobId)}`);
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* The bytes of one descriptor the delivery listed.
|
|
30
|
+
*
|
|
31
|
+
* Checked against {@link SCENE3D_DELIVERY_ASSET_USAGE} rather than a hardcoded pair, which
|
|
32
|
+
* is why a `shot-still` now works: the route has served stills since they existed, and this
|
|
33
|
+
* guard refused them. `source-json` — the recipe a refused run was kept for — is on the same
|
|
34
|
+
* map; the server still decides whether THIS caller may read it.
|
|
35
|
+
*/
|
|
36
|
+
deliveryAssetBytes(jobId, asset, options) {
|
|
37
|
+
if (SCENE3D_DELIVERY_ASSET_USAGE[asset.kind] !== asset.usage) {
|
|
38
|
+
throw new Error("This asset is not available through the delivery endpoint");
|
|
39
|
+
}
|
|
40
|
+
if (!Number.isSafeInteger(asset.byteLength) || asset.byteLength < 1 || asset.byteLength > SCENE3D_V2_LIMITS.maxRendererAssetBytes) {
|
|
41
|
+
throw new Error("Invalid scene delivery asset byte length");
|
|
42
|
+
}
|
|
43
|
+
return this.client.requestBytes("GET", `/v1/3d-scene/deliveries/${encodeURIComponent(jobId)}/assets/${encodeURIComponent(asset.assetId)}`, {
|
|
44
|
+
signal: options?.signal,
|
|
45
|
+
maxBytes: asset.byteLength
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* The recipe a 3D Render Pro run was refused for, parsed — or `null` when there is none.
|
|
50
|
+
*
|
|
51
|
+
* The one thing such a run leaves behind. Its recipe never compiled, so there is no scene
|
|
52
|
+
* revision, no poster and no `.blend`: `output_data` carries a `deliveryId`, the compiler's
|
|
53
|
+
* reasons, and `validation.sourceRetained` saying whether the recipe itself was kept. This
|
|
54
|
+
* fetches it in one call — delivery, then the `source-json` descriptor's bytes.
|
|
55
|
+
*
|
|
56
|
+
* `null` means the delivery has no retained recipe to hand back: no pass ever cleared
|
|
57
|
+
* admission, or this caller holds less than `edit` on the job's workflow and the descriptor
|
|
58
|
+
* is therefore not listed for them.
|
|
59
|
+
*
|
|
60
|
+
* Read it to see what was attempted and to inform the next prompt. There is no input that
|
|
61
|
+
* takes a recipe back: a refused run published no revision, so there is no `{kind:"scene"}`
|
|
62
|
+
* source to re-run it from.
|
|
63
|
+
*/
|
|
64
|
+
async retainedRecipe(jobId, options) {
|
|
65
|
+
const delivery = await this.getDelivery(jobId);
|
|
66
|
+
const asset = delivery.assets.find((item) => item.kind === "source-json");
|
|
67
|
+
if (!asset) return null;
|
|
68
|
+
const bytes = await this.deliveryAssetBytes(jobId, asset, options);
|
|
69
|
+
return JSON.parse(new TextDecoder("utf-8", { fatal: true }).decode(bytes));
|
|
70
|
+
}
|
|
71
|
+
/** Persist deterministic overlays without an LLM or a generation charge. */
|
|
72
|
+
applyEdits(revisionId, params) {
|
|
73
|
+
return this.client.request("POST", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/edits`, { body: params });
|
|
74
|
+
}
|
|
75
|
+
/** Asset access is scoped to an exact retained revision, with fresh authentication. */
|
|
76
|
+
assetBytes(revisionId, asset, options) {
|
|
77
|
+
if (!["glb", "camera-track-json", "poster", "validation-report"].includes(asset.kind)) {
|
|
78
|
+
throw new Error("This asset is not available through the playback endpoint");
|
|
79
|
+
}
|
|
80
|
+
if (!Number.isSafeInteger(asset.byteLength) || asset.byteLength < 1 || asset.byteLength > SCENE3D_V2_LIMITS.maxRendererAssetBytes) {
|
|
81
|
+
throw new Error("Invalid scene asset byte length");
|
|
82
|
+
}
|
|
83
|
+
return this.client.requestBytes("GET", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/assets/${encodeURIComponent(asset.assetId)}`, {
|
|
84
|
+
signal: options?.signal,
|
|
85
|
+
maxBytes: asset.byteLength
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
/** The editable native file has its own authorization lane. */
|
|
89
|
+
sourceBytes(revisionId, options) {
|
|
90
|
+
return this.client.requestBytes("GET", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/source`, {
|
|
91
|
+
signal: options?.signal,
|
|
92
|
+
maxBytes: SCENE3D_V2_LIMITS.maxBlendSourceBytes
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
generate(params) {
|
|
96
|
+
return this.client.nodes.run("generate-3d-scene", params);
|
|
97
|
+
}
|
|
98
|
+
generateAndWait(params, options) {
|
|
99
|
+
return this.client.nodes.runAndWait("generate-3d-scene", params, options);
|
|
100
|
+
}
|
|
101
|
+
edit(params) {
|
|
102
|
+
return this.client.nodes.run("edit-3d-scene", params);
|
|
103
|
+
}
|
|
104
|
+
editAndWait(params, options) {
|
|
105
|
+
return this.client.nodes.runAndWait("edit-3d-scene", params, options);
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Price a 3D Render Pro request WITHOUT starting it.
|
|
109
|
+
*
|
|
110
|
+
* Takes the same body a run takes, minus the `quoteId`, and answers a
|
|
111
|
+
* ceiling (`maxCredits`), a `breakdown` to show, and the
|
|
112
|
+
* `normalizedInputHash` admission re-checks. It reserves nothing and spends
|
|
113
|
+
* nothing — a quote is a price, not a purchase.
|
|
114
|
+
*/
|
|
115
|
+
quotePro(params) {
|
|
116
|
+
return this.client.request("POST", "/v1/pro-3d-render/quote", { body: params });
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Submit a quoted 3D Render Pro run.
|
|
120
|
+
*
|
|
121
|
+
* Requires the `quoteId` from {@link quotePro}: no run starts at a price
|
|
122
|
+
* nobody showed. Sends an `Idempotency-Key` — a fresh one per call unless you
|
|
123
|
+
* supply your own, which you should when retrying a call that timed out.
|
|
124
|
+
*
|
|
125
|
+
* Availability is a property of the deployment: `capabilities().pro` says
|
|
126
|
+
* whether this install can serve it, and which controls you may offer.
|
|
127
|
+
*/
|
|
128
|
+
runPro(params, options) {
|
|
129
|
+
return this.client.nodes.run("pro-3d-render", params, {
|
|
130
|
+
idempotencyKey: options?.idempotencyKey ?? newIdempotencyKey()
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Quote if needed, run, and wait — the whole operation in one call.
|
|
135
|
+
*
|
|
136
|
+
* Two HTTP requests at most, still ONE paid job: when `quoteId` is absent
|
|
137
|
+
* this quotes the identical body first, so the run is admitted against a
|
|
138
|
+
* hash of exactly what was priced. Pass a `quoteId` to run against a quote
|
|
139
|
+
* you already showed the user.
|
|
140
|
+
*
|
|
141
|
+
* Resolves with the settled result — `videoUrl` (the MP4) and `scenePlan`
|
|
142
|
+
* (the exact composition it was rendered from), plus the revision, poster,
|
|
143
|
+
* validation and renderer metadata. A run that AUTHORED also reports its own
|
|
144
|
+
* account of the answer — `metadata.summary`, `repairPasses`,
|
|
145
|
+
* `admissionRetries`, `mechanicalPasses` (repairs the engine applied from
|
|
146
|
+
* the compiler's own remedy with no planner call, counted APART from
|
|
147
|
+
* `repairPasses` on their own quoted allowance), `restoredAssertions`, and
|
|
148
|
+
* any `SCENE_AUTHORING_ASSUMPTION` warnings. A
|
|
149
|
+
* completed result whose `metadata.review` is present passed every mandatory
|
|
150
|
+
* assertion but did NOT get the visual reviewer's approval: `verdict:
|
|
151
|
+
* "refused"` means it objected, each objection also a `SCENE_REVIEW_REFUSED`
|
|
152
|
+
* warning; `verdict: "unavailable"` means the review produced no usable
|
|
153
|
+
* verdict in `attempts` asks (`reason: "provider"` — never reached its
|
|
154
|
+
* provider; `"unusable"` — it answered, unusably), so nobody judged the scene and
|
|
155
|
+
* `SCENE_REVIEW_UNAVAILABLE` leads the warnings. Re-render that same
|
|
156
|
+
* `scenePlan` later with {@link render}, or with a `{kind:'scene'}` source;
|
|
157
|
+
* that costs no authoring.
|
|
158
|
+
*/
|
|
159
|
+
async renderProAndWait(params, options) {
|
|
160
|
+
const quoteId = typeof params.quoteId === "string" ? params.quoteId : (await this.quotePro(params)).quoteId;
|
|
161
|
+
return this.client.nodes.runAndWait("pro-3d-render", { ...params, quoteId }, {
|
|
162
|
+
...options,
|
|
163
|
+
idempotencyKey: options?.idempotencyKey ?? newIdempotencyKey()
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* Uses the supplied immutable revision; never starts authoring or a rebuild.
|
|
168
|
+
*
|
|
169
|
+
* Priced by the plan's frame size — see {@link RenderScene3DParams}.
|
|
170
|
+
*/
|
|
171
|
+
render(params) {
|
|
172
|
+
return this.client.nodes.run("render-video", params);
|
|
173
|
+
}
|
|
174
|
+
renderAndWait(params, options) {
|
|
175
|
+
return this.client.nodes.runAndWait("render-video", params, options);
|
|
176
|
+
}
|
|
177
|
+
};
|
|
178
|
+
|
|
179
|
+
export { SCENE3D_DELIVERY_ASSET_USAGE, Scene3DResource };
|
|
180
|
+
//# sourceMappingURL=chunk-NNHWH7ER.js.map
|
|
181
|
+
//# sourceMappingURL=chunk-NNHWH7ER.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/resources/scene3d-types.ts","../src/resources/scene3d.ts"],"names":[],"mappings":"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","file":"chunk-NNHWH7ER.js","sourcesContent":["import type { Scene3DPlan, Scene3DPlanV2, Scene3DReference, Scene3DEditOperation, Scene3DV2EditOperation, Scene3DJobOutputAny as Scene3DWireJobOutput, Pro3DRenderCapabilities, Pro3DRenderEngine, Pro3DRenderJobOutput as Pro3DRenderWireOutput, Pro3DRenderQuality, Pro3DRenderQuote as Pro3DRenderWireQuote, Pro3DRenderSource, Pro3DRenderStyle } from \"@nodaro/shared/scene3d\"\nimport type { GenerationSessionParams } from \"./nodes.js\"\n\n/** Reuse newRevisionId for transport retries of the same immutable edit. */\nexport interface RetainedScene3DEditParams {\n newRevisionId: string\n expectedContentHash: string\n operations: readonly Scene3DV2EditOperation[]\n lockedObjectIds?: readonly string[]\n}\nexport interface RetainedScene3DEditResult { scenePlan: Scene3DPlanV2; changeSummary: string }\n\n/**\n * The kind of bytes a delivery descriptor names, and the usage it is pinned under.\n *\n * PAIRED, not two free enums: the platform refuses a pin whose usage is not the one its kind is\n * defined to have, and a client that checks only one of the two would accept a mis-pinned\n * artifact the server would then refuse. {@link SCENE3D_DELIVERY_ASSET_USAGE} is the map both\n * halves are read from.\n */\nexport const SCENE3D_DELIVERY_ASSET_USAGE = {\n poster: \"poster\",\n \"validation-report\": \"validation\",\n \"shot-still\": \"shot-still\",\n /** The recipe a run that never compiled was refused for. See {@link Scene3DDeliveryAsset}. */\n \"source-json\": \"checkpoint\",\n} as const\n\nexport type Scene3DDeliveryAssetKind = keyof typeof SCENE3D_DELIVERY_ASSET_USAGE\n\n/**\n * One artifact a delivery pins, as a descriptor: opaque ids and digests only.\n *\n * Four kinds, and two of them are conditional:\n *\n * - `poster` and `validation-report` are on every delivery;\n * - `shot-still` appears once per shot on a render that produced a contact sheet, and carries\n * its own shot identity (`shotIndex`, `frame`, and the frame size);\n * - `source-json` appears on ONE shape only — a `refused-authoring` delivery, published by a\n * 3D Render Pro run whose recipe the compiler refused on every pass. It is the planner's last\n * admitted recipe, and it is the only thing such a run leaves that names what was attempted.\n * Reading it needs `edit` on the job's workflow (the same access the `.blend` export costs);\n * a reader with less simply does not see the descriptor.\n */\nexport interface Scene3DDeliveryAsset {\n assetId: string\n kind: Scene3DDeliveryAssetKind\n usage: (typeof SCENE3D_DELIVERY_ASSET_USAGE)[Scene3DDeliveryAssetKind]\n byteLength: number\n sha256: string\n viaRevisionId: string | null\n /** Set on a `shot-still` and absent on every other kind — never `null`. */\n shotIndex?: number\n frame?: number\n width?: number\n height?: number\n}\n\n/** Export evidence is retained separately from the immutable scene it rendered. */\nexport interface Scene3DDelivery {\n deliveryId: string\n /**\n * Null on a `refused-authoring` delivery and on that alone.\n *\n * A Pro run whose recipe the compiler refused on every pass still retains the refusal\n * report, but nothing was ever compiled, so no scene revision was published. The field is\n * null rather than absent so the shape stays one shape; read `sourceKind` to tell why.\n */\n sceneRevisionId: string | null\n /**\n * What this delivery was made from. Absent when read from a deployment that predates the\n * refused lane, where every delivery necessarily had a scene behind it.\n */\n sourceKind?: \"retained-revision\" | \"job-output\" | \"refused-authoring\"\n /** Null when there is no plan to hash — see `sceneRevisionId`. */\n sourcePlanSha256: string | null\n sourceContentHash: string | null\n sourceJobId: string | null\n workflowId: string | null\n mode: \"authored\" | \"render-only\"\n createdAt: string\n access: \"view\" | \"edit\" | \"own\"\n assets: Scene3DDeliveryAsset[]\n}\n\nexport type Scene3DAuthoringEngine = \"basic\" | \"blender-cloud\" | \"blender-local\"\n\nexport interface Scene3DCapabilities {\n basic: { available: boolean; sceneSchemaVersions: number[] }\n advanced: null | {\n version: string\n engines: Array<Exclude<Scene3DAuthoringEngine, \"basic\">>\n sceneSchemaVersions: number[]\n maxRepairPasses: number\n }\n /**\n * What this deployment can serve for `pro-3d-render`, including which\n * quality profiles, engines and aspect ratios a client may OFFER. Optional so\n * a client of this version reads an older backend without throwing; absent\n * means the node is unavailable.\n */\n pro?: Pro3DRenderCapabilities\n}\n\ninterface Scene3DEngineParams {\n /** Basic is the default. Discover optional engines through scene3d.capabilities(). */\n engine?: Scene3DAuthoringEngine\n acceptedSceneSchemaVersions?: readonly number[]\n localConnectionId?: string\n quoteId?: string\n maxRepairPasses?: number\n}\n\n/** Structured authoring inputs; reference roles are interpreted by the platform. */\nexport interface GenerateScene3DParams extends Record<string, unknown>, Scene3DEngineParams, GenerationSessionParams {\n /** Existing GLBs selected by immutable revision/artifact IDs. Requires an import-capable advanced engine. */\n inputAssets?: readonly import(\"@nodaro/shared/scene3d\").Scene3DInputAsset[]\n prompt: string\n durationSeconds?: number\n fps?: number\n aspectRatio?: string\n references?: readonly Scene3DReference[]\n llmModel?: string\n reasoningEffort?: string\n workflowId?: string\n nodeId?: string\n}\n\n/** Editing creates a new revision and never mutates the supplied scene. */\nexport interface EditScene3DParams extends Record<string, unknown>, Scene3DEngineParams, GenerationSessionParams {\n scenePlan: Scene3DPlan\n expectedRevisionId: string\n /** Replace the complete reference set, including clearing it with an empty list. Default: merge by id. */\n replaceReferences?: boolean\n /** Supply an instruction or deterministic operations, never both. */\n prompt?: string\n operations?: readonly (Scene3DEditOperation | Scene3DV2EditOperation)[]\n references?: readonly Scene3DReference[]\n lockedObjectIds?: readonly string[]\n selectedObjectIds?: readonly string[]\n llmModel?: string\n reasoningEffort?: string\n workflowId?: string\n nodeId?: string\n}\n\n/**\n * 3D Render Pro — ONE durable operation producing a composition and its MP4.\n *\n * `source` is a strict discriminated union, not a bag of optionals:\n * - `{kind:'prompt', prompt, references?}` authors a new scene;\n * - `{kind:'scene', revisionId, sourceJobId}` with NO `editPrompt` is the\n * render-only export — it spends no authoring or build credits, and OMIT\n * the field rather than sending `\"\"`, which would buy an authoring pass;\n * - `{kind:'local-export', exportId, connectionId}` uses a paired desktop.\n *\n * There is no model or effort field: the planner is fixed and server-owned.\n *\n * `durationSeconds` / `fps` / `aspectRatio` on a `scene` source are an EXPLICIT\n * re-time request. Omit them to keep the source's own timing; a conflicting\n * override is rejected rather than silently applied.\n */\nexport interface Pro3DRenderParams extends Record<string, unknown> {\n source: Pro3DRenderSource\n /** Optional. An unknown or unavailable engine is rejected, never downgraded. */\n engine?: Pro3DRenderEngine\n /** Names a paired desktop for a local run. */\n localConnectionId?: string\n durationSeconds?: number\n fps?: number\n aspectRatio?: string\n quality?: Pro3DRenderQuality\n style?: Pro3DRenderStyle\n /** Correction budget, 0-2. Each pass is paid work. */\n maxRepairPasses?: number\n /**\n * Which scene-schema versions THIS client can render. A prompt or\n * local-export source mints v2, so omitting 2 is refused for free; a scene\n * source inherits its revision's version and is left to the server.\n */\n acceptedSceneSchemaVersions?: readonly number[]\n workflowId?: string\n nodeId?: string\n /** Keep every artifact of this run out of publicly-readable storage. */\n forcePrivate?: boolean\n}\n\n/** A run additionally carries the quote it was priced under. */\nexport interface Pro3DRenderRunParams extends Pro3DRenderParams {\n quoteId: string\n}\n\n/** The quote's answer. `maxCredits` is a ceiling; quoting spends nothing. */\nexport type Pro3DRenderQuote = Readonly<Pro3DRenderWireQuote> & Readonly<Record<string, unknown>>\n\n/** Per-call transport controls for the paid run. */\nexport interface Pro3DRenderRunOptions {\n /**\n * The `Idempotency-Key` the run is submitted under. Reuse the same value when\n * retrying a call that timed out, so the run is not started twice; the SDK\n * generates a fresh one per call when this is omitted, because two deliberate\n * calls are two runs.\n */\n idempotencyKey?: string\n}\n\n/**\n * Render the exact scene revision through the existing render-video node.\n *\n * The price follows the plan's OWN `width`/`height`, not any node setting: a\n * frame up to 1920 px on its longest side settles under `render-video`, a\n * larger one under `render-video:3d-large` (1.5x) or, above 5.12 megapixels,\n * `render-video:3d-xlarge` (2.5x). Read the current numbers from the\n * model-cost API for those three identifiers.\n */\nexport interface RenderScene3DParams extends Record<string, unknown>, GenerationSessionParams {\n planType: \"3d-scene\"\n plan: Scene3DPlan\n workflowId?: string\n nodeId?: string\n}\n\n/**\n * Preserve the shared wire contract while allowing additive job metadata.\n *\n * A scene authored by an ADVANCED engine additionally reports what the run knows about its own\n * answer, every field optional and all of them absent on the deterministic Basic lane:\n * `validation.warnings[]` entries coded `SCENE_AUTHORING_ASSUMPTION` (the planner's\n * assumptions), `metadata.summary` (its description of what it authored), `repairPasses`\n * (repairs actually run — `0` when the scene was accepted first time), `admissionRetries`\n * (pre-build planner retries, which spend no repair pass), `mechanicalPasses` (repairs the engine\n * applied from the compiler's own remedy with no planner call, counted APART from `repairPasses`\n * on their own quoted allowance, each with a `REMEDY_AUTO_APPLIED` warning) and\n * `restoredAssertions` (mandatory assertions put back after a planner answer re-shaped one the\n * feedback had not named, each a `ASSERTION_RESTORED` warning).\n *\n * A scene that passed every mandatory assertion but did not get the visual reviewer's approval\n * is delivered anyway, and `metadata.review` carries a verdict saying why. `verdict: \"refused\"`\n * is the ADVISORY delivery — the reviewer objected once the repair budget was spent — with one\n * `SCENE_REVIEW_REFUSED` warning per objection. `verdict: \"unavailable\"` is the UNREVIEWED\n * delivery: the review produced no usable verdict after `attempts` asks — `reason: \"provider\"`\n * when it never reached its provider, `\"unusable\"` when the provider answered with nothing usable\n * (`Scene3DReviewUnavailableReason` in `@nodaro/shared`) — so nobody judged the scene, and\n * `validation.warnings[]` LEADS with `SCENE_REVIEW_UNAVAILABLE` (any objections under it came from\n * review batches that answered usably first, and are not the whole verdict).\n *\n * `validation.status` stays `\"passed\"` on both, so `metadata.review` being present is the only\n * reliable test — use `scene3DReviewVerdictOf` from `@nodaro/shared` rather than reading it by\n * hand, and `scene3DReviewNote` rather than writing the sentence yourself: a message that says\n * the reviewer refused a scene nobody reviewed invents an opinion.\n */\nexport type Scene3DJobOutput = Readonly<Scene3DWireJobOutput> & Readonly<Record<string, unknown>>\n\n/**\n * The settled 3D Render Pro result, plus any additive job metadata.\n *\n * On a run that AUTHORED, the result reports the run's own account of its answer:\n * `validation.warnings[]` entries coded `SCENE_AUTHORING_ASSUMPTION`, `metadata.summary`,\n * `repairPasses` (`0` when accepted first time), `admissionRetries` (pre-build planner retries,\n * which spend no repair pass), `mechanicalPasses` (repairs the engine authored itself from the\n * compiler's own remedy, counted APART from `repairPasses` because they buy their own quoted\n * allowance rather than spending one of your repairs) and `restoredAssertions`. A render-only\n * export authored nothing, so it carries no summary and omits the counts rather than claiming `0`.\n *\n * The one case where `mechanicalPasses` IS a subset of `repairPasses` is a run quoted before that\n * allowance existed — its quote carries no `mechanical` line. The discriminant is the quote, not\n * the result, so read the quote you were given rather than deriving it from the two counts.\n *\n * A completed result may also be published without the visual reviewer's approval, and then\n * `metadata.review` holds a verdict saying which way. `{ verdict: \"refused\", objections[],\n * observed? }` is the ADVISORY delivery: every mandatory assertion passed, the reviewer still\n * objected, and the scene was published once the repair budget was spent, with one\n * `SCENE_REVIEW_REFUSED` warning per objection. `{ verdict: \"unavailable\", reason, attempts,\n * objections[], observed? }` is the UNREVIEWED delivery: the review produced no usable verdict in\n * `attempts` asks — `reason: \"provider\"` when it never reached its provider, `\"unusable\"` when the\n * provider answered with nothing usable — so the assertion-passing scene was delivered with no\n * verdict on it and `validation.warnings[]` LEADS with `SCENE_REVIEW_UNAVAILABLE`. Objections on\n * that arm are whatever review batches answered usably first — real, but not the whole verdict.\n *\n * `validation.status` is `\"passed\"` on both, so test for `metadata.review` — via\n * `scene3DReviewVerdictOf` from `@nodaro/shared` — rather than for the status or the warnings,\n * and render it with `scene3DReviewNote` rather than assuming a refusal.\n */\nexport type Pro3DRenderJobOutput = Readonly<Pro3DRenderWireOutput> & Readonly<Record<string, unknown>>\n","import { SCENE3D_V2_LIMITS, type Scene3DAssetRef } from \"@nodaro/shared/scene3d\"\nimport type { NodaroClientCore } from \"../core.js\"\nimport type { RunNodeResult, RunAndWaitOptions, NodeJobOutput, NodesResource } from \"./nodes.js\"\nimport type { EditScene3DParams, GenerateScene3DParams, Pro3DRenderJobOutput, Pro3DRenderParams, Pro3DRenderQuote, Pro3DRenderRunOptions, Pro3DRenderRunParams, RenderScene3DParams, Scene3DCapabilities, Scene3DJobOutput } from \"./scene3d-types.js\"\nimport type { RetainedScene3DEditParams, RetainedScene3DEditResult } from \"./scene3d-types.js\"\nimport { SCENE3D_DELIVERY_ASSET_USAGE } from \"./scene3d-types.js\"\nimport type { Scene3DDelivery, Scene3DDeliveryAsset } from \"./scene3d-types.js\"\n\n/**\n * A fresh per-call retry token.\n *\n * Random rather than derived from the request: two deliberate calls with the\n * same parameters are two runs, and collapsing them would silently swallow the\n * second. A caller who wants retry safety passes its own key.\n */\nfunction newIdempotencyKey(): string {\n const random = globalThis.crypto?.randomUUID?.()\n return `sdk-pro3d-${random ?? `${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 12)}`}`\n}\n\n/** Scene authoring and render-only export through the same platform nodes. */\nexport class Scene3DResource {\n /** Every operation runs a platform node, so the client must carry `nodes` too. */\n constructor(private client: NodaroClientCore & { readonly nodes: NodesResource }) {}\n\n capabilities(): Promise<Scene3DCapabilities> {\n return this.client.request(\"GET\", \"/v1/3d-scene/capabilities\")\n }\n\n /** Current access to both the delivery and its source is required on every read. */\n getDelivery(jobId: string): Promise<Scene3DDelivery> {\n return this.client.request(\"GET\", `/v1/3d-scene/deliveries/${encodeURIComponent(jobId)}`)\n }\n\n /**\n * The bytes of one descriptor the delivery listed.\n *\n * Checked against {@link SCENE3D_DELIVERY_ASSET_USAGE} rather than a hardcoded pair, which\n * is why a `shot-still` now works: the route has served stills since they existed, and this\n * guard refused them. `source-json` — the recipe a refused run was kept for — is on the same\n * map; the server still decides whether THIS caller may read it.\n */\n deliveryAssetBytes(jobId: string, asset: Scene3DDeliveryAsset, options?: { signal?: AbortSignal }): Promise<ArrayBuffer> {\n if (SCENE3D_DELIVERY_ASSET_USAGE[asset.kind] !== asset.usage) {\n throw new Error(\"This asset is not available through the delivery endpoint\")\n }\n if (!Number.isSafeInteger(asset.byteLength) || asset.byteLength < 1 || asset.byteLength > SCENE3D_V2_LIMITS.maxRendererAssetBytes) {\n throw new Error(\"Invalid scene delivery asset byte length\")\n }\n return this.client.requestBytes(\"GET\", `/v1/3d-scene/deliveries/${encodeURIComponent(jobId)}/assets/${encodeURIComponent(asset.assetId)}`, {\n signal: options?.signal, maxBytes: asset.byteLength,\n })\n }\n\n /**\n * The recipe a 3D Render Pro run was refused for, parsed — or `null` when there is none.\n *\n * The one thing such a run leaves behind. Its recipe never compiled, so there is no scene\n * revision, no poster and no `.blend`: `output_data` carries a `deliveryId`, the compiler's\n * reasons, and `validation.sourceRetained` saying whether the recipe itself was kept. This\n * fetches it in one call — delivery, then the `source-json` descriptor's bytes.\n *\n * `null` means the delivery has no retained recipe to hand back: no pass ever cleared\n * admission, or this caller holds less than `edit` on the job's workflow and the descriptor\n * is therefore not listed for them.\n *\n * Read it to see what was attempted and to inform the next prompt. There is no input that\n * takes a recipe back: a refused run published no revision, so there is no `{kind:\"scene\"}`\n * source to re-run it from.\n */\n async retainedRecipe(jobId: string, options?: { signal?: AbortSignal }): Promise<unknown | null> {\n const delivery = await this.getDelivery(jobId)\n const asset = delivery.assets.find((item) => item.kind === \"source-json\")\n if (!asset) return null\n const bytes = await this.deliveryAssetBytes(jobId, asset, options)\n return JSON.parse(new TextDecoder(\"utf-8\", { fatal: true }).decode(bytes)) as unknown\n }\n\n /** Persist deterministic overlays without an LLM or a generation charge. */\n applyEdits(revisionId: string, params: RetainedScene3DEditParams): Promise<RetainedScene3DEditResult> {\n return this.client.request(\"POST\", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/edits`, { body: params })\n }\n\n /** Asset access is scoped to an exact retained revision, with fresh authentication. */\n assetBytes(revisionId: string, asset: Scene3DAssetRef, options?: { signal?: AbortSignal }): Promise<ArrayBuffer> {\n if (![\"glb\", \"camera-track-json\", \"poster\", \"validation-report\"].includes(asset.kind)) {\n throw new Error(\"This asset is not available through the playback endpoint\")\n }\n if (!Number.isSafeInteger(asset.byteLength) || asset.byteLength < 1 || asset.byteLength > SCENE3D_V2_LIMITS.maxRendererAssetBytes) {\n throw new Error(\"Invalid scene asset byte length\")\n }\n return this.client.requestBytes(\"GET\", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/assets/${encodeURIComponent(asset.assetId)}`, {\n signal: options?.signal, maxBytes: asset.byteLength,\n })\n }\n\n /** The editable native file has its own authorization lane. */\n sourceBytes(revisionId: string, options?: { signal?: AbortSignal }): Promise<ArrayBuffer> {\n return this.client.requestBytes(\"GET\", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/source`, {\n signal: options?.signal, maxBytes: SCENE3D_V2_LIMITS.maxBlendSourceBytes,\n })\n }\n\n generate(params: GenerateScene3DParams): Promise<RunNodeResult> {\n return this.client.nodes.run(\"generate-3d-scene\", params)\n }\n\n generateAndWait(params: GenerateScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput> {\n return this.client.nodes.runAndWait(\"generate-3d-scene\", params, options)\n }\n\n edit(params: EditScene3DParams): Promise<RunNodeResult> {\n return this.client.nodes.run(\"edit-3d-scene\", params)\n }\n\n editAndWait(params: EditScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput> {\n return this.client.nodes.runAndWait(\"edit-3d-scene\", params, options)\n }\n\n /**\n * Price a 3D Render Pro request WITHOUT starting it.\n *\n * Takes the same body a run takes, minus the `quoteId`, and answers a\n * ceiling (`maxCredits`), a `breakdown` to show, and the\n * `normalizedInputHash` admission re-checks. It reserves nothing and spends\n * nothing — a quote is a price, not a purchase.\n */\n quotePro(params: Pro3DRenderParams): Promise<Pro3DRenderQuote> {\n return this.client.request(\"POST\", \"/v1/pro-3d-render/quote\", { body: params })\n }\n\n /**\n * Submit a quoted 3D Render Pro run.\n *\n * Requires the `quoteId` from {@link quotePro}: no run starts at a price\n * nobody showed. Sends an `Idempotency-Key` — a fresh one per call unless you\n * supply your own, which you should when retrying a call that timed out.\n *\n * Availability is a property of the deployment: `capabilities().pro` says\n * whether this install can serve it, and which controls you may offer.\n */\n runPro(params: Pro3DRenderRunParams, options?: Pro3DRenderRunOptions): Promise<RunNodeResult> {\n return this.client.nodes.run(\"pro-3d-render\", params, {\n idempotencyKey: options?.idempotencyKey ?? newIdempotencyKey(),\n })\n }\n\n /**\n * Quote if needed, run, and wait — the whole operation in one call.\n *\n * Two HTTP requests at most, still ONE paid job: when `quoteId` is absent\n * this quotes the identical body first, so the run is admitted against a\n * hash of exactly what was priced. Pass a `quoteId` to run against a quote\n * you already showed the user.\n *\n * Resolves with the settled result — `videoUrl` (the MP4) and `scenePlan`\n * (the exact composition it was rendered from), plus the revision, poster,\n * validation and renderer metadata. A run that AUTHORED also reports its own\n * account of the answer — `metadata.summary`, `repairPasses`,\n * `admissionRetries`, `mechanicalPasses` (repairs the engine applied from\n * the compiler's own remedy with no planner call, counted APART from\n * `repairPasses` on their own quoted allowance), `restoredAssertions`, and\n * any `SCENE_AUTHORING_ASSUMPTION` warnings. A\n * completed result whose `metadata.review` is present passed every mandatory\n * assertion but did NOT get the visual reviewer's approval: `verdict:\n * \"refused\"` means it objected, each objection also a `SCENE_REVIEW_REFUSED`\n * warning; `verdict: \"unavailable\"` means the review produced no usable\n * verdict in `attempts` asks (`reason: \"provider\"` — never reached its\n * provider; `\"unusable\"` — it answered, unusably), so nobody judged the scene and\n * `SCENE_REVIEW_UNAVAILABLE` leads the warnings. Re-render that same\n * `scenePlan` later with {@link render}, or with a `{kind:'scene'}` source;\n * that costs no authoring.\n */\n async renderProAndWait(\n params: Pro3DRenderParams | Pro3DRenderRunParams,\n options?: RunAndWaitOptions & Pro3DRenderRunOptions,\n ): Promise<Pro3DRenderJobOutput> {\n const quoteId =\n typeof (params as Pro3DRenderRunParams).quoteId === \"string\"\n ? (params as Pro3DRenderRunParams).quoteId\n : (await this.quotePro(params)).quoteId\n return this.client.nodes.runAndWait(\"pro-3d-render\", { ...params, quoteId }, {\n ...options,\n idempotencyKey: options?.idempotencyKey ?? newIdempotencyKey(),\n })\n }\n\n /**\n * Uses the supplied immutable revision; never starts authoring or a rebuild.\n *\n * Priced by the plan's frame size — see {@link RenderScene3DParams}.\n */\n render(params: RenderScene3DParams): Promise<RunNodeResult> {\n return this.client.nodes.run(\"render-video\", params)\n }\n\n renderAndWait(params: RenderScene3DParams, options?: RunAndWaitOptions): Promise<NodeJobOutput> {\n return this.client.nodes.runAndWait(\"render-video\", params, options)\n }\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk-NX67YIF3.js"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk-OA6FWYZF.cjs"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk-OJDBSKC2.js"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk-OLPA44QJ.js"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk-OMH7ATOQ.js"}
|