{
  "openapi": "3.0.3",
  "info": {
    "title": "Connector Manifest Schema",
    "version": "1.0.0",
    "description": "Reference for the connector **YAML manifest** — the document you author in the **Register Connector** wizard (Form or YAML) under Workspace → Connectors to create or update a connector.\n\nEvery field below is generated directly from the canonical Zod schema (`ConnectorManifestSchema`), so the descriptions, limits, and required fields shown here are exactly what the server validates against. Keys are camelCase throughout, and every object is strict — unknown keys are rejected rather than silently dropped.\n\nSee **ConnectorManifest** below for the top-level shape; nested types (connector metadata, tools, auth, and tool execution) are linked as `$defs`."
  },
  "paths": {},
  "components": {
    "schemas": {
      "ConnectorManifest": {
        "type": "object",
        "properties": {
          "version": {
            "type": "number",
            "const": 1,
            "description": "Manifest schema version — only `1` is accepted today"
          },
          "connector": {
            "type": "object",
            "properties": {
              "slug": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64,
                "pattern": "^[a-z0-9][a-z0-9-_]*$",
                "description": "Connector slug — unique per organization, used in @-mentions"
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120,
                "description": "Connector display name"
              },
              "description": {
                "type": "string",
                "maxLength": 2000
              },
              "systemPrompt": {
                "type": "string",
                "maxLength": 8000,
                "description": "Agent-facing guidance applied to every tool on this connector"
              },
              "iconUrl": {
                "type": "string",
                "format": "uri",
                "maxLength": 2048
              },
              "baseUrl": {
                "type": "string",
                "format": "uri",
                "maxLength": 2048,
                "description": "Base URL for tool endpoint templates; optional when endpoints are absolute"
              },
              "connectionProbe": {
                "type": "object",
                "properties": {
                  "toolSlug": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "description": "Tool the probe calls; must be a cheap read-only tool"
                  },
                  "args": {
                    "type": "object",
                    "additionalProperties": {},
                    "default": {},
                    "description": "Arguments for the probe call; empty for argument-free tools"
                  }
                },
                "required": [
                  "toolSlug"
                ],
                "additionalProperties": false,
                "description": "mcpServer only: the read-only tool the connection probe calls (with args) to prove a real login; omitted = auto-pick from the live catalog"
              },
              "requestHeaders": {
                "type": "object",
                "additionalProperties": {
                  "type": "string",
                  "maxLength": 1024
                },
                "description": "Fixed non-credential headers sent on every outbound call to the service, e.g. { Notion-Version: 2022-06-28 }. Stored and exported in plain text: never put a key or token here under any name; credentials belong in auth"
              },
              "auth": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "const": "none"
                      }
                    },
                    "required": [
                      "kind"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "const": "bearer"
                      },
                      "headerName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "default": "Authorization"
                      },
                      "prefix": {
                        "type": "string",
                        "maxLength": 32,
                        "default": "Bearer "
                      }
                    },
                    "required": [
                      "kind"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "const": "apiKeyHeader"
                      },
                      "headerName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64
                      }
                    },
                    "required": [
                      "kind",
                      "headerName"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "const": "hmacSha256"
                      },
                      "headerName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "default": "X-Signature"
                      },
                      "signedPayload": {
                        "type": "string",
                        "enum": [
                          "body",
                          "method+path+body"
                        ],
                        "default": "body"
                      }
                    },
                    "required": [
                      "kind"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "const": "oauth2"
                      },
                      "authorizationUrl": {
                        "type": "string",
                        "format": "uri"
                      },
                      "tokenUrl": {
                        "type": "string",
                        "format": "uri"
                      },
                      "scopes": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        },
                        "default": []
                      },
                      "signInMethod": {
                        "type": "string",
                        "enum": [
                          "server",
                          "oauthApp"
                        ]
                      }
                    },
                    "required": [
                      "kind",
                      "authorizationUrl",
                      "tokenUrl"
                    ],
                    "additionalProperties": false
                  }
                ],
                "description": "How the executor authenticates outbound calls"
              },
              "sourceKind": {
                "type": "string",
                "enum": [
                  "httpEndpoint",
                  "mcpServer"
                ],
                "description": "httpEndpoint (default) wraps static tool definitions; mcpServer proxies a live MCP server — no tools declared"
              }
            },
            "required": [
              "slug",
              "name",
              "auth"
            ],
            "additionalProperties": false
          },
          "tools": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "slug": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 64,
                  "pattern": "^[a-z0-9][a-z0-9-_]*$",
                  "description": "Unique tool slug within the connector"
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 120,
                  "description": "Tool display name"
                },
                "description": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 2000,
                  "description": "What the tool does — shown to the agent as the MCP tool description"
                },
                "toolPrompt": {
                  "type": "string",
                  "maxLength": 8000,
                  "description": "Additional agent-facing guidance for when to use this tool"
                },
                "inputSchema": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "Shorthand scalar type or prose description"
                    },
                    {
                      "type": "object",
                      "additionalProperties": {},
                      "description": "Either a JSON Schema object or a shorthand map"
                    }
                  ],
                  "description": "Tool input schema (JSON Schema or shorthand)"
                },
                "outputSchema": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "Shorthand scalar type or prose description"
                    },
                    {
                      "type": "object",
                      "additionalProperties": {},
                      "description": "Either a JSON Schema object or a shorthand map"
                    }
                  ],
                  "description": "Tool output schema (JSON Schema or shorthand)"
                },
                "execution": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "mode": {
                          "type": "string",
                          "const": "sync"
                        },
                        "sync": {
                          "type": "object",
                          "properties": {
                            "request": {
                              "type": "object",
                              "properties": {
                                "method": {
                                  "type": "string",
                                  "enum": [
                                    "GET",
                                    "POST",
                                    "PUT",
                                    "PATCH",
                                    "DELETE"
                                  ]
                                },
                                "urlTemplate": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 2048,
                                  "description": "URL template with {{input.*}} / {{connector.baseUrl}} / {{handle.*}} substitution"
                                },
                                "headers": {
                                  "type": "object",
                                  "additionalProperties": {
                                    "type": "string"
                                  },
                                  "description": "Templated request headers; auth headers are merged in by the executor",
                                  "default": {}
                                },
                                "bodyFrom": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "const": "none"
                                    },
                                    {
                                      "type": "string",
                                      "const": "input"
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "jsonata": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 4000
                                        }
                                      },
                                      "required": [
                                        "jsonata"
                                      ],
                                      "additionalProperties": false,
                                      "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "inputProperty": {
                                          "type": "string",
                                          "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                        },
                                        "binary": {
                                          "type": "object",
                                          "properties": {
                                            "contentTypes": {
                                              "type": "array",
                                              "items": {
                                                "type": "string",
                                                "pattern": "^[a-z0-9][a-z0-9!#$&^_.+-]*\\/[a-z0-9][a-z0-9!#$&^_.+-]*$"
                                              },
                                              "minItems": 1,
                                              "maxItems": 16
                                            },
                                            "contentTypeFrom": {
                                              "type": "string",
                                              "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                            }
                                          },
                                          "required": [
                                            "contentTypes"
                                          ],
                                          "additionalProperties": false
                                        }
                                      },
                                      "required": [
                                        "inputProperty"
                                      ],
                                      "additionalProperties": false
                                    }
                                  ],
                                  "description": "How to construct the request body",
                                  "default": "none"
                                },
                                "pathParams": {
                                  "type": "object",
                                  "additionalProperties": {
                                    "type": "string",
                                    "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                  },
                                  "description": "OpenAPI path placeholders mapped to input fields; values are encoded as single path segments"
                                },
                                "queryParams": {
                                  "type": "object",
                                  "additionalProperties": {
                                    "type": "object",
                                    "properties": {
                                      "inputKey": {
                                        "type": "string",
                                        "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                      },
                                      "explode": {
                                        "type": "boolean"
                                      }
                                    },
                                    "required": [
                                      "inputKey",
                                      "explode"
                                    ],
                                    "additionalProperties": false
                                  },
                                  "description": "OpenAPI form query parameters; absent optional inputs are omitted"
                                },
                                "headerParams": {
                                  "type": "object",
                                  "additionalProperties": {
                                    "type": "string",
                                    "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                  },
                                  "description": "Declared non-authentication OpenAPI header parameters; routing and credential headers are refused"
                                },
                                "nextLinkFrom": {
                                  "type": "string",
                                  "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$",
                                  "description": "Optional continuation URL input; GET only and confined to the same operation origin and path"
                                },
                                "openApiSource": {
                                  "type": "object",
                                  "properties": {
                                    "hash": {
                                      "type": "string",
                                      "pattern": "^[a-f0-9]{64}$"
                                    },
                                    "version": {
                                      "type": "string"
                                    },
                                    "operationId": {
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "hash",
                                    "version",
                                    "operationId"
                                  ],
                                  "additionalProperties": false,
                                  "description": "Imported spec identity; metadata only, never an authorization grant"
                                }
                              },
                              "required": [
                                "method",
                                "urlTemplate"
                              ],
                              "additionalProperties": false
                            },
                            "response": {
                              "type": "object",
                              "properties": {
                                "successStatus": {
                                  "type": "array",
                                  "items": {
                                    "type": "integer",
                                    "minimum": 100,
                                    "maximum": 599
                                  },
                                  "minItems": 1,
                                  "default": [
                                    200
                                  ]
                                },
                                "resultFrom": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "const": "body"
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "jsonata": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 4000
                                        }
                                      },
                                      "required": [
                                        "jsonata"
                                      ],
                                      "additionalProperties": false,
                                      "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                    }
                                  ],
                                  "description": "How to extract the tool result from the response payload",
                                  "default": "body"
                                },
                                "binaryResult": {
                                  "type": "boolean",
                                  "const": true,
                                  "description": "The success body is raw bytes (a file download), not JSON; GET only"
                                }
                              },
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "request",
                            "response"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "mode",
                        "sync"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "mode": {
                          "type": "string",
                          "const": "asyncPoll"
                        },
                        "asyncPoll": {
                          "type": "object",
                          "properties": {
                            "kickoff": {
                              "type": "object",
                              "properties": {
                                "request": {
                                  "type": "object",
                                  "properties": {
                                    "method": {
                                      "type": "string",
                                      "enum": [
                                        "GET",
                                        "POST",
                                        "PUT",
                                        "PATCH",
                                        "DELETE"
                                      ]
                                    },
                                    "urlTemplate": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 2048,
                                      "description": "URL template with {{input.*}} / {{connector.baseUrl}} / {{handle.*}} substitution"
                                    },
                                    "headers": {
                                      "type": "object",
                                      "additionalProperties": {
                                        "type": "string"
                                      },
                                      "description": "Templated request headers; auth headers are merged in by the executor",
                                      "default": {}
                                    },
                                    "bodyFrom": {
                                      "anyOf": [
                                        {
                                          "type": "string",
                                          "const": "none"
                                        },
                                        {
                                          "type": "string",
                                          "const": "input"
                                        },
                                        {
                                          "type": "object",
                                          "properties": {
                                            "jsonata": {
                                              "type": "string",
                                              "minLength": 1,
                                              "maxLength": 4000
                                            }
                                          },
                                          "required": [
                                            "jsonata"
                                          ],
                                          "additionalProperties": false,
                                          "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                        },
                                        {
                                          "type": "object",
                                          "properties": {
                                            "inputProperty": {
                                              "type": "string",
                                              "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                            },
                                            "binary": {
                                              "type": "object",
                                              "properties": {
                                                "contentTypes": {
                                                  "type": "array",
                                                  "items": {
                                                    "type": "string",
                                                    "pattern": "^[a-z0-9][a-z0-9!#$&^_.+-]*\\/[a-z0-9][a-z0-9!#$&^_.+-]*$"
                                                  },
                                                  "minItems": 1,
                                                  "maxItems": 16
                                                },
                                                "contentTypeFrom": {
                                                  "type": "string",
                                                  "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                                }
                                              },
                                              "required": [
                                                "contentTypes"
                                              ],
                                              "additionalProperties": false
                                            }
                                          },
                                          "required": [
                                            "inputProperty"
                                          ],
                                          "additionalProperties": false
                                        }
                                      ],
                                      "description": "How to construct the request body",
                                      "default": "none"
                                    },
                                    "pathParams": {
                                      "type": "object",
                                      "additionalProperties": {
                                        "type": "string",
                                        "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                      },
                                      "description": "OpenAPI path placeholders mapped to input fields; values are encoded as single path segments"
                                    },
                                    "queryParams": {
                                      "type": "object",
                                      "additionalProperties": {
                                        "type": "object",
                                        "properties": {
                                          "inputKey": {
                                            "type": "string",
                                            "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                          },
                                          "explode": {
                                            "type": "boolean"
                                          }
                                        },
                                        "required": [
                                          "inputKey",
                                          "explode"
                                        ],
                                        "additionalProperties": false
                                      },
                                      "description": "OpenAPI form query parameters; absent optional inputs are omitted"
                                    },
                                    "headerParams": {
                                      "type": "object",
                                      "additionalProperties": {
                                        "type": "string",
                                        "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$"
                                      },
                                      "description": "Declared non-authentication OpenAPI header parameters; routing and credential headers are refused"
                                    },
                                    "nextLinkFrom": {
                                      "type": "string",
                                      "pattern": "^[a-zA-Z][a-zA-Z0-9_]*$",
                                      "description": "Optional continuation URL input; GET only and confined to the same operation origin and path"
                                    },
                                    "openApiSource": {
                                      "type": "object",
                                      "properties": {
                                        "hash": {
                                          "type": "string",
                                          "pattern": "^[a-f0-9]{64}$"
                                        },
                                        "version": {
                                          "type": "string"
                                        },
                                        "operationId": {
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "hash",
                                        "version",
                                        "operationId"
                                      ],
                                      "additionalProperties": false,
                                      "description": "Imported spec identity; metadata only, never an authorization grant"
                                    }
                                  },
                                  "required": [
                                    "method",
                                    "urlTemplate"
                                  ],
                                  "additionalProperties": false
                                },
                                "response": {
                                  "type": "object",
                                  "properties": {
                                    "successStatus": {
                                      "type": "array",
                                      "items": {
                                        "type": "integer",
                                        "minimum": 100,
                                        "maximum": 599
                                      },
                                      "minItems": 1,
                                      "default": [
                                        200
                                      ]
                                    },
                                    "resultFrom": {
                                      "anyOf": [
                                        {
                                          "type": "string",
                                          "const": "body"
                                        },
                                        {
                                          "type": "object",
                                          "properties": {
                                            "jsonata": {
                                              "type": "string",
                                              "minLength": 1,
                                              "maxLength": 4000
                                            }
                                          },
                                          "required": [
                                            "jsonata"
                                          ],
                                          "additionalProperties": false,
                                          "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                        }
                                      ],
                                      "description": "How to extract the tool result from the response payload",
                                      "default": "body"
                                    },
                                    "binaryResult": {
                                      "type": "boolean",
                                      "const": true,
                                      "description": "The success body is raw bytes (a file download), not JSON; GET only"
                                    }
                                  },
                                  "additionalProperties": false
                                }
                              },
                              "required": [
                                "request",
                                "response"
                              ],
                              "additionalProperties": false
                            },
                            "handleFrom": {
                              "type": "object",
                              "properties": {
                                "jsonata": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 4000
                                }
                              },
                              "required": [
                                "jsonata"
                              ],
                              "additionalProperties": false,
                              "description": "A JSONata expression evaluated against { input, connector, handle? }"
                            },
                            "poll": {
                              "type": "object",
                              "properties": {
                                "request": {
                                  "type": "object",
                                  "properties": {
                                    "method": {
                                      "type": "string",
                                      "enum": [
                                        "GET",
                                        "POST"
                                      ]
                                    },
                                    "urlTemplate": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 2048,
                                      "description": "URL template with {{input.*}} / {{connector.baseUrl}} / {{handle.*}} substitution"
                                    },
                                    "headers": {
                                      "type": "object",
                                      "additionalProperties": {
                                        "type": "string"
                                      },
                                      "description": "Templated request headers; auth headers are merged in by the executor",
                                      "default": {}
                                    },
                                    "bodyFrom": {
                                      "anyOf": [
                                        {
                                          "type": "string",
                                          "const": "none"
                                        },
                                        {
                                          "type": "object",
                                          "properties": {
                                            "jsonata": {
                                              "type": "string",
                                              "minLength": 1,
                                              "maxLength": 4000
                                            }
                                          },
                                          "required": [
                                            "jsonata"
                                          ],
                                          "additionalProperties": false,
                                          "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                        }
                                      ],
                                      "default": "none"
                                    }
                                  },
                                  "required": [
                                    "method",
                                    "urlTemplate"
                                  ],
                                  "additionalProperties": false
                                },
                                "intervalMs": {
                                  "type": "integer",
                                  "minimum": 100,
                                  "maximum": 60000,
                                  "default": 2000
                                },
                                "timeoutMs": {
                                  "type": "integer",
                                  "minimum": 1000,
                                  "maximum": 1800000,
                                  "default": 300000
                                },
                                "terminalWhen": {
                                  "type": "object",
                                  "properties": {
                                    "jsonata": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 4000
                                    }
                                  },
                                  "required": [
                                    "jsonata"
                                  ],
                                  "additionalProperties": false,
                                  "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                },
                                "successWhen": {
                                  "type": "object",
                                  "properties": {
                                    "jsonata": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 4000
                                    }
                                  },
                                  "required": [
                                    "jsonata"
                                  ],
                                  "additionalProperties": false,
                                  "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                },
                                "progressFrom": {
                                  "type": "object",
                                  "properties": {
                                    "jsonata": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 4000
                                    }
                                  },
                                  "required": [
                                    "jsonata"
                                  ],
                                  "additionalProperties": false,
                                  "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                },
                                "resultFrom": {
                                  "anyOf": [
                                    {
                                      "type": "string",
                                      "const": "body"
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "jsonata": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 4000
                                        }
                                      },
                                      "required": [
                                        "jsonata"
                                      ],
                                      "additionalProperties": false,
                                      "description": "A JSONata expression evaluated against { input, connector, handle? }"
                                    }
                                  ],
                                  "description": "How to extract the tool result from the response payload",
                                  "default": "body"
                                }
                              },
                              "required": [
                                "request",
                                "terminalWhen",
                                "successWhen"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "kickoff",
                            "handleFrom",
                            "poll"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "mode",
                        "asyncPoll"
                      ],
                      "additionalProperties": false
                    }
                  ],
                  "description": "How the tool calls the remote endpoint"
                },
                "timeoutMs": {
                  "type": "integer",
                  "exclusiveMinimum": 0
                },
                "retry": {
                  "type": "object",
                  "properties": {
                    "maxAttempts": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 10,
                      "default": 3
                    },
                    "backoffMs": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 30000,
                      "default": 500
                    }
                  },
                  "additionalProperties": false,
                  "description": "Retry policy applied by the httpCall activity on 5xx / network errors"
                }
              },
              "required": [
                "slug",
                "name",
                "description",
                "inputSchema",
                "outputSchema",
                "execution"
              ],
              "additionalProperties": false
            },
            "default": [],
            "description": "Tools exposed by this connector. Omit or leave empty for mcpServer source connectors — tools are discovered at session init."
          },
          "sharedSecret": {
            "type": "string",
            "description": "Optional static credential for the connector. Encrypted before persistence; never round-tripped back out of the server."
          }
        },
        "required": [
          "version",
          "connector"
        ],
        "additionalProperties": false
      }
    }
  }
}
