1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9629],{49629:(t,s,e)=>{e.r(s),e.d(s,{snapshots:()=>n});var o=e(58361),a=e(26926);let n={createSnapshot:async t=>(await (0,o.bE)("/snapshots",t)).snapshot,getSnapshot:async t=>(await (0,o.get)("/snapshots/".concat(t))).snapshot,async listSnapshots(t){let s=new URLSearchParams;(null==t?void 0:t.sessionId)!==void 0&&s.set("sessionId",t.sessionId),(null==t?void 0:t.limit)!==void 0&&s.set("limit",String(t.limit)),(null==t?void 0:t.offset)!==void 0&&s.set("offset",String(t.offset));let e="/snapshots".concat(s.toString()?"?".concat(s):"");return(await (0,o.get)(e)).snapshots},updateSnapshot:async(t,s)=>(await (0,o.F6)("/snapshots/".concat(t),s)).snapshot,async deleteSnapshot(t){await (0,o.yH)("/snapshots/".concat(t))},async forkSnapshot(t,s,e){let a=await (0,o.bE)("/snapshots/".concat(t,"/fork"),{title:s,teamId:e});return{session:a.session,forkedFromSnapshotId:a.forkedFromSnapshotId}},async getSnapshotEvents(t,s){let e=new URLSearchParams;(null==s?void 0:s.limit)!==void 0&&e.set("limit",String(s.limit)),(null==s?void 0:s.before)!==void 0&&e.set("before",s.before),(null==s?void 0:s.after)!==void 0&&e.set("after",s.after),(null==s?void 0:s.eventsLimit)!==void 0&&e.set("eventsLimit",String(s.eventsLimit)),(null==s?void 0:s.eventsOffset)!==void 0&&e.set("eventsOffset",String(s.eventsOffset));let a="/snapshots/".concat(t,"/events").concat(e.toString()?"?".concat(e):""),n=await (0,o.get)(a);return{sessionRefs:n.sessionRefs,events:n.events}},async getPublicSnapshotFiles(t){let s=await fetch("/api/public/snapshots/".concat(t,"/files"));if(!s.ok)throw Error("Failed to load snapshot files: ".concat(s.status));let e=await s.json();for(let s of e.files)"boolean"==typeof s.isGeneratedMedia&&(0,a.FC)({snapshotId:t,filePath:s.path},s.isGeneratedMedia);return e},async checkPublicSnapshotFileExists(t,s){let e=encodeURIComponent(s),o=await fetch("/api/public/snapshots/".concat(t,"/files?fileName=").concat(e,"&exists&t=").concat(Date.now()));if(!o.ok)throw Error("Failed to check file: HTTP error! status: ".concat(o.status));return o.json()},async getPublicSnapshotFileContent(t,s){let e=encodeURIComponent(s),o="/api/public/snapshots/".concat(t,"/files?fileName=").concat(e,"&t=").concat(Date.now()),a=await fetch(o);if(!a.ok)throw Error("Failed to load file: HTTP error! status: ".concat(a.status));return a.arrayBuffer()},async getPublicSnapshot(t){let s=await fetch("/api/public/snapshots/".concat(t));if(!s.ok)throw Error("Failed to load snapshot: ".concat(s.status));return(await s.json()).snapshot},async getPublicSnapshotEvents(t,s){let e=new URLSearchParams;(null==s?void 0:s.limit)!==void 0&&e.set("limit",String(s.limit)),(null==s?void 0:s.before)!==void 0&&e.set("before",s.before),(null==s?void 0:s.after)!==void 0&&e.set("after",s.after),(null==s?void 0:s.eventsLimit)!==void 0&&e.set("eventsLimit",String(s.eventsLimit)),(null==s?void 0:s.eventsOffset)!==void 0&&e.set("eventsOffset",String(s.eventsOffset));let o="/api/public/snapshots/".concat(t,"/events").concat(e.toString()?"?".concat(e):""),a=await fetch(o);if(!a.ok)throw Error("Failed to load snapshot events: ".concat(a.status));let n=await a.json();return{sessionRefs:n.sessionRefs,events:n.events}}}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.