Publishing & connections·4 min read
Publish to a custom-built website (custom API)
A website with its own admin panel receives articles through an API endpoint your developer creates - no WordPress needed.
Use this when your website does not run WordPress, Shopify, Haravan, Sapo, Ghost, Webflow or Hashnode but is custom-built (Next.js, Laravel, PHP, Python...).
How it works
- Your developer creates an article-receiving endpoint (POST, HTTPS), e.g.
https://your-website.com/api/blog/receive. - Every time you approve an article (or Autopilot publishes one), the system sends the article to that endpoint: title, slug, HTML and Markdown content, description, FAQ, cover image, image list, category, status.
- The website stores the article and returns its
idandurl- only with a url can the system share it on social media. Google indexing is requested manually in Search Console.
Connect
- Go to Website settings › Integrations › Custom API › Add.
- Paste the receiving endpoint. In the Secret box, click Generate and copy this secret into your website's config (the secret is shown only once).
- Enter the category if your website needs one (default
tin-tuc). - Click Test & save - the system sends a trial request with
"event": "ping"; your website should return 200 without storing an article.
For the developer
Full documentation, signature verification (X-Signature, HMAC-SHA256) and sample code for Next.js, Express, Laravel and FastAPI are on the API documentation page.
Common errors
- 401 - the secret on the website differs from the saved one.
- 405 - the endpoint does not accept the POST method yet.
- "The address returned a web page, not an API" - wrong endpoint, or it redirects to a login/404 page.
- Article sent but not visible - the website only treats
"published"as public; the system sends"publish", so accept both.