SEO configuration, robots.txt management, sitemap generation, and search engine indexing (IndexNow + Google Indexing API).

10 endpoints

GET /seo/settings

Get SEO settings

Returns global SEO configuration (default meta tags, robots directives, indexing settings).

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
curl https://api.lynkow.com/v1/seo/settings \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "id": 1,
  "siteId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "robotsRules": [
    {
      "userAgent": "*",
      "rules": [
        {
          "path": "/",
          "allow": true
        },
        {
          "path": "/admin",
          "allow": false
        }
      ]
    }
  ],
  "robotsSitemapLink": true,
  "defaultPriority": 0.5,
  "defaultChangefreq": "weekly",
  "includeContentsInSitemap": true,
  "contentPathPrefixes": {},
  "contentTypePriorities": {},
  "blogUrlMode": "flat",
  "blogPrefix": null,
  "indexNowKey": "abc123def456",
  "indexNowEnabled": true,
  "indexNowLastVerifiedAt": "2025-04-01T10:00:00.000Z",
  "googleIndexingEnabled": false,
  "llmsTxtEnabled": true,
  "llmsSiteDescription": "Lynkow is a headless CMS platform.",
  "sitemapIndexEnabled": false,
  "createdAt": "2025-01-01T00:00:00.000Z",
  "updatedAt": "2025-04-05T14:30:00.000Z"
}

PUT /seo/settings

Update SEO settings

Updates global SEO configuration.

Request Body

Content-Type: application/json

Field

Type

Required

Description

robotsRules

object[]

No

Array of objects

robotsSitemapLink

boolean

No

Boolean

defaultPriority

number

No

Between 0 and 1

defaultChangefreq

"always" | "hourly" | "daily" | "weekly" | "monthly" | "yearly" | "never"

No

One of: always, hourly, daily, weekly, monthly, yearly, never

includeContentsInSitemap

boolean

No

Boolean

contentPathPrefixes

object

No

URL path prefixes for content types

contentTypePriorities

object

No

Content type priority order in sitemap

indexNowEnabled

boolean

No

Boolean

indexNowKey

string

No

8-64 characters

googleIndexingEnabled

boolean

No

Boolean

blogUrlMode

"flat" | "nested"

No

One of: flat, nested

blogPrefix

string | null

No

URL prefix for blog (e.g. "blog")

llmsTxtEnabled

boolean

No

Boolean

llmsSiteDescription

string | null

No

Site description for LLM crawlers

sitemapIndexEnabled

boolean

No

Boolean

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

422

Validation error

Examples

Bash
curl -X PUT https://api.lynkow.com/v1/seo/settings \
  -H "Authorization: Bearer $API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "blogUrlMode": "nested",
    "blogPrefix": "blog",
    "indexNowEnabled": true,
    "llmsTxtEnabled": true,
    "llmsSiteDescription": "Our company blog and knowledge base."
  }'

Response Example

JSON
{
  "id": 1,
  "siteId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "robotsRules": [
    {
      "userAgent": "*",
      "rules": [
        {
          "path": "/",
          "allow": true
        },
        {
          "path": "/admin",
          "allow": false
        }
      ]
    }
  ],
  "robotsSitemapLink": true,
  "defaultPriority": 0.5,
  "defaultChangefreq": "weekly",
  "includeContentsInSitemap": true,
  "contentPathPrefixes": {},
  "contentTypePriorities": {},
  "blogUrlMode": "nested",
  "blogPrefix": "blog",
  "indexNowKey": "abc123def456",
  "indexNowEnabled": true,
  "googleIndexingEnabled": false,
  "llmsTxtEnabled": true,
  "llmsSiteDescription": "Our company blog and knowledge base.",
  "sitemapIndexEnabled": false,
  "createdAt": "2025-01-01T00:00:00.000Z",
  "updatedAt": "2025-04-06T11:00:00.000Z"
}

GET /seo/robots.txt

Get robots.txt

Returns the current robots.txt content as configured in SEO settings.

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
# Returns plain text (Content-Type: text/plain)
curl https://api.lynkow.com/v1/seo/robots.txt \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
"Returns plain text (Content-Type: text/plain). Example output:\nUser-agent: *\nAllow: /\nDisallow: /admin\nSitemap: https://www.example.com/sitemap.xml\n"

