0.2.1 • Published 2 months ago
promptground v0.2.1
PromptGround SDK
A simple Node.js SDK for interacting with the PromptGround API.
Installation
Install the SDK using npm:
npm install promptground
Usage
Here's how you can use the SDK in your Node.js application:
import PromptGround from 'promptground';
const pg = new PromptGround("YOUR API KEY");
async function getPrompt() {
try {
const prompt = await pg.prompt('welcome-user', { name: 'PromptGround' });
console.log(prompt); // Outputs "Welcome to PromptGround"
} catch (error) {
console.error(error);
}
}
getPrompt();