Share your repls and programming experiences

← Back to all posts
🔴[NEW]🔴 Python Lib for www.jsonstore.io. DON'T LOSE YOUR DATA AGAIN WITH JSON STORE 🔴[NEW]🔴
h
leon332157

🔴[NEW]🔴 Python Lib for www.jsonstore.io. DON'T LOSE YOUR DATA AGAIN WITH JSON STORE 🔴[NEW]🔴
This is a client to interact with www.jsonstore.io , an online json storage platform.
GitHub repo: https://github.com/leon332157/json-store-client 🔴STAR IT NOW 🔴 :star: :star: :star:

Installation

Add 'json-store-client' to your requirement.txt

Usage

json-store-client API

json_store_client.Client(token)

Returns the client to use for data operations.

token (str): The API token from jsonstore.io

client.store(key, data[, timeout])

Storing data in jsonstore with a key

key (str): The key to be stored on jsonstore
data (any): The data to be stored under the key. It can be any Python objects. Will be processed with jsonpickle
timeout (int): The timeout for the http request. Default 5 seconds

client.retrieve(key[, timeout])

Retrieve data in jsonstore with a key

key (str): The key to get on jsonstore
timeout (int): The timeout for the http request. Default 5 seconds

client.delete(key[, timeout])

Delete data in jsonstore with a key

key (str): The key to get on jsonstore
timeout (int): The timeout for the http request. Default 5 seconds
Voters
programmeruser
ObiVibKenobi
BenjaminNamika1
LoneAce
dotcomboom
Muhammad_SJC
ash15khng
MarcusWeinberger
mkhoi
c4syner
Comments
hotnewtop
leon332157

Hey everyone, I am aware with the issue of this library, fortunately I think the problem is on jsonstore's side. I'm sorry for any data loss that might have happened. If jsonstore resolves the issue, I would fix it asap. Thanks.

BenjaminNamika1

@leon332157 Thanks...
rip it broke for me right before my midterm project, which uses it for a live server, luckily my teach said i could present it on another day...
when do you think that it will be fixed

BenjaminNamika1

@leon332157 When do you think it will be back online

TimothyAnderso1

Dude you are my god

AmeliaBlackwell

thanks so much!!! I used this in my fishing game https://repl.it/talk/challenge/The-Fishing-Game/12016. though like thedrone said, error messages for timeout errors would be good as I found 5s was often too short. easily fixed with a try loop thing though :)

leon332157

Guys, the highly requested async version is out, check out the project at https://pypi.org/manage/project/json-store-client/release/1.0.2/ and https://github.com/leon332157/json-store-client

eankeen

Nice! I'm working on one for JS also! Yours works great!

TheDrone7

Wait, it really doesn't have error messages! I thought leon could've easily come up with that.

Python3D1

Can i replace an already existing key Data with client.store?

Foster_Bryant

Situational Irony.

BenjaminNamika1

Yay it is working

BenjaminNamika1

@leon332157 Jsonstore isn't working,
this might help "ok" : false

TimothyAnderso1

Whenever I try to use this outside of Repl.it I get this error:
'User-Agent': f'Mozilla/5.0 Python/json-store-client/{self.version}'
Its the same error even when using "from json_store_client import *"

leon332157

@TimothyAnderso1 Can you send a full traceback to me so i can fix it?

TimothyAnderso1

@leon332157 Traceback (most recent call last):
File "C:\Users\me\Desktop\testy.py", line 1, in <module>
from json_store_client import *
File "C:\Users\me\AppData\Local\Programs\Python\Python35\lib\site-packages\json_store_client__init__.py", line 77
'User-Agent': f'Mozilla/5.0 Python/json-store-client/{self.version}'
^
SyntaxError: invalid syntax

TimothyAnderso1

Hello? just replying just in case you didnt see this as its been 27 days, im also on windows 10 just so you know @leon332157

ironweb

eon332157 I love you this is amazing

HarperframeInc

not working @leon332157

https://storage.googleapis.com/replit/images/1557962865528_8add8ade22818ba0b3ededc3babbfc9e.pn

leon332157

Looks like a jsonstore problem with their server @HarperframeInc

HarperframeInc

@leon332157 Who owns JSONstore?

leon332157

https://github.com/bluzi/jsonstore. HOWEVER, I wouldn’t recommend jsonstore in comparison to mongo db @HarperframeInc

HarperframeInc
chocolatejade42

Could you make an aiohttp version too for discord because requests is supposed to be blocking

phanirithvij

I think there should also be search and error messages in case of requesting anything which doesn't exist. like client.get('a')