sinevia / php-library-serverless
PHP Library Serverless
v1.9.0
2020-03-08 09:02 UTC
README
PHP Library Serverless
Library to help with serverless function development
Openwhisk
Sets the $_REQUEST and $_SERVER global variables from the arguments passed to the function.
\Sinevia\Serverless::openwhisk($args);
Session
Serverlsess does not support session out of the box. To replicate this functionality the following may be used together with the Sessions plugin which will save the the sessions in the database.
- Initiate session
Sinevia\Serverless::sessionStart();
- Session ID
\Sinevia\Serverless::sessionId();
- Set Session Variable
\Sinevia\Serverless::sessionSet('UserName', 'Sarah');
- Get Session Variable
$userName = \Sinevia\Serverless::sessionGet('UserName');