I'm using Ionic 3, connecting to a simple PHP api. First I ran into problems with CORS, but could resolve them by using a proxy like this:
{
  "name": "demoApp",
  "integrations": {
    "cordova": {}
  },
  "type": "ionic-angular",
  "proxies": [
    {
      "path": "/mapi",
      "proxyUrl": "https://external.domain.com/mapi"
    }
  ]
}
Everything works just fine when testing inside a browser using ionic serve. However when running in the emulator (both ios and android), or an actual device, I receive an 404 error on a clean and simple GET  request.
Also running a --prod version inside a webbrowser (like so: ionic cordova run browser --prod -l -c) will return the same 404 not found.
The actual error I receive is:
Http failure response for http://localhost:8000/mapi/test: 404 Not Found
Can somebody point me in the right direction here?
Ionic info:
Ionic:
   ionic (Ionic CLI)  : 4.1.2 (/usr/local/lib/node_modules/ionic)
   Ionic Framework    : ionic-angular 3.9.2
   @ionic/app-scripts : 3.2.0
Cordova:
   cordova (Cordova CLI) : 8.0.0
   Cordova Platforms     : android 7.0.0, browser 5.0.4, ios 4.5.4
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.0.5, cordova-plugin-ionic-webview 1.2.0, (and 5 other plugins)
System:
   Android SDK Tools : 25.1.7 (/Users/Vincent/Library/Android/sdk)
   ios-deploy        : 1.9.2
   NodeJS            : v9.1.0 (/usr/local/bin/node)
   npm               : 6.4.1
   OS                : macOS High Sierra
   Xcode             : Xcode 9.4.1 Build version 9F2000
 
     
    