Run Flask alongside PHP [sharing session]
I'm not sure this is the answer you are looking for, but I would not try to have the Flask API access session data from PHP. Sessions and API do not go well together, a well designed API does not need sessions, it is instead 100% stateless.
What I'm going to propose assumes both PHP and Flask have access to the user database. When the user logs in to the PHP app, generate an API token for the user. This can be a random sequence of characters, a uuid, whatever you want, as long as it is unique. Write the token to the user database, along with an expiration date if you like. The login process should pass that token back to the client (use https://, of course).
When the client needs to make an API call, it has to send that token in every request. For example, you can include it in the Authorization header, or you can use a custom header as well. The Flask API gets the token and searches the user database for it. If it does not find the token, it returns 401. If the token is found, it now knows who the user is, without having to share sessions with PHP. For the API endpoints you will be looking up the user from the token for every request.
Hope this helps!
As the title says, I’ am trying to run Flask alongside a PHP app.
Both of them are running under Apache 2.4 on Windows platform. For Flask I’m using wsgi_module.
The Flask app is actually an API. The PHP app controls users login therefore users access to API. Keep in mind that I cannot drop the use of the PHP app because it controls much more that the logging functionality [invoicing, access logs etc].
The flow is:

User logs in via PHP app
PHP stores user data to a database [user id and a flag indicating if user is logged in]
User makes a request to Flask API
Flask checks if user data are in database: If not, redirects to PHP login page, otherwise let user use the Flask API.

I know that between steps 2 and 3, PHP have to share a session variable-cookie [user id] with Flask in order Flask app to check if user is logged in.
Whatever I try fails. I cannot pass PHP session variables to Flask. 
I know that I can’t pass PHP variables to Flask, but I’m not sure for that.
Has anyone tried something similar? 
What kind of user login strategy should I implement to the above setup?