# Create a new session and store it as a JSON document > JSON.SET session:12345 . ‘{“user_id”: 1001, “login_time”: “2024-02-27T10:00:00Z”, “data”: {“last_page_visited”: “/home”, “preferences”: {“theme”: “dark”}}}’ “OK” # Fetch the entire session > JSON.GET session:12345 “{\”user_id\”:1001,\”login_time\”:\”2024-02-27T10:00:00Z\”,\”data\”:{\”last_page_visited\”:\”/home\”,\”preferences\”:{\”theme\”:\
![Redis - The Real-time Data Platform](https://cdn-ak-scissors.b.st-hatena.com/image/square/4de8e5e9b4e469d8aed69b7a4acf520c44194008/height=288;version=1;width=512/https%3A%2F%2Fredis.io%2Fwp-content%2Fuploads%2F2021%2F08%2Fredis-social-1200x628-1.jpg)