web-ext icon indicating copy to clipboard operation
web-ext copied to clipboard

Upload to Edge store

Open Valodim opened this issue 3 years ago • 2 comments

Hey folks,

thanks for developing this package, super useful for deployment of web extensions via CI :v:

There is now finally an API to upload extensions to the edge extension store: https://docs.microsoft.com/en-us/microsoft-edge/extensions-chromium/publish/api/using-addons-api

It would be great if web-ext supported this API. At first glance this looks straightforward to do - retrieve an OAuth token and POST the zip.

Valodim avatar Jul 23 '22 13:07 Valodim

If desired, this could be further simplified by using the suggested library at https://github.com/PlasmoHQ/edge-addons-api instead of plain http requests:

import { EdgeAddonsAPI } from "@plasmohq/edge-addons-api"

const client = new EdgeAddonsAPI({
  productId,
  clientId,
  clientSecret,
  accessTokenUrl
})

await client.submit({
  filePath: "./dist/my-extension.zip",
  notes: "Developer notes"
})

The only issue I see here is that web-ext supports a minimum of node v14 and the library requires v16.

luskaner avatar Oct 05 '22 09:10 luskaner

The only issue I see here is that web-ext supports a minimum of node v14 and the library requires v16.

This lib uses got as well, which is not what web-ext uses at the moment (it uses node-fetch).

Anyway that looks promising. We recently added code to support uploads on AMO so there might be an opportunity to make that part a bit more generic to allow uploads to the Edge store as well.

willdurand avatar Oct 05 '22 12:10 willdurand