Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

simsar78's avatar

Communicate two Laravel projects from api.

Hello, i have two project with Laravel 9 on two separate server.

One project have auth login function with users table and all page is protected.

In the second project don't have a user table.

I need to consume api on the second project from first.

I need to accesso a second project whit secure mode.

Which is the best solution to implement?

0 likes
2 replies
MohamedTammam's avatar

It's a solution but I don't know whether it's the best or not.

You can only allow requests from you server API in the network config.

Sinnbeck's avatar

Set up an api and store some kind of key in env and only allow calls from that

Please or to participate in this conversation.