Skip to content
← Back to Community
Anyone Know how to use Repl.it Database Proxy?
Profile icon
LAMAQDAHODWALA

For those who don't know, Repl.it Database is a database for your repls that is built into the project. However, the only method of sharing this data between repls is called "web hosting", where there is one database that stores everything. Can someone help me pick apart how to use this feature?

Database Proxy: https://repl.it/@util/Replit-Database-proxy

Answered by SixBeeps [earned 5 cycles]
View Answer
Voters
Profile icon
SIDDHARTHANEVR1
Profile icon
LAMAQDAHODWALA
Comments
hotnewtop
Profile icon
RYANTADIPARTHI

i think it needs to be hosted somewhere first

Profile icon
LAMAQDAHODWALA
Profile icon
RYANTADIPARTHI

@LAMAQDAHODWALA like for example you could host it on heroku.com. That would be a good option, since you can do your web hosting there.

Profile icon
LAMAQDAHODWALA

So your saying, go to this site, and make the database there? I need the repl.it Database though. @RYANTADIPARTHI

Profile icon
SixBeeps

@RYANTADIPARTHI The Repl.it Database is a local option, no need to set up extra hosting.

Profile icon
LAMAQDAHODWALA

Do you know how to use the proxy? @SixBeeps

Profile icon
SixBeeps

@LAMAQDAHODWALA You'll want to fork the Repl first so that it uses its own database.
From there, you'll just make HTTP requests to that Repl to interact with it. Attach a key name to the end of the url to get the value of a specific key ("some.url.com/keyname")

Profile icon
LAMAQDAHODWALA

requests? HTTP?!? faints...thanks for the [email protected]

Profile icon
SixBeeps

@LAMAQDAHODWALA Ah c'mon, HTTP ain't that bad!

Profile icon
[deleted]

@SixBeeps what about creating a key

Profile icon
SixBeeps

@snekattack You'd just SET the value at the key name
Also, please avoid necroing and make a new Ask post if you have further questions.

Profile icon
AdvayM

@SixBeeps could you share the exact code you use to make the requests because I don't know lots about python.

Profile icon
SixBeeps

@AdvayM I won't share any code since I rarely ever use Python for this kind of thing, but give the requests library manual a read.
Also, much like the comment above yours, please avoid necroing and make a new Ask post if you have further questions.

Profile icon
JacobRiojas

hjbbkbk