> ## Documentation Index
> Fetch the complete documentation index at: https://docs.daftplug.com/llms.txt
> Use this file to discover all available pages before exploring further.

# REST API

> The rankify/v1 endpoints, their permissions, and what they do.

Crownify registers its endpoints under the `rankify/v1` namespace. They serve the plugin's own admin screens and editor panel, so treat them as an internal API rather than a versioned public contract. The namespace keeps the rankify name for backward compatibility.

```
https://example.com/wp-json/rankify/v1/
```

## Endpoints

| Endpoint | Method | Access |
| - | - | - |
| `/settings` | PUT | `manage_options` |
| `/setup/complete` | POST | `manage_options` |
| `/legacy-seo` | GET | `manage_options` |
| `/redirects` | GET, POST | `manage_options` |
| `/redirects/{id}` | DELETE | `manage_options` |
| `/redirects/import` | POST | `manage_options` |
| `/redirects/export` | GET | `manage_options` |
| `/404s` | GET, DELETE | `manage_options` |
| `/404s/redirect` | POST | `manage_options` |
| `/geo/crawlers` | GET | `manage_options` |
| `/geo/referrals` | GET | `manage_options` |
| `/geo/clear` | POST | `manage_options` |
| `/geo/indexnow` | POST | `manage_options` |
| `/link-suggestions` | GET | `manage_options` |
| `/orphans` | GET | `manage_options` |
| `/retrieval-score` | GET | `edit_post` on the post |
| `/notifications/test` | POST | `manage_options` |

Every endpoint requires authentication. There are no public routes.

> [!NOTE]
>
> `/retrieval-score` is the only one not gated on `manage_options`. It checks `edit_post` against the specific post being scored, so an author can see the score for their own draft without being an administrator.

## Settings

**PUT /settings** `endpoint`

Merges the supplied values over the stored settings. Send only the keys you want to change.

```bash theme={null}
curl -X PUT https://example.com/wp-json/rankify/v1/settings \
  -H "X-WP-Nonce: $NONCE" \
  -H "Content-Type: application/json" \
  --cookie "$COOKIE_JAR" \
  -d '{"settings": {"breadcrumbs": "on"}}'
```

Fires [`rankify_settings_update:before`](/crownify/reference/hooks#rankify_settings_updatebefore-after) and `:after`.

**POST /setup/complete** `endpoint`

Marks the setup wizard as finished and stores the answers.

**GET /legacy-seo** `endpoint`

Reports which other SEO plugins left data on the site and how many posts each covers. Backs the wizard's existing-data step. See [switching to Crownify](/crownify/guides/migrating.md).

## Redirects

**GET /redirects** `endpoint`

Lists redirect rules.

**POST /redirects** `endpoint`

Creates a rule.

**DELETE /redirects/\{id}** `endpoint`

Deletes one rule by ID.

**POST /redirects/import** `endpoint`

Imports rules, which is how you bring them across from another plugin's CSV export.

**GET /redirects/export** `endpoint`

Exports your rules. Useful for moving a rule set between staging and production.

Creating or deleting a rule fires [`rankify_redirects_changed`](/crownify/reference/hooks#redirects-and-links).

## 404 monitor

**GET /404s** `endpoint`

The logged missing URLs, ranked by hit count.

**DELETE /404s** `endpoint`

Clears the log.

**POST /404s/redirect** `endpoint`

Creates a redirect from a logged 404 in one step, which is what the button on the Redirects & Links page calls.

## AI and GEO

**GET /geo/crawlers** `endpoint`

AI crawler activity: which crawlers, how often, which pages. Free returns 7 days, Pro returns 90 with verified identity.

**GET /geo/referrals** `endpoint`

Pro. Visits arriving from AI assistants, per page.

**POST /geo/clear** `endpoint`

Clears the stored crawler and referral data.

**POST /geo/indexnow** `endpoint`

Pro. Submits URLs to IndexNow, reaching Bing, Yandex, and Seznam. Also used by the test submission button.

Fires [`rankify_indexnow_submitted`](/crownify/reference/hooks#rankify_indexnow_submitted).

## Content analysis

**GET /retrieval-score** `endpoint`

Pro. Scores how quotable a post is for answer engines, across five signals worth two points each.

Takes a `postId` parameter and checks `edit_post` against it.

```bash theme={null}
curl "https://example.com/wp-json/rankify/v1/retrieval-score?postId=42" \
  -H "X-WP-Nonce: $NONCE" \
  --cookie "$COOKIE_JAR"
```

The five signals are passage size, self-contained sections, question headings, answer-first opening, and lists and tables. See [answer engine optimization](/crownify/guides/answer-engines.md#the-retrieval-score).

**GET /link-suggestions** `endpoint`

Pro. Related pages worth linking to from the post being edited.

**GET /orphans** `endpoint`

Pro. Pages nothing on the site links to.

## Notifications

**POST /notifications/test** `endpoint`

Sends a test email to the configured recipient.

Worth calling before relying on any alert, because WordPress mail is configured outside the plugin and fails silently more often than anything else on a site.

## Authentication

All endpoints need a capability and a valid `X-WP-Nonce` header. For calls from outside a browser session, use an application password:

```bash theme={null}
curl https://example.com/wp-json/rankify/v1/404s \
  -u "reporting:xxxx xxxx xxxx xxxx xxxx xxxx"
```

> [!NOTE]
>
> Most of these need `manage_options`, which is administrator-level access. Create a dedicated user for any automation rather than reusing your own account.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.