File tree Expand file tree Collapse file tree 1 file changed +31
-1
lines changed Expand file tree Collapse file tree 1 file changed +31
-1
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ ATLauncher-API---NodeJS
22=======================
33Node.js module for interacting with the ATLauncher API.
44
5- Examples
5+ Getting Started
66----
77To get started simply require the package and optionally provide an optional object with settings.
88
@@ -14,6 +14,20 @@ var api = require('atlauncher-api')({
1414
1515The api_key argument is your API-KEY used for admin or PSP api calls.
1616
17+ All the arguments you can pass in are below:
18+
19+ ```
20+ {
21+ base_url: 'https://api.atlauncher.com/', # The base url of the api
22+ api_version: 'v1', # A string representing the verison to be used in URLS
23+ api_key: false, # The API key for authenticated requests/higher rate limits
24+ return_full: false # If the returns from each callback should contain all the data from the response or just the data attribute of the response
25+ }
26+ ```
27+
28+ Examples
29+ ----
30+
1731For instance for running public api calls such as getting a list of all packs you can use the following:
1832
1933```
@@ -28,6 +42,22 @@ api.packs.full.all(function(err, res) {
2842});
2943```
3044
45+ Or to get the entire return from the API and not just the data:
46+
47+ ```
48+ var api = require('atlauncher-api')({
49+ return_full: true
50+ });
51+
52+ api.packs.full.all(function(err, res) {
53+ if (err) {
54+ return console.error(err);
55+ }
56+
57+ console.log(res.data);
58+ });
59+ ```
60+
3161Documentation
3262----
3363* [ ATLauncher API Docs] ( http://wiki.atlauncher.com/api:information )
You can’t perform that action at this time.
0 commit comments