Shopify embedded admin app with App Bridge, hosted as static files

781 Views Asked by At

Is it possible to host the Shopify admin app's frontend part on a CDN/static-like on S3 bucket?

I want to use the NestJS framework for the API part and in a separate codebase (and under different domain) have frontend of the admin panel in React (React Admin). However, in the Shopify App Setup I can only provide a single app url.

  • If I provide frontend, it doesn't go through API and is missing quite some functionality (like checking authentication, installing, etc.).
  • If I provide API's base url, then I get an error that origins don't match when redirected to frontend.

Only solution I see is creating a proxy under NestJS after authentication, but then it doesn't make sense to host it under CDN anymore. Is there an alternative or we're stuck with what Shopify allows us to do? (I really do hope I'm wrong or missing something)

1

There are 1 best solutions below

1
On

Shopify App Setup asks for the homepage of your app. The "API part" will need the authentication code that can be given by the frontend (or stored in configuration if it's a custom app).

So you should use the frontend page in the setup app and build the backend as you wish.

So the answer is yes, you can put your frontend on an S3 if you want. But you will need the authentication code that Shopify will pass you when you connect.