- Repository: github.com/SkyvexSoftware/stratos-core-api
- Latest release: GitHub Releases
- API reference: Stratos VA API: full endpoint contract, useful when you’re forking the module or implementing the same surface in a non-phpVMS stack
- License: MIT
What it adds
The module mounts these endpoints under/api/stratos on your phpVMS install. All require a Bearer token (the pilot’s users.api_key) except the handshake and the credentials sign-in.
users, flights in flights and acars, PIREPs in pireps, custom metadata in pirep_field_values. The module owns zero tables of its own: uninstalling it leaves your phpVMS database exactly as it was.
Install
You’ll need a working phpVMS 7 install with admin access.1
Download the module
Grab the latest
module.zip from the releases page.2
Upload via the admin UI
In your phpVMS admin, navigate to Admin → Modules → Add New Module. Upload the
module.zip you just downloaded. phpVMS will extract it into your modules/StratosCore/ directory automatically.3
Enable the module
Back on the Modules list, find
StratosCore and click Enable.4
Clear caches (before phpVMS 7.0.10)
phpVMS 7.0.10 and newer flush the module caches when you install or enable a module, so skip this step.On an older phpVMS 7 release, the new module’s routes only appear once the module manifest cache’s 6-hour TTL expires. Flush it from Admin → Maintenance → Clear all caches, or from a shell on your phpVMS server:
5
Verify
Hit your handshake endpoint in a browser or with You should get a JSON response like:If you get a 404 or the phpVMS welcome page, the caches are stale: use Admin → Maintenance → Clear all caches (or
curl:php artisan route:clear && php artisan optimize:clear) and check again.Point your airline at it
In the Skyvex Software portal, open your airline’s Settings → Connection:- Stratos endpoint URL: your phpVMS URL plus
/api/stratos, for examplehttps://crew.yourva.com/api/stratos. Click Verify: Skyvex Software checks the handshake endpoint, and the address only goes live for pilots once it passes. - Sign-in: pilots use their phpVMS username and password by default. To use OAuth instead, fill in OAuth set-up and pass Test sign-in (see OAuth on your phpVMS install).
Pilot authentication
Pilots authenticate to the Core API with their phpVMS-issuedapi_key. The flow is:
- Pilot signs into your phpVMS site, generates an API key on their profile page (or your VA does it for them on first onboarding).
- The Stratos desktop client either prompts the pilot for that key directly (credentials mode), or completes an OAuth flow that returns it (OAuth mode: recommended, see OAuth Setup).
- Every subsequent Stratos API call sends the key as
Authorization: Bearer <api_key>.
StratosAuth middleware resolves the key against the users.api_key column and attaches the user to the request. Downstream Stratos modules (such as the Stratos Logbook API) reuse the same middleware: pilots authenticate once.
Troubleshooting
Class "Modules\\StratosCore\\Providers\\..." not found after install
phpVMS caches the module manifest in bootstrap/cache/stratos_core_module.php and in Laravel’s main cache under the phpvms-modules key. If you installed the module but those caches are stale, phpVMS will try to instantiate provider classes from a path that doesn’t yet exist on disk. phpVMS 7.0.10 and newer flush them on install and enable, so this mostly affects older releases.
Fix: Admin → Maintenance → Clear all caches, or:
bootstrap/cache/stratos_core_module.php manually and re-run the command.
Endpoints return 404 but the module shows as enabled
The route cache hasn’t picked up the new module (most often before phpVMS 7.0.10). Use Admin → Maintenance → Clear all caches, or run:Pilots get 401 with a valid API key
Confirm:- The
Authorizationheader is exactlyBearer <key>(case-sensitive scheme, single space, no quotes around the key) - The key matches the value in
users.api_keyfor the pilot - The pilot’s account is active (
users.state = 1)
storage/logs/laravel.log for the auth attempt: StratosAuth logs failures with the offending header for diagnosis.
Updating
Releases go out via the GitHub release feed. To update an existing install:- Download the new
module.zip. - Admin → Modules → Add New Module: upload it. phpVMS will overwrite the existing files in place; your
modules.enabledrow is preserved. - Run
php artisan optimize:clear.
Contributing
The repo accepts PRs. Bug reports go in Issues: please include the phpVMS version, PHP version, and a relevant snippet fromstorage/logs/laravel.log.