GET /seo/sitemap.xml

Get XML sitemap

Returns the generated XML sitemap combining auto-discovered pages (contents, site blocks) and custom sitemap entries.

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
# Returns XML — pipe to file or parse with xmllint
curl https://api.lynkow.com/v1/seo/sitemap.xml \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
"The response is an XML document following the sitemap protocol:\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<urlset xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\">\n  <url>\n    <loc>https://example.com/blog/getting-started</loc>\n    <lastmod>2025-04-05</lastmod>\n    <changefreq>weekly</changefreq>\n    <priority>0.8</priority>\n  </url>\n</urlset>\n"

GET /seo/sitemap.json

Get JSON sitemap

Same as the XML sitemap but in JSON format for programmatic consumption.

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
curl https://api.lynkow.com/v1/seo/sitemap.json \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "data": [
    {
      "url": "https://www.example.com/blog/getting-started",
      "lastmod": "2025-04-05",
      "changefreq": "weekly",
      "priority": 0.8
    },
    {
      "url": "https://www.example.com/about",
      "lastmod": "2025-03-20",
      "changefreq": "monthly",
      "priority": 0.6
    }
  ]
}

GET /seo/indexnow/test

Test IndexNow submission

Submits a test URL to IndexNow to verify the integration is working. Returns the response from the IndexNow API.

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Notes: - Requires an IndexNow key configured in SEO settings.

Examples

Bash
curl https://api.lynkow.com/v1/seo/indexnow/test \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "status": "ok",
  "url": "https://www.example.com",
  "responseCode": 200
}

GET /seo/indexnow/logs

Get IndexNow submission logs

Returns the history of IndexNow submissions with their status (success/error).

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
curl https://api.lynkow.com/v1/seo/indexnow/logs \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "data": [
    {
      "id": 1,
      "url": "https://www.example.com/blog/getting-started",
      "status": "success",
      "responseCode": 200,
      "submittedAt": "2025-04-05T10:30:00.000Z"
    },
    {
      "id": 2,
      "url": "https://www.example.com/blog/new-features",
      "status": "success",
      "responseCode": 200,
      "submittedAt": "2025-04-04T14:00:00.000Z"
    }
  ],
  "meta": {
    "total": 150,
    "perPage": 15,
    "currentPage": 1,
    "lastPage": 10
  }
}

GET /seo/indexnow/stats

Get IndexNow statistics

Returns aggregate IndexNow stats (total submissions, success rate, errors).

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
curl https://api.lynkow.com/v1/seo/indexnow/stats \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "total": 150,
  "success": 142,
  "failed": 8,
  "lastSubmittedAt": "2025-04-05T10:30:00.000Z"
}

GET /seo/google-indexing/logs

Get Google Indexing API logs

Returns the history of Google Indexing API submissions.

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Notes: - Requires Google Search Console integration configured for the site.

Examples

Bash
curl https://api.lynkow.com/v1/seo/google-indexing/logs \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "data": [
    {
      "id": 1,
      "url": "https://www.example.com/blog/getting-started",
      "type": "URL_UPDATED",
      "status": "success",
      "submittedAt": "2025-04-05T11:00:00.000Z"
    },
    {
      "id": 2,
      "url": "https://www.example.com/blog/new-features",
      "type": "URL_UPDATED",
      "status": "error",
      "error": "Quota exceeded",
      "submittedAt": "2025-04-04T15:00:00.000Z"
    }
  ],
  "meta": {
    "total": 85,
    "perPage": 15,
    "currentPage": 1,
    "lastPage": 6
  }
}

GET /seo/google-indexing/stats

Get Google Indexing API statistics

Returns aggregate Google Indexing API stats.

Responses

Status

Description

200

Successful response

401

Unauthorized — invalid or missing API token

403

Forbidden — insufficient permissions

Examples

Bash
curl https://api.lynkow.com/v1/seo/google-indexing/stats \
  -H "Authorization: Bearer $API_TOKEN"

Response Example

JSON
{
  "total": 85,
  "success": 78,
  "failed": 7,
  "lastSubmittedAt": "2025-04-05T11:00:00.000Z"
}