diff --git a/.gitignore b/.gitignore index 00cbbdf..f865399 100644 --- a/.gitignore +++ b/.gitignore @@ -57,3 +57,6 @@ typings/ # dotenv environment variables file .env +# custom +config.json +./test_client \ No newline at end of file diff --git a/README.md b/README.md index 117cfd5..2c8936f 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,67 @@ -# account -Pretendo account server - https://account.nintendo.net replacement +# account.pretendo.cc + +

+ + + +

+ +[![forthebadge](http://forthebadge.com/images/badges/built-with-love.svg)](http://forthebadge.com) + +## Pretendo replacement for https://account.nintendo.net + +# What is this? +This is the PN account server, which replaces the official NN account server account.nintendo.net + +# What works +- [x] PNID (Pretendo Network ID) creation +- [x] PNID deletion +- [x] Logging in (access and refresh tokens granted) +- [x] Email validation (6 digit PIN) +- [x] Email validation (email token) +- [x] Linking existing PNID to new user on console +- [x] Mapping user username -> PID (`mapped_ids` admin endpoint) +- [x] Custom EULA +- [x] Timezone lists +- [x] Unlink PNID from user account on console +- [x] Account retrieval +- [x] NEX token granting (still in testing, currently no working NEX/PRUDP server) + +# Currently implemented endpoints +- [GET] https://account.nintendo.net/v1/api/admin/mapped_ids +- [GET] https://account.nintendo.net/v1/api/content/time_zones/:REGION/:LANGUAGE +- [GET] https://account.nintendo.net/v1/api/content/agreements/:TYPE/:REGION/:VERSION (partly, need help[1](#f1)) +- [GET] https://account.nintendo.net/v1/api/devices/@current/status +- [ALL] https://account.nintendo.net/v1/api/oauth20/access_token/generate (Both `password` and `refresh_token` grant types) +- [POST] https://account.nintendo.net/v1/api/people (PARTLY! NEED HELP![3](#f3)) +- [GET] https://account.nintendo.net/v1/api/people/:USERNAME +- [GET] https://account.nintendo.net/v1/api/people/@me/profile +- [PUT] https://account.nintendo.net/v1/api/people/@me/miis/@primary +- [GET] https://account.nintendo.net/v1/api/people/@me/devices/owner +- [POST] https://account.nintendo.net/v1/api/people/@me/devices +- [GET] https://account.nintendo.net/v1/api/people/@me/devices +- [PUT] https://account.nintendo.net/v1/api/people/@me/devices/@current/inactivate +- [POST] https://account.nintendo.net/v1/api/people/@me/deletion +- [GET] https://account.nintendo.net/v1/api/provider/service_token/@me +- [GET] https://account.nintendo.net/v1/api/provider/nex_token/@me (partly, still in testing) +- [PUT] https://account.nintendo.net/v1/api/support/email_confirmation/:USERPID/:CONFIRMCODE +- [POST] https://account.nintendo.net/v1/api/support/validate/email +- [GET] https://id.nintendo.net/account/email-confirmation + + +### Footnotes + +1 I do not know what other `TYPE`'s there are. I currently only know of one, `Nintendo-Network-EULA`, I still am unsure as to when I should throw error `1102` and I lack the remaining data for the rest of the EULA agreements. [↩](#a1) + +2 There are MANY values here that Nintendo seems to generate on their servers. I have no idea what some of these values mean and where/how they are used. Because of this I am unsure how to properly generate these values, and I am using placeholder values instead! ([see here for an example of what the return for an account is ](https://github.com/RedDuckss/csms/blob/master/OFFICIAL_SCHEMA.md#grab-profile)) + +The entire `accounts` section at the beginning is new, and not sent by the registration request. It seems to have something to do with eShop accounts, though I don't know what exactly. I went to the eShop and it never even makes a request to that endpoint so the eShop isn't using that data, yet it's the only "account" mentioned. I am also unsure as to what `active_flag` is used for. There are also several `id` fields that seem completely pointless, like the `id` field in the `email` section and how the `mii` has it's own `id`, as do each of the different `mii_image` fields. [↩](#a3) + +# Developer and general thanks list + +### Developers: +![RedDuckss' avatar](https://avatars1.githubusercontent.com/u/27011796?s=40&v=4)  [RedDuckss](https://github.com/RedDuckss) | Lead Developer +

+![SuperMarioDaBom's avatar](https://avatars2.githubusercontent.com/u/19657053?s=40&v=4)  [SuperMarioDaBom](https://github.com/SuperMarioDaBom) | Development +

+![superwhiskers' vatar](https://avatars2.githubusercontent.com/u/10212424?s=40&v=4)  [superwhiskers](https://github.com/superwhiskers) | Development