Edit – 2017-06-23:

This hasn’t been updated with new custom APIs that I’ve added over time from feature requests and such. If you want an overview of what extra those might be, I suggest you take a look at the DecAPI documentation, even though it lacks good examples.


Over time I’ve written several “custom APIs” for certain things that I’d find useful to have in chat, to make it easier for myself and other chat moderators.

Some of these custom APIs are already documented on this blog such as the latest tweet, uptime or subscriber count.

Before moving on to covering all of the custom APIs, I will mention a few things beforehand:

  • In most cases, you will be able to utilize other “variables” that the bot supports.
  • For each custom API I will only provide the URL for it as well as a description of it. This URL has to be inserted in the specific bot’s respective variables.
    • You can find the variables below where you replace CUSTOM_API_URL_HERE with the URL of the custom API you wish to use.
      • For Nightbot:
        • $(urlfetch CUSTOM_API_URL_HERE)
      • For Streamlabs Chatbot (formerly Ankhbot):
        • $readapi(CUSTOM_API_URL_HERE)
      • For Deepbot:
        • @customapi@[CUSTOM_API_URL_HERE]
    • If your bot isn’t listed here it’s still possible it has the ability to utilize these custom APIs. Please refer to your bot’s own documentation for information regarding this.
  • Example/placeholder parameters will be surrounded by ‘curly brackets’, for example {CHANNEL}.
    • Do not include these in the actual URLs. Example: {CHANNEL} = decicus.
  • Optional parameters will be covered per custom API, if there are any.
  • Some of these custom APIs may be marked as “beta” and may change at any time (this is written in the notes about the endpoints).


  • https://decapi.me/twitch/help/{SEARCH}
    • Description: Retrieves a Twitch help article based on the specified search.
    • Optional parameters:
      • list – Returns a list of available help articles, with the title of each article (cannot be used in chat due to length).
    • Notes:
      • If {SEARCH} is list, it will provide a link to the list of help articles (with titles).
      • This generally requires another variable to accept user input, such as Nightbot’s $(querystring)or Streamlabs Chatbot’s $msg.
        • Other bots may have something similar. Please refer to their documentation for further information.
      • It’s currently in “beta”, which means it might need some tweaks. Please contact me if you have any suggestions or reports.
    • Example:
  • https://decapi.me/twitch/followage/_CHANNEL_/_USER_
    • Description: Checks the specified user’s “follow age” (how long it has been since the user followed the channel).
    • Optional parameters:
      • precision – How precise the calculation of the “follow age” is. Defaults to 2.
        • While there is technically no limit on the precision, this will not require anything higher than “7” as the precision is calculated in this order:
          • years, months, weeks, days, hours, minutes, seconds
    • Notes:
      • This custom API is currently in “beta” and may change at any time.
      • This calculates the time between the last time the user followed and now, if the user has been following for a while, then unfollows and refollows, it will be reset.
    • Example:


  • https://decapi.me/twitter/latest?name={USERNAME}
    • Description: Gets the latest tweet of a specified user.
    • Optional parameters:
      • no_rts – Ignores retweets and gets the latest normal tweet.
      • url – Appends the direct URL of the tweet. Looks like this: This is a tweet - TWEET_URL_HERE
      • howlong – Appends how long it has been since the tweet was tweeted out. Looks like this: This is a tweet - 12 hours, 4 minutes ago
    • Notes: Your tweets have to be open to the public for this to work.
    • Example: https://decapi.me/twitter/latest?name=Decicus&no_rts&howlong&url



  • https://decapi.me/steam/hours?id={STEAM64}&appid={APP_ID}
    • Description: Gets the amount of hours of a game (APP_ID) for the specified Steam ID.
    • Notes:
      • If the custom API doesn’t work, then you either have to put your Steam profile to public or use your own Steam API key (check “Optional parameters” for this method).
      • Your Steam64 ID can be found using several tools, such as steamid.co.
      • The app ID is the ID of the Steam game. This is relatively easy to find in the store page URL. For example, the Steam store page URL for Counter-Strike: Global Offensive is http://store.steampowered.com/app/730/ where the number “730” is the app ID.
    • Optional parameters:
      • round – The number of decimals to round the number of hours down to. Defaults to 2.
      • key – Only recommended if you need to keep your Steam profile set to private.
        • This parameter needs to be the account owner’s Steam API key for it to have an effect.
        • You can sign up and get your Steam API key here: https://steamcommunity.com/dev/apikey
        • If you decide to use this, please make sure to not add your command directly through chat as exposing your API key to the public is not recommended!
    • Example: https://decapi.me/steam/hours?id=76561197997719567&appid=730&round=1 (My profile – Game: Counter-Strike: Global Offensive – 1 decimal)
  • https://decapi.me/br/player/_ID_
    • Description: Retrieves player information about the specified player from the Battle Royale leaderboards, where {ID} is either your STEAM64 ID or your unique ID from Battle Royale.
    • Notes:
      • By default, this will retrieve from the regular ranked games. If you want hardcore, add /hardcore at the end of the URL.
        • Please keep in mind that if you add /hardcore to the URL, all options parameters must come after the /hardcore part.
      • Alternatively, you can add /regular at the end of the URL, but since the default falls back to regular anyways, this is generally.
      • This custom API is in beta and may change at any time.
    • Optional parameters:
      • options – You can see what it retrieves by default by specifying default . You can specify list to see a list of available options.
        • Remember to comma-separate all options you wish to use.
      • separator – By default, this is the | (pipe) character. A space will be added before and after the separator, between each value.
    • Example:

End notes:

Congratulations! You reached the end of my post. Hopefully you’ll find some use out of these “custom APIs”.

If you have any questions or other concerns, please feel free to contact me.

If you would like to support me in any way (buying me a coffee/supporting server costs) then you can do so via this Streamtip link.

Thanks for reading!

Custom APIs for Bots (Nightbot/Streamlabs Chatbot/Deepbot)
Tagged on: