Quickstart

Analyse a writing sample and restyle AI text to match it — in 3 steps and under 5 minutes.

1

Get an API key

Sign in and visit /dashboard/api-keys to create a key. Copy it — you'll pass it in the Authorization header on every request.

Authorization: Bearer YOUR_API_KEY
2

Analyse a writing sample

Send at least 200 words of writing to POST /api/v1/analyze. Parlaví extracts lexical, syntactic, and rhetorical features and returns a profileId — save this for step 3.

Request
curl -X POST https://parlavi.ai/api/v1/analyze \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "text": "Good writing sounds effortless. Every smooth sentence is the product of rewriting. The first draft exists to get ideas out of your head and onto the page. Revision turns raw material into something readable."
  }'

Response (200 OK):

Response
{
  "profileId": "66c964b2-5a3e-4b9f-a2c1-3d8e7f1a0b2c",
  "features": {
    "formality_level": "formal",
    "vocabulary_richness": 0.72,
    "avg_sentence_length": 12.4,
    "hedging_frequency": 0.08,
    "argument_structure": "thesis-support"
  },
  "featureCoveragePct": 91,
  "shareUrl": "/profile/66c964b2-5a3e-4b9f-a2c1-3d8e7f1a0b2c",
  "durationMs": 1240
}

Save the profileId — it identifies the voice fingerprint for restyles.

3

Restyle text in that voice

Pass the profile_id and the AI-generated text you want to rewrite to POST /api/v1/restyle. Get back a restyledText that sounds like the original author.

Request
curl -X POST https://parlavi.ai/api/v1/restyle \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "profile_id": "66c964b2-5a3e-4b9f-a2c1-3d8e7f1a0b2c",
    "text": "Our AI solution leverages advanced machine learning to synergize cross-functional value creation."
  }'

Response (200 OK):

Response
{
  "restyledText": "Our tool uses machine learning to help teams work better together.",
  "profileId": "66c964b2-5a3e-4b9f-a2c1-3d8e7f1a0b2c",
  "durationMs": 980,
  "modelUsed": "qwen3-4b-lora/professional-en",
  "inputTokens": 48,
  "outputTokens": 17
}

Next steps