Is it possible to be able to specify an API key server-side that gets attached to the URL? Or is there another way of hard-coding the URL, plus the API key, and then being able to specify any actions or commands in the MediaWiki template?
For example, some server-side code:
$jsonerBaseUrl = "http://my.testapi.com/key?=xxxxxxx";
Then in MediaWiki:
{{#jsoner: f-SelectSubtree=stats | t-JsonDump}}
I would rather not expose the API key in the MediaWiki template; I'd like to have the key exist server-side instead.
Additionally, I noticed that multiple {{#jsoner}} calls are necessary for individual variables. If I wanted to make one API call and use all the data from its result in different parts of the page, how can that be done? All I see so far are examples where {{#jsoner}} makes an API call every time it is invoked. If I want to invoke it only once and use the results from that one call in different aspects of the page, how can that be accomplished?
Is it possible to be able to specify an API key server-side that gets attached to the URL? Or is there another way of hard-coding the URL, plus the API key, and then being able to specify any actions or commands in the MediaWiki template?
For example, some server-side code:
Then in MediaWiki:
I would rather not expose the API key in the MediaWiki template; I'd like to have the key exist server-side instead.
Additionally, I noticed that multiple
{{#jsoner}}calls are necessary for individual variables. If I wanted to make one API call and use all the data from its result in different parts of the page, how can that be done? All I see so far are examples where{{#jsoner}}makes an API call every time it is invoked. If I want to invoke it only once and use the results from that one call in different aspects of the page, how can that be accomplished?