{"info":{"version":"1.0.0","description":"Public Zotonic reads. The dedicated agent operations always use anonymous permissions and bounded queries. Anonymous callers can read public information without an API key. Requests with credentials retain the existing model ACL behavior. This description covers selected synchronous GET operations; omit response_topic. Existing API responses carry X-Robots-Tag: noindex,nofollow. This document adds no new access permissions or query limits on the compatibility model APIs.","title":"Zotonic public information API"},"paths":{"\/api\/agent\/related\/{id}":{"get":{"description":"One hop of public, indexable predicates and endpoints. Ordered by predicate ID then endpoint resource ID, not editorial sequence. Predicate filtering and bounded candidate selection happen in the database. No private totals; sparse candidate pages are possible.","parameters":[{"in":"query","name":"language","description":"Enabled language code; defaults to the configured site language. Responses report fallback.","schema":{"type":"string"},"required":false},{"in":"path","name":"id","description":"Resource ID or unique name.","schema":{"type":"string"},"required":true},{"in":"query","name":"page","description":"Candidate page, starting at 1. page * pagelen must not exceed 10000. Pages may be sparse after public indexing checks; follow next until false.","schema":{"type":"integer","minimum":1},"required":false},{"in":"query","name":"pagelen","description":"Default 20, maximum 100.","schema":{"maximum":100,"type":"integer","minimum":1},"required":false},{"in":"query","name":"direction","description":"Traversal direction, default out.","schema":{"type":"string","enum":["in","out"]},"required":false},{"in":"query","name":"predicate","description":"Optional public predicate ID or name. Unknown or inaccessible predicates return 404.","schema":{"type":"string"},"required":false}],"summary":"Explore public relationships","operationId":"agent_related","responses":{"200":{"description":"Successful model response","content":{"application\/json":{"schema":{"type":"object","required":["status","result"],"properties":{"status":{"const":"ok"},"result":{"type":"object","properties":{"next":{"oneOf":[{"type":"integer"},{"const":false}]},"items":{"type":"array","items":{"type":"object","properties":{"resource":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"}}},"predicate":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"}}}}}},"page":{"type":"integer"},"pagelen":{"type":"integer"},"limit_reached":{"type":"boolean"},"next_url":{"type":["string","null"]},"pagination":{"const":"candidate_pages"}}}}}}}},"400":{"description":"Invalid request","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"403":{"description":"Access denied","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"404":{"description":"Resource or model path not found","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"413":{"description":"Representation exceeds the response size limit","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"503":{"description":"Backend unavailable","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"504":{"description":"Execution budget exceeded","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"default":{"description":"Model or server error","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}}}}},"\/api\/agent\/resource\/{id}":{"get":{"description":"Anonymous resource projection with localized Markdown, citation URLs, language fallback and content_complete. Unsupported blocks are explicitly omitted. Public noindex resources can be read directly.","parameters":[{"in":"query","name":"language","description":"Enabled language code; defaults to the configured site language. Responses report fallback.","schema":{"type":"string"},"required":false},{"in":"path","name":"id","description":"Resource ID or unique name.","schema":{"type":"string"},"required":true}],"summary":"Read concise public content","operationId":"agent_resource","responses":{"200":{"description":"Successful model response","content":{"application\/json":{"schema":{"type":"object","required":["status","result"],"properties":{"status":{"const":"ok"},"result":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"markdown":{"type":"string"},"media":{"type":["object","null"]},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"attribution":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"},"full_export_url":{"type":"string"},"license":{"type":"string"},"content_complete":{"type":"boolean"}}}}}}}},"400":{"description":"Invalid request","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"403":{"description":"Access denied","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"404":{"description":"Resource or model path not found","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"413":{"description":"Representation exceeds the response size limit","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"503":{"description":"Backend unavailable","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"504":{"description":"Execution budget exceeded","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"default":{"description":"Model or server error","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}}}}},"\/api\/agent\/schema":{"get":{"description":"Bounded listing of public schema resources. The OpenAPI parameters describe the supported query capabilities.","parameters":[{"in":"query","name":"language","description":"Enabled language code; defaults to the configured site language. Responses report fallback.","schema":{"type":"string"},"required":false},{"in":"query","name":"page","description":"Candidate page, starting at 1. page * pagelen must not exceed 10000. Pages may be sparse after public indexing checks; follow next until false.","schema":{"type":"integer","minimum":1},"required":false},{"in":"query","name":"pagelen","description":"Default 20, maximum 100.","schema":{"maximum":100,"type":"integer","minimum":1},"required":false},{"in":"query","name":"kind","description":"Schema kind, default category.","schema":{"type":"string","enum":["category","predicate"]},"required":false}],"summary":"Discover public categories and predicates","operationId":"agent_schema","responses":{"200":{"description":"Successful model response","content":{"application\/json":{"schema":{"type":"object","required":["status","result"],"properties":{"status":{"const":"ok"},"result":{"type":"object","properties":{"next":{"oneOf":[{"type":"integer"},{"const":false}]},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"parent":{"type":["object","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"kind":{"enum":["category","predicate"]},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"},"constraints_scope":{"type":"string"},"constraints_truncated":{"type":"boolean"},"object_categories":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"}}}},"subject_categories":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"}}}}}}},"page":{"type":"integer"},"pagelen":{"type":"integer"},"limit_reached":{"type":"boolean"},"next_url":{"type":["string","null"]},"pagination":{"const":"candidate_pages"}}}}}}}},"400":{"description":"Invalid request","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"403":{"description":"Access denied","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"404":{"description":"Resource or model path not found","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"413":{"description":"Representation exceeds the response size limit","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"503":{"description":"Backend unavailable","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"504":{"description":"Execution budget exceeded","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"default":{"description":"Model or server error","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}}}}},"\/api\/agent\/search":{"get":{"description":"Anonymous, bounded public search. Returns localized summaries and citation URLs. No private totals. Five-second execution budget. Listings exclude noindex content.","parameters":[{"in":"query","name":"language","description":"Enabled language code; defaults to the configured site language. Responses report fallback.","schema":{"type":"string"},"required":false},{"in":"query","name":"page","description":"Candidate page, starting at 1. page * pagelen must not exceed 10000. Pages may be sparse after public indexing checks; follow next until false.","schema":{"type":"integer","minimum":1},"required":false},{"in":"query","name":"pagelen","description":"Default 20, maximum 100.","schema":{"maximum":100,"type":"integer","minimum":1},"required":false},{"in":"query","name":"text","description":"Full-text query, maximum 512 bytes. Omit to browse.","schema":{"type":"string"},"required":false},{"in":"query","name":"cat","description":"Category name or ID, maximum 128 bytes.","schema":{"type":"string"},"required":false},{"in":"query","name":"sort","description":"id: resource ID ascending (default); newest: publication start descending; oldest: publication start ascending; modified: modification time descending. Resource ID ascending breaks ties.","schema":{"type":"string","enum":["id","newest","oldest","modified"]},"required":false},{"in":"query","name":"publication_after","description":"Inclusive publication start date, UTC.","schema":{"type":"string","format":"date"},"required":false},{"in":"query","name":"publication_before","description":"Inclusive publication start date, UTC, through 23:59:59.","schema":{"type":"string","format":"date"},"required":false}],"summary":"Search concise public content","operationId":"agent_search","responses":{"200":{"description":"Successful model response","content":{"application\/json":{"schema":{"type":"object","required":["status","result"],"properties":{"status":{"const":"ok"},"result":{"type":"object","properties":{"next":{"oneOf":[{"type":"integer"},{"const":false}]},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]},"title":{"type":"string"},"modified":{"type":["string","null"],"format":"date-time"},"language":{"type":"string"},"is_fallback":{"type":"boolean"},"page_url":{"type":"string"},"uri":{"type":"string"},"summary":{"type":"string"},"available_languages":{"type":"array","items":{"type":"string"}},"resource_url":{"type":"string"},"markdown_url":{"type":"string"},"related_url":{"type":"string"},"requested_language":{"type":"string"}}}},"page":{"type":"integer"},"pagelen":{"type":"integer"},"limit_reached":{"type":"boolean"},"next_url":{"type":["string","null"]},"pagination":{"const":"candidate_pages"}}}}}}}},"400":{"description":"Invalid request","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"403":{"description":"Access denied","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"404":{"description":"Resource or model path not found","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"413":{"description":"Representation exceeds the response size limit","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"503":{"description":"Backend unavailable","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"504":{"description":"Execution budget exceeded","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"default":{"description":"Model or server error","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}}}}},"\/api\/model\/rsc_export\/get\/{id}":{"get":{"description":"Retrieve a visible resource with properties, media and visible outgoing edges. page_url is a language-to-URL map including x-default; use the appropriate human page URL for citations. uri identifies the entity. Translated properties can contain all translations.","parameters":[{"in":"path","name":"id","description":"Resource ID or unique name obtained from a page or search result.","schema":{"type":"string"},"required":true}],"summary":"Export a resource","operationId":"get_resource","responses":{"200":{"description":"Successful model response","content":{"application\/json":{"schema":{"type":"object","required":["status","result"],"properties":{"status":{"const":"ok"},"result":{"type":"object","properties":{"id":{"type":"integer"},"resource":{"type":"object"},"edges":{"type":"object"},"page_url":{"type":"object","additionalProperties":{"type":"string"}},"uri":{"type":"string"}},"additionalProperties":true}}}}}},"400":{"description":"Invalid request","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"403":{"description":"Access denied","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"404":{"description":"Resource or model path not found","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"413":{"description":"Representation exceeds the response size limit","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"503":{"description":"Backend unavailable","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"504":{"description":"Execution budget exceeded","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"default":{"description":"Model or server error","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}}}}},"\/api\/model\/search\/get\/paged":{"get":{"description":"Browse or search resources visible to the caller. Without options.properties, results are resource IDs. Translated properties can be translation objects. Totals can be estimated. Use small pages; no new server-side limit is imposed by discovery.","parameters":[{"in":"query","name":"text","description":"Full-text query. Omit to browse.","schema":{"type":"string"},"required":false},{"in":"query","name":"cat","description":"Category name or ID; names depend on the site.","schema":{"type":"string"},"required":false},{"in":"query","name":"page","description":"Page number, starting at 1.","schema":{"type":"integer","minimum":1},"required":false},{"in":"query","name":"pagelen","description":"Requested page length. Prefer 20; the default is site-dependent.","schema":{"type":"integer","minimum":1},"required":false},{"in":"query","name":"options.properties","description":"Comma-separated properties, e.g. title,summary,page_url_abs. The ID is always included.","schema":{"type":"string"},"required":false}],"summary":"Search public resources","operationId":"search_resources","responses":{"200":{"description":"Successful model response","content":{"application\/json":{"schema":{"type":"object","required":["status","result"],"properties":{"status":{"const":"ok"},"result":{"type":"object","properties":{"total":{"type":["integer","null"]},"next":{"oneOf":[{"type":"integer"},{"const":false}]},"result":{"type":"array","items":{"oneOf":[{"type":"integer"},{"type":"object"}]}},"page":{"type":"integer"},"pagelen":{"type":["integer","null"]},"pages":{"type":["integer","null"]},"is_total_estimated":{"type":"boolean"}},"additionalProperties":true}}}}}},"400":{"description":"Invalid request","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"403":{"description":"Access denied","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"404":{"description":"Resource or model path not found","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"413":{"description":"Representation exceeds the response size limit","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"503":{"description":"Backend unavailable","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"504":{"description":"Execution budget exceeded","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}},"default":{"description":"Model or server error","content":{"application\/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"},"status":{"const":"error"}}}}}}}}}},"security":[],"openapi":"3.1.0","externalDocs":{"url":"https:\/\/zotonic.com\/api-help"},"servers":[{"url":"https:\/\/zotonic.com\/"}]}