1.4.2 • Published 2 years ago

chatgtp-node-js-api-call v1.4.2

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

ChatGTP-NODE-JS-API-CALL

A simple Node.js function to call the ChatGTP endpoint.

Installation

To install the package, run the following command:

npm install chatgtp-node-js-api-call

npm install axios

Usage

To use the package, import the chatGTP function and call it with your question and API key.

const { chatGTP } = require('chatgtp-node-js-api-call')

async function chatWithGTP() {
    const question = 'What is the capital of France?'
    const apiKey = 'YOUR_OPEN_API_KEY'

    const completion = await chatGTP(question, apiKey)
    console.log(completion.content)
}
1.4.2

2 years ago

1.4.1

2 years ago

1.4.0

2 years ago

1.3.0

2 years ago

1.2.0

2 years ago

1.1.0

2 years ago

1.0.0

2 years ago