Captures a report — dashboards especially — to a tracked PNG document
and returns its guid, ready to embed in email.
_ensure_doc_type(package) upserts the screenshots def_document typeBase=data.documents → data.documents/screenshots/package.<pkg>/<guid>.png;PurgeTTL from config drives the reaper).ObjDocumentFile.create/read/get_file_name.ObjRenderToken)<render_base>/report/<code>/naked?rtoken=<token> (no site chrome,ObjMcpClient.playwright_screenshot_sdk.build_detail registers size/mime/dimensions on the document row.AXION_PACKAGE=wynberg ./dev-env/bin/python \
factory.service/package.core/ObjServiceScreenshot.py capture mailinglist
# → guid: screenshots_... path: data.documents/screenshots/package.wynberg/<guid>.png
# embed in email with: {docimage:<guid>}
Method form: ObjServiceScreenshot().capture(report_code, naked=True, width=1280, height=1600, full_page=True, render_base="") → {ok, guid, path, report, package}.
screenshot.render_base — local render URL (default http://localhost:9400;http://localhost:9407). Localhost, not the public host, so capturescreenshot.retention_days — PurgeTTL for the screenshots type (default 30).data.documents is not publicly served, so a screenshot has no public
URL. Embed it into email as a CID inline image via the {docimage:<guid>}
body token (resolved at send by ObjChannel/ObjWebMail). The reaper deletes
file + record after retention_days.
ObjRenderToken (the pass), ObjMcpClient.playwright_screenshot_sdk (the
capture), ObjDocument/ObjDocumentFile (the record), ObjDocumentReaper
(cleanup), WebPageReport._render_token_ok (the ACL bypass point).