[{"data":1,"prerenderedAt":1005},["ShallowReactive",2],{"docs:\u002Fdocs\u002Freference\u002Fservices":3,"docs:navigation":881,"docs:surround:\u002Fdocs\u002Freference\u002Fservices":1000},{"id":4,"title":5,"body":6,"description":872,"extension":873,"meta":874,"navigation":875,"navigationTitle":876,"path":877,"seo":878,"stem":879,"__hash__":880},"docs\u002Fdocs\u002F6.reference\u002F4.services.md","Services",{"type":7,"value":8,"toc":861},"minimark",[9,34,39,50,144,195,198,205,316,392,395,470,473,527,562,565,695,698,731,734,818,822,840,844,857],[10,11,12,13,17,18,21,22,25,26,29,30,33],"p",{},"Get services with ",[14,15,16],"code",{},"useAgentic(event)"," (Nuxt) or ",[14,19,20],{},"agentic.services(request, env)"," (Void). Every\ncall acts as the signed-in user in the selected workspace, with the same access checks as the\nREST API. Errors are thrown as ",[14,23,24],{},"AgenticError"," with an HTTP ",[14,27,28],{},"status"," and a ",[14,31,32],{},"message",".",[35,36,38],"h2",{"id":37},"list-queries","List queries",[10,40,41,42,45,46,49],{},"Every ",[14,43,44],{},"list"," takes the same optional query and returns\n",[14,47,48],{},"{ data, totalCount, totalPages, page, pageSize }",":",[51,52,53,66],"table",{},[54,55,56],"thead",{},[57,58,59,63],"tr",{},[60,61,62],"th",{},"Field",[60,64,65],{},"Description",[67,68,69,80,90,100,110,131],"tbody",{},[57,70,71,77],{},[72,73,74],"td",{},[14,75,76],{},"page",[72,78,79],{},"Page number from 1",[57,81,82,87],{},[72,83,84],{},[14,85,86],{},"pageSize",[72,88,89],{},"Up to 100, default 50",[57,91,92,97],{},[72,93,94],{},[14,95,96],{},"limit",[72,98,99],{},"Stop after this many rows in total",[57,101,102,107],{},[72,103,104],{},[14,105,106],{},"search",[72,108,109],{},"Free-text search over the searchable fields",[57,111,112,117],{},[72,113,114],{},[14,115,116],{},"sortBy",[72,118,119,120,123,124,127,128],{},"Field to sort by; ",[14,121,122],{},"sortDir"," is ",[14,125,126],{},"asc"," or ",[14,129,130],{},"desc",[57,132,133,138],{},[72,134,135],{},[14,136,137],{},"filters",[72,139,140,141],{},"A filter group, ",[14,142,143],{},"{ type: 'group', logic: 'and', children: [...] }",[10,145,146,147,150,151,154,155,154,158,161,162,154,165,154,168,154,171,154,174,154,177,154,180,154,183,154,186,161,189,127,192,33],{},"Conditions are ",[14,148,149],{},"{ type: 'condition', field, operator, value }"," with ",[14,152,153],{},"eq",", ",[14,156,157],{},"neq",[14,159,160],{},"like",",\n",[14,163,164],{},"not_contains",[14,166,167],{},"starts_with",[14,169,170],{},"ends_with",[14,172,173],{},"gt",[14,175,176],{},"gte",[14,178,179],{},"lt",[14,181,182],{},"lte",[14,184,185],{},"is_empty",[14,187,188],{},"is_not_empty",[14,190,191],{},"is_any_of",[14,193,194],{},"is_none_of",[35,196,197],{"id":197},"models",[10,199,200,201,204],{},"One entry per Agentic Model, typed from its table and limited to the actions its ",[14,202,203],{},"access"," allows.",[206,207,212],"pre",{"className":208,"code":209,"language":210,"meta":211,"style":211},"language-ts shiki shiki-themes github-dark-default","const { models } = await useAgentic(event)\nconst { data } = await models.customer.list({ filter: { plan: 'pro' }, columns: ['name'] })\nconst customer = await models.customer.update(42, { plan: 'free' })\n","ts","",[14,213,214,246,283],{"__ignoreMap":211},[215,216,219,223,227,230,233,236,239,243],"span",{"class":217,"line":218},"line",1,[215,220,222],{"class":221},"suJrU","const",[215,224,226],{"class":225},"sZEs4"," { ",[215,228,197],{"class":229},"sFSAA",[215,231,232],{"class":225}," } ",[215,234,235],{"class":221},"=",[215,237,238],{"class":221}," await",[215,240,242],{"class":241},"sc3cj"," useAgentic",[215,244,245],{"class":225},"(event)\n",[215,247,249,251,253,256,258,260,262,265,267,270,274,277,280],{"class":217,"line":248},2,[215,250,222],{"class":221},[215,252,226],{"class":225},[215,254,255],{"class":229},"data",[215,257,232],{"class":225},[215,259,235],{"class":221},[215,261,238],{"class":221},[215,263,264],{"class":225}," models.customer.",[215,266,44],{"class":241},[215,268,269],{"class":225},"({ filter: { plan: ",[215,271,273],{"class":272},"s9uIt","'pro'",[215,275,276],{"class":225}," }, columns: [",[215,278,279],{"class":272},"'name'",[215,281,282],{"class":225},"] })\n",[215,284,286,288,291,294,296,298,301,304,307,310,313],{"class":217,"line":285},3,[215,287,222],{"class":221},[215,289,290],{"class":229}," customer",[215,292,293],{"class":221}," =",[215,295,238],{"class":221},[215,297,264],{"class":225},[215,299,300],{"class":241},"update",[215,302,303],{"class":225},"(",[215,305,306],{"class":229},"42",[215,308,309],{"class":225},", { plan: ",[215,311,312],{"class":272},"'free'",[215,314,315],{"class":225}," })\n",[51,317,318,327],{},[54,319,320],{},[57,321,322,325],{},[60,323,324],{},"Operation",[60,326,65],{},[67,328,329,346,356,366,379],{},[57,330,331,336],{},[72,332,333],{},[14,334,335],{},"list(query?)",[72,337,338,339,342,343],{},"Also takes ",[14,340,341],{},"filter"," (equality shorthand) and ",[14,344,345],{},"columns",[57,347,348,353],{},[72,349,350],{},[14,351,352],{},"get(id)",[72,354,355],{},"One record in scope",[57,357,358,363],{},[72,359,360],{},[14,361,362],{},"create(input)",[72,364,365],{},"Validated against the model's writable fields",[57,367,368,373],{},[72,369,370],{},[14,371,372],{},"update(id, input, options?)",[72,374,375,378],{},[14,376,377],{},"options.expectedFingerprint"," rejects changes made since review",[57,380,381,386],{},[72,382,383],{},[14,384,385],{},"delete(id, options?)",[72,387,388,389],{},"Same option; returns ",[14,390,391],{},"{ deleted }",[35,393,394],{"id":394},"agents",[51,396,397,405],{},[54,398,399],{},[57,400,401,403],{},[60,402,324],{},[60,404,65],{},[67,406,407,416,425,438,448,458],{},[57,408,409,413],{},[72,410,411],{},[14,412,335],{},[72,414,415],{},"Saved and code agents in the workspace",[57,417,418,422],{},[72,419,420],{},[14,421,352],{},[72,423,424],{},"One agent",[57,426,427,432],{},[72,428,429],{},[14,430,431],{},"code(slug)",[72,433,434,435],{},"The workspace copy of ",[14,436,437],{},"server\u002Fagents\u002F\u003Cslug>.md",[57,439,440,445],{},[72,441,442],{},[14,443,444],{},"create(definition)",[72,446,447],{},"Save a new agent",[57,449,450,455],{},[72,451,452],{},[14,453,454],{},"update(id, patch)",[72,456,457],{},"Change a saved agent; code agents are read-only",[57,459,460,465],{},[72,461,462],{},[14,463,464],{},"delete(id)",[72,466,467,468],{},"Returns ",[14,469,391],{},[35,471,472],{"id":472},"runs",[51,474,475,483],{},[54,476,477],{},[57,478,479,481],{},[60,480,324],{},[60,482,65],{},[67,484,485,495,507,517],{},[57,486,487,492],{},[72,488,489],{},[14,490,491],{},"start(agentId, { runId, payload?, instructions?, sessionId? })",[72,493,494],{},"Start a durable run",[57,496,497,502],{},[72,498,499],{},[14,500,501],{},"get(agentId, runId, { sessionId? })",[72,503,504],{},[14,505,506],{},"{ runId, status, output, error, approvalId? }",[57,508,509,514],{},[72,510,511],{},[14,512,513],{},"cancel(agentId, runId, { sessionId? })",[72,515,516],{},"Cancel a run that has not finished",[57,518,519,524],{},[72,520,521],{},[14,522,523],{},"runtimes()",[72,525,526],{},"Available providers, models and local runtimes",[10,528,529,532,533,536,537,540,541,123,543,154,546,154,549,552,553,154,556,127,559,33],{},[14,530,531],{},"runId"," is yours to choose (letters, digits, ",[14,534,535],{},"_"," and ",[14,538,539],{},"-","), so retries never start a second run.\n",[14,542,28],{},[14,544,545],{},"queued",[14,547,548],{},"running",[14,550,551],{},"waiting"," (for an approval), ",[14,554,555],{},"succeeded",[14,557,558],{},"failed",[14,560,561],{},"cancelled",[35,563,564],{"id":564},"automations",[51,566,567,575],{},[54,568,569],{},[57,570,571,573],{},[60,572,324],{},[60,574,65],{},[67,576,577,597,611,624,637,650,663,679],{},[57,578,579,594],{},[72,580,581,154,583,154,586,154,589,154,591],{},[14,582,44],{},[14,584,585],{},"get",[14,587,588],{},"create",[14,590,300],{},[14,592,593],{},"delete",[72,595,596],{},"Automation records",[57,598,599,604],{},[72,600,601],{},[14,602,603],{},"start(id, { payload, eventId? })",[72,605,606,607,610],{},"Run now; the same ",[14,608,609],{},"eventId"," never runs twice",[57,612,613,618],{},[72,614,615],{},[14,616,617],{},"deliverEvent({ event, id, payload })",[72,619,620,621],{},"Start every active automation triggered by ",[14,622,623],{},"event",[57,625,626,631],{},[72,627,628],{},[14,629,630],{},"endpoint(id)",[72,632,633,636],{},[14,634,635],{},"{ url }",": the secret webhook URL",[57,638,639,647],{},[72,640,641,154,644],{},[14,642,643],{},"cancel(runId)",[14,645,646],{},"resume(runId)",[72,648,649],{},"Control an automation run",[57,651,652,660],{},[72,653,654,154,657],{},[14,655,656],{},"runs.list",[14,658,659],{},"runs.get",[72,661,662],{},"Run history",[57,664,665,676],{},[72,666,667,154,670,154,673],{},[14,668,669],{},"folders.list",[14,671,672],{},"folders.create",[14,674,675],{},"folders.delete",[72,677,678],{},"Folders in the sidebar",[57,680,681,689],{},[72,682,683,154,686],{},[14,684,685],{},"templates.list()",[14,687,688],{},"templates.install(slug)",[72,690,691,694],{},[14,692,693],{},"defineAutomation"," templates",[35,696,697],{"id":697},"approvals",[51,699,700,708],{},[54,701,702],{},[57,703,704,706],{},[60,705,324],{},[60,707,65],{},[67,709,710,721],{},[57,711,712,718],{},[72,713,714,154,716],{},[14,715,335],{},[14,717,352],{},[72,719,720],{},"The current user's approval requests",[57,722,723,728],{},[72,724,725],{},[14,726,727],{},"answer(id, approve)",[72,729,730],{},"Approve or reject; an approved call runs, then the run resumes",[35,732,733],{"id":733},"workspaces",[51,735,736,744],{},[54,737,738],{},[57,739,740,742],{},[60,741,324],{},[60,743,65],{},[67,745,746,756,768,784,797],{},[57,747,748,753],{},[72,749,750],{},[14,751,752],{},"session()",[72,754,755],{},"The user and their workspaces",[57,757,758,765],{},[72,759,760,154,763],{},[14,761,762],{},"list()",[14,764,352],{},[72,766,767],{},"Workspaces and one workspace's members",[57,769,770,781],{},[72,771,772,154,775,154,778],{},[14,773,774],{},"create({ name, slug })",[14,776,777],{},"update(id, { name, slug })",[14,779,780],{},"updateLogo(id, logo)",[72,782,783],{},"Manage workspaces",[57,785,786,794],{},[72,787,788,154,791],{},[14,789,790],{},"setRole(id, memberId, role)",[14,792,793],{},"removeMember(id, memberId)",[72,795,796],{},"Manage members",[57,798,799,815],{},[72,800,801,154,804,154,806,154,809,154,812],{},[14,802,803],{},"invitations.list",[14,805,588],{},[14,807,808],{},"revoke",[14,810,811],{},"preview",[14,813,814],{},"accept",[72,816,817],{},"Invitations by email link",[35,819,821],{"id":820},"prompt-and-data","prompt and data",[10,823,824,154,827,154,830,536,833,836,837,839],{},[14,825,826],{},"prompt.options()",[14,828,829],{},"prompt.plan(...)",[14,831,832],{},"prompt.execute(...)",[14,834,835],{},"prompt.cancel(...)"," run the\ndashboard prompt; ",[14,838,255],{}," reads the dashboard's model views. Both exist for the dashboard and\ncustom prompt UIs; most apps do not call them directly.",[35,841,843],{"id":842},"your-features","Your features",[10,845,846,847,852,853,856],{},"Services from your own ",[848,849,851],"a",{"href":850},"\u002Fdocs\u002Fguides\u002Ffeatures","features"," appear next to these, typed from the\nfeature's ",[14,854,855],{},"services"," function.",[858,859,860],"style",{},"html pre.shiki code .suJrU, html code.shiki .suJrU{--shiki-default:#FF7B72}html pre.shiki code .sZEs4, html code.shiki .sZEs4{--shiki-default:#E6EDF3}html pre.shiki code .sFSAA, html code.shiki .sFSAA{--shiki-default:#79C0FF}html pre.shiki code .sc3cj, html code.shiki .sc3cj{--shiki-default:#D2A8FF}html pre.shiki code .s9uIt, html code.shiki .s9uIt{--shiki-default:#A5D6FF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":211,"searchDepth":248,"depth":248,"links":862},[863,864,865,866,867,868,869,870,871],{"id":37,"depth":248,"text":38},{"id":197,"depth":248,"text":197},{"id":394,"depth":248,"text":394},{"id":472,"depth":248,"text":472},{"id":564,"depth":248,"text":564},{"id":697,"depth":248,"text":697},{"id":733,"depth":248,"text":733},{"id":820,"depth":248,"text":821},{"id":842,"depth":248,"text":843},"Every actor-bound service, its operations and their inputs.","md",{},true,null,"\u002Fdocs\u002Freference\u002Fservices",{"title":5,"description":872},"docs\u002F6.reference\u002F4.services","J_9mC9a3-HwjJNV2UNzwi8pnt3HhKkkQ9eoF7-7PWsI",[882],{"title":883,"path":884,"stem":885,"children":886,"navigationTitle":876},"Introduction","\u002Fdocs","docs\u002F0.index",[887,888,906,910,962,966,970,996],{"title":883,"path":884,"stem":885,"navigationTitle":876},{"title":889,"path":890,"stem":891,"children":892,"page":905},"Getting Started","\u002Fdocs\u002Fgetting-started","docs\u002F1.getting-started",[893,897,901],{"title":894,"path":895,"stem":896,"navigationTitle":876},"Free module","\u002Fdocs\u002Fgetting-started\u002Ffree","docs\u002F1.getting-started\u002F1.free",{"title":898,"path":899,"stem":900,"navigationTitle":876},"Pro on Nuxt","\u002Fdocs\u002Fgetting-started\u002Fnuxt","docs\u002F1.getting-started\u002F2.nuxt",{"title":902,"path":903,"stem":904,"navigationTitle":876},"Pro on Void","\u002Fdocs\u002Fgetting-started\u002Fvoid","docs\u002F1.getting-started\u002F3.void",false,{"title":907,"path":908,"stem":909,"navigationTitle":876},"Concepts","\u002Fdocs\u002Fconcepts","docs\u002F2.concepts",{"title":911,"path":912,"stem":913,"children":914,"page":905},"Guides","\u002Fdocs\u002Fguides","docs\u002F3.guides",[915,919,923,926,930,934,938,942,946,950,954,958],{"title":916,"path":917,"stem":918,"navigationTitle":876},"Agents","\u002Fdocs\u002Fguides\u002Fagents","docs\u002F3.guides\u002F1.agents",{"title":920,"path":921,"stem":922,"navigationTitle":876},"Events","\u002Fdocs\u002Fguides\u002Fevents","docs\u002F3.guides\u002F10.events",{"title":924,"path":850,"stem":925,"navigationTitle":876},"Features","docs\u002F3.guides\u002F11.features",{"title":927,"path":928,"stem":929,"navigationTitle":876},"Coding agents","\u002Fdocs\u002Fguides\u002Fcoding-agents","docs\u002F3.guides\u002F12.coding-agents",{"title":931,"path":932,"stem":933,"navigationTitle":876},"Tools","\u002Fdocs\u002Fguides\u002Ftools","docs\u002F3.guides\u002F2.tools",{"title":935,"path":936,"stem":937,"navigationTitle":876},"Automations","\u002Fdocs\u002Fguides\u002Fautomations","docs\u002F3.guides\u002F3.automations",{"title":939,"path":940,"stem":941,"navigationTitle":876},"Agentic Models","\u002Fdocs\u002Fguides\u002Fagentic-models","docs\u002F3.guides\u002F4.agentic-models",{"title":943,"path":944,"stem":945,"navigationTitle":876},"Outcomes","\u002Fdocs\u002Fguides\u002Foutcomes","docs\u002F3.guides\u002F5.outcomes",{"title":947,"path":948,"stem":949,"navigationTitle":876},"Integrations","\u002Fdocs\u002Fguides\u002Fintegrations","docs\u002F3.guides\u002F6.integrations",{"title":951,"path":952,"stem":953,"navigationTitle":876},"Prompt","\u002Fdocs\u002Fguides\u002Fprompt","docs\u002F3.guides\u002F7.prompt",{"title":955,"path":956,"stem":957,"navigationTitle":876},"Server logic","\u002Fdocs\u002Fguides\u002Fserver-logic","docs\u002F3.guides\u002F8.server-logic",{"title":959,"path":960,"stem":961,"navigationTitle":876},"Dashboard UI","\u002Fdocs\u002Fguides\u002Fui","docs\u002F3.guides\u002F9.ui",{"title":963,"path":964,"stem":965,"navigationTitle":876},"Deploy to Cloudflare","\u002Fdocs\u002Fdeploy","docs\u002F4.deploy",{"title":967,"path":968,"stem":969,"navigationTitle":876},"Upgrading","\u002Fdocs\u002Fupgrade","docs\u002F5.upgrade",{"title":971,"path":972,"stem":973,"children":974,"page":905},"Reference","\u002Fdocs\u002Freference","docs\u002F6.reference",[975,979,983,987,988,992],{"title":976,"path":977,"stem":978,"navigationTitle":876},"Configuration","\u002Fdocs\u002Freference\u002Fconfiguration","docs\u002F6.reference\u002F1.configuration",{"title":980,"path":981,"stem":982,"navigationTitle":876},"Composables","\u002Fdocs\u002Freference\u002Fcomposables","docs\u002F6.reference\u002F2.composables",{"title":984,"path":985,"stem":986,"navigationTitle":876},"Server utilities","\u002Fdocs\u002Freference\u002Fserver-utils","docs\u002F6.reference\u002F3.server-utils",{"title":5,"path":877,"stem":879,"navigationTitle":876},{"title":989,"path":990,"stem":991,"navigationTitle":876},"REST API","\u002Fdocs\u002Freference\u002Frest-api","docs\u002F6.reference\u002F5.rest-api",{"title":993,"path":994,"stem":995,"navigationTitle":876},"CLI","\u002Fdocs\u002Freference\u002Fcli","docs\u002F6.reference\u002F6.cli",{"title":997,"path":998,"stem":999,"navigationTitle":876},"Licensing & FAQ","\u002Fdocs\u002Flicensing","docs\u002F8.licensing",[1001,1003],{"title":984,"path":985,"stem":986,"description":1002,"children":-1},"Nuxt server utilities and helpers for agents, tools, automations, integrations and models.",{"title":989,"path":990,"stem":991,"description":1004,"children":-1},"Every route the Agentic API serves, generated from the route manifest.",1792672479677]