Mika Scraper / ChatGPTOnline
Function: ChatGPTOnline
ChatGPTOnline(
message
):Promise<string>
Defined in: src/_other-scraper/gpt.ts:9
Fetches a response from gptonline.ai by simulating a user message.
Parameters
message
- Type:
string
- Description: The userβs message to be sent to the GPT Online service.
Returns
- Type:
Promise<string>
- Description: A Promise that resolves to the AIβs response, returned as a string.
Example
const userMessage = "What is the weather today?";
ChatGPTOnline(userMessage)
.then(response => {
console.log(`AI Response: ${response}`);
})
.catch(error => {
console.error(`Error: ${error}`);
});
Last updated on