1.0.7 • Published 10 months ago

threadsnetapi v1.0.7

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

Threads.net Unofficial API

This is an unofficial API for the website threads.net. It is a website like twitter but made by Meta. This API allows you to get information Threads for now. New features will be added soon.

Installation

npm install threadsnetapi

Usage

const threads = require('threadsnetapi');

(async () => {
    const threadsAPI = new ThreadsAPI({
        headless: true, // Default value is false,
        proxy: {
            server: "socks5://myproxy.com:3128"  // This is an example, you can use any proxy server, but its not required
        }
    });

    await threadsAPI.init();

    const thread = await threadsAPI.getThread('thread_id'); // Default value is CuP48CiS5sx you can use it as an example

    /** Output
     * {
     *    id: 'thread_id',
     *    content: 'thread_content',
     *    user: "@username",
     *    whenShared: Date,
     *    repliesCount: Number,
     *    likesCount: Number,
     * }
     */
    
    const user = await threadsAPI.getUser('username'); // Default value is zuck you can use it as an example

    /** Output
     * {
     *    id: 'user_id',
     *    name: 'name',
     *    username: '@username',
     *    profilePicture: 'user_profile_picture_url',
     *    bio: 'user_bio',
     *    followersCount: Number,
     *    instagramAccount: "@instagram_account",
     * }
     */


    await threadsAPI.close(); // You should close the browser when you are done
})();
1.0.7

10 months ago

1.0.6

10 months ago

1.0.4

10 months ago

1.0.3

10 months ago

1.0.2

10 months ago

1.0.1

10 months ago

1.0.0

10 months ago