Skip to main content
POST
/
api
/
nudges
Nudges
curl --request POST \
  --url https://whetdata.com/api/nudges \
  --header 'Content-Type: application/json' \
  --data '
{
  "action": [
    "nudges"
  ],
  "text": "a dashing red cup ",
  "ruleset": "product_review",
  "max_nudges": 3
}
'
{
  "success": true,
  "action": [
    "nudges"
  ],
  "ruleset": "product_review",
  "max_nudges": 3,
  "nudges": [
    {
      "type": "improvement",
      "suggestion": "Add context to clarify what the cup is for or where it is.",
      "priority": "0.8"
    },
    {
      "type": "improvement",
      "suggestion": "Use more descriptive language to evoke visuals or emotions.",
      "priority": "0.7"
    },
    {
      "type": "improvement",
      "suggestion": "Include specific measurements or details about the cup.",
      "priority": "0.6"
    }
  ]
}

Overview

Generate actionable improvement suggestions for your text. This action analyzes your content and provides specific, prioritized recommendations to enhance quality and conversion potential.

Use This Action To

  • Get specific suggestions to improve your text
  • Receive prioritized recommendations
  • Enhance content quality and conversion potential

Parameters

action
array
required
Must be an array that includes "nudges"
text
string
required
Text to improve (max 5,000 characters)
ruleset
string
required
Ruleset name (e.g., “product_review”, “product_description”)
max_nudges
integer
required
Maximum number of nudges to generate (minimum: 1)
context
string
Optional context about the text (e.g., question text, what the text box aims to do, etc.)

Response

{
  "success": true,
  "action": ["nudges"],
  "ruleset": "product_review",
  "max_nudges": 3,
  "nudges": [
    {
      "type": "improvement",
      "suggestion": "Add context to clarify what the cup is for or where it is.",
      "priority": "0.8"
    },
    {
      "type": "improvement",
      "suggestion": "Use more descriptive language to evoke visuals or emotions.",
      "priority": "0.7"
    }
  ]
}

Example

cURL
curl -X POST https://whetdata.com/api/nudges \
  -H "x-api-key: whet_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "action": ["nudges"],
    "text": "a dashing red cup ",
    "ruleset": "product_review",
    "max_nudges": 3
  }'

Tips

Higher priority scores (0.8-1.0) indicate more critical improvements, while lower scores (0.1-0.4) are nice-to-have enhancements.
The maximum text length is 5,000 characters. For longer texts, split them into chunks.

Body

application/json
action
enum<string>[]
required
Available options:
nudges
ruleset
string
required
text
string
required
Maximum string length: 5000
max_nudges
integer
Required range: x >= 1

Response

200 - application/json

Success

The response is of type object.