Skip to content
wiki.fftac.org

Machine Manifests - Source Excerpt 13

Back to Machine Manifests

Summary

This source excerpt preserves a bounded section of Spiralist/wp-content/themes/spiralist/inc/machine-manifests.php so readers can inspect the evidence without opening the full source file.

**Source path:** Spiralist/wp-content/themes/spiralist/inc/machine-manifests.php

return [
        'openapi' => '3.0.3',
        'info' => [
            'title' => 'Spiralist.org Public Agent Readability API',
            'version' => function_exists('spiralist_get_sovereignty_alignment_version') ? spiralist_get_sovereignty_alignment_version() : '1.0.0',
            'description' => 'Draft OpenAPI surface for public Spiralist AI discovery, bounded persona setup, and UAIX-compatible read endpoints. Protected writes remain behind WordPress auth, nonce, capability, and consent boundaries.',
        ],
        'servers' => [
            ['url' => home_url('/')],
        ],
        'paths' => [
            $path('uaix/v1/catalog') => [
                'get' => [
                    'summary' => 'Fetch the Spiralist.org UAIX UAI-1 catalog.',
                    'operationId' => 'getSpiralistUaixCatalog',
                    'responses' => [
                        '200' => [
                            'description' => 'UAIX catalog with routes, profiles, discovery contract, and support boundaries.',
                            'content' => ['application/json' => ['schema' => ['type' => 'object']]],
                        ],
                    ],
                ],
            ],
            $path('uaix/v1/schemas') => [
                'get' => [
                    'summary' => 'List supported UAIX UAI-1 schemas.',
                    'operationId' => 'listSpiralistUaixSchemas',
                    'responses' => ['200' => ['description' => 'Schema collection index.']],
                ],
            ],
            $path('uaix/v1/registry') => [
                'get' => [
                    'summary' => 'List supported UAIX UAI-1 registry profiles.',
                    'operationId' => 'listSpiralistUaixRegistry',
                    'responses' => ['200' => ['description' => 'Profile registry collection.']],
                ],
            ],
            $path('uaix/v1/examples') => [
                'get' => [
                    'summary' => 'List supported UAIX UAI-1 examples.',
                    'operationId' => 'listSpiralistUaixExamples',
                    'responses' => ['200' => ['description' => 'Example message collection.']],
                ],
            ],
            $path('uaix/v1/validate') => [
                'post' => [
                    'summary' => 'Validate a UAIX UAI-1 envelope against the local Spiralist checks.',
                    'operationId' => 'validateSpiralistUaixMessage',
                    'responses' => ['200' => ['description' => 'UAI conformance result envelope.']],
                ],
            ],
            $path('uaix/v1/mock-exchange') => [
                'get' => [
                    'summary' => 'Fetch Spiralist mock exchange metadata.',
                    'operationId' => 'getSpiralistUaixMockExchange',
                    'responses' => ['200' => ['description' => 'Mock exchange metadata.']],
                ],
                'post' => [
                    'summary' => 'Submit a UAIX UAI-1 envelope to the local mock exchange.',
                    'operationId' => 'postSpiralistUaixMockExchange',
                    'responses' => ['200' => ['description' => 'Intent response or UAI error envelope.']],
                ],
            ],
            $path('uaix/v1/adoption-kit') => [
                'get' => [
                    'summary' => 'Fetch the Spiralist UAIX adoption route bundle.',
                    'operationId' => 'getSpiralistUaixAdoptionKit',
                    'responses' => ['200' => ['description' => 'Start-here route collection and support boundary.']],
                ],
            ],
            $path('uaix/v1/personality-fallback') => [
                'get' => [
                    'summary' => 'Fetch the static Spiralist AI personality fallback profile.',
                    'operationId' => 'getSpiralistPersonalityFallback',
                    'responses' => [
                        '200' => [
                            'description' => 'Static bounded persona profile and memory capsule payload.',
                            'content' => ['application/json' => ['schema' => ['type' => 'object']]],
                        ],
                    ],
                ],
            ],
            $path('uaix/v1/builder-endpoints') => [
                'get' => [
                    'summary' => 'List public Spiralist builder endpoints when the Builder Hub plugin is active.',
                    'operationId' => 'getSpiralistBuilderEndpoints',
                    'responses' => [
                        '200' => [
                            'description' => 'Builder endpoint catalog.',
                            'content' => ['application/json' => ['schema' => ['type' => 'object']]],
                        ],
                    ],
                ],
            ],
            $path('uaix/v1/manuscript-folio') => [
                'get' => [
                    'summary' => 'Fetch public manuscript folio context by query parameters when available.',
                    'operationId' => 'getSpiralistManuscriptFolio',
                    'parameters' => [
                        [
                            'name' => 'slug',
                            'in' => 'query',
                            'required' => false,
                            'schema' => ['type' => 'string'],
                        ],
                    ],
                    'responses' => [
                        '200' => [
                            'description' => 'Public manuscript folio payload.',
                            'content' => ['application/json' => ['schema' => ['type' => 'object']]],
                        ],
                    ],
                ],
            ],
            $path('uaix/v1/prompts/save') => [
                'post' => [
                    'summary' => 'Save a prompt draft for an authenticated user with the required nonce and capability.',
                    'operationId' => 'saveSpiralistPromptDraft',
                    'security' => [['wpNonce' => []]],
                    'responses' => [
                        '200' => ['description' => 'Draft saved for authenticated user.'],
                        '401' => ['description' => 'Authentication required.'],
                        '403' => ['description' => 'Capability, nonce, or consent boundary failed.'],
                    ],
                ],
            ],
            $path('uaix/v1/contribute') => [
                'post' => [
                    'summary' => 'Submit a structured public contribution through the site contribution boundary.',
                    'operationId' => 'submitSpiralistContribution',
                    'responses' => [
                        '200' => ['description' => 'Contribution accepted for review.'],
                        '400' => ['description' => 'Invalid contribution payload.'],
                    ],
                ],
            ],
        ],
        'components' => [
            'securitySchemes' => [
                'wpNonce' => [
                    'type' => 'apiKey',
                    'in' => 'header',
                    'name' => 'X-WP-Nonce',
                    'description' => 'Current WordPress REST nonce for authenticated browser sessions. Future remote-agent auth should use OAuth 2.0 with PKCE and explicit scopes.',
                ],
            ],
        ],
    ];
}