scratch-api-unofficial-docs
scratch-api-unofficial-docs copied to clipboard
Add new studio API
Now that studios have been moved over to scratch-www from scratchr2, all of the comments, projects, activity, and curator APIs are accessible in a JSON format just like the rest of 3.0. The general format mostly seems to duplicate the existing Projects API. Just by looking at network requests that the studio page makes, I've gathered most of the endpoints:
- GET
/studios/1234567/projects/?limit=40&offset=0
- GET
/studios/1234567/comments/?limit=40&offset=0
- GET
/studios/1234567/curators/?limit=40&offset=0
- GET
/studios/1234567/managers/?limit=40&offset=0
- GET
/studios/1234567/activity/?limit=40&dateLimit=2021-06-05T13%3A39%3A30.000Z
And I have a few notes:
- It's safe to say that the limit and offset parameters perform the same way as on the project page.
- The
activity
request has a strange parameter calleddateLimit
which I believe is a URI-encoded Javascript date object. If I had to guess I'd say it shows any activity later than the specified date, regulated by thelimit
parameter. Edit: I was correct - see this line from scratch-www. - I have not investigated any of the POST-based endpoints yet. To-do!
After further research, it appears that promotion, inviting, and removing curators has not moved away from the site-api
endpoint (source).