@ibaraki-douji/bing-ai
v1.0.2
Published
Just a way to use Bing AI in NodeJS
Downloads
1
Readme
#Bing AI Simple Bing AI for NodeJS
Getting started
npm i @ibaraki-douji/bing-ai --save
Usage
Import the lib
const BingAI = require('@ibaraki-douji/bing-ai').default
Init the lib
const BingAI = require('@ibaraki-douji/bing-ai').default
const ai = new BingAI("_U=123456789;");
You can get the cookies from the devtools or with an exension like EditThisCookie.
The cookies needs to be formated like this : cookieName=cookieValue; cookieName2=cookieValue2;
The useful cookie name is _U
. WIthout it bing will think you are not logged in and will not give you the access.
Create a conversation
const BingAI = require('@ibaraki-douji/bing-ai').default
const ai = new BingAI("_U=123456789;");
ai.createConversation().then((conversation) => {
// do something with the conversation
})
Send a message to the conversation
ai.createConversation().then((conversation) => {
conversation.sendMessage("Hello").then((response) => {
// do something with the response
})
})
Get a suggestion for your current message
const ai = new BingAI("_U=123456789;");
ai.suggest("Hello").then((suggestions) => {
// do something with the suggestions
})
Exemple
To see a real exemple of the lib, check the lib/main.js file.
More Help and Support
Discord : Ibaraki Douji#1406