RiiConnect24 / RiiTag-Next

A customizable Gamertag for Wii, Wii U and more! Now powered by Next.js.
https://tag.rc24.xyz
GNU Affero General Public License v3.0
15 stars 12 forks source link

Public API #17

Open Brawl345 opened 1 year ago

Brawl345 commented 1 year ago

There should be a public API where developers can read the tag info in a machine-readable format. This should be read-only for now, maybe with support for API keys so bots can't scrape just every user. I'm currently deciding on the data structure:

Example data structure ```json { "NOTE":"!!! This API is still in BETA and some fields may be removed in the future !!!", "user":{ "id":"111", "name":"Brawl", "coins":30, "avatar_url":"https://cdn.discordapp.com/avatars/111...", "profile_url":"http://localhost:3000/user/110806999020625920", "member_since":"2021-11-29T20:46:56.782Z" }, "mii":{ "type":"upload", "data":"04c004....", "cmocEntryNo":null }, "tag":{ "url":{ "normal":"http://localhost:3000/110806999020625920/tag.png", "max":"http://localhost:3000/110806999020625920/tag.max.png" }, "settings":{ "comment":"Some Comment", "flag":"de", "overlay":"overlay6", "background":"mac12.png", "coin":"mario", "font":"default", "coverType":"cover3D", "coverRegion":"EN", "showAvatar":true, "showMii":true } }, "games":[ { "game_id":"RMCE01", "console":"wii", "name":"Mario Kart Wii", "region":"US", "cover_url":"http://localhost:3000/api/cover/wii/RMCE01", "played_on":"2022-08-09T17:12:22.795Z" }, { "game_id":"RSBJ01", "console":"wii", "name":"大乱闘スマッシュブラザーズX", "region":"JA", "cover_url":"http://localhost:3000/api/cover/wii/RSBJ01", "played_on":"2022-08-09T16:45:39.985Z" } ] } ```

Undecided if I should also include the URLs to the assets (e.g. backgrounds, overlays, etc.) directly, but I think it's unnecessary.

Furdox commented 1 year ago

+1

Santabo commented 1 week ago

The API blocks requests from my github, if you want to know your api link, it is: https://tag.rc24.xyz/api/user/

E.g. My API link is: https://tag.rc24.xyz/api/user/789872551731527690

Brawl345 commented 1 week ago

Keep in mind that this is not a public API and should not be used. It's strictly internal, an implementation detail from Next.js. I'm no longer working on RiiTag and it will be replaced in the near future so you should ask the WiiLink guys if they intend to make a public API for their replacement service.

Santabo commented 1 week ago

@Brawl345

Keep in mind that this is not a public API and should not be used. It's strictly internal, an implementation detail from Next.js. I'm no longer working on RiiTag and it will be replaced in the near future so you should ask the WiiLink guys if they intend to make a public API for their replacement service.

I don't know how to contact them, this is the right repo, right?

Brawl345 commented 1 week ago

It's the repo for the current site, yes. I don't know if any of them reads here. You could also try their Discord.