File tree Expand file tree Collapse file tree 3 files changed +8
-1
lines changed
Expand file tree Collapse file tree 3 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -51,3 +51,6 @@ CONNECT_SECRET=
5151CONNECT_AUTORIZE = https://vatsim-germany.org/oauth/authorize
5252CONNECT_TOKEN = http://hp.vatsim-germany.org/oauth/token
5353CONNECT_USER = http://hp.vatsim-germany.org/oauth/userinfo
54+
55+ HOMEPAGE_API_KEY =
56+ STATSIM_API_KEY = FNLb3Dg3xceuAbJFc6sEKBzgXb25dFDzhr4Ym4x4
Original file line number Diff line number Diff line change @@ -52,9 +52,12 @@ public function check(Request $request)
5252 'to ' => $ to ,
5353 ]);
5454 $ url = "$ apiUrl? $ query " ;
55+ $ key = config ('myconfig.statsim_api_key ' );
5556
5657 try {
57- $ response = Http::acceptJson ()->get ($ url );
58+ $ response = Http::withHeaders ([
59+ 'X-API-Key ' => $ key ,
60+ ])->acceptJson ()->get ($ url );
5861 } catch (ConnectionException ) {
5962 return Inertia::flash ('checkResult ' , [
6063 'leg_id ' => $ validated ['leg ' ],
Original file line number Diff line number Diff line change 22
33return [
44 "homepage_api_key " => env ('HOMEPAGE_API_KEY ' ),
5+ "statsim_api_key " => env ('STATSIM_API_KEY ' ),
56];
You can’t perform that action at this time.
0 commit comments