UsageResult SchemaCopy pageEnforce a specific schema of the result.parsed object for task results using Zod (TypeScript) or Pydantic (Python). TypeScriptPython1import { BrowserUseClient } from "browser-use-sdk";2import { z } from "zod";34const client = new BrowserUseClient();56const TaskOutput = z.object({7 posts: z.array(8 z.object({9 title: z.string(),10 url: z.string(),11 }),12 ),13});1415const task = await client.tasks.createTask({16 task: "Search for the top 10 Hacker News posts and return the title and url.",17 schema: TaskOutput,18});1920const result = await task.complete();2122for (const post of result.parsed.posts) {23 console.log(`${post.title} - ${post.url}`);24}