{"openapi":"3.1.0","info":{"title":"SearchBlueprint REST API","version":"1","summary":"Projects, audits, articles, article generation and publishing for the websites a key can see.","description":"Authorize with a content API key (sbk_...) made on a project's Publishing page, sent as X-API-Key or Authorization: Bearer. A key sees one project, or a workspace's projects. An id outside the key's scope answers 404, the same as a missing one. Reads: 120 requests per 10 minutes per IP. POST /articles and POST /articles/{id}/publish: a further 20 per 10 minutes per key, since each spends credits or writes to a site. Responses are not versioned by path: fields are added over time, so read the ones you use and ignore the rest. Errors are JSON with an error string.","contact":{"name":"SearchBlueprint support","email":"hello@searchblueprint.io","url":"https://docs.searchblueprint.io/developers/rest-api"}},"externalDocs":{"description":"REST API guide","url":"https://docs.searchblueprint.io/developers/rest-api"},"servers":[{"url":"https://searchblueprint.io/api/v1"}],"security":[{"apiKey":[]},{"bearer":[]}],"paths":{"/projects":{"get":{"operationId":"listProjects","summary":"List the projects the key can see","description":"Each project with the grade of its latest finished audit.","responses":{"200":{"description":"The projects.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Project"}}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/projects/{id}/audit":{"get":{"operationId":"getLatestAudit","summary":"Get a project's latest finished SEO audit","description":"The latest graded audit: score, grade, verdict, category grades and recommendations. audit is null when none has finished.","parameters":[{"name":"id","in":"path","required":true,"description":"The project's uuid.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"The latest audit, or null.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditEnvelope"}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such project in the key's scope.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/projects/{id}/integrations":{"get":{"operationId":"listIntegrations","summary":"List a project's publishing connections","description":"The CMS connections an article can be published through, with each one's draft-vs-live default.","parameters":[{"name":"id","in":"path","required":true,"description":"The project's uuid.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"The connections.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Integration"}}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such project in the key's scope.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/projects/{id}/rankings":{"get":{"operationId":"getRankings","deprecated":true,"summary":"Retired: rank history","description":"Retired on 2026-09-17. Always answers 410 Gone; tracked keywords live on each website's Rankings page.","parameters":[{"name":"id","in":"path","required":true,"description":"The project's uuid.","schema":{"type":"string","format":"uuid"}}],"responses":{"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"410":{"description":"Retired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/articles":{"get":{"operationId":"listArticles","summary":"List articles, newest first","description":"Article summaries without their bodies.","parameters":[{"name":"limit","in":"query","required":false,"description":"How many to return.","schema":{"type":"integer","minimum":1,"maximum":50,"default":20}},{"name":"offset","in":"query","required":false,"description":"How many to skip.","schema":{"type":"integer","minimum":0,"default":0}}],"responses":{"200":{"description":"The articles.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ArticleSummary"}}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"createArticle","summary":"Start writing an article","description":"Queues one article for a keyword and spends the article's credits. Generation runs over several minutes: poll GET /jobs/{id} until status is done, then read article_id.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["keyword"],"properties":{"keyword":{"type":"string","description":"The search the article should rank for."},"title":{"type":"string","description":"A title to use instead of the writer's own."},"brief":{"type":"string","description":"Notes for the writer: audience, angle, facts to include."},"projectId":{"type":"string","format":"uuid","description":"Required for a workspace key; a project key has one project."}}}}}},"responses":{"202":{"description":"The queued job.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Job"}}}},"400":{"description":"Missing keyword, a malformed id, or a keyword the writer refuses.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The workspace is out of credits.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"The project already has an article for that keyword (existing_article_id), or it is being written.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/articles/{id}":{"get":{"operationId":"getArticle","summary":"Get one article with its body","description":"The article as markdown and as HTML.","parameters":[{"name":"id","in":"path","required":true,"description":"The article's uuid.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"The article.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Article"}}}},"400":{"description":"The id is not a uuid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such article in the key's scope.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/articles/{id}/publish":{"post":{"operationId":"publishArticle","summary":"Publish an article through one connection","description":"Sends the article to a CMS connection. Read state, not sent: published only after the public URL was fetched and carried the article.","parameters":[{"name":"id","in":"path","required":true,"description":"The article's uuid.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["integrationId"],"properties":{"integrationId":{"type":"string","format":"uuid","description":"A connection from GET /projects/{id}/integrations."},"status":{"type":"string","enum":["draft","publish"],"description":"Leave out to use the connection's own default."}}}}}},"responses":{"200":{"description":"What the publish did.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublishResult"}}}},"400":{"description":"A malformed id or a status other than draft or publish.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"The article or connection is not in the key's scope.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"The publish gate blocked the article (placeholders, refusal text, two H1s); issues lists why.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/jobs/{id}":{"get":{"operationId":"getJob","summary":"Check an article generation","description":"Where a generation stands; article_id is set once status is done.","parameters":[{"name":"id","in":"path","required":true,"description":"The job's uuid.","schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"The job.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Job"}}}},"400":{"description":"The id is not a uuid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"No such job in the key's scope.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/feed.xml":{"get":{"operationId":"getFeed","summary":"RSS feed of the key's articles","description":"The key's articles as RSS, for anything that imports a feed. A feed reader that cannot send a header uses the feed URL from Publishing > Developer, whose token reads this feed and nothing else.","parameters":[{"name":"token","in":"query","required":false,"description":"A feed-only token, sbf_... Never the API key.","schema":{"type":"string"}}],"responses":{"200":{"description":"RSS 2.0.","content":{"application/rss+xml":{"schema":{"type":"string"}}}},"401":{"description":"No key, or a revoked one.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited. Wait for the Retry-After header's seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The request failed on our side.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"X-API-Key","description":"A content API key, sbk_..."},"bearer":{"type":"http","scheme":"bearer","description":"The same key as a bearer token."}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"string"}},"additionalProperties":true},"Project":{"type":"object","required":["id","name","domain","created_at"],"properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"domain":{"type":"string"},"country":{"type":["string","null"]},"latest_grade":{"type":["string","null"],"description":"Grade of the latest finished audit."},"created_at":{"type":"string","format":"date-time"}}},"AuditEnvelope":{"type":"object","required":["audit"],"properties":{"audit":{"oneOf":[{"$ref":"#/components/schemas/Audit"},{"type":"null"}]}}},"Audit":{"type":"object","properties":{"analysis_id":{"type":"string","format":"uuid"},"domain":{"type":"string"},"generated_at":{"type":"string","format":"date-time"},"score":{"type":"number","minimum":0,"maximum":100},"grade":{"type":"string"},"verdict":{"type":"string"},"totals":{"type":"object","properties":{"pages":{"type":"integer"},"checks":{"type":"integer"},"pass":{"type":"integer"},"warn":{"type":"integer"},"fail":{"type":"integer"}}},"categories":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"score":{"type":"number"},"grade":{"type":"string"},"counts":{"type":"object"}}}},"recommendations":{"type":"array","items":{"type":"object","properties":{"category":{"type":"string"},"issue":{"type":"string"},"severity":{"type":"string"},"fix":{"type":"string"},"url":{"type":"string"}}}},"unassessed":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"reason":{"type":"string"}}}},"audit_running":{"type":"boolean","description":"A newer audit is in progress."}}},"Integration":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"provider":{"type":"string"},"status":{"type":"string","enum":["untested","connected","error"]},"last_error":{"type":["string","null"]},"auto_publish":{"type":"boolean"},"auto_publish_status":{"type":"string","enum":["draft","publish"],"description":"What a publish does when status is left out."},"created_at":{"type":"string","format":"date-time"}}},"ArticleSummary":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"title":{"type":"string"},"slug":{"type":"string"},"meta_description":{"type":"string"},"excerpt":{"type":"string"},"seedKeyword":{"type":"string"},"keywords":{"type":"array","items":{"type":"string"}},"languageCode":{"type":"string"},"hero_image_url":{"type":["string","null"],"description":"Always null: no hero image is stored."},"orgWebsite":{"type":["string","null"]},"created_at":{"type":"string","format":"date-time"}}},"Article":{"allOf":[{"$ref":"#/components/schemas/ArticleSummary"},{"type":"object","properties":{"content_markdown":{"type":"string"},"content_html":{"type":"string"}}}]},"Job":{"type":"object","properties":{"job_id":{"type":"string","format":"uuid"},"status":{"type":"string","enum":["queued","drafting","revising","done","failed"]},"keyword":{"type":"string"},"project_id":{"type":["string","null"]},"article_id":{"type":["string","null"],"description":"Set once status is done."},"score":{"type":["number","null"]},"revisions":{"type":"integer"},"working":{"type":"boolean"},"queue_ahead":{"type":["integer","null"]},"error":{"type":["string","null"]},"updated_at":{"type":"string","format":"date-time"}}},"PublishResult":{"type":"object","properties":{"sent":{"type":"boolean","description":"The CMS accepted the write. Not proof the page is live; read state."},"requested":{"type":"string","enum":["draft","publish"]},"external_url":{"type":["string","null"]},"error":{"type":["string","null"]},"event":{"type":["object","null"]},"state":{"type":"string","enum":["published","checking","not_live","unverified","gated","failed"]}}}}}}