Connect a custom-built site with the SEOAsist Site API
For sites that don't run on WordPress or Shopify: install and connect the Site API so SEO fixes, blog posts and llms.txt are applied to your site automatically, server-side.
Open this screen in the panelIf your site isn't on WordPress or Shopify (Next.js, Laravel, .NET, plain PHP…), you can add a small API to it and let SEOAsist do the SEO work. Once connected, title, description, canonical, robots, structured-data and redirect fixes are applied server-side, blog posts get published and llms.txt stays up to date. No plugin, no pull requests.
Prerequisites
- You can change the site's code (yourself, a developer, or an AI coding assistant such as Claude or Cursor).
- You can set environment variables for the site (
.envor your hosting panel). - You have edit rights in the panel; otherwise you'll see “You need edit rights for this.”
1. Install the API on your site
- Open the site from Sites and switch to the Fix channels tab.
- In the SEOAsist Site API (custom-built sites) card at the top, press Setup prompt.
- Press Copy in the dialog and hand the text to Claude, Cursor or the developer working on your project. The prompt contains the full spec plus details for this site (site URL, API base URL and, if connected, its GitHub repository).
- Prefer to code it yourself? Press Developer guide. It has Steps, Spec, Next.js, PHP and Test tabs with copy-paste code to start from.
Your site exposes four endpoints under one base path: GET /manifest, PUT /rules, POST /content and PUT /files. See the Site API reference for the details.
2. Save the URL and add the token
- Type the API address into the API base URL field at the bottom of the card. The default suggestion is
https://<your-domain>/api/seoasist. - Press Connect. A yellow box titled Token — shown only now appears with a
SEOASIST_SITE_TOKEN=sa_…line. - Press Copy and add that line to the site's environment variables. Then restart or redeploy the site.
The token is shown only once. If you lose it, press New token to generate another one. The old token stops working immediately, so update the value on your site.
3. Test the connection
- Optionally, try
/manifestfirst with thecurlcommand in Developer guide → Test. - Press Test connection in the card. SEOAsist calls the
/manifestendpoint and stores the capabilities your site declares. - On success you'll see “Connected · capabilities: … · N rules sent”. All enabled rules that were waiting are pushed to the site right away.
What happens automatically after connecting
The status line shows the capabilities your site declared: SEO rules, Content publishing and llms.txt / robots. Each one works on its own, and SEOAsist only uses the ones your site lists.
| Capability | What happens automatically |
|---|---|
| SEO rules | Whenever you add a rule in the Pixel tab, apply meta suggestions or a workspace task runs, the full set of enabled rules is sent to the site. |
| Content publishing | When publishing a post in Content & AI, you can pick Site API (custom site) as the Channel. Your site stores the post in its own blog/CMS and returns the URL. |
| llms.txt / robots | Workspace tasks write llms.txt and the AI-crawler policy block straight to the site. |
The card also has two manual buttons: Send rules now (N) and Send llms.txt. The llms.txt button needs an llms.txt generated in the AI access tab first.
Auto-fix in Technical Audit
When the Site API is connected with the “SEO rules” capability, an Auto-fix button appears next to supported issues on the Technical Audit page. Supported issues: missing, too long, too short or duplicate titles; missing, too long or duplicate meta descriptions; missing canonicals or canonicals pointing to another page; missing html lang; pages marked noindex.
It builds values for the affected pages of the latest crawl (up to 40): AI writes titles and descriptions, while canonical, lang and robots values are computed. They are sent to your site as rules and a verification crawl starts. Running it again for the same issue replaces the earlier rules. More in Intentional issues and auto-fix.
Verification
- The card's status line shows a green Connected, the capability tags and “last push N rules”.
- Open the page source of one of your pages (“View page source” in the browser). The applied title or meta description must be in the HTML. Rules are meant to be applied server-side, not with client-side JavaScript.
- If something fails, the status turns red (Error) and the last error message is shown in the card. See Site API connection problems.
FAQ
Are the rules on my site deleted when I disconnect?
No. Disconnect only stops SEOAsist from sending; the rules stored on your site stay as they are.
What happens if I change the API URL?
Enter the new URL and press Save URL. The status changes to Awaiting test; run Test connection again. The token stays the same.
Does my site change when there are no rules?
It shouldn't. The spec requires every page to render exactly as today when there are no rules, and the setup prompt explicitly asks not to break existing SEO behaviour.
How is this different from the Pixel?
They share the same rules. The Pixel applies them in the browser with JavaScript; the Site API applies them on your server, so search engines see the change directly in the HTML. The Site API can also publish posts and write llms.txt.
Can I connect a local development URL (localhost)?
No. SEOAsist only calls publicly reachable addresses; localhost and private network addresses are rejected. Install the API on your live site.
Related articles
- Site API reference (seoasist-site-api/1)The complete SEOAsist Site API spec: authentication and HMAC signing, the four endpoints, rule kinds and a summary of the ready-made Next.js/PHP samples.
- Site API connection test failsFind and fix the cause of “Test failed”: token, signature, wrong URL, redirects, timeouts, or Apache dropping the Authorization header.
- Accept audit issues as intentional and fix them automaticallyHow to mark issues you left on purpose as Intentional, undo that, and fix issues automatically with rules or a GitHub pull request.
- Content studio: suggestions, blog, page updates and publishingGet title/meta suggestions from Search Console opportunities, write blog posts with AI, expand existing pages and publish to WordPress, the Site API, GitHub or Shopify.