create-database-service
Create a database service connector by providing name, database type, and connection configuration.
Instructions
Create a new database service connector
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Service name | |
| serviceType | Yes | Database type (e.g. 'Mysql', 'Postgres', 'BigQuery', 'Snowflake', 'Redshift', 'Hive', 'Mssql', 'Oracle') | |
| connection | Yes | Connection configuration | |
| description | No |
Implementation Reference
- src/tools/services.ts:44-49 (schema)Zod schema for create-database-service tool: defines name, serviceType, connection (record), and optional description.
export const createDatabaseServiceSchema = z.object({ name: z.string().describe("Service name"), serviceType: z.string().describe("Database type (e.g. 'Mysql', 'Postgres', 'BigQuery', 'Snowflake', 'Redshift', 'Hive', 'Mssql', 'Oracle')"), connection: z.record(z.string(), z.any()).describe("Connection configuration"), description: z.string().optional(), }); - src/tools/services.ts:51-54 (handler)Handler function for create-database-service: asserts write allowed, then POSTs to /services/databaseServices with params.
export async function createDatabaseService(params: z.infer<typeof createDatabaseServiceSchema>) { assertWriteAllowed(); return omClient.post("/services/databaseServices", params); } - src/index.ts:214-214 (registration)Registration of the 'create-database-service' tool with its schema and wrapped handler.
tool("create-database-service", "Create a new database service connector", createDatabaseServiceSchema.shape, wrapToolHandler(createDatabaseService));