Vatsim-Scandinavia / controlcenter

Training Management System created by VATSIM Scandinavia
https://docs.vatsca.org/controlcenter/
GNU General Public License v3.0
15 stars 14 forks source link

Move to VATSIM API v2 #808

Open blt950 opened 4 months ago

blt950 commented 4 months ago

VATSIM is no longer issuing v2 keys. Update our API calls to thew new API.

bedrich-schindler commented 4 months ago

@blt950 Still waiting for VATSIM API key for v2. When obtained, I will jump onto it.

blt950 commented 4 months ago

Could be we need to support both v1 and v2 in a transition period to not block others of upgrading.

blt950 commented 4 months ago

Roster is in place and rating times.

What's left is the activity counter. In v1 we could restrict it to only return sessions from a given date to today, but now that's not possible - we can only limit amount in the reply. Waiting reply from VATSIM Tech if this will be implemented, otherwise we need to just ask for whole log and go through a long history and filter the dates as well ...

bedrich-schindler commented 4 months ago

@blt950 Thanks! I just updated necessary parts to v2 (which require auth) and left the rest as I've found out same problem with the filters as you. Tech team seems busy, so it was on purpose. But thank you anyway. If you want me to finish the rest when API Core is ready, just let me know.

(First PR was a little wild from my side as I am not active PHP developer anymore and I am used to be controller by PHP PSRs, linters and static analyzers which have totally different setup than used in CC. I will do my best in future PRs :) )

blt950 commented 4 months ago

Thanks anyway. It's not that urgent, so I guess we'll just await this last change until they implement it. Until then the v1 API just for this call specifically works fine, and is better than doing a temporary workaround due to missing functionality.