{"openapi":"3.1.0","info":{"title":"ServiceM8 Templates (BYOK) API","version":"0.1.0","description":"ServiceM8 Templates (BYOK) lets an AI assistant read your own ServiceM8 Templates data through the ServiceM8 Templates API with a key you supply (ServiceM8 API key). Read-only: 5 tools (list_document_templates, list_email_templates, list_sms_templates, list_knowledge_articles, list_security_roles). The BYOK key travels with each request, is used for that one call only and is never stored, logged...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-servicem8-templates.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-servicem8-templates/docs"},"termsOfService":"https://connectorbay.com/byok-servicem8-templates/terms"},"servers":[{"url":"https://byok-servicem8-templates.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-servicem8-templates/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_document_templates":{"post":{"operationId":"list_document_templates","summary":"List document templates (quotes, invoices, forms and so on) with name, template type and the kind of record they apply t","description":"List document templates (quotes, invoices, forms and so on) with name, template type and the kind of record they apply to. Use for \"Which document templates exist in ServiceM8\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":250,"type":"string"},{"type":"null"}],"default":null,"description":"Optional OData-style filter, for example \"active eq 1\". Operators eq, ne, gt, lt joined by 'and'; text values in single quotes.","title":"Filter"}},"title":"list_document_templatesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_email_templates":{"post":{"operationId":"list_email_templates","summary":"List email templates with name and subject line (the message body is not returned). Use for \"What email templates are sa","description":"List email templates with name and subject line (the message body is not returned). Use for \"What email templates are saved in ServiceM8\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":250,"type":"string"},{"type":"null"}],"default":null,"description":"Optional OData-style filter, for example \"active eq 1\". Operators eq, ne, gt, lt joined by 'and'; text values in single quotes.","title":"Filter"}},"title":"list_email_templatesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_sms_templates":{"post":{"operationId":"list_sms_templates","summary":"List SMS templates by name (the message text is not returned). Use for \"What SMS templates are saved in ServiceM8\".","description":"List SMS templates by name (the message text is not returned). Use for \"What SMS templates are saved in ServiceM8\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":250,"type":"string"},{"type":"null"}],"default":null,"description":"Optional OData-style filter, for example \"active eq 1\". Operators eq, ne, gt, lt joined by 'and'; text values in single quotes.","title":"Filter"}},"title":"list_sms_templatesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_knowledge_articles":{"post":{"operationId":"list_knowledge_articles","summary":"List knowledge articles with title, article type (video, rich text and so on) and tags (the content is not returned). Us","description":"List knowledge articles with title, article type (video, rich text and so on) and tags (the content is not returned). Use for \"Which knowledge articles does my ServiceM8 team have about boilers\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":250,"type":"string"},{"type":"null"}],"default":null,"description":"Optional OData-style filter, for example \"active eq 1\". Operators eq, ne, gt, lt joined by 'and'; text values in single quotes.","title":"Filter"}},"title":"list_knowledge_articlesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_security_roles":{"post":{"operationId":"list_security_roles","summary":"List staff security roles with name and description (no staff members). Use for \"What security roles are defined in Serv","description":"List staff security roles with name and description (no staff members). Use for \"What security roles are defined in ServiceM8\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":250,"type":"string"},{"type":"null"}],"default":null,"description":"Optional OData-style filter, for example \"active eq 1\". Operators eq, ne, gt, lt joined by 'and'; text values in single quotes.","title":"Filter"}},"title":"list_security_rolesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}