{
    "openapi": "3.1.0",
    "info": {
        "title": "SYSTEMS CPA agent API",
        "version": "1.0.0",
        "description": "Public API for AI assistants and agents acting for a person: evaluate SYSTEMS CPA (licensed CPA practice in Istanbul for foreign-owned companies in Turkey), compare its services, read its guidance and send a scoped proposal request with the user's approval. No sign-in. MCP server: https://www.systemscpa.com/wp-json/scpa/v1/mcp. Guide: https://www.systemscpa.com/for-ai-agents/. Fees are not published.",
        "contact": {
            "name": "SYSTEMS CPA",
            "email": "info@ozmconsultancy.com",
            "url": "https://www.systemscpa.com/for-ai-agents/"
        }
    },
    "servers": [
        {
            "url": "https://www.systemscpa.com/wp-json/scpa/v1"
        }
    ],
    "paths": {
        "/firm": {
            "get": {
                "operationId": "getFirmProfile",
                "summary": "Firm profile: licence, who the firm serves, contact, engagement model and rules for assistants",
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/services": {
            "get": {
                "operationId": "listServices",
                "summary": "Service catalogue with scope, fee drivers (no prices) and the information a CPA needs",
                "parameters": [
                    {
                        "name": "q",
                        "in": "query",
                        "required": false,
                        "description": "Optional keywords",
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/services/{id}": {
            "get": {
                "operationId": "getService",
                "summary": "One service by id",
                "parameters": [
                    {
                        "name": "id",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Unknown service id"
                    }
                }
            }
        },
        "/search": {
            "get": {
                "operationId": "searchSite",
                "summary": "Search pages and guides; returns summaries, Markdown links and matching short answers",
                "parameters": [
                    {
                        "name": "q",
                        "in": "query",
                        "required": true,
                        "description": "Question or keywords",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "required": false,
                        "description": "Pages to return, 1-10",
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/answers": {
            "get": {
                "operationId": "getAnswers",
                "summary": "Short answers from the site FAQs, each with its source URL",
                "parameters": [
                    {
                        "name": "q",
                        "in": "query",
                        "required": false,
                        "description": "Question or keywords",
                        "schema": {
                            "type": "string"
                        }
                    },
                    {
                        "name": "limit",
                        "in": "query",
                        "required": false,
                        "description": "Answers to return, 1-25",
                        "schema": {
                            "type": "integer"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/page": {
            "get": {
                "operationId": "getPage",
                "summary": "A page in Markdown",
                "parameters": [
                    {
                        "name": "url",
                        "in": "query",
                        "required": true,
                        "description": "Full URL or path of a page on this site",
                        "schema": {
                            "type": "string"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "404": {
                        "description": "Not found"
                    }
                }
            }
        },
        "/request": {
            "post": {
                "operationId": "requestProposal",
                "summary": "Send a scoped proposal request on behalf of the user (requires the user's approval)",
                "description": "Call first with dry_run: true and show the preview to the user. Send only after the user approves, with user_confirmed: true, using the user's own contact details. A licensed CPA replies by e-mail with questions or a written fixed-fee proposal.",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "user_confirmed": {
                                        "type": "boolean",
                                        "description": "true only after the user has seen and approved the exact details of this request"
                                    },
                                    "dry_run": {
                                        "type": "boolean",
                                        "description": "true returns a preview to show the user; nothing is sent"
                                    },
                                    "contact_name": {
                                        "type": "string",
                                        "description": "Full name of the user, the person the firm will reply to",
                                        "maxLength": 120
                                    },
                                    "contact_email": {
                                        "type": "string",
                                        "format": "email",
                                        "description": "The user's own e-mail address"
                                    },
                                    "contact_role": {
                                        "type": "string",
                                        "description": "Role, e.g. CFO, finance manager, legal counsel",
                                        "maxLength": 120
                                    },
                                    "phone": {
                                        "type": "string",
                                        "description": "Optional phone number",
                                        "maxLength": 40
                                    },
                                    "company": {
                                        "type": "string",
                                        "description": "Company / subsidiary name",
                                        "maxLength": 160
                                    },
                                    "hq_country": {
                                        "type": "string",
                                        "description": "Headquarters country",
                                        "maxLength": 80
                                    },
                                    "service": {
                                        "type": "string",
                                        "enum": [
                                            "accounting",
                                            "bookkeeping",
                                            "tax-compliance",
                                            "payroll",
                                            "management-reporting",
                                            "accounting-takeover",
                                            "entity-health-check",
                                            "fiscal-representation",
                                            "turkish-customers-vat-pe",
                                            "tax-opinion",
                                            "tax-counsel-for-firms",
                                            "market-entry",
                                            "free-zone-accounting",
                                            "sworn-cpa-report",
                                            "fraud-audit",
                                            "ets-review",
                                            "industrial-registry",
                                            "e2-source-of-funds",
                                            "international-partnerships",
                                            "other"
                                        ],
                                        "description": "Service id from list_services, or other"
                                    },
                                    "turkish_entity_status": {
                                        "type": "string",
                                        "description": "For example: none yet, Ltd, A.Ş., branch, liaison office, non-resident with VAT registration",
                                        "maxLength": 160
                                    },
                                    "monthly_transaction_volume": {
                                        "type": "string",
                                        "description": "Approximate monthly transaction volume",
                                        "maxLength": 160
                                    },
                                    "headcount": {
                                        "type": "string",
                                        "description": "Employees in Turkey, now or planned",
                                        "maxLength": 80
                                    },
                                    "reporting_currency_deadline": {
                                        "type": "string",
                                        "description": "Reporting currency and HQ reporting deadline",
                                        "maxLength": 160
                                    },
                                    "erp_software": {
                                        "type": "string",
                                        "description": "ERP or accounting software",
                                        "maxLength": 160
                                    },
                                    "requested_start_date": {
                                        "type": "string",
                                        "description": "Requested start date",
                                        "maxLength": 80
                                    },
                                    "message": {
                                        "type": "string",
                                        "minLength": 10,
                                        "maxLength": 4000,
                                        "description": "What the user needs, in their own words. For tax opinions: the question, the facts, the countries involved and the deadline."
                                    },
                                    "preferred_language": {
                                        "type": "string",
                                        "enum": [
                                            "en",
                                            "tr"
                                        ],
                                        "description": "Language for the reply"
                                    },
                                    "agent_name": {
                                        "type": "string",
                                        "description": "Name of the assistant or platform sending the request",
                                        "maxLength": 80
                                    }
                                },
                                "required": [
                                    "contact_name",
                                    "contact_email",
                                    "company",
                                    "hq_country",
                                    "service",
                                    "message"
                                ]
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "Preview (dry_run) or already received",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "201": {
                        "description": "Request received",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "202": {
                        "description": "Recorded, but the e-mail notification failed; the user should also e-mail the firm",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "400": {
                        "description": "Missing or invalid fields, or user_confirmed not true",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "429": {
                        "description": "Too many requests from this sender"
                    },
                    "503": {
                        "description": "Could not be delivered; the user can e-mail the firm directly"
                    }
                }
            }
        },
        "/mcp": {
            "post": {
                "operationId": "mcp",
                "summary": "MCP server: JSON-RPC 2.0 over Streamable HTTP (tools: get_firm_profile, list_services, search_site, get_answers, get_page, request_proposal)",
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "202": {
                        "description": "Notification accepted"
                    }
                }
            }
        }
    }
}