Endpoints for running SEO analysis and reading scores.
GET /rankforge/v1/analyze/{post_id}
Run a full SEO analysis on a post. This recalculates the score, identifies issues, and updates the cached result in the database.
curl -u "admin:ABCD 1234 EFGH 5678 IJKL 9012" \
https://example.com/wp-json/rankforge/v1/analyze/42{
"score": 72,
"issues": [
{
"severity": "error",
"message": "Meta description is missing",
"group": "content",
"points": 6,
"code": "description_length"
},
{
"severity": "warning",
"message": "Focus keyword not in title",
"group": "basic",
"points": 5,
"code": "kw_in_title"
},
{
"severity": "info",
"message": "No images or video in content",
"group": "additional",
"points": 5,
"code": "media"
}
],
"suggestions": [
"Meta description is missing"
]
}Each issue carries the group and the code of the check, and its points: what passing the check is worth. A failed check never lowers the score. suggestions lists the messages of the issues with severity error.
{
"code": "rest_post_invalid_id",
"message": "Invalid post ID.",
"data": { "status": 404 }
}GET /rankforge/v1/score/{post_id}
Lightweight endpoint returning only the cached SEO score. Does not trigger a re-analysis.
curl -u "admin:ABCD 1234 EFGH 5678 IJKL 9012" \
https://example.com/wp-json/rankforge/v1/score/42{
"score": 72
}If the post has never been analyzed, score will be 0.
—