Cannot Connect to Custom API on Localhost

Okay, I figured it out.

I can indeed setup a localhost app host. When I did that, the studio.plasmic.app’s HTTP REST API Fetcher component started magically working.

Here’s the short version of how I got it to work:

  1. Published my app from the studio.plasmic.app
  2. With node installed (used the one in .tool-versions), ran npx create-plasmic-app@latest in a folder of my choice.
  3. Configured the app. Chose default everything.
  4. Ran npm run dev
  5. In plasmic studio, hit the triple dots in the project dropdown, selected configure custom app host.
  6. Changed https to http, and typed out localhost:3000/plasmic-host
  7. Success

Source 1: Cannot make integration API calls - Plasmic Studio Questions - Plasmic Community

Source 2: New Plasmic codebase (CLI) | Learn Plasmic

Source 3: Host Plasmic Studio in your app | Learn Plasmic

Originally, my app wasn’t published, but once I cleared the app host, published, and selected http instead of https, it worked.

1 Like