Moved nex_server ips and ports to config

Updated README with list of implemented nex servers and info on EULAs
This commit is contained in:
SuperMarioDaBom
2018-03-07 22:47:53 -08:00
parent f40fd8fa35
commit d6c58cce76
3 changed files with 18 additions and 13 deletions

View File

@@ -50,6 +50,10 @@ This is the PN account server, which replaces the official NN account server acc
- [POST] https://account.nintendo.net/v1/api/support/validate/email
- [GET] https://id.nintendo.net/account/email-confirmation
# Currently implemented nex servers
- supermariomaker
- friends
### Footnotes
@@ -58,3 +62,5 @@ This is the PN account server, which replaces the official NN account server acc
<b id="f3">2</b> 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)
The EULAs need to be changed, as they are currently stock Nintendo's.

View File

@@ -16,5 +16,15 @@
},
"http": {
"port": 8080
}
},
"nex_servers": {
"friends": {
"ip": "ip",
"port": "port"
},
"supermariomaker": {
"ip": "ip",
"port": "port"
}
}
}

View File

@@ -2,21 +2,10 @@ const routes = require('express').Router();
const json2xml = require('json2xml');
const debug = require('../../debugger');
const route_debugger = new debug('Provider Route'.green);
const gamePort = require('../../config.json').nex_servers;
route_debugger.log('Loading \'provider\' API routes');
//The game ips and ports are stored here. When the game tries to access its specific server, it will be given the respecive ip and port.
const gamePort = {
friends: {
ip: '10.0.0.225',
port: '1300'
},
supermariomaker: {
ip: '10.0.0.225',
port: '1301'
}
};
/**
* [GET]
* Replacement for: https://account.nintendo.net/v1/api/provider/service_token/@me