POST
/
v1
/
prompt_engine
/
{id}
import { JigsawStack } from "jigsawstack";

const jigsaw = JigsawStack({ apiKey: "your-api-key" });

const response = await jigsaw.prompt_engine.run({
  "input_values": {
        "text": "How to get started with JigsawStack?"
  },
  "id": "0073d008-da9b-4c27-90a8-0240f3ecd4f5"
})
{
  "success": true,
  "result": {
        "outline": [
              {
                    "section": "Introduction to JigsawStack"
              },
              {
                    "section": "What is JigsawStack?"
              },
              {
                    "section": "Key Features and Benefits"
              },
              {
                    "section": "Prerequisites"
              },
              {
                    "section": "Setting up Your Environment"
              },
              {
                    "section": "Installation Guide"
              },
              {
                    "section": "Step-by-step Installation Instructions"
              },
              {
                    "section": "Configuration"
              },
              {
                    "section": "Basic Configuration Options"
              },
              {
                    "section": "Running Your First JigsawStack Application"
              },
              {
                    "section": "Creating a Simple Project"
              },
              {
                    "section": "Understanding the Project Structure"
              },
              {
                    "section": "Deploying Your Application"
              },
              {
                    "section": "Troubleshooting Common Issues"
              },
              {
                    "section": "Common Errors and Solutions"
              },
              {
                    "section": "Resources and Further Learning"
              },
              {
                    "section": "Official Documentation"
              },
              {
                    "section": "Community Forums and Support"
              },
              {
                    "section": "Conclusion"
              }
        ]
  },
  "_usage": {
        "input_tokens": 17,
        "output_tokens": 202,
        "inference_time_tokens": 2493,
        "total_tokens": 2712
  }
}
x-api-key
string
required

Your JigsawStack API key

Body

input_values
object

The input values. This is required if the inputs parameter was specified when creating a prompt. Each input value has a 500000 character limit

stream
boolean

If set, partial message chunk will be sent.

Response

success
boolean

Indicates whether the call was successful.

import { JigsawStack } from "jigsawstack";

const jigsaw = JigsawStack({ apiKey: "your-api-key" });

const response = await jigsaw.prompt_engine.run({
  "input_values": {
        "text": "How to get started with JigsawStack?"
  },
  "id": "0073d008-da9b-4c27-90a8-0240f3ecd4f5"
})
{
  "success": true,
  "result": {
        "outline": [
              {
                    "section": "Introduction to JigsawStack"
              },
              {
                    "section": "What is JigsawStack?"
              },
              {
                    "section": "Key Features and Benefits"
              },
              {
                    "section": "Prerequisites"
              },
              {
                    "section": "Setting up Your Environment"
              },
              {
                    "section": "Installation Guide"
              },
              {
                    "section": "Step-by-step Installation Instructions"
              },
              {
                    "section": "Configuration"
              },
              {
                    "section": "Basic Configuration Options"
              },
              {
                    "section": "Running Your First JigsawStack Application"
              },
              {
                    "section": "Creating a Simple Project"
              },
              {
                    "section": "Understanding the Project Structure"
              },
              {
                    "section": "Deploying Your Application"
              },
              {
                    "section": "Troubleshooting Common Issues"
              },
              {
                    "section": "Common Errors and Solutions"
              },
              {
                    "section": "Resources and Further Learning"
              },
              {
                    "section": "Official Documentation"
              },
              {
                    "section": "Community Forums and Support"
              },
              {
                    "section": "Conclusion"
              }
        ]
  },
  "_usage": {
        "input_tokens": 17,
        "output_tokens": 202,
        "inference_time_tokens": 2493,
        "total_tokens": 2712
  }
}