Business Tools
Business Tools are workspace-scoped capabilities the AI can invoke during chat. Qefro supports two implementation kinds:
| Kind | How you register | Best for |
|---|---|---|
rest / OpenAPI | Admin Console or OpenAPI import | Existing HTTPS APIs |
sdk | @qefro-ai/backend / qefro-backend-sdk + Sync Tools | Auth, workflows, custom logic |
Platform overview: Business Tools.
SDK registration guide: Register SDK Business Tools.
SDK tool metadata
When you register with the framework:
namedescriptionauth—none|optional|requiredauthentication_methods— optional list (e.g.email_otp)permissionstimeoutinput_schema
Example
app.tool({
name: "download_invoice",
description: "Download customer invoice",
auth: "required",
permissions: ["invoice.read"],
timeout: 30,
authentication_methods: ["email_otp"],
}, async (ctx) => {
return invoiceService.download(String(ctx.customer.require().id));
});
After Sync Tools with auto_register into a workspace, this handler becomes a Business Tool with:
implementation_kind = sdksdk_handler_name = download_invoicerequired_auth_level = organization_challenge(becauseauthentication_methodsis set)
Return values
Return structured JSON and predictable schemas so the LLM can ground replies.
Errors
Use clear business-safe errors and avoid leaking internal details.
Timeouts
Keep tools bounded; optimize handler logic before raising timeout limits.