[{"data":1,"prerenderedAt":699},["ShallowReactive",2],{"navigation_docs":3,"-guide-diff":88,"-guide-diff-surround":694},[4,40],{"title":5,"path":6,"stem":7,"children":8,"icon":39},"Guide","\u002Fguide","1.guide\u002F1.index",[9,11,15,19,23,27,31,35],{"title":10,"path":6,"stem":7},"Getting Started",{"title":12,"path":13,"stem":14},"Listing Captures","\u002Fguide\u002Fsnapshots","1.guide\u002F2.snapshots",{"title":16,"path":17,"stem":18},"Reading Captures","\u002Fguide\u002Fcontent","1.guide\u002F3.content",{"title":20,"path":21,"stem":22},"Comparing Versions","\u002Fguide\u002Fdiff","1.guide\u002F4.diff",{"title":24,"path":25,"stem":26},"Configuration","\u002Fguide\u002Fconfiguration","1.guide\u002F5.configuration",{"title":28,"path":29,"stem":30},"Agents","\u002Fguide\u002Fagents","1.guide\u002F6.agents",{"title":32,"path":33,"stem":34},"Custom Providers","\u002Fguide\u002Fcustom","1.guide\u002F7.custom",{"title":36,"path":37,"stem":38},"Explorer","\u002Fguide\u002Fexplorer","1.guide\u002F8.explorer","i-lucide-book-open",{"title":41,"path":42,"stem":43,"children":44,"icon":87},"Providers","\u002Fproviders","2.providers\u002F0.index",[45,47,51,55,59,63,67,71,75,79,83],{"title":46,"path":42,"stem":43},"Overview",{"title":48,"path":49,"stem":50},"Wayback Machine","\u002Fproviders\u002Fwayback","2.providers\u002F01.wayback",{"title":52,"path":53,"stem":54},"Arquivo.pt","\u002Fproviders\u002Farquivo","2.providers\u002F02.arquivo",{"title":56,"path":57,"stem":58},"Webarchiv Österreich","\u002Fproviders\u002Fwebarchiv","2.providers\u002F03.webarchiv",{"title":60,"path":61,"stem":62},"Archive.today","\u002Fproviders\u002Farchive-today","2.providers\u002F04.archive-today",{"title":64,"path":65,"stem":66},"Common Crawl","\u002Fproviders\u002Fcommoncrawl","2.providers\u002F05.commoncrawl",{"title":68,"path":69,"stem":70},"WebCite","\u002Fproviders\u002Fwebcite","2.providers\u002F06.webcite",{"title":72,"path":73,"stem":74},"Memento","\u002Fproviders\u002Fmemento","2.providers\u002F07.memento",{"title":76,"path":77,"stem":78},"Archive-It","\u002Fproviders\u002Farchive-it","2.providers\u002F08.archive-it",{"title":80,"path":81,"stem":82},"Conifer","\u002Fproviders\u002Fconifer","2.providers\u002F09.conifer",{"title":84,"path":85,"stem":86},"Perma.cc","\u002Fproviders\u002Fpermacc","2.providers\u002F10.permacc","i-lucide-library",{"id":89,"title":20,"body":90,"description":687,"extension":688,"links":689,"meta":690,"navigation":161,"path":21,"seo":692,"stem":22,"__hash__":693},"docs\u002F1.guide\u002F4.diff.md",{"type":91,"value":92,"toc":680},"minimark",[93,98,356,369,373,376,397,400,404,483,486,490,644,655,659,676],[94,95,97],"h2",{"id":96},"the-call","The call",[99,100,105],"pre",{"className":101,"code":102,"language":103,"meta":104,"style":104},"language-ts shiki shiki-themes vitesse-light vitesse-light vesper","import { createArchive, diffArchivedContent, providers } from \"@agntn\u002Farchives\";\n\nconst archive = createArchive(providers.wayback());\nconst before = await archive.getContent(\"https:\u002F\u002Fexample.com\", { timestamp: \"2024\" });\nconst after = await archive.getContent(\"https:\u002F\u002Fexample.com\", { timestamp: \"2026\" });\n\nconst visible = diffArchivedContent(before, after);\nconst source = diffArchivedContent(before, after, { format: \"raw\" });\n","ts","",[106,107,108,156,163,195,246,289,294,318],"code",{"__ignoreMap":104},[109,110,113,117,121,125,128,131,133,136,139,142,146,150,153],"span",{"class":111,"line":112},"line",1,[109,114,116],{"class":115},"sB1ot","import",[109,118,120],{"class":119},"sldxI"," {",[109,122,124],{"class":123},"sA8fy"," createArchive",[109,126,127],{"class":119},",",[109,129,130],{"class":123}," diffArchivedContent",[109,132,127],{"class":119},[109,134,135],{"class":123}," providers",[109,137,138],{"class":119}," }",[109,140,141],{"class":115}," from",[109,143,145],{"class":144},"sbwUx"," \"",[109,147,149],{"class":148},"sHyde","@agntn\u002Farchives",[109,151,152],{"class":144},"\"",[109,154,155],{"class":119},";\n",[109,157,159],{"class":111,"line":158},2,[109,160,162],{"emptyLinePlaceholder":161},true,"\n",[109,164,166,170,173,177,180,183,186,189,192],{"class":111,"line":165},3,[109,167,169],{"class":168},"s8Cdk","const",[109,171,172],{"class":123}," archive",[109,174,176],{"class":175},"sUeik"," =",[109,178,124],{"class":179},"shFES",[109,181,182],{"class":119},"(",[109,184,185],{"class":123},"providers",[109,187,188],{"class":119},".",[109,190,191],{"class":179},"wayback",[109,193,194],{"class":119},"());\n",[109,196,198,200,203,205,208,210,212,215,217,219,222,224,226,229,233,236,238,241,243],{"class":111,"line":197},4,[109,199,169],{"class":168},[109,201,202],{"class":123}," before",[109,204,176],{"class":175},[109,206,207],{"class":115}," await",[109,209,172],{"class":123},[109,211,188],{"class":119},[109,213,214],{"class":179},"getContent",[109,216,182],{"class":119},[109,218,152],{"class":144},[109,220,221],{"class":148},"https:\u002F\u002Fexample.com",[109,223,152],{"class":144},[109,225,127],{"class":119},[109,227,228],{"class":119}," { ",[109,230,232],{"class":231},"sYv7f","timestamp",[109,234,235],{"class":119},": ",[109,237,152],{"class":144},[109,239,240],{"class":148},"2024",[109,242,152],{"class":144},[109,244,245],{"class":119}," });\n",[109,247,249,251,254,256,258,260,262,264,266,268,270,272,274,276,278,280,282,285,287],{"class":111,"line":248},5,[109,250,169],{"class":168},[109,252,253],{"class":123}," after",[109,255,176],{"class":175},[109,257,207],{"class":115},[109,259,172],{"class":123},[109,261,188],{"class":119},[109,263,214],{"class":179},[109,265,182],{"class":119},[109,267,152],{"class":144},[109,269,221],{"class":148},[109,271,152],{"class":144},[109,273,127],{"class":119},[109,275,228],{"class":119},[109,277,232],{"class":231},[109,279,235],{"class":119},[109,281,152],{"class":144},[109,283,284],{"class":148},"2026",[109,286,152],{"class":144},[109,288,245],{"class":119},[109,290,292],{"class":111,"line":291},6,[109,293,162],{"emptyLinePlaceholder":161},[109,295,297,299,302,304,306,308,311,313,315],{"class":111,"line":296},7,[109,298,169],{"class":168},[109,300,301],{"class":123}," visible",[109,303,176],{"class":175},[109,305,130],{"class":179},[109,307,182],{"class":119},[109,309,310],{"class":123},"before",[109,312,127],{"class":119},[109,314,253],{"class":123},[109,316,317],{"class":119},");\n",[109,319,321,323,326,328,330,332,334,336,338,340,342,345,347,349,352,354],{"class":111,"line":320},8,[109,322,169],{"class":168},[109,324,325],{"class":123}," source",[109,327,176],{"class":175},[109,329,130],{"class":179},[109,331,182],{"class":119},[109,333,310],{"class":123},[109,335,127],{"class":119},[109,337,253],{"class":123},[109,339,127],{"class":119},[109,341,228],{"class":119},[109,343,344],{"class":231},"format",[109,346,235],{"class":119},[109,348,152],{"class":144},[109,350,351],{"class":148},"raw",[109,353,152],{"class":144},[109,355,245],{"class":119},[357,358,359,362,363,368],"p",{},[106,360,361],{},"diffArchivedContent"," works on two captures already in memory. It does not fetch. Read both bodies first, then compare; the ",[364,365,367],"a",{"href":366},"\u002Ftimeline","Timeline"," runs this on any two captures you tick.",[94,370,372],{"id":371},"what-it-refuses","What it refuses",[357,374,375],{},"The helper throws rather than guess when:",[377,378,379,383,386,389],"ul",{},[380,381,382],"li",{},"the captures come from different providers, or from Memento but different underlying archive hosts;",[380,384,385],{},"the original URLs differ;",[380,387,388],{},"either body is not text;",[380,390,391,394,395,188],{},[106,392,393],{},"after"," is not later than ",[106,396,310],{},[357,398,399],{},"Replay engines rewrite links, inject banners and normalise markup differently. Comparing a Wayback body with an Arquivo.pt body would show those differences as if the site had changed. One provider, one URL, chronological order: those are the conditions under which a diff means something.",[94,401,403],{"id":402},"options","Options",[405,406,407,423],"table",{},[408,409,410],"thead",{},[411,412,413,417,420],"tr",{},[414,415,416],"th",{},"Option",[414,418,419],{},"Default",[414,421,422],{},"Meaning",[424,425,426,444,457,470],"tbody",{},[411,427,428,433,438],{},[429,430,431],"td",{},[106,432,344],{},[429,434,435],{},[106,436,437],{},"\"text\"",[429,439,440,441],{},"Compare visible text, or the decoded markup with ",[106,442,443],{},"\"raw\"",[411,445,446,451,454],{},[429,447,448],{},[106,449,450],{},"context",[429,452,453],{},"3",[429,455,456],{},"Unchanged lines kept around each hunk",[411,458,459,464,467],{},[429,460,461],{},[106,462,463],{},"timeout",[429,465,466],{},"1 000 ms",[429,468,469],{},"Elapsed budget for the line diff",[411,471,472,477,480],{},[429,473,474],{},[106,475,476],{},"maxEditLength",[429,478,479],{},"10 000",[429,481,482],{},"Edit distance ceiling before the diff gives up",[357,484,485],{},"The two bounds exist because a diff between two large, unrelated bodies is quadratic. Hitting either throws; a caller that wants an answer anyway can raise them.",[94,487,489],{"id":488},"what-comes-back","What comes back",[99,491,493],{"className":101,"code":492,"language":103,"meta":104,"style":104},"interface ArchivedContentDiff {\n  before: ArchivedContentSummary; \u002F\u002F url, timestamp, snapshot, mime, bytes, truncated, provider, archive?\n  after: ArchivedContentSummary;\n  patch: string; \u002F\u002F unified diff\n  additions: number;\n  deletions: number;\n  identical: boolean;\n  partial: boolean; \u002F\u002F either body was truncated before comparison\n  format: \"text\" | \"raw\";\n  context: number;\n}\n",[106,494,495,507,525,536,551,563,574,586,600,626,638],{"__ignoreMap":104},[109,496,497,500,504],{"class":111,"line":112},[109,498,499],{"class":168},"interface",[109,501,503],{"class":502},"s0_b1"," ArchivedContentDiff",[109,505,506],{"class":119}," {\n",[109,508,509,512,515,518,521],{"class":111,"line":158},[109,510,511],{"class":123},"  before",[109,513,514],{"class":175},":",[109,516,517],{"class":502}," ArchivedContentSummary",[109,519,520],{"class":119},";",[109,522,524],{"class":523},"szOLe"," \u002F\u002F url, timestamp, snapshot, mime, bytes, truncated, provider, archive?\n",[109,526,527,530,532,534],{"class":111,"line":165},[109,528,529],{"class":123},"  after",[109,531,514],{"class":175},[109,533,517],{"class":502},[109,535,155],{"class":119},[109,537,538,541,543,546,548],{"class":111,"line":197},[109,539,540],{"class":123},"  patch",[109,542,514],{"class":175},[109,544,545],{"class":502}," string",[109,547,520],{"class":119},[109,549,550],{"class":523}," \u002F\u002F unified diff\n",[109,552,553,556,558,561],{"class":111,"line":248},[109,554,555],{"class":123},"  additions",[109,557,514],{"class":175},[109,559,560],{"class":502}," number",[109,562,155],{"class":119},[109,564,565,568,570,572],{"class":111,"line":291},[109,566,567],{"class":123},"  deletions",[109,569,514],{"class":175},[109,571,560],{"class":502},[109,573,155],{"class":119},[109,575,576,579,581,584],{"class":111,"line":296},[109,577,578],{"class":123},"  identical",[109,580,514],{"class":175},[109,582,583],{"class":502}," boolean",[109,585,155],{"class":119},[109,587,588,591,593,595,597],{"class":111,"line":320},[109,589,590],{"class":123},"  partial",[109,592,514],{"class":175},[109,594,583],{"class":502},[109,596,520],{"class":119},[109,598,599],{"class":523}," \u002F\u002F either body was truncated before comparison\n",[109,601,603,606,608,610,613,615,618,620,622,624],{"class":111,"line":602},9,[109,604,605],{"class":123},"  format",[109,607,514],{"class":175},[109,609,145],{"class":144},[109,611,612],{"class":148},"text",[109,614,152],{"class":144},[109,616,617],{"class":175}," |",[109,619,145],{"class":144},[109,621,351],{"class":148},[109,623,152],{"class":144},[109,625,155],{"class":119},[109,627,629,632,634,636],{"class":111,"line":628},10,[109,630,631],{"class":123},"  context",[109,633,514],{"class":175},[109,635,560],{"class":502},[109,637,155],{"class":119},[109,639,641],{"class":111,"line":640},11,[109,642,643],{"class":119},"}\n",[357,645,646,647,650,651,654],{},"The summaries keep the exact capture dates and snapshot URLs, because the dates you asked for and the dates the archive resolved to are rarely the same. ",[106,648,649],{},"partial: true"," means a body hit ",[106,652,653],{},"maxBytes","; absence beyond that prefix is not proved, and a report built on the diff should say so.",[94,656,658],{"id":657},"over-mcp","Over MCP",[357,660,661,664,665,668,669,672,673,675],{},[106,662,663],{},"archives_diff"," does the fetching and the comparing in one call. With ",[106,666,667],{},"provider=all"," it tries providers in order until one can serve both captures; it never combines versions from two archives. The result text carries the resolved dates, both snapshot URLs, a SHA-256 of the complete patch, and a ",[106,670,671],{},"continue"," line for the next slice of a long patch. ",[364,674,28],{"href":29}," covers the slice contract.",[677,678,679],"style",{},"html pre.shiki code .sB1ot, html code.shiki .sB1ot{--shiki-light:#1E754F;--shiki-default:#1E754F;--shiki-dark:#A0A0A0}html pre.shiki code .sldxI, html code.shiki .sldxI{--shiki-light:#999999;--shiki-default:#999999;--shiki-dark:#FFF}html pre.shiki code .sA8fy, html code.shiki .sA8fy{--shiki-light:#B07D48;--shiki-default:#B07D48;--shiki-dark:#FFF}html pre.shiki code .sbwUx, html code.shiki .sbwUx{--shiki-light:#B5695977;--shiki-default:#B5695977;--shiki-dark:#99FFE4}html pre.shiki code .sHyde, html code.shiki .sHyde{--shiki-light:#B56959;--shiki-default:#B56959;--shiki-dark:#99FFE4}html pre.shiki code .s8Cdk, html code.shiki .s8Cdk{--shiki-light:#AB5959;--shiki-default:#AB5959;--shiki-dark:#A0A0A0}html pre.shiki code .sUeik, html code.shiki .sUeik{--shiki-light:#999999;--shiki-default:#999999;--shiki-dark:#A0A0A0}html pre.shiki code .shFES, html code.shiki .shFES{--shiki-light:#59873A;--shiki-default:#59873A;--shiki-dark:#FFC799}html pre.shiki code .sYv7f, html code.shiki .sYv7f{--shiki-light:#998418;--shiki-default:#998418;--shiki-dark:#FFF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .s0_b1, html code.shiki .s0_b1{--shiki-light:#2E8F82;--shiki-default:#2E8F82;--shiki-dark:#FFC799}html pre.shiki code .szOLe, html code.shiki .szOLe{--shiki-light:#A0ADA0;--shiki-default:#A0ADA0;--shiki-dark:#8B8B8B94}",{"title":104,"searchDepth":158,"depth":158,"links":681},[682,683,684,685,686],{"id":96,"depth":158,"text":97},{"id":371,"depth":158,"text":372},{"id":402,"depth":158,"text":403},{"id":488,"depth":158,"text":489},{"id":657,"depth":158,"text":658},"A bounded line diff between two captures that keeps provenance and never overstates an absence.","md",null,{"icon":691},"i-lucide-diff",{"title":20,"description":687},"LQFWjH4L2mpIeProuK6LMaoMs7K-B6RDQKmFchOPqNk",[695,697],{"title":16,"path":17,"stem":18,"description":696,"children":-1},"How a timestamp becomes a capture, what comes back, and which archives can serve a body at all.",{"title":24,"path":25,"stem":26,"description":698,"children":-1},"Config files through c12, the unstorage cache, and where an MCP server looks for its config.",1788446777799]