apyhub
Back

Text Analysis & Scoring API

What it does

Text Analysis & Scoring API grades how readable and engaging a piece of writing is. Send text (and optionally its title) as query parameters and get back JSON with standard readability metrics, sub-scores, and overall totals.

Score Readability takes text and returns a readability object with subscores from established formulas (Flesch, Flesch-Kincaid, Gunning Fog, SMOG, ARI, Coleman-Liau, LIX, FORCAST), an estimated reading_time_seconds, and a mainscores total out of a possible maximum. Score Text takes both title and text and returns broader breakdowns for readability, style, skimmability, and interestingness, plus a total_score, number_of_words, and number_of_sentences.

Text Analysis & Scoring API is a good fit when you need to check content quality in an editorial workflow, enforce a reading-level target for help docs or marketing copy, or compare drafts with a consistent, deterministic score.

▣ ENDPOINT 01 / 02
GET
Score Readability API
https://api.eu.apyhub.com/skycraft/text-analysis-scoring/score-readability

QUICKSTART

GUIDE

Quickstart

Check the readability score for a piece of text by passing it as a query parameter.

curl -X GET "https://api.eu.apyhub.com/skycraft/text-analysis-scoring/score-readability?text=A%20rather%20complex%20text%2C%20hard%20to%20read%2C%20and%20highly%20convoluted%20using%20acronym%20TERMS." \
  -H "apy-token: $APY_TOKEN"

What you'll get back

Returns a JSON object with a readability object. Inside it, subscores contains numeric readability metrics such as ari, fog, lix, smog, flesch, forcast, kincaid, coleman_liau, and reading_time_seconds, and mainscores contains total and total_possible integers.

{
  "readability": {
    "subscores": {
      "ari": 0,
      "fog": 0,
      "lix": 0,
      "smog": 0,
      "flesch": 0,
      "forcast": 0,
      "kincaid": 0,
      "coleman_liau": 0,
      "reading_time_seconds": 0
    },
    "mainscores": {
      "total": 0,
      "total_possible": 0
    }
  }
}
TRY ITLIVE · 20 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.

About this endpoint

What it does

Scores the readability of the provided text and returns a JSON object containing a readability object with subscore and main score breakdowns.

Query Parameter(s)

AttributeTypeDescription
textStringThe text to score. Maximum length: 2,000 characters for Latin-script text (about 800 for other scripts, because the text is sent in the URL).

Response

Returns a JSON object with a readability object field. The readability object contains a subscores object with numeric readability metrics and a mainscores object with integer totals.

ParameterTypeDescription
readabilityObjectReadability score details.
readability.subscoresObjectIndividual readability subscores.
readability.subscores.ariNumberAutomated Readability Index score.
readability.subscores.fogNumberGunning fog score.
readability.subscores.lixNumberLIX score.
readability.subscores.smogNumberSMOG score.
readability.subscores.fleschNumberFlesch score.
readability.subscores.forcastNumberFORCAST score.
readability.subscores.kincaidNumberFlesch-Kincaid score.
readability.subscores.coleman_liauNumberColeman-Liau score.
readability.subscores.reading_time_secondsIntegerEstimated reading time in seconds.
readability.mainscoresObjectOverall readability totals.
readability.mainscores.totalIntegerTotal score.
readability.mainscores.total_possibleIntegerMaximum possible total score.
▣ ENDPOINT 02 / 02
GET
Score Text API
https://api.eu.apyhub.com/skycraft/text-analysis-scoring/score-text

QUICKSTART

GUIDE

Quickstart

Score a text by passing its title and text as query parameters.

curl -X GET "https://api.eu.apyhub.com/skycraft/text-analysis-scoring/score-text?title=A%20short%20story&text=A%20nice%20short%20story%20to%20be%20analyzed" \
  -H "apy-token: $APY_TOKEN"

What you'll get back

Returns a JSON object with score breakdowns for style, readability, skimmability, and interestingness, plus total_score, number_of_words, and number_of_sentences.

  • style, readability, skimmability, and interestingness are objects with subscores and mainscores.
  • total_score is a number.
  • number_of_words and number_of_sentences are integers.
{
  "number_of_words": 7,
  "number_of_sentences": 1,
  "readability": {
    "mainscores": { "total": 10.0, "total_possible": 10 },
    "subscores": { "forcast": -1.0, "flesch": 78.873, "smog": 8.842, "ari": 0.237, "lix": -1.0, "kincaid": 3.997, "fog": 8.514, "coleman_liau": 2.633, "reading_time_seconds": 1 }
  },
  "skimmability": {
    "mainscores": { "total": 3.08, "total_possible": 10 },
    "subscores": { "highlighted_word_ratio_score": [0, 2], "bullet_point_ratio_score": [0, 2], "paragraph_headline_ratio_score": [0, 2], "image_score": [0, 3], "video_score": [0, 1], "paragraph_score": [4, 3] }
  },
  "interestingness": {
    "mainscores": { "total": 3.57, "total_possible": 10 },
    "subscores": { "google_hits_score": [4, 4], "link_score": [0, 2], "quote_score": [0, 1], "title_rating_score": [1, 4], "length_score": [0, 2] }
  },
  "style": {
    "mainscores": { "total": 10.0, "total_possible": 10 },
    "subscores": { "abbreviation_score": [3, 3], "style_score": [5, 5], "spelling_score": [5, 5] }
  },
  "total_score": 6.66
}
TRY ITLIVE · 20 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.

About this endpoint

What it does

Scores a piece of text by evaluating the supplied title and text query parameters and returning multiple scoring breakdowns, plus overall counts and totals.

Query Parameter(s)

AttributeTypeDescription
textStringText to analyze. Maximum length: 2,000 characters for Latin-script text (about 800 for other scripts, because the text is sent in the URL).
titleStringTitle associated with the text. Maximum length: 2,000 characters for Latin-script text (about 800 for other scripts, because the text is sent in the URL).

Response

Returns a JSON object with style, readability, total_score, skimmability, interestingness, number_of_words, and number_of_sentences fields. The nested score objects contain subscores and mainscores breakdowns, while total_score is a number and the word/sentence counts are integers.

ParameterTypeDescription
styleObjectStyle scoring breakdown. Includes subscores and mainscores.
readabilityObjectReadability scoring breakdown. Includes subscores and mainscores.
total_scoreNumberOverall score.
skimmabilityObjectSkimmability scoring breakdown. Includes subscores and mainscores.
interestingnessObjectInterestingness scoring breakdown. Includes subscores and mainscores.
number_of_wordsIntegerTotal number of words.
number_of_sentencesIntegerTotal number of sentences.
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.