API DOCS

CloudList - API Docs

Getting Started

All post request types must be accompanied with authorization (your bot api key). You can create a new key here.
All post requests must be made through https://www.cloudlist.xyz/api/

Posting Guild Count

To post your bot's guild count,you will need to POST request to https://www.cloudlist.xyz/api/stats/:id

Where:


=> Id: Your Bot Id


=> Authorization: Bot Api Key



Simple Example using node-fetch

Run npm i node-fetch in your node.js console

Then All you need to do is paste this code:




    fetch("https://www.cloudlist.xyz/api/stats/:BOT_ID", {
      method: "POST",
      
headers: {
'Authorization': API_TOKEN,
"Content-Type": "application/json",
},
body:JSON.stringify({count:client.guilds.size}),
})
.then(res => res.json())
.then(async response => {
console.log(response)
})

//Sends {Success: "true",bot:Count}

Getting Bot Information

To get your bot's information,you will need to GET request to https://www.cloudlist.xyz/api/bot/:id

Where:


=> Id: Your Bot Id


=> Authorization: Bot Api Key



Simple Example using node-fetch

Run npm i node-fetch in your node.js console

Then All you need to do is paste this code:




    fetch("https://www.cloudlist.xyz/api/bot/:BOT_ID", {
    
method: "GET",
headers: {
'Authorization': API_TOKEN,
"Content-Type": "application/json",
},
})
.then(res => res.json())
.then(async response => {
console.log(response)
})

//Sends{ success: 'true',votes: amount of votes that your bot has,name: Bot name,library: 'Bot library,prefix: bot prefix }

Getting Users that voted for your bot

To get Users that voted for your bot,you will need to GET request to https://www.cloudlist.xyz/api/bot/vote/:id

Where:


=> Id: Your Bot Id


=> Authorization: Bot Api Key



Simple Example using node-fetch

Run npm i node-fetch in your node.js console

Then All you need to do is paste this code:




    fetch("https://www.cloudlist.xyz/api/bot/vote/:BOT_ID", {
    
method: "GET",
headers: {
'Authorization': API_TOKEN,
"Content-Type": "application/json",
},
})
.then(res => res.json())
.then(async response => {
console.log(response)
})

//Sends { 'User_ID': { vote: AMOUNT OF VOTES } }