# Tasks ## Task Search `client.ai.tasks.list(TaskListParamsparams, RequestOptionsoptions?): SinglePage` **get** `/accounts/{account_id}/ai/tasks/search` Searches Workers AI models by task type (e.g., text-generation, embeddings). ### Parameters - `params: TaskListParams` - `account_id: string` ### Returns - `TaskListResponse = unknown` ### Example ```node import Cloudflare from 'cloudflare'; const client = new Cloudflare({ apiToken: process.env['CLOUDFLARE_API_TOKEN'], // This is the default and can be omitted }); // Automatically fetches more pages as needed. for await (const taskListResponse of client.ai.tasks.list({ account_id: '023e105f4ecef8ad9ca31a8372d0c353', })) { console.log(taskListResponse); } ``` #### Response ```json { "errors": [ {} ], "messages": [ "string" ], "result": [ {} ], "success": true } ``` ## Domain Types ### Task List Response - `TaskListResponse = unknown`