In the /me/associated method, I get back a bunch of JSON - but the api_site_parameter
name is nowhere to be found.
Why? It's kind of important. Could we have it?
In the /me/associated method, I get back a bunch of JSON - but the api_site_parameter
name is nowhere to be found.
Why? It's kind of important. Could we have it?
I don't see any particular reason not to add it, but there are some workarounds you can use in the meantime:
api_site_parameter
value (and associated information) that way.or
Use the fact that the domain name can be passed as a valid value for the site
parameter, in all API routes that require it. EG: /2.2/answers?site=unix.stackexchange.com
Clean up the returned site_url
to fit, i.e.:
var api_site = network_user.site_url.substring(
network_user.site_url.indexOf("//") + 2,
network_user.site_url.length - 1
);
space.stackexchange.com
for site and it would get me results for Space Exploration?
site
parameter in the documentation, specifically "This parameter can be the full domain name (ie. "stackoverflow.com"), or a short form identified by api_site_parameter
on the site object." (emphasis mine)
http(s)://
. Simple!
/
(maybe they used to). No big deal but the little substring snippet doesn't work verbatim like this.