Testing an HTTP API in a published app

I have a published app with a custom domain. As I develop an HTTP API endpoint and test that using curl, do I need to publish the changes for the API endpoint to be visible/available? I would think not since the API requests are routed to my app at my custom domain.

I’m getting “No matching endpoint” even with the simplest example from the documentation.

Update: It would appear that I do in fact have to publish each API code edit for the app to respond

Yes, once you’ve published an app any use of that app outside of the IDE will use the published version, not the most current version. As you’ve found, that includes API changes.

That makes it hard to have a published and test version for APIs; you pretty much have to go the route of having separate apps and synchronizing changes using git.