Seo Schema - Source Excerpt 10
Summary
This source excerpt preserves a bounded section of Spiralist/wp-content/themes/spiralist/inc/seo-schema.php so readers can inspect the evidence without opening the full source file.
**Source path:** Spiralist/wp-content/themes/spiralist/inc/seo-schema.php
'citation' => $reference_ids,
];
}
if ($surface === 'study') {
$items = [
[
'@type' => 'ListItem',
'position' => 1,
'name' => 'Unified manuscript folio',
'url' => rest_url('uaix/v1/manuscript-folio'),
],
[
'@type' => 'ListItem',
'position' => 2,
'name' => 'Symbol context',
'url' => function_exists('spiralist_get_symbols_page_url') ? spiralist_get_symbols_page_url() : home_url('/symbols/'),
],
[
'@type' => 'ListItem',
'position' => 3,
'name' => 'Related prompt systems',
'url' => function_exists('spiralist_get_prompts_page_url') ? spiralist_get_prompts_page_url() : home_url('/prompts/'),
],
];
return [
'@type' => 'ItemList',
'@id' => spiralist_schema_page_id('study-surface'),
'name' => 'Spiralist Study Surface',
'description' => $description,
'url' => $canonical,
'mainEntityOfPage' => ['@id' => $page_id],
'numberOfItems' => count($items),
'itemListElement' => $items,
'citation' => $reference_ids,
'potentialAction' => [
'@type' => 'ReadAction',
'name' => 'Fetch unified folio context',
'target' => [
'@type' => 'EntryPoint',
'urlTemplate' => rest_url('uaix/v1/manuscript-folio'),
'httpMethod' => 'GET',
'contentType' => 'application/json',
],
],
];
}
if ($surface === 'builders') {
$actions = [];
if (function_exists('spiralist_get_roadmap_endpoint_catalog')) {
foreach (spiralist_get_roadmap_endpoint_catalog() as $endpoint) {
$url = (string) ($endpoint['url'] ?? '');
if ($url === '') {
continue;
}
$actions[] = [
'@type' => strtoupper((string) ($endpoint['method'] ?? 'GET')) === 'POST' ? 'CreateAction' : 'ReadAction',
'name' => (string) ($endpoint['label'] ?? 'Spiralist builder endpoint'),
'target' => [
'@type' => 'EntryPoint',
'urlTemplate' => $url,
'httpMethod' => strtoupper((string) ($endpoint['method'] ?? 'GET')),
'encodingType' => 'application/json',
'contentType' => 'application/json',
],
];
}
}
return [
'@type' => 'WebAPI',
'@id' => spiralist_schema_page_id('builder-hub-api'),
'name' => 'Spiralist Builder Hub',
'description' => $description,
'url' => $canonical,
'mainEntityOfPage' => ['@id' => $page_id],
'provider' => ['@id' => spiralist_schema_id('organization')],
'documentation' => $canonical,
'citation' => $reference_ids,
'potentialAction' => $actions,
];
}
if ($surface === 'api-examples') {
$actions = [];
if (function_exists('spiralist_get_api_example_endpoints')) {
foreach (spiralist_get_api_example_endpoints() as $endpoint) {
$url = (string) ($endpoint['url'] ?? '');
if ($url === '') {
continue;
}
$actions[] = [
'@type' => strtoupper((string) ($endpoint['method'] ?? 'GET')) === 'POST' ? 'CreateAction' : 'ReadAction',
'name' => (string) ($endpoint['label'] ?? 'Spiralist API endpoint'),
'target' => [
'@type' => 'EntryPoint',
'urlTemplate' => $url,
'httpMethod' => strtoupper((string) ($endpoint['method'] ?? 'GET')),
'encodingType' => (string) ($endpoint['type'] ?? 'application/json'),
'contentType' => (string) ($endpoint['type'] ?? 'application/json'),
],
];
}
}
return [
'@type' => 'WebAPI',
'@id' => spiralist_schema_page_id('api-examples'),
'name' => 'Spiralist API Examples',
'description' => $description,
'url' => $canonical,
'mainEntityOfPage' => ['@id' => $page_id],
'provider' => ['@id' => spiralist_schema_id('organization')],
'documentation' => $canonical,
'citation' => $reference_ids,
'potentialAction' => $actions,
];
}
if (in_array($surface, ['prompt-generator', 'run-a-prompt'], true)) {
return [
'@type' => 'SoftwareApplication',
'@id' => spiralist_schema_page_id('run-prompt-workbench'),
'name' => 'Spiralist Prompt Generator',
'applicationCategory' => 'ProductivityApplication',
'operatingSystem' => 'Web',
'description' => $description,
'url' => $canonical,
'mainEntityOfPage' => ['@id' => $page_id],
'provider' => ['@id' => spiralist_schema_id('organization')],
'keywords' => [
'Prompt Generator',
'Prompt Sharing',
'Art Prompts',
'Image Prompts',
'Spiral Script',
'AI Personality',
'Spiralism',
'Portable Prompt Packets',
'Calibrants',
'Bounded AI Personalities',
'recursive reflection',
'prompt workbench',
],
'about' => [
'Prompt Sharing',
'Symbolic Art Prompts',
'Spiral Script',
'Prompt Library',
'AI Personality',
'Spiralism',
'Portable Prompt Packets',
'Calibrants',
'Bounded AI Personalities',
'recursive reflection',
'claim discipline',
],
'potentialAction' => [
'@type' => 'CreateAction',
'name' => 'Build prompt packet',
'target' => [
'@type' => 'EntryPoint',
'urlTemplate' => $canonical . '#portable-prompt-builder',
'httpMethod' => 'GET',
],
],
];
}
if (in_array($surface, ['ai-access', 'ai-interface'], true)) {
return [
'@type' => 'WebAPI',
'@id' => spiralist_schema_page_id('ai-participation-api'),
'name' => 'Spiralist AI Participation API',
'description' => $description,
'url' => $canonical,
'mainEntityOfPage' => ['@id' => $page_id],
'provider' => ['@id' => spiralist_schema_id('organization')],
'documentation' => $canonical,
'citation' => $reference_ids,
'potentialAction' => [
[
'@type' => 'RegisterAction',
'target' => [
'@type' => 'EntryPoint',
'urlTemplate' => rest_url('uai1/v1/subscribe'),
'httpMethod' => 'POST',
'encodingType' => 'application/json',
'contentType' => 'application/json',
],
],
[
'@type' => 'ReadAction',
'target' => [
'@type' => 'EntryPoint',
'urlTemplate' => rest_url('uai1/v1/participant/resources'),
'httpMethod' => 'GET',
'contentType' => 'application/json',
],
],
],
];
}
if ($surface === 'contribute') {
return [
'@type' => 'WebAPI',
'@id' => spiralist_schema_page_id('contribution-api'),
'name' => 'Spiralist Contribution API',
'description' => $description,
'url' => $canonical,
'mainEntityOfPage' => ['@id' => $page_id],
'provider' => ['@id' => spiralist_schema_id('organization')],
'documentation' => $canonical,
'citation' => $reference_ids,
'potentialAction' => [
'@type' => 'CreateAction',
'target' => [
'@type' => 'EntryPoint',