4chan-promise

Javascript 4chan API client with support for async await and promises.

Usage no npm install needed!

<script type="module">
  import chanPromise from 'https://cdn.skypack.dev/4chan-promise';
</script>

README

4chan-promise

4Chan Javascript Client with Promises.

Usage

const chan = require("4chan-promise");

const paper = chan.getBoard("po");

async function printPages() {
  const pages = await biz.threads();
  console.log(pages);
}

async function getThread(threadId) {
  const thread = await biz.thread(threadId);
}

printPages();
getThread(570368);

Schema

To see how to use this effectively, you need to know what is the structure of the objects returned. Check it out here.