Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please add support for commonjs #48

Open
ShreshthTiwari opened this issue Jul 31, 2023 · 3 comments
Open

Please add support for commonjs #48

ShreshthTiwari opened this issue Jul 31, 2023 · 3 comments

Comments

@ShreshthTiwari
Copy link

No description provided.

@debotos
Copy link

debotos commented Aug 6, 2023

Yes, Please.

@alokid
Copy link

alokid commented Aug 18, 2023

await import("bing-chat")

@Zibri
Copy link

Zibri commented May 2, 2024

import('bing-chat').then(_=>{

   BingChat=_.BingChat;
   async function main() {
       // Initialize the API with your valid cookie
       const api = new BingChat({ cookie: process.env.BING_COOKIE });

       // Send a message to Bing Chat
       const response = await api.sendMessage('Hello, how can I help?');
       console.log('Bing Chat response:', response.text);
   }

   main();

});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants