@extenshi/mcp 0.9.0 → 0.10.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 +6 -1
- package/dist/bff.d.ts +21 -0
- package/dist/bff.d.ts.map +1 -1
- package/dist/bff.js +4 -0
- package/dist/bff.js.map +1 -1
- package/dist/development-guide.d.ts +118 -34
- package/dist/development-guide.d.ts.map +1 -1
- package/dist/development-guide.js +85 -9
- package/dist/development-guide.js.map +1 -1
- package/dist/icon-workflow.d.ts.map +1 -1
- package/dist/icon-workflow.js +15 -2
- package/dist/icon-workflow.js.map +1 -1
- package/dist/pay.d.ts +8 -1
- package/dist/pay.d.ts.map +1 -1
- package/dist/pay.js +9 -0
- package/dist/pay.js.map +1 -1
- package/dist/project-media.d.ts +29 -0
- package/dist/project-media.d.ts.map +1 -0
- package/dist/project-media.js +72 -0
- package/dist/project-media.js.map +1 -0
- package/dist/publish.d.ts +101 -0
- package/dist/publish.d.ts.map +1 -1
- package/dist/publish.js +81 -2
- package/dist/publish.js.map +1 -1
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +237 -11
- package/dist/tools.js.map +1 -1
- package/package.json +3 -3
|
@@ -35,8 +35,11 @@ export const DEVELOPMENT_SERVICES = [
|
|
|
35
35
|
purpose: 'Existing projects: selected browser types, manifests, repository binding, saved tool state, hosted URLs and starter files.',
|
|
36
36
|
tools: [
|
|
37
37
|
'list_my_projects',
|
|
38
|
+
'create_project',
|
|
38
39
|
'get_project_state',
|
|
39
40
|
'get_project_scaffold',
|
|
41
|
+
'get_decisions',
|
|
42
|
+
'propose_decision',
|
|
40
43
|
'get_project_workspace',
|
|
41
44
|
'import_manifest',
|
|
42
45
|
'diff_project_state',
|
|
@@ -49,7 +52,7 @@ export const DEVELOPMENT_SERVICES = [
|
|
|
49
52
|
'list_hosted_pages',
|
|
50
53
|
'get_release_readiness',
|
|
51
54
|
],
|
|
52
|
-
access: 'Own-project MCP reads are free and require identity. Projects are created in the cabinet. Repository metadata, source/built manifests and scope synchronize through typed revisioned patches. project.write, evidence.write and hosted.write require explicit OAuth consent. Repository metadata does not grant GitHub access. CI evidence (source=ci) is written only by the verified ingest endpoint, which authenticates with a secret from create_ci_ingest_secret. Automated release-readiness access requires a Pro project.',
|
|
55
|
+
access: 'Own-project MCP reads are free and require identity. Projects are created in the cabinet or with create_project (idempotent, project.write). Owner decisions (AMO add-on id, license, seller identity, pricing, targets) are proposed by agents and decided only by the owner in the cabinet; release readiness reports undecided ones as blockers. Repository metadata, source/built manifests and scope synchronize through typed revisioned patches. project.write, evidence.write and hosted.write require explicit OAuth consent. Repository metadata does not grant GitHub access. CI evidence (source=ci) is written only by the verified ingest endpoint, which authenticates with a secret from create_ci_ingest_secret. Automated release-readiness access requires a Pro project.',
|
|
53
56
|
urls: [
|
|
54
57
|
DEVELOPMENT_GUIDE_URL,
|
|
55
58
|
'https://dojo.extenshi.io/projects',
|
|
@@ -112,9 +115,10 @@ export const DEVELOPMENT_SERVICES = [
|
|
|
112
115
|
'publish_landing_page',
|
|
113
116
|
'get_landing_page',
|
|
114
117
|
'unpublish_landing_page',
|
|
118
|
+
'upload_project_media',
|
|
115
119
|
'upsert_hosted_page',
|
|
116
120
|
],
|
|
117
|
-
access:
|
|
121
|
+
access: "The landing-page generator is free and offline: it returns static HTML (CLI: extenshi page generate). The same page can be hosted by Extenshi at page.extenshi.io/{code} with publish_landing_page (identity and hosted.write; CLI: extenshi page publish), which also registers it as the project homepage; images there are store screenshots, Dojo uploads or files uploaded with upload_project_media (hosted.write; CLI: extenshi media upload, or page publish --upload-local) to the project's public media store. Store screenshots per locale come from CLI extenshi screenshots and listing artwork from CLI extenshi icon store-assets (formats and sizes: guide section storeMedia). A page hosted elsewhere on HTTPS is registered with upsert_hosted_page (CLI: extenshi page register). The registered homepage feeds HOMEPAGE_URL. Listing copy and store-risk review are covered by CLI generate-listing / review-risk and cabinet tools where enabled. MCP has no listing or SEO execution tool.",
|
|
118
122
|
urls: [
|
|
119
123
|
docs('cli'),
|
|
120
124
|
docs('ai-visibility'),
|
|
@@ -126,17 +130,27 @@ export const DEVELOPMENT_SERVICES = [
|
|
|
126
130
|
},
|
|
127
131
|
{
|
|
128
132
|
id: 'verification-and-ci',
|
|
129
|
-
purpose: '
|
|
130
|
-
tools: ['scan_extension'],
|
|
131
|
-
access: '
|
|
133
|
+
purpose: 'Reproducible per-browser packages, installed smoke tests of the exact package in Chromium, Edge and Firefox, store-risk review, final package scan, and release evidence recorded from those results.',
|
|
134
|
+
tools: ['scan_extension', 'record_project_evidence', 'get_release_readiness'],
|
|
135
|
+
access: 'Local CLI, free: `extenshi package <dir> --browser chrome,edge,firefox` writes byte-reproducible zips plus extenshi-packages.json (sha256 per browser; refuses a placeholder Firefox add-on ID; --fix-war expands wildcard web_accessible_resources). `extenshi test smoke <zip|extenshi-packages.json> --browser chromium|edge|firefox --json` installs that exact zip and checks service worker/background start, manifest errors and console errors on popup/options pages (Playwright for Chromium/Edge, any Firefox binary). `--evidence` on scan, review-risk, generate-listing and test smoke records scan / permissions / listing (per locale) / installed evidence for the project bound with `extenshi project bind` (advisory listing findings stay passed and are listed in the evidence summary); release prepare accepts extenshi-packages.json. Scan requires an API key and spends 1 scan credit. CI: the scaffold writes .github/workflows/extenshi-verify.yml and extenshi-evidence.yml; CI-sourced evidence arrives through `extenshi evidence ingest` with the create_ci_ingest_secret secret.',
|
|
132
136
|
urls: [docs('cli'), docs('cli-github-actions'), docs('store-policies')],
|
|
133
137
|
},
|
|
134
138
|
{
|
|
135
139
|
id: 'publishing',
|
|
136
140
|
purpose: 'Store credential validation, submission of the exact tested package to Chrome Web Store, Firefox Add-ons and/or Edge Add-ons, and verification of review status and the public listing.',
|
|
137
141
|
tools: ['publish_extension'],
|
|
138
|
-
access: 'Local stdio or CLI with local store credentials; publishing access is checked. Store registration, disclosures and review are separate steps. Upload success alone does not establish a live release.'
|
|
139
|
-
|
|
142
|
+
access: 'Local stdio or CLI with local store credentials; publishing access is checked. Store registration, disclosures and review are separate steps. Upload success alone does not establish a live release. ' +
|
|
143
|
+
'CLI: extenshi publish --stores chrome,edge,firefox (comma-separated; a subset also works, e.g. --stores firefox,edge) submits to every named store from the tested artifact. ' +
|
|
144
|
+
'Firefox/AMO adds requirements the other stores do not have: browser_specific_settings.gecko.id is required to sign a Manifest V3 add-on and should be treated as permanent once first published; ' +
|
|
145
|
+
'new add-ons submitted since 2025-11-03 must declare browser_specific_settings.gecko.data_collection_permissions; minified/bundled/transpiled code needs a source-code submission with reproducible build instructions (extenshi amo-source generates the archive and BUILD.md); and `web-ext lint` should report 0 errors before submission. ' +
|
|
146
|
+
"Microsoft Edge Add-ons: a NEW extension's first submission must be created by hand in Partner Center — the REST API (publisher/src/services/edge.ts) only uploads a package and publishes an EXISTING submission, it cannot create one.",
|
|
147
|
+
urls: [
|
|
148
|
+
docs('cli'),
|
|
149
|
+
docs('publish-to-chrome-web-store'),
|
|
150
|
+
docs('publish-to-edge-add-ons'),
|
|
151
|
+
docs('publish-to-firefox-add-ons'),
|
|
152
|
+
toolPage('publish'),
|
|
153
|
+
],
|
|
140
154
|
},
|
|
141
155
|
{
|
|
142
156
|
id: 'maintenance',
|
|
@@ -159,6 +173,7 @@ export const DEVELOPMENT_SERVICES = [
|
|
|
159
173
|
'create_pay_app',
|
|
160
174
|
'get_pay_app',
|
|
161
175
|
'get_pay_readiness',
|
|
176
|
+
'get_pay_payment_evidence',
|
|
162
177
|
'link_pay_app',
|
|
163
178
|
'unlink_pay_app',
|
|
164
179
|
'archive_pay_app',
|
|
@@ -228,6 +243,7 @@ const WORKFLOW = [
|
|
|
228
243
|
'generate_welcome_page_workflow',
|
|
229
244
|
'generate_landing_page',
|
|
230
245
|
'publish_landing_page',
|
|
246
|
+
'upload_project_media',
|
|
231
247
|
'upsert_hosted_page',
|
|
232
248
|
'list_privacy_policy_versions',
|
|
233
249
|
'get_privacy_policy_version',
|
|
@@ -239,8 +255,8 @@ const WORKFLOW = [
|
|
|
239
255
|
},
|
|
240
256
|
{
|
|
241
257
|
id: 'quality-and-listing',
|
|
242
|
-
actions: 'Stage 7 — Quality and listing: each browser package is built; unit/integration checks and manual browser scenarios run. Disclosures, permission justifications, listing copy and screenshots are reviewed against the build (CLI review-risk and generate-listing
|
|
243
|
-
relatedTools: ['search_docs', 'scan_extension'],
|
|
258
|
+
actions: 'Stage 7 — Quality and listing: each browser package is built reproducibly (CLI package), and that exact zip is installed and smoke-tested per browser (CLI test smoke); unit/integration checks and manual browser scenarios run. Disclosures, permission justifications, listing copy and screenshots are reviewed against the build (CLI review-risk and generate-listing --store chrome|edge|firefox, which draft CHROMEWEBSTORE.md / EDGE.md / AMO.md — the same listing draft review-risk --listing reads back regardless of which one). A Firefox build with minified/bundled code additionally needs extenshi amo-source (source archive + BUILD.md) and a clean `web-ext lint`. With --evidence, scan, review-risk, generate-listing and test smoke record their release evidence for the bound project; the final package is scanned. Exact commands: the CLI docs. CI runs the scaffolded extenshi-verify workflow.',
|
|
259
|
+
relatedTools: ['search_docs', 'scan_extension', 'get_release_readiness'],
|
|
244
260
|
doneWhen: 'The exact versioned artifact has passing checks, retained scan/review reports and truthful store materials; unresolved findings have a disposition.',
|
|
245
261
|
},
|
|
246
262
|
{
|
|
@@ -264,6 +280,7 @@ export const GUIDE_SECTIONS = [
|
|
|
264
280
|
'repository',
|
|
265
281
|
'workflow',
|
|
266
282
|
'handoff',
|
|
283
|
+
'storeMedia',
|
|
267
284
|
];
|
|
268
285
|
const SECTION_SUMMARIES = {
|
|
269
286
|
tools: 'Every tool registered on this connection: description, read-only/destructive hints and docs links.',
|
|
@@ -272,6 +289,64 @@ const SECTION_SUMMARIES = {
|
|
|
272
289
|
repository: 'Git repository recommendation, setup, layout and secret-handling practice.',
|
|
273
290
|
workflow: 'The nine lifecycle stages with descriptions, related tools and exit criteria.',
|
|
274
291
|
handoff: 'Items a completed handoff records.',
|
|
292
|
+
storeMedia: 'Store screenshots per locale (CLI screenshots + scenes.json format), listing artwork sizes per store (CLI icon store-assets) and the public project media store.',
|
|
293
|
+
};
|
|
294
|
+
/**
|
|
295
|
+
* Store image requirements and the scenes format. Static reference: the CLI
|
|
296
|
+
* (tools/extenshi-cli/src/store-assets.ts, screenshots-scenes.ts) is the
|
|
297
|
+
* implementation; sizes cite the stores' own pages.
|
|
298
|
+
*/
|
|
299
|
+
const STORE_MEDIA = {
|
|
300
|
+
screenshots: {
|
|
301
|
+
command: 'npx @extenshi/cli@latest screenshots <unpacked-dir|zip> --scenes scenes.json [--locales en,de] [--store chrome,edge,firefox] [--small] [--out store-screenshots] [--json]',
|
|
302
|
+
requires: 'Playwright with the full Chromium build in the project (npm i -D playwright && npx playwright install chromium); the headless shell cannot load extensions. The source build is never modified: it is staged into a temporary copy.',
|
|
303
|
+
output: '<out>/<store>/<locale>/NN-<scene>-WxH.png, plus <out>/screenshots.json (files with sha256, verified locales, warnings).',
|
|
304
|
+
localeSwitching: 'Each locale runs in a fresh Chromium with its UI language set (--lang; LANGUAGE on Linux; -AppleLanguages on macOS, where --lang has no effect). chrome.i18n inside the extension has to report the locale and render a message from _locales/<locale>; a mismatch fails the run. A locale missing from _locales is refused.',
|
|
305
|
+
determinism: 'Fixed viewport and device scale factor, reduced motion, animations/transitions/caret disabled, UTC timezone, optional fixed clock (time), fonts and images awaited before capture, store canvas composed by a WebAssembly renderer. Identical inputs produce byte-identical PNGs on the same machine.',
|
|
306
|
+
sizes: {
|
|
307
|
+
chrome: '1280×800 (default) or 640×400 with --small; full bleed; 1–5 per locale — https://developer.chrome.com/docs/webstore/images',
|
|
308
|
+
edge: '1280×800 or 640×480 with --small; up to 6 — https://learn.microsoft.com/en-us/microsoft-edge/extensions/publish/publish-extension',
|
|
309
|
+
firefox: '1280×800 recommended (1.6:1), uploaded as AMO previews — https://extensionworkshop.com/documentation/develop/create-an-appealing-listing/',
|
|
310
|
+
},
|
|
311
|
+
scenesFormat: {
|
|
312
|
+
example: {
|
|
313
|
+
version: 1,
|
|
314
|
+
viewport: { width: 1280, height: 800 },
|
|
315
|
+
deviceScaleFactor: 2,
|
|
316
|
+
fixtures: 'fixtures',
|
|
317
|
+
frame: { background: '#eef2ff', backgroundTo: '#e0e7ff', margin: 48, shadow: true, radius: 12 },
|
|
318
|
+
setup: [{ storage: { area: 'local', set: { onboarded: true } } }],
|
|
319
|
+
scenes: [
|
|
320
|
+
{ name: 'popup', open: 'popup', steps: [{ click: '#enable' }, { wait: 300 }] },
|
|
321
|
+
{
|
|
322
|
+
name: 'on-a-page',
|
|
323
|
+
open: 'fixture:article.{locale}.html',
|
|
324
|
+
steps: [{ mouse: { x: 640, y: 330 } }],
|
|
325
|
+
},
|
|
326
|
+
{ name: 'options', open: 'options', crop: { selector: 'main', padding: 24 } },
|
|
327
|
+
],
|
|
328
|
+
},
|
|
329
|
+
open: 'popup | options (from the manifest) | page:<path inside the extension> | fixture:<file under fixtures, served from 127.0.0.1> | url:https://…. {locale} and {lang} expand to the _locales code (pt_BR) and BCP 47 tag (pt-BR).',
|
|
330
|
+
steps: 'click <selector>, hover <selector>, type <selector> + text, press <key>, mouse {x,y}, scroll {x?,y}, wait <ms up to 30000>, waitFor <selector> (+state), storage {area: local|sync|session, set?, remove?, clear?} in the extension context, eval <JS expression> in the scene page.',
|
|
331
|
+
sceneOptions: 'viewport, colorScheme (light|dark), init (JS before the page scripts, e.g. stubbing chrome.tabs.query for a popup opened as a tab), crop (viewport | content — default for popup | fullPage | {selector, padding}), fit (contain — centered on the frame, not magnified past its captured pixels | cover), frame, stores (subset).',
|
|
332
|
+
fileOptions: 'viewport (default 1280×800), deviceScaleFactor (1–3), colorScheme, time (ISO date for Date.now), fixtures (dir, default the scenes file dir), animations (disabled|allow), frame {background, backgroundTo, margin, shadow, radius}, setup (steps run once per locale before the scenes), scenes (1–12).',
|
|
333
|
+
},
|
|
334
|
+
},
|
|
335
|
+
storeAssets: {
|
|
336
|
+
command: 'npx @extenshi/cli@latest icon store-assets <icon.svg|png> [--store chrome,edge,firefox] [--out store-assets] [--background <color>] [--promo <file>] [--marquee <file>] [--font <file.ttf>]',
|
|
337
|
+
outputs: {
|
|
338
|
+
chrome: 'icon-128.png (96×96 artwork + 16 px transparent padding), promo-small-440x280.png (required), marquee-1400x560.png — https://developer.chrome.com/docs/webstore/images',
|
|
339
|
+
edge: 'logo-300x300.png (1:1, min 128), promo-small-440x280.png, promo-large-1400x560.png — https://learn.microsoft.com/en-us/microsoft-edge/extensions/publish/publish-extension',
|
|
340
|
+
firefox: 'icon-128.png (AMO listing icon; AMO derives 32/64), icon-64.png and icon-32.png (manifest icons) — https://mozilla.github.io/addons-server/topics/api/addons.html#addon-icon',
|
|
341
|
+
},
|
|
342
|
+
notes: 'Offline WebAssembly renderer, no API key. Built-in padding in the source is trimmed rather than doubled. Tiles are composed from the icon on a tint of its colour unless --promo / --marquee artwork is given; clipped content, wrong aspect ratios and upscaled rasters are reported as warnings. <style> blocks in SVG sources are removed by the scrubber; text uses matching system fonts or --font.',
|
|
343
|
+
},
|
|
344
|
+
publicMedia: {
|
|
345
|
+
tool: 'upload_project_media (hosted.write)',
|
|
346
|
+
cli: 'npx @extenshi/cli@latest media upload <file…> --project <id>, or page publish --upload-local',
|
|
347
|
+
accepts: 'PNG, JPEG or WebP up to 2 MB, 16–4096 px per side; SVG is rasterized by the CLI (the MCP tool refuses it). Magic bytes are checked, EXIF/XMP/text metadata and trailing bytes are stripped, and the key is the SHA-256 of the stored bytes, so the URL is stable and a re-upload returns the same URL. Quota: 100 files / 50 MB per project, Dojo uploads included.',
|
|
348
|
+
use: 'The returned url is accepted by publish_landing_page as screenshots[].url or logoUrl.',
|
|
349
|
+
},
|
|
275
350
|
};
|
|
276
351
|
const AVAILABILITY = 'Tool lists describe the tools registered on THIS connection. Registration does not prove account access, remaining credits or local prerequisites. Service URLs describe where work happens; account/project access is checked live. Exact input schemas come from MCP tools/list. This guide makes no network calls.';
|
|
277
352
|
function buildSections(registeredTools) {
|
|
@@ -313,6 +388,7 @@ function buildSections(registeredTools) {
|
|
|
313
388
|
],
|
|
314
389
|
},
|
|
315
390
|
workflow: WORKFLOW,
|
|
391
|
+
storeMedia: STORE_MEDIA,
|
|
316
392
|
handoff: [
|
|
317
393
|
'scope and acceptance criteria',
|
|
318
394
|
'project ID, repository URL, branch and commit',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"development-guide.js","sourceRoot":"","sources":["../src/development-guide.ts"],"names":[],"mappings":"AAoBA,MAAM,IAAI,GAAG,CAAC,IAAY,EAAE,EAAE,CAAC,uCAAuC,IAAI,EAAE,CAAA;AAC5E,MAAM,QAAQ,GAAG,CAAC,GAAW,EAAE,EAAE,CAAC,kCAAkC,GAAG,EAAE,CAAA;AAEzE,MAAM,CAAC,MAAM,qBAAqB,GAAG,IAAI,CAAC,sBAAsB,CAAC,CAAA;AAEjE,MAAM,CAAC,MAAM,oBAAoB,GAAG;IACnC;QACC,EAAE,EAAE,eAAe;QACnB,OAAO,EAAE,iFAAiF;QAC1F,KAAK,EAAE,CAAC,uBAAuB,EAAE,aAAa,EAAE,0BAA0B,CAAC;QAC3E,MAAM,EAAE,gFAAgF;QACxF,IAAI,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,qBAAqB,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;KAChE;IACD;QACC,EAAE,EAAE,SAAS;QACb,OAAO,EAAE,gFAAgF;QACzF,KAAK,EAAE,CAAC,oBAAoB,EAAE,wBAAwB,CAAC;QACvD,MAAM,EAAE,yFAAyF;QACjG,IAAI,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,EAAE,mCAAmC,EAAE,kCAAkC,CAAC;KACrG;IACD;QACC,EAAE,EAAE,UAAU;QACd,OAAO,EAAE,mFAAmF;QAC5F,KAAK,EAAE;YACN,mBAAmB;YACnB,eAAe;YACf,aAAa;YACb,cAAc;YACd,uBAAuB;YACvB,iBAAiB;SACjB;QACD,MAAM,EACL,kLAAkL;QACnL,IAAI,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,6BAA6B,CAAC;KAClD;IACD;QACC,EAAE,EAAE,UAAU;QACd,OAAO,EACN,4HAA4H;QAC7H,KAAK,EAAE;YACN,kBAAkB;YAClB,mBAAmB;YACnB,sBAAsB;YACtB,uBAAuB;YACvB,iBAAiB;YACjB,oBAAoB;YACpB,qBAAqB;YACrB,yBAAyB;YACzB,yBAAyB;YACzB,oBAAoB;YACpB,wBAAwB;YACxB,oBAAoB;YACpB,mBAAmB;YACnB,uBAAuB;SACvB;QACD,MAAM,EACL,
|
|
1
|
+
{"version":3,"file":"development-guide.js","sourceRoot":"","sources":["../src/development-guide.ts"],"names":[],"mappings":"AAoBA,MAAM,IAAI,GAAG,CAAC,IAAY,EAAE,EAAE,CAAC,uCAAuC,IAAI,EAAE,CAAA;AAC5E,MAAM,QAAQ,GAAG,CAAC,GAAW,EAAE,EAAE,CAAC,kCAAkC,GAAG,EAAE,CAAA;AAEzE,MAAM,CAAC,MAAM,qBAAqB,GAAG,IAAI,CAAC,sBAAsB,CAAC,CAAA;AAEjE,MAAM,CAAC,MAAM,oBAAoB,GAAG;IACnC;QACC,EAAE,EAAE,eAAe;QACnB,OAAO,EAAE,iFAAiF;QAC1F,KAAK,EAAE,CAAC,uBAAuB,EAAE,aAAa,EAAE,0BAA0B,CAAC;QAC3E,MAAM,EAAE,gFAAgF;QACxF,IAAI,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,qBAAqB,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;KAChE;IACD;QACC,EAAE,EAAE,SAAS;QACb,OAAO,EAAE,gFAAgF;QACzF,KAAK,EAAE,CAAC,oBAAoB,EAAE,wBAAwB,CAAC;QACvD,MAAM,EAAE,yFAAyF;QACjG,IAAI,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,EAAE,mCAAmC,EAAE,kCAAkC,CAAC;KACrG;IACD;QACC,EAAE,EAAE,UAAU;QACd,OAAO,EAAE,mFAAmF;QAC5F,KAAK,EAAE;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EAAE,EAAE,CAAC,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE,CAAA;IAC/F,CAAC;IAED,OAAO;QACN,GAAG,IAAI;QACP,QAAQ,EACP,0LAA0L;QAC3L,SAAS,EAAE,eAAe,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC;QACnD,cAAc,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,EAAE,QAAQ,EAAE,CAAC,CAAC;QACtE,QAAQ,EAAE,cAAc,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;YACrC,OAAO,EAAE,EAAE;YACX,OAAO,EAAE,iBAAiB,CAAC,EAAE,CAAC;YAC9B,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAE,IAAI,CAAC,EAAE,CAAwB,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;SACtF,CAAC,CAAC;QACH,iBAAiB,EAChB,gIAAgI;KACjI,CAAA;AACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icon-workflow.d.ts","sourceRoot":"","sources":["../src/icon-workflow.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,MAAM,WAAW,gBAAgB;IAChC,aAAa,CAAC,EAAE,MAAM,CAAA;CACtB;AAED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,gBAAgB,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"icon-workflow.d.ts","sourceRoot":"","sources":["../src/icon-workflow.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,MAAM,WAAW,gBAAgB;IAChC,aAAa,CAAC,EAAE,MAAM,CAAA;CACtB;AAED,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,gBAAgB,GAAG,MAAM,CAuEjE"}
|
package/dist/icon-workflow.js
CHANGED
|
@@ -61,12 +61,25 @@ Extenshi CLI renders an offline verification page. No API key, no credits, no up
|
|
|
61
61
|
\`\`\`
|
|
62
62
|
5. **Install** — the exported \`icons/\` folder is unpacked into the extension and referenced
|
|
63
63
|
from \`manifest.json\` as above.
|
|
64
|
+
6. **Store listing artwork** from the same master (free, offline, WebAssembly renderer):
|
|
65
|
+
|
|
66
|
+
\`\`\`bash
|
|
67
|
+
npx @extenshi/cli@latest icon store-assets ${iconFile} --out store-assets
|
|
68
|
+
\`\`\`
|
|
69
|
+
|
|
70
|
+
Output per store: Chrome Web Store \`icon-128.png\` (96 px artwork, 16 px transparent
|
|
71
|
+
padding), \`promo-small-440x280.png\` (required) and \`marquee-1400x560.png\`; Edge Add-ons
|
|
72
|
+
\`logo-300x300.png\`, \`promo-small-440x280.png\` and \`promo-large-1400x560.png\`; AMO
|
|
73
|
+
\`icon-128.png\`, \`icon-64.png\` and \`icon-32.png\`. Tiles are composed from the icon on a tint
|
|
74
|
+
of its colour; \`--promo\` / \`--marquee\` take full-bleed artwork instead, with a warning when
|
|
75
|
+
content is clipped or the aspect ratio is off.
|
|
64
76
|
|
|
65
77
|
## Related
|
|
66
78
|
|
|
67
79
|
- Hosted AI icon generation (no local tooling needed): https://dojo.extenshi.io/tools/icon-generator
|
|
68
|
-
-
|
|
69
|
-
|
|
80
|
+
- A logo or screenshot for a hosted landing page goes into the project's public media store
|
|
81
|
+
with upload_project_media (CLI: \`npx @extenshi/cli@latest media upload <file> --project <id>\`),
|
|
82
|
+
which returns a stable URL accepted as \`logoUrl\` / \`screenshots[].url\`.
|
|
70
83
|
- Documentation: https://docs.extenshi.io/developers/icon-generator
|
|
71
84
|
`;
|
|
72
85
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icon-workflow.js","sourceRoot":"","sources":["../src/icon-workflow.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAMH,MAAM,UAAU,kBAAkB,CAAC,IAAsB;IACxD,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,EAAE,IAAI,EAAE,IAAI,cAAc,CAAA;IACzD,MAAM,QAAQ,GAAG,UAAU,CAAA;IAC3B,OAAO;;;;;;;;;;;;;;;;;;;;;4CAqBoC,QAAQ;;;;;2CAKT,QAAQ,YAAY,IAAI;;;;;;;kFAOe,QAAQ
|
|
1
|
+
{"version":3,"file":"icon-workflow.js","sourceRoot":"","sources":["../src/icon-workflow.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAMH,MAAM,UAAU,kBAAkB,CAAC,IAAsB;IACxD,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,EAAE,IAAI,EAAE,IAAI,cAAc,CAAA;IACzD,MAAM,QAAQ,GAAG,UAAU,CAAA;IAC3B,OAAO;;;;;;;;;;;;;;;;;;;;;4CAqBoC,QAAQ;;;;;2CAKT,QAAQ,YAAY,IAAI;;;;;;;kFAOe,QAAQ;;;;;;;;;;;;;;;;;gDAiB1C,QAAQ;;;;;;;;;;;;;;;;;CAiBvD,CAAA;AACD,CAAC"}
|
package/dist/pay.d.ts
CHANGED
|
@@ -38,6 +38,13 @@ export declare const paySchemas: {
|
|
|
38
38
|
}, {
|
|
39
39
|
appId: string;
|
|
40
40
|
}>;
|
|
41
|
+
readonly getPayPaymentEvidence: z.ZodObject<{
|
|
42
|
+
appId: z.ZodString;
|
|
43
|
+
}, "strict", z.ZodTypeAny, {
|
|
44
|
+
appId: string;
|
|
45
|
+
}, {
|
|
46
|
+
appId: string;
|
|
47
|
+
}>;
|
|
41
48
|
readonly linkPayApp: z.ZodObject<{
|
|
42
49
|
appId: z.ZodString;
|
|
43
50
|
} & {
|
|
@@ -208,7 +215,7 @@ export type PayMethod = keyof typeof paySchemas;
|
|
|
208
215
|
export type PayBff = {
|
|
209
216
|
[M in PayMethod]: (input: z.infer<(typeof paySchemas)[M]>) => Promise<unknown>;
|
|
210
217
|
};
|
|
211
|
-
export declare const PAY_OPERATIONS: readonly [readonly ["listPayApps", "list_pay_apps", "list", "payApp.list", false, "List your independent Pay applications. No development project required. Paginated: nextCursor is set while more results exist."], readonly ["createPayApp", "create_pay_app", "create", "payApp.create", true, "Create an independent Pay application; linking a development project is optional. Not idempotent: each call creates a new application, including a call repeated after a timeout."], readonly ["getPayApp", "get_pay_app", "get", "payApp.get", false, "Read your Pay application and optional project link."], readonly ["getPayReadiness", "get_pay_readiness", "readiness", "payApp.readiness", false, "Check current checkout and launch prerequisites. A passing checkout check does not prove a live external purchase or SDK publication."], readonly ["linkPayApp", "link_pay_app", "link", "payApp.link", true, "Link your Pay application to your development project. Existing purchases remain attached to the Pay application."], readonly ["unlinkPayApp", "unlink_pay_app", "unlink", "payApp.unlink", true, "Remove the optional development-project link without deleting Pay data."], readonly ["archivePayApp", "archive_pay_app", "archive", "payApp.archive", true, "Archive your application and stop new checkout. Payment records and existing entitlements are preserved."], readonly ["exportPayData", "export_pay_data", "export", "payApp.export", false, "Export one page of one resource (offers, payments, subscriptions, entitlements or customers). nextCursor is null on the last page. The output contains sensitive customer and payment data."], readonly ["getPaySeller", "get_pay_seller", "seller", "paySeller.get", false, "Read seller connection, public profile, offers, the publishable SDK key and the public entitlement verification key. Those two keys are the ones meant to be embedded in extension code; secret keys are not part of the response. Agreement signing and KYC take place in the browser."], readonly ["connectPaySeller", "connect_pay_seller", "connect", "paySeller.connect", true, "Start Stripe Connect onboarding and return a browser action URL. KYC and legal acceptance are completed by the author at that URL; this tool does not perform them."], readonly ["refreshPaySeller", "refresh_pay_seller", "refresh", "paySeller.refreshStatus", true, "Refresh current payment-provider onboarding status. This does not complete KYC or accept agreements."], readonly ["setPaySellerProfile", "set_pay_seller_profile", "profile", "paySeller.setPublicProfile", true, "Save the public seller profile: display name, support URL or email, and terms URL. The values are stored as provided and are publicly visible."], readonly ["upsertPayOffer", "upsert_pay_offer", "offer-upsert", "paySeller.upsertOffer", true, "Create or update an offer keyed by a stable SKU. Price is in minor currency units. Subscriptions keep the given billing interval; one-time and lifetime offers store no interval. Price and features are stored as provided."], readonly ["archivePayOffer", "archive_pay_offer", "offer-archive", "paySeller.archiveOffer", true, "Stop offering a SKU for new checkout; historical purchases are preserved."], readonly ["setPayEnabled", "set_pay_enabled", "enable", "paySeller.setEnabled", true, "Enable or disable new payments for the application; requires a connected payment provider. Enabling re-reads the seller status from the provider (charges and payouts). It does not verify the public profile, agreement or offer sync: buyers can check out only when every readiness check reported by get_pay_readiness passes. Enabling is a live commerce change."], readonly ["rotatePayKey", "rotate_pay_key", "rotate-key", "paySeller.rotatePublishableKey", true, "Generate a new publishable SDK key. Not idempotent: each call issues another key. Prior keys remain accepted for installed extension builds; this does not revoke any secret."]];
|
|
218
|
+
export declare const PAY_OPERATIONS: readonly [readonly ["listPayApps", "list_pay_apps", "list", "payApp.list", false, "List your independent Pay applications. No development project required. Paginated: nextCursor is set while more results exist."], readonly ["createPayApp", "create_pay_app", "create", "payApp.create", true, "Create an independent Pay application; linking a development project is optional. Not idempotent: each call creates a new application, including a call repeated after a timeout."], readonly ["getPayApp", "get_pay_app", "get", "payApp.get", false, "Read your Pay application and optional project link."], readonly ["getPayReadiness", "get_pay_readiness", "readiness", "payApp.readiness", false, "Check current checkout and launch prerequisites. A passing checkout check does not prove a live external purchase or SDK publication."], readonly ["getPayPaymentEvidence", "get_pay_payment_evidence", "payment-evidence", "payApp.paymentEvidence", false, "Read what Extenshi's own payment ledger proves about this application's payment path, per mode: checkout completed, license issued, an installation received the signed license, restored on a second installation, refund revoked. Derived from provider-signed webhooks, not from any report; opaque IDs and timestamps only, no buyer data. Only a live-mode purchase can satisfy a release's payment requirement; test-mode purchases are listed without satisfying it."], readonly ["linkPayApp", "link_pay_app", "link", "payApp.link", true, "Link your Pay application to your development project. Existing purchases remain attached to the Pay application."], readonly ["unlinkPayApp", "unlink_pay_app", "unlink", "payApp.unlink", true, "Remove the optional development-project link without deleting Pay data."], readonly ["archivePayApp", "archive_pay_app", "archive", "payApp.archive", true, "Archive your application and stop new checkout. Payment records and existing entitlements are preserved."], readonly ["exportPayData", "export_pay_data", "export", "payApp.export", false, "Export one page of one resource (offers, payments, subscriptions, entitlements or customers). nextCursor is null on the last page. The output contains sensitive customer and payment data."], readonly ["getPaySeller", "get_pay_seller", "seller", "paySeller.get", false, "Read seller connection, public profile, offers, the publishable SDK key and the public entitlement verification key. Those two keys are the ones meant to be embedded in extension code; secret keys are not part of the response. Agreement signing and KYC take place in the browser."], readonly ["connectPaySeller", "connect_pay_seller", "connect", "paySeller.connect", true, "Start Stripe Connect onboarding and return a browser action URL. KYC and legal acceptance are completed by the author at that URL; this tool does not perform them."], readonly ["refreshPaySeller", "refresh_pay_seller", "refresh", "paySeller.refreshStatus", true, "Refresh current payment-provider onboarding status. This does not complete KYC or accept agreements."], readonly ["setPaySellerProfile", "set_pay_seller_profile", "profile", "paySeller.setPublicProfile", true, "Save the public seller profile: display name, support URL or email, and terms URL. The values are stored as provided and are publicly visible."], readonly ["upsertPayOffer", "upsert_pay_offer", "offer-upsert", "paySeller.upsertOffer", true, "Create or update an offer keyed by a stable SKU. Price is in minor currency units. Subscriptions keep the given billing interval; one-time and lifetime offers store no interval. Price and features are stored as provided."], readonly ["archivePayOffer", "archive_pay_offer", "offer-archive", "paySeller.archiveOffer", true, "Stop offering a SKU for new checkout; historical purchases are preserved."], readonly ["setPayEnabled", "set_pay_enabled", "enable", "paySeller.setEnabled", true, "Enable or disable new payments for the application; requires a connected payment provider. Enabling re-reads the seller status from the provider (charges and payouts). It does not verify the public profile, agreement or offer sync: buyers can check out only when every readiness check reported by get_pay_readiness passes. Enabling is a live commerce change."], readonly ["rotatePayKey", "rotate_pay_key", "rotate-key", "paySeller.rotatePublishableKey", true, "Generate a new publishable SDK key. Not idempotent: each call issues another key. Prior keys remain accepted for installed extension builds; this does not revoke any secret."]];
|
|
212
219
|
/** The legacy seller API uses projectId as the payment namespace. Never substitute a linked project ID. */
|
|
213
220
|
export declare function payWireInput(method: PayMethod, input: Record<string, unknown>): Record<string, unknown>;
|
|
214
221
|
//# sourceMappingURL=pay.d.ts.map
|
package/dist/pay.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pay.d.ts","sourceRoot":"","sources":["../src/pay.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAavB,eAAO,MAAM,UAAU
|
|
1
|
+
{"version":3,"file":"pay.d.ts","sourceRoot":"","sources":["../src/pay.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAavB,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmDb,CAAA;AACV,MAAM,MAAM,SAAS,GAAG,MAAM,OAAO,UAAU,CAAA;AAC/C,MAAM,MAAM,MAAM,GAAG;KAAG,CAAC,IAAI,SAAS,GAAG,CAAC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,OAAO,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,OAAO,CAAC,OAAO,CAAC;CAAE,CAAA;AACvG,eAAO,MAAM,cAAc,u5IAyIjB,CAAA;AAEV,2GAA2G;AAC3G,wBAAgB,YAAY,CAAC,MAAM,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAIvG"}
|
package/dist/pay.js
CHANGED
|
@@ -24,6 +24,7 @@ export const paySchemas = {
|
|
|
24
24
|
.strict(),
|
|
25
25
|
getPayApp: app,
|
|
26
26
|
getPayReadiness: app,
|
|
27
|
+
getPayPaymentEvidence: app,
|
|
27
28
|
linkPayApp: app.extend({ projectId: z.string().uuid() }),
|
|
28
29
|
unlinkPayApp: app,
|
|
29
30
|
archivePayApp: app,
|
|
@@ -95,6 +96,14 @@ export const PAY_OPERATIONS = [
|
|
|
95
96
|
false,
|
|
96
97
|
'Check current checkout and launch prerequisites. A passing checkout check does not prove a live external purchase or SDK publication.',
|
|
97
98
|
],
|
|
99
|
+
[
|
|
100
|
+
'getPayPaymentEvidence',
|
|
101
|
+
'get_pay_payment_evidence',
|
|
102
|
+
'payment-evidence',
|
|
103
|
+
'payApp.paymentEvidence',
|
|
104
|
+
false,
|
|
105
|
+
"Read what Extenshi's own payment ledger proves about this application's payment path, per mode: checkout completed, license issued, an installation received the signed license, restored on a second installation, refund revoked. Derived from provider-signed webhooks, not from any report; opaque IDs and timestamps only, no buyer data. Only a live-mode purchase can satisfy a release's payment requirement; test-mode purchases are listed without satisfying it.",
|
|
106
|
+
],
|
|
98
107
|
[
|
|
99
108
|
'linkPayApp',
|
|
100
109
|
'link_pay_app',
|
package/dist/pay.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pay.js","sourceRoot":"","sources":["../src/pay.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,MAAM,GAAG,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAA;AAC3D,MAAM,GAAG,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,4BAA4B,CAAC,CAAA;AAC1D,MAAM,SAAS,GAAG,CAAC;KACjB,MAAM,EAAE;KACR,IAAI,EAAE;KACN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GAA2G;AAC3G,MAAM,UAAU,YAAY,CAAC,MAAiB,EAAE,KAA8B;IAC7E,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,GAAG,KAAK,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,YAAY,CAAC;QAAE,OAAO,KAAK,CAAA;IAC/F,MAAM,EAAE,KAAK,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,CAAA;IAChC,OAAO,EAAE,GAAG,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,CAAA;AACrC,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Client-side half of `upload_project_media`: turn a tool call into the BFF's
|
|
3
|
+
* `{ mime, dataBase64 }` payload.
|
|
4
|
+
*
|
|
5
|
+
* The BFF is the real gate (magic bytes, metadata stripping, dimension and
|
|
6
|
+
* quota limits). What only the client can decide is WHICH local file may be
|
|
7
|
+
* read at all. The stdio server runs with the developer's filesystem, so a
|
|
8
|
+
* `filePath` is confined to the workspace (the server's working directory):
|
|
9
|
+
* a prompt-injected "upload ~/Pictures/passport.jpg" must not be able to
|
|
10
|
+
* publish an arbitrary personal image to a public bucket. Files elsewhere go
|
|
11
|
+
* through the CLI (`extenshi media upload`), where the path is on the command
|
|
12
|
+
* line in front of the developer.
|
|
13
|
+
*/
|
|
14
|
+
export type ProjectMediaMime = 'image/png' | 'image/jpeg' | 'image/webp';
|
|
15
|
+
export declare const PROJECT_MEDIA_MAX_BYTES: number;
|
|
16
|
+
export declare const PROJECT_MEDIA_MIME_TYPES: readonly ["image/png", "image/jpeg", "image/webp"];
|
|
17
|
+
export declare class ProjectMediaInputError extends Error {
|
|
18
|
+
}
|
|
19
|
+
/** Same signatures the BFF accepts. Anything else (SVG, HTML, GIF) → null. */
|
|
20
|
+
export declare function sniffMediaMime(bytes: Uint8Array): ProjectMediaMime | null;
|
|
21
|
+
/** Read a workspace-local image for upload. `root` is the workspace (default: cwd). */
|
|
22
|
+
export declare function readWorkspaceImage(filePath: string, root?: string): Promise<{
|
|
23
|
+
mime: ProjectMediaMime;
|
|
24
|
+
dataBase64: string;
|
|
25
|
+
bytes: number;
|
|
26
|
+
}>;
|
|
27
|
+
/** Validate an inline payload the same way before it is sent. */
|
|
28
|
+
export declare function checkInlineImage(dataBase64: string, declared: ProjectMediaMime): void;
|
|
29
|
+
//# sourceMappingURL=project-media.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-media.d.ts","sourceRoot":"","sources":["../src/project-media.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAKH,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,YAAY,GAAG,YAAY,CAAA;AAExE,eAAO,MAAM,uBAAuB,QAAkB,CAAA;AACtD,eAAO,MAAM,wBAAwB,oDAAqD,CAAA;AAE1F,qBAAa,sBAAuB,SAAQ,KAAK;CAAG;AAEpD,8EAA8E;AAC9E,wBAAgB,cAAc,CAAC,KAAK,EAAE,UAAU,GAAG,gBAAgB,GAAG,IAAI,CAWzE;AAMD,uFAAuF;AACvF,wBAAsB,kBAAkB,CACvC,QAAQ,EAAE,MAAM,EAChB,IAAI,SAAgB,GAClB,OAAO,CAAC;IAAE,IAAI,EAAE,gBAAgB,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CA2BxE;AAED,iEAAiE;AACjE,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,gBAAgB,GAAG,IAAI,CAMrF"}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Client-side half of `upload_project_media`: turn a tool call into the BFF's
|
|
3
|
+
* `{ mime, dataBase64 }` payload.
|
|
4
|
+
*
|
|
5
|
+
* The BFF is the real gate (magic bytes, metadata stripping, dimension and
|
|
6
|
+
* quota limits). What only the client can decide is WHICH local file may be
|
|
7
|
+
* read at all. The stdio server runs with the developer's filesystem, so a
|
|
8
|
+
* `filePath` is confined to the workspace (the server's working directory):
|
|
9
|
+
* a prompt-injected "upload ~/Pictures/passport.jpg" must not be able to
|
|
10
|
+
* publish an arbitrary personal image to a public bucket. Files elsewhere go
|
|
11
|
+
* through the CLI (`extenshi media upload`), where the path is on the command
|
|
12
|
+
* line in front of the developer.
|
|
13
|
+
*/
|
|
14
|
+
import { readFile, realpath, stat } from 'node:fs/promises';
|
|
15
|
+
import path from 'node:path';
|
|
16
|
+
export const PROJECT_MEDIA_MAX_BYTES = 2 * 1024 * 1024;
|
|
17
|
+
export const PROJECT_MEDIA_MIME_TYPES = ['image/png', 'image/jpeg', 'image/webp'];
|
|
18
|
+
export class ProjectMediaInputError extends Error {
|
|
19
|
+
}
|
|
20
|
+
/** Same signatures the BFF accepts. Anything else (SVG, HTML, GIF) → null. */
|
|
21
|
+
export function sniffMediaMime(bytes) {
|
|
22
|
+
const b = bytes;
|
|
23
|
+
if (b.length >= 8 && b[0] === 0x89 && b[1] === 0x50 && b[2] === 0x4e && b[3] === 0x47)
|
|
24
|
+
return 'image/png';
|
|
25
|
+
if (b.length >= 3 && b[0] === 0xff && b[1] === 0xd8 && b[2] === 0xff)
|
|
26
|
+
return 'image/jpeg';
|
|
27
|
+
if (b.length >= 12 &&
|
|
28
|
+
String.fromCharCode(b[0], b[1], b[2], b[3]) === 'RIFF' &&
|
|
29
|
+
String.fromCharCode(b[8], b[9], b[10], b[11]) === 'WEBP')
|
|
30
|
+
return 'image/webp';
|
|
31
|
+
return null;
|
|
32
|
+
}
|
|
33
|
+
const NOT_AN_IMAGE = 'is not a PNG, JPEG or WebP image (checked by content). SVG is not accepted: rasterize it first ' +
|
|
34
|
+
'(npx @extenshi/cli@latest icon store-assets <file.svg>) or pass an inline logo as logoSvg to publish_landing_page.';
|
|
35
|
+
/** Read a workspace-local image for upload. `root` is the workspace (default: cwd). */
|
|
36
|
+
export async function readWorkspaceImage(filePath, root = process.cwd()) {
|
|
37
|
+
let resolved;
|
|
38
|
+
let rootReal;
|
|
39
|
+
try {
|
|
40
|
+
resolved = await realpath(path.resolve(root, filePath));
|
|
41
|
+
rootReal = await realpath(root);
|
|
42
|
+
}
|
|
43
|
+
catch {
|
|
44
|
+
throw new ProjectMediaInputError(`File not found: ${filePath}`);
|
|
45
|
+
}
|
|
46
|
+
const relative = path.relative(rootReal, resolved);
|
|
47
|
+
if (relative.startsWith('..') || path.isAbsolute(relative)) {
|
|
48
|
+
throw new ProjectMediaInputError(`"${filePath}" is outside the workspace (${rootReal}). upload_project_media only reads files inside it; ` +
|
|
49
|
+
'for other files run `npx @extenshi/cli@latest media upload <file> --project <id>` or send dataBase64.');
|
|
50
|
+
}
|
|
51
|
+
const info = await stat(resolved);
|
|
52
|
+
if (!info.isFile())
|
|
53
|
+
throw new ProjectMediaInputError(`"${filePath}" is not a file.`);
|
|
54
|
+
if (info.size > PROJECT_MEDIA_MAX_BYTES) {
|
|
55
|
+
throw new ProjectMediaInputError(`"${filePath}" is ${(info.size / 1024 / 1024).toFixed(1)} MB; the limit is 2 MB per image.`);
|
|
56
|
+
}
|
|
57
|
+
const bytes = await readFile(resolved);
|
|
58
|
+
const mime = sniffMediaMime(bytes);
|
|
59
|
+
if (!mime)
|
|
60
|
+
throw new ProjectMediaInputError(`"${filePath}" ${NOT_AN_IMAGE}`);
|
|
61
|
+
return { mime, dataBase64: bytes.toString('base64'), bytes: bytes.length };
|
|
62
|
+
}
|
|
63
|
+
/** Validate an inline payload the same way before it is sent. */
|
|
64
|
+
export function checkInlineImage(dataBase64, declared) {
|
|
65
|
+
const bytes = Buffer.from(dataBase64.slice(0, 64), 'base64');
|
|
66
|
+
const mime = sniffMediaMime(bytes);
|
|
67
|
+
if (!mime)
|
|
68
|
+
throw new ProjectMediaInputError(`dataBase64 ${NOT_AN_IMAGE}`);
|
|
69
|
+
if (mime !== declared)
|
|
70
|
+
throw new ProjectMediaInputError(`dataBase64 contains ${mime} but mime says ${declared}.`);
|
|
71
|
+
}
|
|
72
|
+
//# sourceMappingURL=project-media.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-media.js","sourceRoot":"","sources":["../src/project-media.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAA;AAC3D,OAAO,IAAI,MAAM,WAAW,CAAA;AAI5B,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,GAAG,IAAI,GAAG,IAAI,CAAA;AACtD,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,WAAW,EAAE,YAAY,EAAE,YAAY,CAAU,CAAA;AAE1F,MAAM,OAAO,sBAAuB,SAAQ,KAAK;CAAG;AAEpD,8EAA8E;AAC9E,MAAM,UAAU,cAAc,CAAC,KAAiB;IAC/C,MAAM,CAAC,GAAG,KAAK,CAAA;IACf,IAAI,CAAC,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI;QAAE,OAAO,WAAW,CAAA;IACzG,IAAI,CAAC,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI;QAAE,OAAO,YAAY,CAAA;IACzF,IACC,CAAC,CAAC,MAAM,IAAI,EAAE;QACd,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,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C,IAAI,GAAG,uBAAuB,EAAE,CAAC;QACzC,MAAM,IAAI,sBAAsB,CAC/B,IAAI,QAAQ,QAAQ,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,mCAAmC,CAC3F,CAAA;IACF,CAAC;IACD,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,QAAQ,CAAC,CAAA;IACtC,MAAM,IAAI,GAAG,cAAc,CAAC,KAAK,CAAC,CAAA;IAClC,IAAI,CAAC,IAAI;QAAE,MAAM,IAAI,sBAAsB,CAAC,IAAI,QAAQ,KAAK,YAAY,EAAE,CAAC,CAAA;IAC5E,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,MAAM,EAAE,CAAA;AAC3E,CAAC;AAED,iEAAiE;AACjE,MAAM,UAAU,gBAAgB,CAAC,UAAkB,EAAE,QAA0B;IAC9E,MAAM,KAAK,GAAG,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,QAAQ,CAAC,CAAA;IAC5D,MAAM,IAAI,GAAG,cAAc,CAAC,KAAK,CAAC,CAAA;IAClC,IAAI,CAAC,IAAI;QAAE,MAAM,IAAI,sBAAsB,CAAC,cAAc,YAAY,EAAE,CAAC,CAAA;IACzE,IAAI,IAAI,KAAK,QAAQ;QACpB,MAAM,IAAI,sBAAsB,CAAC,uBAAuB,IAAI,kBAAkB,QAAQ,GAAG,CAAC,CAAA;AAC5F,CAAC"}
|
package/dist/publish.d.ts
CHANGED
|
@@ -27,6 +27,12 @@ export interface StoreCredentials {
|
|
|
27
27
|
};
|
|
28
28
|
}
|
|
29
29
|
export declare const ENV_DOCS: Record<StoreType, string[]>;
|
|
30
|
+
/**
|
|
31
|
+
* Store credentials, with an explicitly stated AMO add-on id filling
|
|
32
|
+
* FIREFOX_ADDON_GUID when the environment has none. A different environment
|
|
33
|
+
* value is refused: one run publishes to one add-on id.
|
|
34
|
+
*/
|
|
35
|
+
export declare function storeCredentialsFor(addonId?: string, env?: NodeJS.ProcessEnv): StoreCredentials;
|
|
30
36
|
export declare function readStoreCredentials(env?: NodeJS.ProcessEnv): StoreCredentials;
|
|
31
37
|
export declare function credentialsHelp(stores: StoreType[]): string;
|
|
32
38
|
export interface PublishArgs {
|
|
@@ -34,9 +40,104 @@ export interface PublishArgs {
|
|
|
34
40
|
stores?: StoreType[];
|
|
35
41
|
firefoxArtifactPath?: string;
|
|
36
42
|
releaseNotes?: string;
|
|
43
|
+
/** Explicit AMO add-on id; fills FIREFOX_ADDON_GUID when the environment has none. */
|
|
44
|
+
addonId?: string;
|
|
45
|
+
/** Listed AMO submission with metadata instead of a version-only upload. */
|
|
46
|
+
firefoxListing?: {
|
|
47
|
+
listingPath: string;
|
|
48
|
+
sourcePath?: string;
|
|
49
|
+
screenshotsDir?: string;
|
|
50
|
+
/** Resolved by amoCreateAllowed — creating an add-on fixes its id permanently. */
|
|
51
|
+
allowCreate: boolean;
|
|
52
|
+
replaceScreenshots?: boolean;
|
|
53
|
+
};
|
|
37
54
|
}
|
|
38
55
|
export declare class PublishSetupError extends Error {
|
|
39
56
|
}
|
|
57
|
+
/**
|
|
58
|
+
* Whether this call may CREATE a new AMO add-on. With a project, its
|
|
59
|
+
* owner-decided `amo.addonId` governs (and a different FIREFOX_ADDON_GUID is
|
|
60
|
+
* refused). Without one, `allowNewAddon` is the switch and `addonId` has to
|
|
61
|
+
* state the id explicitly — it is never taken silently from the environment.
|
|
62
|
+
* Mirrors the CLI's gate.
|
|
63
|
+
*/
|
|
64
|
+
export declare function amoCreateAllowed(opts: {
|
|
65
|
+
addonGuid: string;
|
|
66
|
+
allowNewAddon?: boolean;
|
|
67
|
+
addonId?: string;
|
|
68
|
+
projectId?: string;
|
|
69
|
+
decision?: {
|
|
70
|
+
status: string;
|
|
71
|
+
value: unknown;
|
|
72
|
+
} | null;
|
|
73
|
+
}): boolean;
|
|
74
|
+
/** Load the listing, source and screenshots for a listed AMO submission. */
|
|
75
|
+
export declare function loadFirefoxListing(listing: NonNullable<PublishArgs['firefoxListing']>): {
|
|
76
|
+
listing: {
|
|
77
|
+
defaultLocale: string;
|
|
78
|
+
explicitDefaultLocale: boolean;
|
|
79
|
+
name: {
|
|
80
|
+
[x: string]: string;
|
|
81
|
+
};
|
|
82
|
+
summary: {
|
|
83
|
+
[x: string]: string;
|
|
84
|
+
};
|
|
85
|
+
description: {
|
|
86
|
+
[x: string]: string;
|
|
87
|
+
} | undefined;
|
|
88
|
+
developerComments: {
|
|
89
|
+
[x: string]: string;
|
|
90
|
+
} | undefined;
|
|
91
|
+
homepage: {
|
|
92
|
+
[x: string]: string;
|
|
93
|
+
} | undefined;
|
|
94
|
+
supportEmail: {
|
|
95
|
+
[x: string]: string;
|
|
96
|
+
} | undefined;
|
|
97
|
+
supportUrl: {
|
|
98
|
+
[x: string]: string;
|
|
99
|
+
} | undefined;
|
|
100
|
+
privacyPolicy: {
|
|
101
|
+
[x: string]: string;
|
|
102
|
+
} | undefined;
|
|
103
|
+
eula: {
|
|
104
|
+
[x: string]: string;
|
|
105
|
+
} | undefined;
|
|
106
|
+
releaseNotes: {
|
|
107
|
+
[x: string]: string;
|
|
108
|
+
} | undefined;
|
|
109
|
+
customLicense: {
|
|
110
|
+
name: {
|
|
111
|
+
[x: string]: string;
|
|
112
|
+
};
|
|
113
|
+
text: {
|
|
114
|
+
[x: string]: string;
|
|
115
|
+
};
|
|
116
|
+
} | undefined;
|
|
117
|
+
screenshots: {
|
|
118
|
+
file: string;
|
|
119
|
+
caption: {
|
|
120
|
+
[x: string]: string;
|
|
121
|
+
} | undefined;
|
|
122
|
+
}[] | undefined;
|
|
123
|
+
categories: string[];
|
|
124
|
+
tags?: string[] | undefined;
|
|
125
|
+
slug?: string | undefined;
|
|
126
|
+
requiresPayment?: boolean | undefined;
|
|
127
|
+
contributionsUrl?: string | undefined;
|
|
128
|
+
license?: string | undefined;
|
|
129
|
+
approvalNotes?: string | undefined;
|
|
130
|
+
compatibility?: ("firefox" | "android")[] | Partial<Record<"firefox" | "android", {
|
|
131
|
+
min?: string | undefined;
|
|
132
|
+
max?: string | undefined;
|
|
133
|
+
}>> | undefined;
|
|
134
|
+
addonId?: string | undefined;
|
|
135
|
+
};
|
|
136
|
+
sourceFilePath: string | undefined;
|
|
137
|
+
screenshotPaths: string[] | undefined;
|
|
138
|
+
allowCreate: boolean;
|
|
139
|
+
replaceScreenshots: boolean;
|
|
140
|
+
};
|
|
40
141
|
export declare function publishArtifact(args: PublishArgs): Promise<UniversalPublishResult>;
|
|
41
142
|
export declare function validateStoreCredentials(stores?: StoreType[]): Promise<Array<{
|
|
42
143
|
store: StoreType;
|
package/dist/publish.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"publish.d.ts","sourceRoot":"","sources":["../src/publish.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;
|
|
1
|
+
{"version":3,"file":"publish.d.ts","sourceRoot":"","sources":["../src/publish.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,OAAO,EAKN,KAAK,SAAS,EACd,KAAK,sBAAsB,EAC3B,MAAM,qBAAqB,CAAA;AAG5B,MAAM,WAAW,gBAAgB;IAChC,MAAM,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,YAAY,EAAE,MAAM,CAAC;QAAC,YAAY,EAAE,MAAM,CAAA;KAAE,CAAA;IACxF,OAAO,CAAC,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,CAAA;IACrE,IAAI,CAAC,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,YAAY,EAAE,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