HTTP API Requests

,

Hey!

I just started developing in the Playdate SDK. I Find it very cool so far, but the only feature I am disappointed at not having is HTTP requests.
I am planning on making a weather app and a social media client. I know that you can use playdate.simulator.getURL(url) in the simulator, but I would like more functionality.
Here are some example of requests:

  • playdate.requests.get("https://api.wasteof.money/session", json = {"username": username, "password": password})
  • playdate.requests.post("https://api.wasteof.money/posts", headers = {"token": token, "content": content})
  • And other types of requests, such as PUT, DELETE, PATCH, etc.
  • Websockets:
playdate.socketio.connect("https://api.wasteof.money", {"authorization": token})

function playdate.socketio.onevent("updateMessageCount")
  -- get new messages
end
1 Like

It's definitely something we'd like to do, but we need to figure out the best way to do it while balancing performance, security, battery life, and other concerns. Wish I had a better answer!

4 Likes

When could we expect this to be released?