Social Blade API in JavaScript
Information and Disclaimer
Just because I work for Social Blade does not mean this is an official library. Though it is used in Social Blade official products.
This library supports most of the api.socialblade.com
endpoints that are being exposed by either the official Social Blade Browser Extensions, Apps, or Website.
Social Blade's API is a private API used for Social Blade official tools and for companies with express written permission. Use of the Social Blade API without express permission is prohibited by the active Terms of Service and may result in being blocked from the Social Blade website and all of it's data.
Install
npm install --save socialblade
Usage
Import the library into your project and construct a new client which will be used to access the API.
Use either the third-party Auth
function or first-party AuthAsUser
function to set the client as "active".
TypeScript
import { SocialBladeClient } from 'socialblade';
const socialblade: SocialBladeClient = new SocialBladeClient();
socialblade.Auth("Third-Party API Key").then((data: IDeveloper) => {
console.log(data)
});
socialblade.AuthAsUser("User Email", "User Access Token").then((data: IUser) => {
console.log(data)
});
ES6+
const SocialBladeClient = require("socialblade").SocialBladeClient;
const socialblade = new SocialBladeClient();
socialblade.Auth("Third-Party API Key").then(console.log)
socialblade.AuthAsUser("User Email", "User Access Token").then(console.log)
Examples
More examples coming soon. Library still early development
Troubleshooting
If you have official access to the Social Blade API via express permission from the company then feel free to contact me via Twitter or email me for any help.