Connector REST API Overview for Developers
The SEOvault AI WordPress plugin provides a REST API for the web app and external integrations to manage SEO data, content, and settings. This API uses the seovaultai/v1 namespace and requires site key authentication.
Base URL
Section titled “Base URL”All endpoints use the WordPress REST API base URL with the SEOvault namespace:
https://yoursite.com/wp-json/seovaultai/v1/Authentication
Section titled “Authentication”The API uses site key authentication. Include the site key in the X-Site-Key header:
X-Site-Key: your-site-key-hereKey types
Section titled “Key types”The plugin supports three key types with different permission levels:
- Legacy key — Original site key (full access)
- Read key — Read-only access to data
- Write key — Full read and write access
Keys are resolved using timing-safe comparison for security. The plugin checks keys in order: legacy → read → write.
Example request
Section titled “Example request”curl -X GET https://yoursite.com/wp-json/seovaultai/v1/posts \ -H "X-Site-Key: your-site-key-here"The API implements CORS with an allowlist for cross-origin requests from the web app.
CORS headers
Section titled “CORS headers”Allowed origins are configured in the plugin. Responses include:
Access-Control-Allow-Origin— Allowed origin (if allowlisted)Access-Control-Allow-Methods—GET, POST, OPTIONSAccess-Control-Allow-Headers—Authorization, Content-Type, X-Site-KeyAccess-Control-Max-Age—3600
Preflight requests
Section titled “Preflight requests”OPTIONS requests to the namespace are handled automatically for CORS preflight.
Endpoints
Section titled “Endpoints”Site verification
Section titled “Site verification”GET /verify
Section titled “GET /verify”Verify the site connection and key validity.
Authentication: Requires site verify capability
Response: Site verification status
GET /posts
Section titled “GET /posts”List posts with pagination.
Authentication: Site key required
Query parameters:
per_page— Number of results per page (default: 20)page— Page number (default: 1)
Response: Array of post objects with SEO metadata
POST /posts
Section titled “POST /posts”Create a new post.
Authentication: Site key required
Body: Post data including title, content, and SEO fields
Response: Created post object
GET /posts/{id}
Section titled “GET /posts/{id}”Get a single post by ID.
Authentication: Site key required
Response: Post object with SEO metadata
POST /posts/{id}
Section titled “POST /posts/{id}”Update a post by ID.
Authentication: Site key required
Body: Post data to update
Response: Updated post object
POST /posts/{id}/restore-revision
Section titled “POST /posts/{id}/restore-revision”Restore a post to a previous revision.
Authentication: Site key required
Response: Restored post object
GET /pages
Section titled “GET /pages”List pages with pagination.
Authentication: Site key required
Query parameters:
per_page— Number of results per page (default: 20)page— Page number (default: 1)
Response: Array of page objects
GET /pages/{id}
Section titled “GET /pages/{id}”Get a single page by ID.
Authentication: Site key required
Response: Page object with SEO metadata
POST /pages/{id}
Section titled “POST /pages/{id}”Update a page by ID.
Authentication: Site key required
Body: Page data to update
Response: Updated page object
POST /pages/{id}/restore-revision
Section titled “POST /pages/{id}/restore-revision”Restore a page to a previous revision.
Authentication: Site key required
Response: Restored page object
Categories
Section titled “Categories”GET /categories
Section titled “GET /categories”List categories.
Authentication: Site key required
Response: Array of category objects
GET /media
Section titled “GET /media”List media library items with pagination.
Authentication: Site key required
Query parameters:
per_page— Number of results per page (default: 20)page— Page number (default: 1)
Response: Array of media objects
POST /media/upload
Section titled “POST /media/upload”Upload a media file.
Authentication: Site key required
Body: File data
Response: Uploaded media object
IndexNow
Section titled “IndexNow”POST /indexnow/setup
Section titled “POST /indexnow/setup”Configure IndexNow settings.
Authentication: Site key required
Body: IndexNow configuration
Response: Configuration status
GET /indexnow/status
Section titled “GET /indexnow/status”Get IndexNow status.
Authentication: Site key required
Response: IndexNow status object
POST /indexnow/submit
Section titled “POST /indexnow/submit”Submit URLs to IndexNow.
Authentication: Site key required
Body: URLs to submit
Response: Submission status
Sitemap
Section titled “Sitemap”GET /sitemap-proxy
Section titled “GET /sitemap-proxy”Proxy sitemap requests through the API.
Authentication: Site key required
Query parameters:
path— Sitemap path (required, validated)
Response: Sitemap XML content
SEO capabilities
Section titled “SEO capabilities”GET /seo/capabilities
Section titled “GET /seo/capabilities”Get SEO capabilities and feature availability.
Authentication: Site key required
Response: Capabilities object
Image SEO
Section titled “Image SEO”POST /posts/{id}/inject-image-alt
Section titled “POST /posts/{id}/inject-image-alt”Inject image alt text into a post.
Authentication: Site key required
Body: Image alt data
Response: Updated post object
AEO (Answer Engine Optimization)
Section titled “AEO (Answer Engine Optimization)”POST /posts/{id}/inject-aeo
Section titled “POST /posts/{id}/inject-aeo”Inject AEO snippet into a post.
Authentication: Site key required
Body: AEO snippet data
Response: Updated post object
Internal links
Section titled “Internal links”GET /internal-links/manifest
Section titled “GET /internal-links/manifest”Get internal links manifest.
Authentication: Site key required
Response: Internal links manifest
GET /internal-links/sync
Section titled “GET /internal-links/sync”Sync internal links with optional filtering.
Authentication: Site key required
Query parameters:
cursor— Pagination cursorsince— Filter by datelimit— Number of resultstypes— Post type filterincludeBodyPhrases— Include body phrases
Response: Internal links sync data
AI Visibility
Section titled “AI Visibility”GET /ai-visibility/status
Section titled “GET /ai-visibility/status”Get AI visibility status.
Authentication: Site key required
Response: AI visibility status object
llms.txt
Section titled “llms.txt”GET /llms/status
Section titled “GET /llms/status”Get llms.txt publishing status.
Authentication: Site key required
Response: llms.txt status
POST /llms/preview
Section titled “POST /llms/preview”Preview llms.txt content.
Authentication: Site key required
Body: llms.txt configuration
Response: Preview content
POST /llms/publish
Section titled “POST /llms/publish”Publish llms.txt.
Authentication: Site key required
Body: llms.txt configuration
Response: Publish status
Robots.txt
Section titled “Robots.txt”GET /robots/status
Section titled “GET /robots/status”Get robots.txt modification status.
Authentication: Site key required
Response: Robots.txt status
POST /robots/preview
Section titled “POST /robots/preview”Preview robots.txt modifications.
Authentication: Site key required
Body: Robots.txt rules
Response: Preview content
POST /robots/apply
Section titled “POST /robots/apply”Apply robots.txt modifications.
Authentication: Site key required
Body: Robots.txt rules
Response: Apply status
POST /robots/restore
Section titled “POST /robots/restore”Restore original robots.txt.
Authentication: Site key required
Response: Restore status
Schema
Section titled “Schema”GET /schema/status
Section titled “GET /schema/status”Get schema status.
Authentication: Site key required
Response: Schema status object
POST /schema/preview
Section titled “POST /schema/preview”Preview schema markup.
Authentication: Site key required
Body: Schema configuration
Response: Preview schema JSON-LD
POST /schema/inject
Section titled “POST /schema/inject”Inject schema markup into a post.
Authentication: Site key required
Body: Schema data
Response: Injection status
Crawler logs
Section titled “Crawler logs”GET /crawler-logs/status
Section titled “GET /crawler-logs/status”Get crawler logging status.
Authentication: Site key required
Response: Crawler logs status
POST /crawler-logs/enable
Section titled “POST /crawler-logs/enable”Enable crawler logging.
Authentication: Site key required
Response: Enable status
POST /crawler-logs/disable
Section titled “POST /crawler-logs/disable”Disable crawler logging.
Authentication: Site key required
Response: Disable status
GET /crawler-logs
Section titled “GET /crawler-logs”Get crawler log entries.
Authentication: Site key required
Response: Array of crawler log entries
Import
Section titled “Import”GET /seo/import/summary
Section titled “GET /seo/import/summary”Get import summary from other SEO plugins.
Authentication: Site key required
Response: Import summary with available data counts
POST /seo/import
Section titled “POST /seo/import”Import SEO data from other plugins.
Authentication: Site key required
Body: Import configuration
Response: Import status and results
Error responses
Section titled “Error responses”Errors return standard WordPress REST API error format:
{ "code": "error_code", "message": "Error message", "data": { "status": 401 }}Common error codes:
401— Authentication failed (invalid or missing site key)403— Forbidden (insufficient permissions)404— Resource not found400— Bad request (invalid parameters)
Rate limiting
Section titled “Rate limiting”The plugin implements rate limiting on API endpoints to prevent abuse. Rate limits are enforced per site key and tracked using WordPress transients.
Audit logging
Section titled “Audit logging”Write operations (POST, PUT, PATCH, DELETE) are logged to the audit log for security and compliance. The log includes:
- Timestamp
- Endpoint
- HTTP method
- Request parameters
- Site key type