JSPM

  • Created
  • Published
  • Downloads 101
  • Score
    100M100P100Q52422F
  • License MIT

A simple npm package to perform requests as a user on the OpenAI ChatGPT page.

Package Exports

  • @ab6162/simple-chatgpt-wrapper
  • @ab6162/simple-chatgpt-wrapper/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@ab6162/simple-chatgpt-wrapper) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

simple-chatgpt-wrapper

A simple npm package to perform requests as a user on the ChatGPT page.

Install

Package managers

npm: npm i @ab6162/simple-chatgpt-wrapper

Usage

Using this package is so easy, just pass it the user credentials you use in the OpenAI ChatGPT platform and the magic will happen.

This is a fully functional initial version for those who want to connect some kind of service in NodeJS. It's recommended to keep the timeouts as they're to avoid possible bans.

This package doesn't collect any kind of data, which you can see in the source code published in GitHub

This is an example code for use:

const chatgpt = require('@ab6162/simple-chatgpt-wrapper');

(async () => {

    //user and password here
    const statusLogin = await chatgpt.login('example@example.com', 'xxxx');

    //verify that the answer is not null
    if (statusLogin) {

        //send a request and wait the response in raw format.
        var response = await chatgpt.sendMessage('¿Hello, how are you?');

        console.log(response);

        response = await chatgpt.sendMessage('Give me five names...');

        console.log(response);

    } else {
        console.log('Login failed!');
    }

})();

Issues

If there are any bugs or questions open a new issue

License

MIT