- I have a challenge in which i need to save a value and use it later for concurrent users.
- I have tried by using $request->ip() to store in DB and can retrieve--> Failed since its not in same network
- Browsed and found one more solution with Session and Cookie --> Failed since its rest API
- Tried apc_store cache method in php --> giving error undefined method in php 7 (laravel 7)
Save Value : This endpoint should allow the user to save a value for later use.
Method: POST
Endpoint: /save
Body: {"value": 12}
Response : {"save": true}
Retrieve Value This endpoint should return the saved value
Method: GET
Endpoint: /savedValue
Response : {"value": 12}]
Can anyone give me a solution for this please
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire