@standards/schema 1.0.0-alpha.397 → 1.0.0-alpha.400
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{all-Cuw60VCF.d.ts → all-Y3tO-bfa.d.mts} +80 -70
- package/dist/{all-BMhGZOJ4.d.mts → all-o498zQ_Z.d.ts} +80 -70
- package/dist/api/index.d.mts +160 -64
- package/dist/api/index.d.ts +160 -64
- package/dist/api/index.js +1 -1
- package/dist/api/index.mjs +1 -1
- package/dist/{attributes-DHbSq5-c.d.ts → attributes-BOIIZZpP.d.ts} +1 -1
- package/dist/{attributes-ybI2RY0p.d.mts → attributes-CAYOHQLt.d.mts} +1 -1
- package/dist/{checkbox-DvtCTshQ.d.mts → checkbox-RJEhZTDu.d.mts} +2 -2
- package/dist/{checkbox-BgyfKv2J.d.ts → checkbox-UJEOyMLV.d.ts} +2 -2
- package/dist/{date-B9livx2w.d.mts → date-jqgfgslv.d.mts} +2 -2
- package/dist/{date-CDg8dTJA.d.ts → date-rwqgadEE.d.ts} +2 -2
- package/dist/{exceptions-CeP0QxYo.d.mts → exceptions-RCZEE1uQ.d.mts} +6 -2
- package/dist/{exceptions-CeP0QxYo.d.ts → exceptions-RCZEE1uQ.d.ts} +6 -2
- package/dist/exceptions.d.mts +1 -1
- package/dist/exceptions.d.ts +1 -1
- package/dist/{index-BttvvaQY.d.mts → index-BC5mEVkb.d.mts} +3 -3
- package/dist/{index-DpDZ-UoW.d.mts → index-Bk_zzZUx.d.mts} +418 -78
- package/dist/{index-CanuuQuP.d.ts → index-BsOZnVmp.d.ts} +3 -3
- package/dist/{index-BaxABgqT.d.ts → index-C0k7xmHS.d.ts} +418 -78
- package/dist/{index-ea_C0sbY.d.ts → index-CFXgKvOC.d.ts} +1 -1
- package/dist/{index-DICp0at8.d.mts → index-CiKELB3w.d.mts} +1 -1
- package/dist/{index-bLYmzLtL.d.mts → index-ColQV1OG.d.mts} +3 -3
- package/dist/{index-Jjt6ggWu.d.ts → index-DMBl9Ahc.d.ts} +3 -3
- package/dist/index.d.mts +14 -14
- package/dist/index.d.ts +14 -14
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{number-MnY5CLQ-.d.ts → number-CfG_k0mZ.d.ts} +2 -2
- package/dist/{number-CASI8GSl.d.mts → number-DYkxcIqq.d.mts} +2 -2
- package/dist/{objects-DgAAilNd.d.ts → objects-Dc4zYk9o.d.ts} +2 -2
- package/dist/{objects-q1d_wU_1.d.mts → objects-Dmn8ZIXZ.d.mts} +2 -2
- package/dist/record-operation-BP69nfIq.mjs +2 -0
- package/dist/record-operation-BU_PIu6m.js +2 -0
- package/dist/{text-CIY_GzA4.d.ts → text-BkLwT1XH.d.ts} +2 -2
- package/dist/{text-BjaTSXw_.d.mts → text-DkZ-_8Qs.d.mts} +2 -2
- package/dist/{utils-DDQvppjN.d.ts → utils-Brab7BhE.d.ts} +1 -1
- package/dist/{utils-BrTiR8t6.d.mts → utils-C8viP5ET.d.mts} +1 -1
- package/dist/utils.d.mts +1 -1
- package/dist/utils.d.ts +1 -1
- package/dist/validation/all.d.mts +4 -4
- package/dist/validation/all.d.ts +4 -4
- package/dist/validation/all.js +1 -1
- package/dist/validation/all.mjs +1 -1
- package/dist/validation/complex/currency.d.mts +2 -2
- package/dist/validation/complex/currency.d.ts +2 -2
- package/dist/validation/complex/location.d.mts +2 -2
- package/dist/validation/complex/location.d.ts +2 -2
- package/dist/validation/complex/phone.d.mts +2 -2
- package/dist/validation/complex/phone.d.ts +2 -2
- package/dist/validation/complex/relation.d.mts +2 -2
- package/dist/validation/complex/relation.d.ts +2 -2
- package/dist/validation/complex/richtext.d.mts +2 -2
- package/dist/validation/complex/richtext.d.ts +2 -2
- package/dist/validation/complex/select.d.mts +2 -2
- package/dist/validation/complex/select.d.ts +2 -2
- package/dist/validation/complex/user.d.mts +2 -2
- package/dist/validation/complex/user.d.ts +2 -2
- package/dist/validation/computed/formula.d.mts +2 -2
- package/dist/validation/computed/formula.d.ts +2 -2
- package/dist/validation/computed/rollup.d.mts +2 -2
- package/dist/validation/computed/rollup.d.ts +2 -2
- package/dist/validation/config/index.d.mts +1 -1
- package/dist/validation/config/index.d.ts +1 -1
- package/dist/validation/core/index.d.mts +1 -1
- package/dist/validation/core/index.d.ts +1 -1
- package/dist/validation/object/index.d.mts +1 -1
- package/dist/validation/object/index.d.ts +1 -1
- package/dist/validation/primitives/checkbox.d.mts +1 -1
- package/dist/validation/primitives/checkbox.d.ts +1 -1
- package/dist/validation/primitives/date.d.mts +1 -1
- package/dist/validation/primitives/date.d.ts +1 -1
- package/dist/validation/primitives/number.d.mts +1 -1
- package/dist/validation/primitives/number.d.ts +1 -1
- package/dist/validation/primitives/text.d.mts +1 -1
- package/dist/validation/primitives/text.d.ts +1 -1
- package/dist/view-config.schema-B9y7-OCJ.mjs +2 -0
- package/dist/view-config.schema-Cyl6PedI.js +2 -0
- package/package.json +2 -2
- package/dist/record-operation-CYn0ql3E.mjs +0 -2
- package/dist/record-operation-DLlWYtBc.js +0 -2
- package/dist/view-config.schema-Cbq9lhVg.js +0 -2
- package/dist/view-config.schema-D7TH6B1r.mjs +0 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { NumberAttribute } from "./attributes-
|
|
3
|
-
import { ValidationMessages } from "./index-
|
|
2
|
+
import { NumberAttribute } from "./attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "./index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/primitives/number.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { NumberAttribute } from "./attributes-
|
|
3
|
-
import { ValidationMessages } from "./index-
|
|
2
|
+
import { NumberAttribute } from "./attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "./index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/primitives/number.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { Uuid } from "./utils-
|
|
3
|
-
import { Attribute } from "./attributes-
|
|
2
|
+
import { Uuid } from "./utils-Brab7BhE.js";
|
|
3
|
+
import { Attribute } from "./attributes-BOIIZZpP.js";
|
|
4
4
|
import { ColorId, IconName } from "@standards/constants";
|
|
5
5
|
//#region src/types/appearance.d.ts
|
|
6
6
|
/** Icon used when neither the entity nor its parent has one. */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { Uuid } from "./utils-
|
|
3
|
-
import { Attribute } from "./attributes-
|
|
2
|
+
import { Uuid } from "./utils-C8viP5ET.mjs";
|
|
3
|
+
import { Attribute } from "./attributes-CAYOHQLt.mjs";
|
|
4
4
|
import { ColorId, IconName } from "@standards/constants";
|
|
5
5
|
//#region src/types/appearance.d.ts
|
|
6
6
|
/** Icon used when neither the entity nor its parent has one. */
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! © 2025-2026 AND YOU CREATE SAS (RCS Paris 940 190 614). Proprietary — see LICENSE (Standards SDK License 1.0). */
|
|
2
|
+
import{SchemaError as e,SchemaErrorCode as t,ToolGroupGrantError as n,ValidationError as r}from"./exceptions.mjs";import"./zod-locale.mjs";import{assertUniqueBy as i,colorIdSchema as a,iconNameSchema as ee}from"./primitives-D9A6pmXV.mjs";import*as o from"zod";import{AVATAR_COLOR_IDS as te}from"@standards/constants";const ne=[`completed`,`failed`,`cancelled`];function invalidSessionState(n){throw new e(n,t.INVARIANT_VIOLATION)}function assertSessionState(e){e.phase===`running`?e.runningTurnId===void 0&&invalidSessionState(`running session without runningTurnId`):e.runningTurnId!==void 0&&invalidSessionState(`runningTurnId present on a ${e.phase} session`),e.phase===`parked`?e.parkedOn===void 0&&invalidSessionState(`parked session without parkedOn`):e.parkedOn!==void 0&&invalidSessionState(`parkedOn present on a ${e.phase} session`),e.parkedOn===`human`?e.humanRequestIds===void 0&&invalidSessionState(`human-parked session without humanRequestIds`):e.humanRequestIds!==void 0&&invalidSessionState(`humanRequestIds present on a session not parked on a human`)}const re=[`createdAt`,`lastActivity`],s=Object.freeze({mutation:`ask`,destructive:`ask`,outward:`ask`}),ie=[`active`,`completed`,`abandoned`],ae=[`openai`,`anthropic`,`google`,`spacexai`,`deepseek`,`moonshotai`,`alibaba`,`mistral`,`minimax`,`meta`,`zai`,`cursor`],oe=[`standard`,`fast`],se=[`none`,`minimal`,`low`,`medium`,`high`,`xhigh`],ce=[`conversation`,`writing`,`coding`,`analysis`,`extraction`],le=[`light`,`standard`,`heavy`],ue=[`manual`,`auto`],de={interactive:{inputPerMillionUsd:5,outputPerMillionUsd:25},delegated:{inputPerMillionUsd:2,outputPerMillionUsd:12}},c=[`model`,`speed`,`reasoning`,`imageModel`,`routing`];function mergeSessionInferencePatch(e,t){let n={...e};for(let e of c){let r=t[e];r===null?delete n[e]:r!==void 0&&Object.assign(n,{[e]:r})}return t.model&&t.routing===void 0&&(n.routing=`manual`),n}function isRoutineActorMetadata(e){return e?.kind===`routine`}const l=[`octopus`,`clover`,`flower`,`triangle`,`square`,`blob`,`circle`,`drop`,`hexagon`,`pill`,`pebble`,`puddle`],u=[`relaxed`,`neutral`],fe=4,pe=200;function agentDisplayName(e){return e.label?.trim()||e.name}const d=[`approval-requested`,`approval-responded`,`approval-dispatched`],f=[`streaming`,`running`,`pending`,...d];function isOpenToolPartState(e){return f.includes(e)}function isToolApprovalState(e){return d.includes(e)}const p=[`CREDITS_EXHAUSTED`];function isSystemPartCode(e){return typeof e==`string`&&p.includes(e)}const me=20,he=4e3,ge=32e3;function compareAgentSessionMessages(e,t){let n=e.createdAt.getTime()-t.createdAt.getTime();return n===0?e.id.localeCompare(t.id):n}function orderAgentSessionMessages(e){return[...e].sort(compareAgentSessionMessages)}const _e=200,ve=182,ye=366,m=`agent-notification`;function isAgentNotificationMetadata(e){return e?.kind===m}const h=`agent-message`;function isAgentMessageMetadata(e){return e?.kind===h}const be=`architect-publication`;function isArchitectPublicationMetadata(e){return e?.kind===be}const xe=[`pending`,`in_progress`,`completed`,`blocked`],Se=[`objects`,`fields`,`relations`,`views`,`samples`],Ce=50,we=80,Te=500,g=[`sandbox`,`web`,`image`,`memory`,`bulk`,`activity`,`orchestration`,`host`,`cloud-browser`,`notifications`],Ee=`browser_launch`,_=[`mcp`,`email.read`,`email.send`,`calendar.read`,`github`,`slack.read`,`slack.write`,`device`,`browser`,`browser-profile`,`login`],De=[`definition`,`default`,`child`,`inline`],Oe=[`manual`,`name-asc`,`name-desc`,`date-desc`,`date-asc`],ke=100,Ae=500,je=2048,Me=[`reader`,`runner`,`editor`],v=[`reader`,`editor`],Ne=[`manual`,`meeting_attendee`],Pe=new Set([`memory`,`skill`]);function parseRole(e,t){if(typeof t==`string`&&e.includes(t))return t;let n=`role must be one of: ${e.join(`, `)}`;throw new r(n,[{path:[`role`],message:n}])}function parseRecordAccessRole(e){return parseRole(v,e)}function parseAgentDefinitionAccessRole(e){return parseRole(Me,e)}function parsePageAccessRole(e){return parseRole(v,e)}function deriveViewerAccess(e,t){return e.visibility===`workspace`?`workspace`:e.ownedBy!==null&&t.includes(e.ownedBy)?`owner`:e.viewerGrant===`editor`?`editor`:e.viewerGrant===`runner`?`runner`:`reader`}const Fe=[`fr`,`en`],y=[`none`,`estimated`,`exact`];function parseCountMode(e){if(typeof e==`string`&&y.includes(e))return e;throw new r(`countMode must be one of: ${y.join(`, `)} (received: ${String(e)})`,[])}function parseOptionalCountMode(e){return e===void 0?void 0:parseCountMode(e)}const Ie=1e4,Le=[`record`,`object`,`attribute`,`view`,`user`,`role`,`settings`,`file`,`agent`,`bundle`,`tenant_invitation`,`api_key`],Re=`record.created,record.updated,record.deleted,record.restored,record.purged,record.access_changed,agent.access_changed,object.created,object.updated,object.deleted,attribute.created,attribute.updated,attribute.deleted,view.created,view.updated,view.deleted,bundle.synced,bundle.removed,bundle.added,user.created,user.invited,user.updated,user.deleted,user.login,user.logout,tenant_invitation.created,tenant_invitation.delivery_failed,tenant_invitation.resent,tenant_invitation.revoked,tenant_invitation.accepted,role.created,role.updated,role.deleted,role.assigned,role.revoked,api_key.detached,settings.updated,file.uploaded,file.updated,file.deleted`.split(`,`),ze=`agentSessionId`;function isAgentWrittenAuditEntry(e){return e.actorType===`agent`||typeof e.metadata?.agentSessionId==`string`}const Be=[`draft_schema`],Ve=`discard_architect_draft`,b=`request_design_review`,He=`get_architect_draft`,x=`ask_questions`,S=`request_setup`,Ue=new Set([x,b,S]),We=new Set([x,S]),Ge=new Set([b]),Ke=4,qe=2e3,Je=50,Ye=o.union([o.object({value:o.string(),label:o.string()}).strict(),o.object({values:o.array(o.string()),labels:o.array(o.string()),text:o.string().optional()}).strict(),o.object({text:o.string()}).strict()]),Xe=o.object({skipped:o.boolean().describe(`True if the person skipped all questions`),answers:o.record(o.string(),Ye).describe(`Map of question ID to the answer given, with each chosen option's value and label`)});function readAskQuestionsResult(e){let t=Xe.safeParse(e);return t.success?t.data:null}function humanRequestKind(e){return e.approvalId==null?We.has(e.name)?`question`:Ge.has(e.name)?`review`:null:`approval`}function isAwaitingHuman(e){return humanRequestKind(e)===null||e.state===`streaming`||!isOpenToolPartState(e.state)||e.result!==void 0||e.error!==void 0?!1:e.approvalId==null||e.state===`approval-requested`&&e.approved===void 0}function isBlocking(e){let t=humanRequestKind(e);return t===`review`?isOpenToolPartState(e.state):t===`approval`&&e.state===`approval-requested`&&e.approved===void 0}function humanRequestId(e){return e.approvalId??e.toolCallId}function openRequests(e,t){let n=t.blocking?isBlocking:isAwaitingHuman,r=[];for(let t of e)for(let e of t.parts??[])isToolRequestPart(e)&&n(e)&&r.push({part:e,id:humanRequestId(e),requestedAt:t.createdAt});return r}function isToolRequestPart(e){return e.type===`tool`}function isParkedOnHuman(e){return e?.phase===`parked`&&e.parkedOn===`human`}const Ze=50;function recentActivityEntryKey(e){return e.kind===`record`?JSON.stringify([`record`,e.objectName,e.recordId]):JSON.stringify([`conversation`,`sessionId`in e?e.sessionId:e.session.id])}const Qe=200,$e=5242880,et=`Notetaker`,tt=/^\d{1,9}(\.\d{1,6})?$/,nt={meetingRecordingPolicy:`none`,meetingBotDisplayName:et,memoryPersonMonthlyLimitUsd:null,memoryTenantMonthlyLimitUsd:null,findImages:!0},rt=[`active`,`suspended`],it=[`architect`,`manual`,`auto`],at=[`panel`,`fullscreen`],ot=50,st=200,ct=50,lt=o.discriminatedUnion(`type`,[o.strictObject({type:o.literal(`record`),object:o.string().min(1),id:o.guid()}),o.strictObject({type:o.literal(`user`),id:o.guid()})]),ut=o.strictObject({nodes:o.array(lt).min(1).max(50),limitPerNode:o.number().int().min(1).max(200).default(50)});function recordGraphNodeKey(e){return e.type===`record`?`record:${e.object}:${e.id}`:`user:${e.id}`}const dt=100,ft=64e3,pt=`work`,C=`/vercel/sandbox/${pt}`,w=`/workspace`;function environmentWorkdir(e){return e?C:w}const T=[{id:`claude-code`,label:`Claude Code`,provider:`anthropic`,apiKeyEnv:`ANTHROPIC_API_KEY`,models:[{id:`sonnet`,label:`Claude Sonnet`},{id:`opus`,label:`Claude Opus`},{id:`haiku`,label:`Claude Haiku`}],defaultModel:`sonnet`},{id:`codex`,label:`Codex`,provider:`openai`,apiKeyEnv:`OPENAI_API_KEY`,models:[{id:`gpt-6.1-sol`,label:`GPT-6.1 Sol`},{id:`gpt-6-luna`,label:`GPT-6 Luna`},{id:`gpt-6-astra`,label:`GPT-6 Astra`}],defaultModel:`gpt-6.1-sol`},{id:`cursor`,label:`Cursor`,provider:`cursor`,apiKeyEnv:`CURSOR_API_KEY`,models:[{id:`auto`,label:`Auto`,cliDefault:!0},{id:`composer-2.5`,label:`Composer 2.5`}],defaultModel:`auto`}],E=new Map(T.map(e=>[e.id,e]));function isEnvironmentHarnessId(e){return E.has(e)}function findEnvironmentHarness(e){return E.get(e)}function environmentHarness(n){let r=E.get(n);if(!r)throw new e(`Unknown harness "${n}"`,t.INVARIANT_VIOLATION);return r}function cliDefaultModelOf(e){return environmentHarness(e).models.find(e=>e.cliDefault)?.id}function compiledHarnessModels(e){let t=environmentHarness(e);return t.models.map(e=>({id:e.id,label:e.label,...e.id===t.defaultModel?{isDefault:!0}:{}}))}function harnessModelChoices(e,t){let{provider:n}=environmentHarness(e);return t.map(e=>({id:e.id,provider:n,label:e.label,...e.isDefault?{isDefault:!0}:{}}))}const D=[`search`,`query`,`read`,`write`,`delete`,`organize`,`copy`,`send`],O=[...D,`edit_content`],k=[...O,`ask_questions`,`compact_context`,`request_work_mode`,`write_todos`],A=[`browser_autopilot`,`browser_batch`,`browser_computer`,`browser_find`,`browser_form_input`,`browser_get_text`,`browser_javascript`,`browser_navigate`,`browser_read_page`,`browser_sign_in`,`browser_tabs`],mt=[`record`,`document`,`file`,`skill`,`schema`,`guide`],j={memory:{kinds:[`memory`],capabilities:[],tools:[`propose_memory`]},bulk:{kinds:[],capabilities:[`bulk`],tools:[]},activity:{kinds:[],capabilities:[`activity`],tools:[]},"email.read":{kinds:[`email`,`thread`],capabilities:[`copy_email`],tools:[]},"email.send":{kinds:[`email`,`thread`,`draft`],capabilities:[`copy_email`],tools:[]},"calendar.read":{kinds:[`event`],capabilities:[`transcript`],tools:[]}},M={sandbox:{icon:`terminal`,tools:[`exec_command`,`publish_artifact`,`sandbox_validate_payload`]},web:{icon:`globe`,tools:[`read_webpage`,`web_search`]},image:{icon:`image`,tools:[`generate_image`]},memory:{icon:`book-open`,tools:j.memory.tools},bulk:{icon:`layers-two`,tools:j.bulk.tools},activity:{icon:`activity`,tools:j.activity.tools},orchestration:{icon:`git-branch`,tools:[`message_agent`,`spawn_agent`]},host:{icon:`wrench`,tools:[]},"cloud-browser":{icon:`globe`,tools:[`browser_launch`]},notifications:{icon:`bell`,tools:[`notify`]}},N={mcp:{icon:`puzzle`,tools:[]},"email.read":{icon:`envelope`,tools:j[`email.read`].tools},"email.send":{icon:`send`,tools:j[`email.send`].tools},"calendar.read":{icon:`calendar`,tools:j[`calendar.read`].tools},github:{icon:`brand-github`,tools:[]},"slack.read":{icon:`brand-slack`,tools:[`slack_read`,`slack_find`,`slack_download_file`]},"slack.write":{icon:`brand-slack`,tools:[`slack_send`,`slack_react`,`slack_set_status`]},device:{icon:`desktop`,tools:[`exec_command`]},browser:{icon:`link`,tools:A},"browser-profile":{icon:`globe`,tools:[`browser_launch`,...A]},login:{icon:`key`,tools:[]}},ht={sandbox:{kinds:[],capabilities:[],tools:M.sandbox.tools},web:{kinds:[],capabilities:[],tools:M.web.tools},image:{kinds:[],capabilities:[],tools:M.image.tools},memory:j.memory,bulk:j.bulk,activity:j.activity,orchestration:{kinds:[],capabilities:[],tools:M.orchestration.tools},host:{kinds:[],capabilities:[],tools:M.host.tools},"cloud-browser":{kinds:[],capabilities:[],tools:M[`cloud-browser`].tools},notifications:{kinds:[],capabilities:[],tools:M.notifications.tools},mcp:{kinds:[],capabilities:[],tools:N.mcp.tools},"email.read":j[`email.read`],"email.send":j[`email.send`],"calendar.read":j[`calendar.read`],github:{kinds:[],capabilities:[],tools:N.github.tools},"slack.read":{kinds:[],capabilities:[],tools:N[`slack.read`].tools},"slack.write":{kinds:[],capabilities:[],tools:N[`slack.write`].tools},device:{kinds:[],capabilities:[],tools:N.device.tools},browser:{kinds:[],capabilities:[],tools:N.browser.tools},"browser-profile":{kinds:[],capabilities:[],tools:N[`browser-profile`].tools},login:{kinds:[],capabilities:[],tools:N.login.tools}},gt={schema:[`discard_architect_draft`,`draft_schema`,`get_architect_draft`,`get_schema_history`,`request_design_review`,`search_icons`],"agent-config":[`get_agents`,`upsert_agent`],setup:[`request_setup`],internal:[`load_toolset`]},_t=[...new Set([...k,...g.flatMap(e=>M[e].tools),..._.flatMap(e=>N[e].tools)])],vt={"email.read":[`gmail`,`outlook`],"email.send":[`gmail`,`outlook`],"calendar.read":[`google-calendar`,`outlook-calendar`]};function connectionGrantKindsOf(e){switch(e){case`github`:return[`github`];case`slack`:return[`slack.read`,`slack.write`];case`google-calendar`:case`outlook-calendar`:return[`calendar.read`];case`gmail`:case`outlook`:return[`email.read`,`email.send`]}}const yt=[`activity`,`bulk`,`image`,`memory`,`orchestration`,`sandbox`,`web`],P=[`memory`],bt=new Set([`sandbox`,`host`,`cloud-browser`]);function needsManageWhenUnattended(e){return bt.has(e)||isResourceGrant(e)}function isNativeToolGroup(e){return g.includes(e)}function parseToolGroupGrant(e){if(isNativeToolGroup(e))return{type:`native`,group:e};let t=e.indexOf(`:`);if(t<=0)return null;let n=e.slice(0,t),r=e.slice(t+1);return r.length===0||!_.includes(n)?null:{type:`resource`,kind:n,id:r}}function grantKindOf(e){let t=parseToolGroupGrant(e);return t?.type===`resource`?t.kind:null}function isResourceGrant(e){return parseToolGroupGrant(e)?.type===`resource`}function resourceGrant(e,t){return`${e}:${t}`}function canonicalToolGroups(e){return[...new Set(e)].sort()}const F=[{key:`direct`,icon:`message`,color:`ink`,description:`A message a person wrote to this mailbox: a conversation, a question, a request, a reply.`},{key:`transactional`,icon:`credit-card`,color:`terra`,description:`An automated message about an account or an operation: receipt, invoice, payment, order, shipping, booking, password reset, security alert.`},{key:`notifications`,icon:`bell`,color:`ochre`,description:`An automated alert from a tool or a service: activity on GitHub, Slack, a calendar, a CRM, a monitoring system.`},{key:`newsletters`,icon:`book-open`,color:`stone`,description:`Editorial content the mailbox subscribed to: newsletters, digests, articles, community updates.`},{key:`marketing`,icon:`percentage`,color:`iris`,description:`Promotion or prospecting: offers, discounts, product announcements, cold sales outreach.`}],I={direct:{en:`Direct`,fr:`Direct`},transactional:{en:`Transactional`,fr:`Transactionnel`},notifications:{en:`Notifications`,fr:`Notifications`},newsletters:{en:`Newsletters`,fr:`Newsletters`},marketing:{en:`Marketing`,fr:`Marketing`}},xt=8,St=24,Ct=10,wt=500,Tt=`tag`,L=`stone`,R=new Set(`gmail.com,googlemail.com,outlook.com,hotmail.com,hotmail.fr,outlook.fr,live.com,live.fr,msn.com,yahoo.com,yahoo.fr,icloud.com,me.com,mac.com,proton.me,protonmail.com,gmx.com,gmx.fr,orange.fr,wanadoo.fr,free.fr,laposte.net,sfr.fr,bbox.fr,numericable.fr,aol.com`.split(`,`)),Et=new Set(F.map(e=>e.key)),Dt=new Set(Object.entries(I).flatMap(([e,t])=>[e,t.en,t.fr].map(e=>e.toLowerCase())));function isSystemEmailCategory(e){return Et.has(e)}function isSystemEmailCategoryName(e){return Dt.has(e.trim().toLowerCase())}function isPublicMailDomain(e){return R.has(e.toLowerCase())}const z={maxConcurrentRuns:3,retryPolicy:{maxRetries:3,backoffMs:1e3,backoffMultiplier:2}};var AgentBuilder=class{constructor(e){if(!e.name||e.name.trim().length===0)throw new r(`Agent name is required`,[]);this.bp={name:e.name,system:!0,visibility:`workspace`,triggers:[]}}description(e){return this.bp.description=e,this}label(e){return this.bp.label=e,this}avatar(e){return this.bp.avatar={type:e.type,color:e.color,expression:e.expression??`relaxed`},this}starters(e){return e.length===0?delete this.bp.starters:this.bp.starters=[...e],this}systemPrompt(e){return this.bp.systemPrompt=e,this}model(e,t,n){return this.bp.model={provider:e,model:t,...n},this}toolGroups(e){let r=e.find(e=>!isNativeToolGroup(e));if(r!==void 0)throw new n(t.AGENT_TOOL_GROUP_UNKNOWN,r,`Agent "${this.bp.name}": "${r}" is not a native tool group (blueprints cannot grant tenant resources)`);return this.bp.toolGroups=canonicalToolGroups(e),this}schedule(e){return this.bp.schedule={...e,enabled:e.enabled??!0},this}config(e){let t=this.bp.config??z,n=e.inference===void 0?t.inference:{...t.inference,...e.inference};return this.bp.config={...t,...e,...n===void 0?{}:{inference:n}},this}delegation(e){return Object.assign(this.bp,e),this}approval(e){return this.bp.approval={...s,...this.bp.approval,...e},this}visibility(e){return this.bp.visibility=e,this}trigger(e,t,n){return this.bp.triggers.push({name:e,eventType:t,...n,enabled:n?.enabled??!0}),this}runtime(){return this.bp.system=!1,this}build(){if(!this.bp.systemPrompt)throw new r(`Agent "${this.bp.name}": systemPrompt is required`,[]);if(!this.bp.model)throw new r(`Agent "${this.bp.name}": model is required`,[]);if(this.bp.system&&this.bp.visibility===`private`)throw new r(`Agent "${this.bp.name}": system agents must use workspace visibility`,[]);return i(this.bp.triggers,e=>e.name,e=>new r(`Agent "${this.bp.name}": duplicate trigger name "${e}"`,[])),{...this.bp,visibility:this.bp.visibility??`workspace`,toolGroups:this.bp.toolGroups??[...P],config:this.bp.config??z,systemPrompt:this.bp.systemPrompt,model:this.bp.model}}};function agent(e){return new AgentBuilder(e)}const B={issue:{events:[`issues`],actions:[`opened`,`edited`,`closed`,`reopened`,`labeled`,`unlabeled`,`assigned`,`unassigned`,`milestoned`,`demilestoned`,`transferred`,`pinned`],conditions:[`label`,`issueLabels`,`assignees`,`milestone`,`issueType`,`text`]},pull_request:{events:[`pull_request`],actions:[`opened`,`ready_for_review`,`synchronize`,`review_requested`,`merged`,`closed`,`reopened`,`converted_to_draft`,`labeled`,`assigned`,`edited`],conditions:[`baseBranch`,`headBranch`,`draft`,`issueLabels`,`changedPaths`,`prAuthor`]},review:{events:[`pull_request_review`],actions:[`submitted`,`edited`,`dismissed`],conditions:[`reviewState`,`prAuthor`]},comment:{events:[`issue_comment`,`pull_request_review_comment`,`commit_comment`],actions:[`created`,`edited`,`deleted`],conditions:[`text`,`issueAuthor`,`prAuthor`]},push:{events:[`push`],actions:[`pushed`],conditions:[`branch`,`changedPaths`,`forced`]},ref:{events:[`create`,`delete`],actions:[`created`,`deleted`],conditions:[`refType`,`branch`,`tag`]},workflow:{events:[`workflow_run`],actions:[`requested`,`in_progress`,`completed`],conditions:[`workflowName`,`conclusion`,`branch`,`originEvent`]},check:{events:[`check_suite`,`check_run`],actions:[`completed`,`rerequested`],conditions:[`checkApp`,`checkName`,`conclusion`]},project_item:{events:[`projects_v2_item`],actions:[`created`,`edited`,`archived`,`restored`,`deleted`],conditions:[`project`,`projectField`,`from`,`to`,`itemType`]},release:{events:[`release`],actions:[`published`,`created`,`edited`,`prereleased`,`deleted`],conditions:[`prerelease`,`tag`]},discussion:{events:[`discussion`,`discussion_comment`],actions:[`created`,`commented`,`answered`,`labeled`,`closed`],conditions:[`category`,`issueLabels`,`text`]},repository:{events:[`star`,`fork`,`repository`],actions:[`starred`,`forked`,`created`,`archived`],conditions:[]}},Ot={mention:{events:[`app_mention`],conditions:[`text`]},message:{events:[`message`],conditions:[`position`,`text`,`hasFile`]},dm:{events:[`message`],conditions:[`text`,`hasFile`]},reaction:{events:[`reaction_added`],conditions:[`messageAuthor`]},member_joined:{events:[`member_joined_channel`],conditions:[]}},kt=o.object({field:o.literal(`text`),operator:o.enum([`contains`,`starts_with`]),value:o.string().min(1)}).strict();function stringCondition(e){return o.object({field:o.literal(e),value:o.string().min(1)}).strict()}function booleanCondition(e){return o.object({field:o.literal(e),value:o.boolean()}).strict()}function listCondition(e){return o.object({field:o.literal(e),operator:o.enum([`any`,`all`]).default(`any`),value:o.array(o.string().min(1)).min(1)}).strict()}const At=o.discriminatedUnion(`field`,[kt,stringCondition(`label`),listCondition(`issueLabels`),listCondition(`assignees`),stringCondition(`milestone`),stringCondition(`issueType`),stringCondition(`baseBranch`),stringCondition(`headBranch`),stringCondition(`branch`),booleanCondition(`draft`),stringCondition(`changedPaths`),booleanCondition(`forced`),stringCondition(`prAuthor`),stringCondition(`issueAuthor`),o.object({field:o.literal(`reviewState`),value:o.enum([`approved`,`changes_requested`,`commented`])}).strict(),stringCondition(`workflowName`),stringCondition(`checkApp`),stringCondition(`checkName`),stringCondition(`conclusion`),stringCondition(`originEvent`),stringCondition(`project`),stringCondition(`projectField`),o.object({field:o.literal(`from`),value:o.string().nullable()}).strict(),o.object({field:o.literal(`to`),value:o.string().nullable()}).strict(),o.object({field:o.literal(`itemType`),value:o.enum([`issue`,`pull_request`,`draft`])}).strict(),booleanCondition(`prerelease`),stringCondition(`tag`),o.object({field:o.literal(`refType`),value:o.enum([`branch`,`tag`])}).strict(),stringCondition(`category`)]),jt=o.discriminatedUnion(`field`,[kt,o.object({field:o.literal(`position`),value:o.enum([`top_level`,`reply`])}).strict(),booleanCondition(`hasFile`),stringCondition(`messageAuthor`)]),Mt=o.string().regex(/^[A-Za-z0-9_.-]+\/[A-Za-z0-9_.-]+$/),Nt=o.enum([`human`,`me`,`any`]),Pt=o.object({family:o.enum(Object.keys(B)),actions:o.array(o.string()).default([]),repositories:o.array(Mt).default([]),sender:o.union([Nt,o.object({logins:o.array(o.string().min(1)).min(1)}).strict()]).default(`human`),conditions:o.array(At).default([])}).strict().superRefine((e,t)=>{let n=B[e.family];e.actions.forEach((r,i)=>{n.actions.includes(r)||t.addIssue({code:`custom`,path:[`actions`,i],message:`Action ${r} is not supported by ${e.family}`})}),e.conditions.forEach((r,i)=>{n.conditions.includes(r.field)||t.addIssue({code:`custom`,path:[`conditions`,i,`field`],message:`Condition ${r.field} is not supported by ${e.family}`})})}).transform(e=>e),Ft=o.object({on:o.enum([`mention`,`message`,`dm`,`reaction`,`member_joined`]),channels:o.array(o.string().min(1)).default([]),reactions:o.array(o.string().min(1)).optional(),sender:o.union([Nt,o.object({users:o.array(o.string().min(1)).min(1)}).strict()]).default(`human`),conditions:o.array(jt).default([])}).strict().superRefine((e,t)=>{e.conditions.forEach((n,r)=>{Ot[e.on].conditions.includes(n.field)||t.addIssue({code:`custom`,path:[`conditions`,r,`field`],message:`Condition ${n.field} is not supported by ${e.on}`})}),e.reactions!==void 0&&e.on!==`reaction`&&t.addIssue({code:`custom`,path:[`reactions`],message:`reactions requires on=reaction`})}).transform(e=>e),It=o.union([Pt,Ft]),Lt=[`read`,`write`,`full`],Rt=[`accepted`,`declined`,`tentative`],zt=[`force`,`skip`],Bt=[`none`,`all`,`external_only`],Vt={override:null,status:`none`,failureReason:null,botId:null},Ht=o.object({speaker:o.string().nullable(),startsAtMs:o.number(),endsAtMs:o.number(),text:o.string()}),Ut=o.object({fullText:o.string(),segments:o.array(Ht),language:o.string().nullable(),startedAt:o.string().nullable(),endedAt:o.string().nullable()}),Wt={width:1280,height:720,maxBytes:13e5,mimeType:`image/jpeg`},Gt=Math.ceil(Wt.maxBytes/3)*4,Kt=o.object({conferenceJoinUrl:o.string().min(1),botDisplayName:o.string().min(1),startsAt:o.string().nullable(),callbackUrl:o.url(),botImageJpeg:o.string().max(Gt).optional()}),qt=o.object({botId:o.string().min(1)}),Jt=o.discriminatedUnion(`kind`,[o.object({kind:o.literal(`transcript-ready`),botId:o.string().min(1)}),o.object({kind:o.literal(`failure`),botId:o.string().min(1),reason:o.string()})]),Yt=100;let Xt=function(e){return e.Desktop=`desktop`,e}({});function isMailProvider(e){return e===`gmail`||e===`outlook`}const Zt=`DRAFT`;function isProviderDraft(e){return e.includes(Zt)}const Qt=[`read`,`unread`,`archive`,`trash`,`restore`],$t=[`threads`,`messages`];function isMailboxListMode(e){return $t.includes(e)}const en=[`reply`,`reply_all`];function isReplyMode(e){return en.includes(e)}const tn=2e5,nn=2e4,rn=998,V=o.number().finite().nonnegative(),H=o.enum(ae),U=o.enum(oe),W=o.enum(se),G=o.enum(ue),K=o.object({provider:H,model:o.string().min(1)}).strict(),an=o.object({speed:U.optional(),reasoning:W.optional(),routing:G.optional()}).strict(),q=o.string().regex(/^[a-z0-9][a-z0-9-]*\/[a-z0-9][a-z0-9._-]*$/),on=o.object({model:K.optional(),speed:U.optional(),reasoning:W.optional(),imageModel:q.optional(),routing:G.optional()}).strict(),sn=on.refine(e=>c.some(t=>e[t]!==void 0),{message:`At least one inference override is required`});function isSessionInferencePatch(e){return Object.keys(e).length>0&&Object.values(e).every(e=>e!==void 0)}const cn=o.object({model:K.nullable().optional(),speed:U.nullable().optional(),reasoning:W.nullable().optional(),imageModel:q.nullable().optional(),routing:G.nullable().optional()}).strict().refine(isSessionInferencePatch,{message:`At least one inference override is required`}),ln=o.object({model:o.string().min(1),routing:o.object({mode:o.literal(`auto`),tasks:o.array(o.enum(ce)).optional(),demand:o.enum(le).optional(),reason:o.enum([`selected`,`retained`,`fallback`]).optional(),relation:o.enum([`continue`,`modify`,`new`,`aside`,`unknown`]).optional(),anchorMessageId:o.string().min(1).optional()})}),J=o.object({label:o.string(),denied:o.boolean().optional(),deletion:o.object({target:o.string().optional(),count:V.optional(),restorableDays:V.optional()}).strict().optional(),record:o.object({objectName:o.string(),id:o.string(),label:o.string(),objectIcon:o.string().optional()}).strict().optional(),object:o.object({name:o.string(),label:o.string()}).strict().optional(),email:o.object({from:o.string(),to:o.array(o.string()),cc:o.array(o.string()),bcc:o.array(o.string()),subject:o.string().nullable(),text:o.string(),truncatedChars:V,outsideThread:o.array(o.string()),attachments:o.array(o.object({name:o.string(),size:V}).strict()),updatedAt:o.string(),forwarded:o.object({from:o.string(),subject:o.string().nullable(),quote:o.string(),quoteTruncatedChars:V}).strict().optional()}).strict().optional(),counts:o.record(o.string(),V).optional(),warnings:o.array(o.string()).optional()}).strict(),un=o.union([o.object({type:o.literal(`text`),text:o.string()}).strict(),o.object({type:o.literal(`reasoning`),text:o.string()}).strict(),o.object({type:o.literal(`system`),code:o.enum(p)}).strict(),o.object({type:o.literal(`error`),error:o.string(),errorClass:o.string().optional()}).strict(),o.object({type:o.literal(`tool`),toolCallId:o.string(),name:o.string(),args:o.record(o.string(),o.unknown()),result:o.unknown().optional(),error:o.string().optional(),errorCode:o.enum([`output_limit_reached`,`interrupted`,t.INVALID_TOOL_INPUT,`external_outcome_unknown`,`external_not_dispatched`]).optional(),state:o.enum([`streaming`,`running`,`completed`,`error`,`pending`,`approval-requested`,`approval-responded`,`approval-dispatched`]),durationMs:V.optional(),approvalId:o.string().optional(),approvalImpact:J.optional(),approved:o.boolean().optional(),approvalReason:o.string().optional(),approvalDecidedBy:o.string().optional(),approvalDecidedAt:o.string().optional(),approvalRelaxableByAuto:o.boolean().optional()}).strict(),o.object({type:o.literal(`file`),fileId:o.string(),name:o.string(),mimeType:o.string()}).strict(),o.object({type:o.literal(`compaction`),state:o.literal(`in-progress`),reason:o.enum([`preflight_threshold`,`overflow_recovery`]),estimatedTokens:V.optional(),reportedTokens:V.optional()}).strict(),o.object({type:o.literal(`compaction`),state:o.literal(`completed`),tokensBefore:V,tokensAfter:V,tokensSaved:V,strategy:o.enum([`no-op`,`summary`,`truncation`]),durationMs:V,summary:o.string().optional()}).strict(),o.object({type:o.literal(`compaction`),state:o.literal(`failed`),reason:o.string(),durationMs:V.optional()}).strict()]),dn=o.object({id:o.string(),name:o.string(),mimeType:o.string(),size:V}).strict(),fn=o.object({id:o.string(),artifactId:o.string(),revision:o.number().int().min(1),selectedText:o.string()}).strict(),pn=o.object({id:o.string(),type:o.string().transform(e=>e),entityId:o.string(),label:o.string(),objectName:o.string().optional(),startIndex:V,endIndex:V}).strict(),mn=o.object({provider:H,model:o.string(),maxTokens:V.optional(),contextWindow:V.optional()}).strict(),hn=o.union([o.date(),o.string().datetime({offset:!0}).transform(e=>new Date(e))]),gn=o.object({id:o.string(),sessionId:o.string(),tenantId:o.string().optional(),runId:o.string().optional(),role:o.enum([`user`,`assistant`,`system`,`tool`]),parts:o.array(un),attachments:o.array(dn).optional(),mentions:o.array(pn).optional(),quotes:o.array(fn).optional(),model:mn.optional(),tokenUsage:o.object({input:V,output:V}).strict().optional(),metadata:o.record(o.string(),o.unknown()).optional(),createdAt:hn}).strict(),_n=o.object({id:o.string(),description:o.string(),status:o.enum([`pending`,`in_progress`,`completed`,`blocked`]),result:o.string().optional(),updatedAt:V.optional(),target:o.object({phase:o.enum(Se)}).strict().optional()}).strict(),vn=o.object({id:o.string(),sessionId:o.string(),status:o.enum([`active`,`completed`,`abandoned`]),todos:o.array(_n),version:V,createdAt:o.string(),updatedAt:o.string(),completedAt:o.string().optional()}).strict(),Y={"compaction-start":o.object({reason:o.enum([`preflight_threshold`,`overflow_recovery`]),estimatedTokens:V.optional(),reportedTokens:V.optional()}).strict(),"compaction-end":o.object({tokensBefore:V,tokensAfter:V,tokensSaved:V,strategy:o.enum([`no-op`,`summary`,`truncation`]),durationMs:V,summary:o.string().optional()}).strict(),"compaction-failed":o.object({reason:o.string()}).strict(),usage:o.object({messageId:o.string().min(1).optional(),inputTokens:V,outputTokens:V,totalTokens:V,cacheReadTokens:V.optional(),cacheCreationTokens:V.optional(),contextWindow:V,residentTokens:V,utilization:o.number().finite().min(0).max(1),costUsd:V.optional()}).strict(),"message-updated":o.object({message:gn}).strict(),"approval-context":o.object({approvalId:o.string(),toolCallId:o.string(),impact:J.optional(),relaxableByAuto:o.boolean().optional()}).strict()};function isAgentUIDataName(e){return e in Y}function agentUIValidationError(e){return new r(`Invalid agent UI message chunk`,e.map(e=>({path:e.path.map(String),message:e.message,code:e.code})))}function assertCustomAgentUIMessageChunk(e){if(typeof e!=`object`||!e||typeof e.type!=`string`)throw new r(`Invalid agent UI message chunk`,[{path:[`type`],message:`Expected UI message chunk type`,code:`invalid_type`}]);let t=e.type;if(!t.startsWith(`data-`))throw new r(`Invalid agent UI message chunk`,[{path:[`type`],message:`Expected agent data chunk type`,code:`invalid_value`}]);let n=t.slice(5);if(!isAgentUIDataName(n))throw new r(`Invalid agent UI message chunk`,[{path:[`type`],message:`Unknown agent UI data type: ${n}`,code:`invalid_value`}]);let i=o.object({type:o.literal(`data-${n}`),id:o.string().optional(),data:Y[n],transient:o.boolean().optional()}).strict().safeParse(e);if(!i.success)throw agentUIValidationError(i.error.issues);return i.data}function agentDataChunk(e,t,n){return assertCustomAgentUIMessageChunk({type:`data-${e}`,...n?.id===void 0?{}:{id:n.id},data:t,...n?.transient===void 0?{}:{transient:n.transient}})}const yn=o.string().trim().min(1).max(24),bn=o.string().trim().min(10).max(500),xn=o.enum([`address`,`domain`]),Sn=o.object({scope:o.enum([`personal`,`workspace`]),name:yn,description:bn,icon:ee.default(`tag`),color:a.default(L)}),Cn=o.object({name:yn.optional(),description:bn.optional(),icon:ee.optional(),color:a.optional()}).refine(e=>Object.values(e).some(e=>e!==void 0),{message:`Nothing to update`}),wn=o.object({moveTo:o.string().min(1).nullable().default(null)}),Tn=o.object({category:o.string().min(1).optional(),important:o.boolean().optional()}).refine(e=>e.category!==void 0||e.important!==void 0,{message:`Nothing to classify`}),En=o.object({verdict:o.object({category:o.string().min(1).nullable(),important:o.boolean(),classifiedBy:o.enum([`model`,`rule`,`manual`]).nullable()}),ruleId:o.string().uuid().nullable(),previousRule:o.object({scope:xn,match:o.string().trim().toLowerCase().min(1),category:o.string().min(1)}).nullable()}).refine(e=>e.ruleId!==null||e.previousRule===null,{message:`A previous rule needs the rule it restores`}),Dn=o.object({scope:o.literal(`domain`)}),On=o.object({scope:o.enum([`personal`,`workspace`])}),kn=o.object({type:o.enum(l),color:o.enum(te),expression:o.enum(u).default(`relaxed`)}).strict(),An=o.array(o.string().trim().min(1).max(200)).max(4);function agentAvatarFromMetadata(e){let t=kn.safeParse(e);return t.success?t.data:void 0}const jn=[`record.created`,`record.updated`,`record.deleted`,`form.submitted`,`webhook`,`github`,`slack`],Mn=new Set([`record.created`,`record.updated`,`record.deleted`]),Nn=/^[A-Z_][A-Z0-9_]*$/,Pn=o.object({cron:o.string().min(9),timezone:o.string().optional(),enabled:o.boolean(),input:o.record(o.string(),o.unknown()).optional(),runFor:o.enum([`armer`,`audience`]).optional(),continueConversation:o.boolean().optional()}),Fn=/^[A-Za-z0-9_$-]+(\.[A-Za-z0-9_$-]+)*$/,X=o.object({name:o.string().max(120).optional(),eventType:o.enum(jn),objectId:o.guid().optional(),watchedFields:o.array(o.string()).max(50).optional(),debounceMs:o.number().int().min(0).max(3e5).optional(),filter:o.object({combinator:o.enum([`and`,`or`]).default(`and`),rules:o.array(o.object({attribute:o.string(),operator:o.string(),value:o.unknown().optional()}))}).optional(),formDefinitionId:o.string().optional(),continuationKey:o.string().max(200).regex(Fn).nullable().optional(),connectionId:o.guid().optional(),match:It.optional(),continueConversation:o.boolean().optional(),enabled:o.boolean().optional()});function refineTrigger(e){return e.refine(e=>!e.watchedFields?.length||e.eventType===`record.updated`,{message:`watchedFields requires eventType=record.updated`,path:[`watchedFields`]}).refine(e=>!(e.eventType&&Mn.has(e.eventType))||!!e.objectId,{message:`objectId is required for record.* triggers`,path:[`objectId`]}).refine(e=>!(e.continuationKey&&e.eventType)||e.eventType===`webhook`,{message:`continuationKey requires eventType=webhook`,path:[`continuationKey`]}).superRefine((e,t)=>{let n=e.eventType===`github`||e.eventType===`slack`;if(n&&!e.connectionId&&t.addIssue({code:`custom`,path:[`connectionId`],message:`connectionId is required for native connector triggers`}),n&&!e.match&&t.addIssue({code:`custom`,path:[`match`],message:`match is required for native connector triggers`}),e.match&&e.eventType&&((e.eventType===`github`?`family`in e.match:e.eventType===`slack`&&`on`in e.match)||t.addIssue({code:`custom`,path:[`match`],message:`match must belong to the trigger provider`})),e.eventType&&!n)for(let n of[`connectionId`,`continueConversation`])e[n]!==void 0&&t.addIssue({code:`custom`,path:[n],message:`${n} requires a native connector trigger`})})}const In=refineTrigger(X).transform(e=>({...e,...e.eventType===`github`||e.eventType===`slack`?{continueConversation:e.continueConversation??!0}:{}})),Ln=X.partial();function parseMergedAgentTrigger(e,t){let n=Ln.safeParse(t);if(!n.success)throw triggerValidationError(n.error);let r=Object.fromEntries(Object.entries(n.data).filter(([,e])=>e!==void 0)),i=In.safeParse({...e,...r});if(!i.success)throw triggerValidationError(i.error);return i.data}function triggerValidationError(e){return new r(`Invalid agent trigger`,e.issues.map(e=>({path:e.path.map(String),message:e.message})))}const Rn=100,Z=o.uuid(),Q=o.record(o.string(),o.unknown()),zn=o.strictObject({objectName:o.string(),recordId:Z,attribute:o.string(),base:o.unknown(),props:Q.optional()}),Bn=o.strictObject({kind:o.literal(`record.set`),objectId:Z,recordId:Z,values:Q,base:Q.optional()}),Vn=o.strictObject({kind:o.literal(`record.create`),objectId:Z,recordId:Z,values:Q,options:o.strictObject({visibility:o.enum([`workspace`,`private`]).optional(),allowDraft:o.boolean().optional(),linkTo:zn.optional()}).optional()}),Hn=o.strictObject({kind:o.literal(`record.delete`),objectId:Z,recordId:Z}),Un=o.strictObject({kind:o.literal(`record.restore`),objectId:Z,recordId:Z}),$=o.string().min(1),Wn=o.discriminatedUnion(`command`,[o.strictObject({command:o.literal(`replace`),oldText:$,newText:o.string(),replaceAll:o.boolean().optional()}),o.strictObject({command:o.literal(`insert`),text:$,after:$.optional()})]),Gn=o.strictObject({kind:o.literal(`record.patch`),objectId:Z,recordId:Z,attribute:o.string(),edit:Wn}),Kn=o.discriminatedUnion(`kind`,[Bn,Vn,Hn,Un,Gn]),qn=o.strictObject({opId:Z,steps:o.array(Kn).min(1).max(100)}).superRefine((e,t)=>{let n=new Set;for(let r of e.steps){if(n.has(r.recordId)){t.addIssue({code:`custom`,message:`one step per record`,path:[`steps`]});return}n.add(r.recordId)}});export{Lt as ACCESS_LEVELS,Me as ACCESS_ROLES,ge as AGENT_ASIDE_ANSWER_MAX_LENGTH,me as AGENT_ASIDE_HISTORY_LIMIT,he as AGENT_ASIDE_QUESTION_MAX_LENGTH,u as AGENT_AVATAR_EXPRESSIONS,l as AGENT_AVATAR_TYPES,h as AGENT_MESSAGE_KIND,m as AGENT_NOTIFICATION_KIND,re as AGENT_SESSION_LIST_ORDERS,De as AGENT_SESSION_ORIGINS,fe as AGENT_STARTERS_MAX,pe as AGENT_STARTER_MAX_LENGTH,ce as AGENT_TASK_KINDS,_t as ALL_CATALOG_TOOL_NAMES,mt as ALWAYS_KINDS,Ge as APPROVAL_FAMILY_TOOL_NAMES,be as ARCHITECT_PUBLICATION_KIND,qe as ASK_QUESTIONS_ANSWER_MAX_LENGTH,Je as ASK_QUESTIONS_ANSWER_MAX_VALUES,Ke as ASK_QUESTIONS_MAX_BATCH,x as ASK_QUESTIONS_TOOL_NAME,Re as AUDIT_ACTIONS,ze as AUDIT_AGENT_SESSION_METADATA_KEY,Le as AUDIT_RESOURCE_TYPES,AgentBuilder,Ee as BROWSER_LAUNCH_TOOL_NAME,Fe as BUNDLE_LOCALES,vt as CONNECTION_GRANT_PROVIDERS,Fn as CONTINUATION_KEY_PATTERN,at as CONVERSATION_SURFACES,O as CORE_RECORD_TOOL_NAMES,k as CORE_TOOL_NAMES,y as COUNT_MODES,z as DEFAULT_AGENT_EXECUTION_CONFIG,yt as DEFAULT_AGENT_TOOL_GROUPS,s as DEFAULT_APPROVAL_POLICY,P as DEFAULT_BLUEPRINT_TOOL_GROUPS,ve as DEFAULT_DAILY_ACTIVITY_DAYS,et as DEFAULT_MEETING_BOT_DISPLAY_NAME,nt as DEFAULT_TENANT_SETTINGS,Ve as DISCARD_ARCHITECT_DRAFT_TOOL_NAME,Oe as DOCUMENT_SORT_MODES,Be as DRAFT_WRITE_TOOL_NAMES,L as EMAIL_CATEGORY_DEFAULT_COLOR,Tt as EMAIL_CATEGORY_DEFAULT_ICON,wt as EMAIL_CATEGORY_DESCRIPTION_MAX,Ct as EMAIL_CATEGORY_DESCRIPTION_MIN,xt as EMAIL_CATEGORY_LIMIT,St as EMAIL_CATEGORY_NAME_MAX,T as ENVIRONMENT_HARNESSES,pt as ENVIRONMENT_HARNESS_SANDBOX_WORKDIR,C as ENVIRONMENT_HARNESS_WORKDIR,dt as ENVIRONMENT_NAME_MAX_CHARS,w as ENVIRONMENT_STANDARDS_WORKDIR,Nn as ENV_VAR_KEY_PATTERN,Ie as ESTIMATED_COUNT_CAP,Qe as FILE_URLS_MAX_IDS,He as GET_ARCHITECT_DRAFT_TOOL_NAME,B as GITHUB_TRIGGER_CATALOG,ht as GRANT_ENABLES,Ue as HITL_TOOL_NAMES,se as INFERENCE_REASONING_OPTIONS,ue as INFERENCE_ROUTING_MODES,oe as INFERENCE_SPEEDS,_e as LAST_RUN_ERROR_MAX_LENGTH,$t as MAILBOX_LIST_MODES,tn as MAIL_DRAFT_BODY_MAX_CHARS,nn as MAIL_SIGNATURE_MAX_CHARS,rn as MAIL_SUBJECT_MAX_CHARS,ye as MAX_DAILY_ACTIVITY_DAYS,Ce as MAX_TODOS,Te as MAX_TODO_DESCRIPTION_CHARS,we as MAX_TODO_ID_CHARS,Yt as MCP_SERVER_NAME_MAX_LENGTH,Wt as MEETING_BOT_IMAGE,Gt as MEETING_BOT_IMAGE_BASE64_MAX_LENGTH,Rt as MEETING_RESPONSES,tt as MEMORY_SPEND_LIMIT_PATTERN,Xt as McpOAuthCompletionMode,g as NATIVE_TOOL_GROUPS,M as NATIVE_TOOL_GROUP_CATALOG,Vt as NO_RECORDING,f as OPEN_TOOL_PART_STATES,Rn as OPERATION_MAX_STEPS,Zt as PROVIDER_DRAFT_LABEL,ae as PROVIDER_NAMES,R as PUBLIC_MAIL_DOMAINS,We as QUESTION_FAMILY_TOOL_NAMES,Ze as RECENT_ACTIVITY_LEDGER_LIMIT,zt as RECORDING_OVERRIDES,Bt as RECORDING_POLICIES,v as RECORD_ACCESS_ROLES,Ne as RECORD_ACCESS_SOURCES,je as RECORD_DRIVE_CURSOR_MAX_LENGTH,ke as RECORD_DRIVE_PAGE_DEFAULT_LIMIT,Ae as RECORD_DRIVE_PAGE_MAX_LIMIT,ct as RECORD_GRAPH_DEFAULT_LIMIT_PER_NODE,st as RECORD_GRAPH_MAX_LIMIT_PER_NODE,ot as RECORD_GRAPH_MAX_NODES,$e as RECORD_IMAGE_MAX_BYTES,en as REPLY_MODES,b as REQUEST_DESIGN_REVIEW_TOOL_NAME,S as REQUEST_SETUP_TOOL_NAME,_ as RESOURCE_GRANT_KINDS,N as RESOURCE_KIND_CATALOG,de as ROUTING_PRICE_CEILINGS,c as SESSION_INFERENCE_PATCH_KEYS,ft as SETUP_SCRIPT_MAX_CHARS,Ot as SLACK_TRIGGER_CATALOG,gt as SURFACE_TOOL_NAMES,F as SYSTEM_EMAIL_CATEGORIES,I as SYSTEM_EMAIL_CATEGORY_NAMES,p as SYSTEM_PART_CODES,le as TASK_DEMAND_LEVELS,Se as TODO_PHASES,ie as TODO_PLAN_STATUSES,xe as TODO_STATUSES,d as TOOL_APPROVAL_STATES,Qt as TRIAGE_ACTIONS,jn as TRIGGER_EVENT_TYPES,ne as TURN_OUTCOMES,Pe as UNSHAREABLE_OBJECT_NAMES,rt as USER_STATUSES,it as USER_WORK_POSTURES,D as VERB_NAMES,agent,agentAvatarFromMetadata,kn as agentAvatarSchema,agentDataChunk,agentDisplayName,an as agentInferencePreferencesSchema,dn as agentMessageAttachmentSchema,un as agentMessagePartSchema,Pn as agentScheduleSchema,on as agentSessionInferenceOverridesInputSchema,sn as agentSessionInferenceOverridesSchema,gn as agentSessionMessageSchema,An as agentStartersSchema,X as agentTriggerBaseSchema,Ln as agentTriggerPatchSchema,In as agentTriggerSchema,agentUIValidationError,fn as artifactQuoteSchema,Xe as askQuestionsOutputSchema,assertCustomAgentUIMessageChunk,assertSessionState,canonicalToolGroups,En as classificationRestoreSchema,Tn as classifyEmailSchema,cliDefaultModelOf,compareAgentSessionMessages,compiledHarnessModels,connectionGrantKindsOf,It as connectorTriggerMatchSchema,Y as customDataChunkSchemas,deriveViewerAccess,hn as durableDateSchema,Sn as emailCategoryCreateSchema,wn as emailCategoryDeleteSchema,On as emailCategoryScopeQuerySchema,Cn as emailCategoryUpdateSchema,Dn as emailRuleScopeSchema,environmentHarness,environmentWorkdir,findEnvironmentHarness,At as githubConditionSchema,Pt as githubTriggerMatchSchema,grantKindOf,harnessModelChoices,humanRequestId,humanRequestKind,q as imageModelIdSchema,W as inferenceReasoningSchema,G as inferenceRoutingSchema,U as inferenceSpeedSchema,isAgentMessageMetadata,isAgentNotificationMetadata,isAgentUIDataName,isAgentWrittenAuditEntry,isArchitectPublicationMetadata,isAwaitingHuman,isBlocking,isEnvironmentHarnessId,isMailProvider,isMailboxListMode,isNativeToolGroup,isOpenToolPartState,isParkedOnHuman,isProviderDraft,isPublicMailDomain,isReplyMode,isResourceGrant,isRoutineActorMetadata,isSessionInferencePatch,isSystemEmailCategory,isSystemEmailCategoryName,isSystemPartCode,isToolApprovalState,Kt as meetingBotDispatchRequestSchema,qt as meetingBotDispatchResponseSchema,Jt as meetingBotNotificationSchema,Ht as meetingTranscriptSegmentSchema,pn as mentionReferenceSchema,mergeSessionInferencePatch,mn as modelDefinitionSchema,K as modelReferenceSchema,needsManageWhenUnattended,Ut as normalizedMeetingTranscriptSchema,openRequests,orderAgentSessionMessages,parseAgentDefinitionAccessRole,parseCountMode,parseMergedAgentTrigger,parseOptionalCountMode,parsePageAccessRole,parseRecordAccessRole,parseToolGroupGrant,H as providerNameSchema,readAskQuestionsResult,recentActivityEntryKey,recordGraphNodeKey,ut as recordGraphRequestSchema,qn as recordOperationSchema,refineTrigger,resourceGrant,ln as routedMessageInferenceSchema,cn as sessionInferencePatchSchema,jt as slackConditionSchema,Ft as slackTriggerMatchSchema,_n as todoItemSchema,vn as todoPlanSchema,J as toolImpactSchema};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! © 2025-2026 AND YOU CREATE SAS (RCS Paris 940 190 614). Proprietary — see LICENSE (Standards SDK License 1.0). */
|
|
2
|
+
const e=require("./rolldown-runtime-DETHMehu.js"),t=require("./exceptions.js");require("./zod-locale.js");const n=require("./primitives-BBtVhLdq.js");let r=require("zod");r=e.__toESM(r);let i=require("@standards/constants");const a=[`completed`,`failed`,`cancelled`];function invalidSessionState(e){throw new t.SchemaError(e,t.SchemaErrorCode.INVARIANT_VIOLATION)}function assertSessionState(e){e.phase===`running`?e.runningTurnId===void 0&&invalidSessionState(`running session without runningTurnId`):e.runningTurnId!==void 0&&invalidSessionState(`runningTurnId present on a ${e.phase} session`),e.phase===`parked`?e.parkedOn===void 0&&invalidSessionState(`parked session without parkedOn`):e.parkedOn!==void 0&&invalidSessionState(`parkedOn present on a ${e.phase} session`),e.parkedOn===`human`?e.humanRequestIds===void 0&&invalidSessionState(`human-parked session without humanRequestIds`):e.humanRequestIds!==void 0&&invalidSessionState(`humanRequestIds present on a session not parked on a human`)}const ee=[`createdAt`,`lastActivity`],o=Object.freeze({mutation:`ask`,destructive:`ask`,outward:`ask`}),te=[`active`,`completed`,`abandoned`],s=[`openai`,`anthropic`,`google`,`spacexai`,`deepseek`,`moonshotai`,`alibaba`,`mistral`,`minimax`,`meta`,`zai`,`cursor`],c=[`standard`,`fast`],ne=[`none`,`minimal`,`low`,`medium`,`high`,`xhigh`],re=[`conversation`,`writing`,`coding`,`analysis`,`extraction`],ie=[`light`,`standard`,`heavy`],ae=[`manual`,`auto`],oe={interactive:{inputPerMillionUsd:5,outputPerMillionUsd:25},delegated:{inputPerMillionUsd:2,outputPerMillionUsd:12}},l=[`model`,`speed`,`reasoning`,`imageModel`,`routing`];function mergeSessionInferencePatch(e,t){let n={...e};for(let e of l){let r=t[e];r===null?delete n[e]:r!==void 0&&Object.assign(n,{[e]:r})}return t.model&&t.routing===void 0&&(n.routing=`manual`),n}function isRoutineActorMetadata(e){return e?.kind===`routine`}const se=[`octopus`,`clover`,`flower`,`triangle`,`square`,`blob`,`circle`,`drop`,`hexagon`,`pill`,`pebble`,`puddle`],ce=[`relaxed`,`neutral`];function agentDisplayName(e){return e.label?.trim()||e.name}const u=[`approval-requested`,`approval-responded`,`approval-dispatched`],le=[`streaming`,`running`,`pending`,...u];function isOpenToolPartState(e){return le.includes(e)}function isToolApprovalState(e){return u.includes(e)}const d=[`CREDITS_EXHAUSTED`];function isSystemPartCode(e){return typeof e==`string`&&d.includes(e)}function compareAgentSessionMessages(e,t){let n=e.createdAt.getTime()-t.createdAt.getTime();return n===0?e.id.localeCompare(t.id):n}function orderAgentSessionMessages(e){return[...e].sort(compareAgentSessionMessages)}const f=`agent-notification`;function isAgentNotificationMetadata(e){return e?.kind===f}const ue=`agent-message`;function isAgentMessageMetadata(e){return e?.kind===ue}const p=`architect-publication`;function isArchitectPublicationMetadata(e){return e?.kind===p}const de=[`pending`,`in_progress`,`completed`,`blocked`],m=[`objects`,`fields`,`relations`,`views`,`samples`],h=[`sandbox`,`web`,`image`,`memory`,`bulk`,`activity`,`orchestration`,`host`,`cloud-browser`,`notifications`],g=[`mcp`,`email.read`,`email.send`,`calendar.read`,`github`,`slack.read`,`slack.write`,`device`,`browser`,`browser-profile`,`login`],fe=[`definition`,`default`,`child`,`inline`],pe=[`manual`,`name-asc`,`name-desc`,`date-desc`,`date-asc`],me=[`reader`,`runner`,`editor`],_=[`reader`,`editor`],he=[`manual`,`meeting_attendee`],ge=new Set([`memory`,`skill`]);function parseRole(e,n){if(typeof n==`string`&&e.includes(n))return n;let r=`role must be one of: ${e.join(`, `)}`;throw new t.ValidationError(r,[{path:[`role`],message:r}])}function parseRecordAccessRole(e){return parseRole(_,e)}function parseAgentDefinitionAccessRole(e){return parseRole(me,e)}function parsePageAccessRole(e){return parseRole(_,e)}function deriveViewerAccess(e,t){return e.visibility===`workspace`?`workspace`:e.ownedBy!==null&&t.includes(e.ownedBy)?`owner`:e.viewerGrant===`editor`?`editor`:e.viewerGrant===`runner`?`runner`:`reader`}const _e=[`fr`,`en`],v=[`none`,`estimated`,`exact`];function parseCountMode(e){if(typeof e==`string`&&v.includes(e))return e;throw new t.ValidationError(`countMode must be one of: ${v.join(`, `)} (received: ${String(e)})`,[])}function parseOptionalCountMode(e){return e===void 0?void 0:parseCountMode(e)}const ve=[`record`,`object`,`attribute`,`view`,`user`,`role`,`settings`,`file`,`agent`,`bundle`,`tenant_invitation`,`api_key`],ye=`record.created,record.updated,record.deleted,record.restored,record.purged,record.access_changed,agent.access_changed,object.created,object.updated,object.deleted,attribute.created,attribute.updated,attribute.deleted,view.created,view.updated,view.deleted,bundle.synced,bundle.removed,bundle.added,user.created,user.invited,user.updated,user.deleted,user.login,user.logout,tenant_invitation.created,tenant_invitation.delivery_failed,tenant_invitation.resent,tenant_invitation.revoked,tenant_invitation.accepted,role.created,role.updated,role.deleted,role.assigned,role.revoked,api_key.detached,settings.updated,file.uploaded,file.updated,file.deleted`.split(`,`);function isAgentWrittenAuditEntry(e){return e.actorType===`agent`||typeof e.metadata?.agentSessionId==`string`}const be=[`draft_schema`],y=`request_design_review`,b=`ask_questions`,x=`request_setup`,xe=new Set([b,y,x]),Se=new Set([b,x]),Ce=new Set([y]),we=r.union([r.object({value:r.string(),label:r.string()}).strict(),r.object({values:r.array(r.string()),labels:r.array(r.string()),text:r.string().optional()}).strict(),r.object({text:r.string()}).strict()]),Te=r.object({skipped:r.boolean().describe(`True if the person skipped all questions`),answers:r.record(r.string(),we).describe(`Map of question ID to the answer given, with each chosen option's value and label`)});function readAskQuestionsResult(e){let t=Te.safeParse(e);return t.success?t.data:null}function humanRequestKind(e){return e.approvalId==null?Se.has(e.name)?`question`:Ce.has(e.name)?`review`:null:`approval`}function isAwaitingHuman(e){return humanRequestKind(e)===null||e.state===`streaming`||!isOpenToolPartState(e.state)||e.result!==void 0||e.error!==void 0?!1:e.approvalId==null||e.state===`approval-requested`&&e.approved===void 0}function isBlocking(e){let t=humanRequestKind(e);return t===`review`?isOpenToolPartState(e.state):t===`approval`&&e.state===`approval-requested`&&e.approved===void 0}function humanRequestId(e){return e.approvalId??e.toolCallId}function openRequests(e,t){let n=t.blocking?isBlocking:isAwaitingHuman,r=[];for(let t of e)for(let e of t.parts??[])isToolRequestPart(e)&&n(e)&&r.push({part:e,id:humanRequestId(e),requestedAt:t.createdAt});return r}function isToolRequestPart(e){return e.type===`tool`}function isParkedOnHuman(e){return e?.phase===`parked`&&e.parkedOn===`human`}function recentActivityEntryKey(e){return e.kind===`record`?JSON.stringify([`record`,e.objectName,e.recordId]):JSON.stringify([`conversation`,`sessionId`in e?e.sessionId:e.session.id])}const Ee=`Notetaker`,De=/^\d{1,9}(\.\d{1,6})?$/,Oe={meetingRecordingPolicy:`none`,meetingBotDisplayName:Ee,memoryPersonMonthlyLimitUsd:null,memoryTenantMonthlyLimitUsd:null,findImages:!0},ke=[`active`,`suspended`],Ae=[`architect`,`manual`,`auto`],je=[`panel`,`fullscreen`],Me=r.discriminatedUnion(`type`,[r.strictObject({type:r.literal(`record`),object:r.string().min(1),id:r.guid()}),r.strictObject({type:r.literal(`user`),id:r.guid()})]),Ne=r.strictObject({nodes:r.array(Me).min(1).max(50),limitPerNode:r.number().int().min(1).max(200).default(50)});function recordGraphNodeKey(e){return e.type===`record`?`record:${e.object}:${e.id}`:`user:${e.id}`}const Pe=`work`,Fe=`/vercel/sandbox/${Pe}`,Ie=`/workspace`;function environmentWorkdir(e){return e?Fe:Ie}const S=[{id:`claude-code`,label:`Claude Code`,provider:`anthropic`,apiKeyEnv:`ANTHROPIC_API_KEY`,models:[{id:`sonnet`,label:`Claude Sonnet`},{id:`opus`,label:`Claude Opus`},{id:`haiku`,label:`Claude Haiku`}],defaultModel:`sonnet`},{id:`codex`,label:`Codex`,provider:`openai`,apiKeyEnv:`OPENAI_API_KEY`,models:[{id:`gpt-6.1-sol`,label:`GPT-6.1 Sol`},{id:`gpt-6-luna`,label:`GPT-6 Luna`},{id:`gpt-6-astra`,label:`GPT-6 Astra`}],defaultModel:`gpt-6.1-sol`},{id:`cursor`,label:`Cursor`,provider:`cursor`,apiKeyEnv:`CURSOR_API_KEY`,models:[{id:`auto`,label:`Auto`,cliDefault:!0},{id:`composer-2.5`,label:`Composer 2.5`}],defaultModel:`auto`}],C=new Map(S.map(e=>[e.id,e]));function isEnvironmentHarnessId(e){return C.has(e)}function findEnvironmentHarness(e){return C.get(e)}function environmentHarness(e){let n=C.get(e);if(!n)throw new t.SchemaError(`Unknown harness "${e}"`,t.SchemaErrorCode.INVARIANT_VIOLATION);return n}function cliDefaultModelOf(e){return environmentHarness(e).models.find(e=>e.cliDefault)?.id}function compiledHarnessModels(e){let t=environmentHarness(e);return t.models.map(e=>({id:e.id,label:e.label,...e.id===t.defaultModel?{isDefault:!0}:{}}))}function harnessModelChoices(e,t){let{provider:n}=environmentHarness(e);return t.map(e=>({id:e.id,provider:n,label:e.label,...e.isDefault?{isDefault:!0}:{}}))}const w=[`search`,`query`,`read`,`write`,`delete`,`organize`,`copy`,`send`],T=[...w,`edit_content`],E=[...T,`ask_questions`,`compact_context`,`request_work_mode`,`write_todos`],D=[`browser_autopilot`,`browser_batch`,`browser_computer`,`browser_find`,`browser_form_input`,`browser_get_text`,`browser_javascript`,`browser_navigate`,`browser_read_page`,`browser_sign_in`,`browser_tabs`],Le=[`record`,`document`,`file`,`skill`,`schema`,`guide`],O={memory:{kinds:[`memory`],capabilities:[],tools:[`propose_memory`]},bulk:{kinds:[],capabilities:[`bulk`],tools:[]},activity:{kinds:[],capabilities:[`activity`],tools:[]},"email.read":{kinds:[`email`,`thread`],capabilities:[`copy_email`],tools:[]},"email.send":{kinds:[`email`,`thread`,`draft`],capabilities:[`copy_email`],tools:[]},"calendar.read":{kinds:[`event`],capabilities:[`transcript`],tools:[]}},k={sandbox:{icon:`terminal`,tools:[`exec_command`,`publish_artifact`,`sandbox_validate_payload`]},web:{icon:`globe`,tools:[`read_webpage`,`web_search`]},image:{icon:`image`,tools:[`generate_image`]},memory:{icon:`book-open`,tools:O.memory.tools},bulk:{icon:`layers-two`,tools:O.bulk.tools},activity:{icon:`activity`,tools:O.activity.tools},orchestration:{icon:`git-branch`,tools:[`message_agent`,`spawn_agent`]},host:{icon:`wrench`,tools:[]},"cloud-browser":{icon:`globe`,tools:[`browser_launch`]},notifications:{icon:`bell`,tools:[`notify`]}},A={mcp:{icon:`puzzle`,tools:[]},"email.read":{icon:`envelope`,tools:O[`email.read`].tools},"email.send":{icon:`send`,tools:O[`email.send`].tools},"calendar.read":{icon:`calendar`,tools:O[`calendar.read`].tools},github:{icon:`brand-github`,tools:[]},"slack.read":{icon:`brand-slack`,tools:[`slack_read`,`slack_find`,`slack_download_file`]},"slack.write":{icon:`brand-slack`,tools:[`slack_send`,`slack_react`,`slack_set_status`]},device:{icon:`desktop`,tools:[`exec_command`]},browser:{icon:`link`,tools:D},"browser-profile":{icon:`globe`,tools:[`browser_launch`,...D]},login:{icon:`key`,tools:[]}},Re={sandbox:{kinds:[],capabilities:[],tools:k.sandbox.tools},web:{kinds:[],capabilities:[],tools:k.web.tools},image:{kinds:[],capabilities:[],tools:k.image.tools},memory:O.memory,bulk:O.bulk,activity:O.activity,orchestration:{kinds:[],capabilities:[],tools:k.orchestration.tools},host:{kinds:[],capabilities:[],tools:k.host.tools},"cloud-browser":{kinds:[],capabilities:[],tools:k[`cloud-browser`].tools},notifications:{kinds:[],capabilities:[],tools:k.notifications.tools},mcp:{kinds:[],capabilities:[],tools:A.mcp.tools},"email.read":O[`email.read`],"email.send":O[`email.send`],"calendar.read":O[`calendar.read`],github:{kinds:[],capabilities:[],tools:A.github.tools},"slack.read":{kinds:[],capabilities:[],tools:A[`slack.read`].tools},"slack.write":{kinds:[],capabilities:[],tools:A[`slack.write`].tools},device:{kinds:[],capabilities:[],tools:A.device.tools},browser:{kinds:[],capabilities:[],tools:A.browser.tools},"browser-profile":{kinds:[],capabilities:[],tools:A[`browser-profile`].tools},login:{kinds:[],capabilities:[],tools:A.login.tools}},ze={schema:[`discard_architect_draft`,`draft_schema`,`get_architect_draft`,`get_schema_history`,`request_design_review`,`search_icons`],"agent-config":[`get_agents`,`upsert_agent`],setup:[`request_setup`],internal:[`load_toolset`]},Be=[...new Set([...E,...h.flatMap(e=>k[e].tools),...g.flatMap(e=>A[e].tools)])],Ve={"email.read":[`gmail`,`outlook`],"email.send":[`gmail`,`outlook`],"calendar.read":[`google-calendar`,`outlook-calendar`]};function connectionGrantKindsOf(e){switch(e){case`github`:return[`github`];case`slack`:return[`slack.read`,`slack.write`];case`google-calendar`:case`outlook-calendar`:return[`calendar.read`];case`gmail`:case`outlook`:return[`email.read`,`email.send`]}}const He=[`activity`,`bulk`,`image`,`memory`,`orchestration`,`sandbox`,`web`],j=[`memory`],Ue=new Set([`sandbox`,`host`,`cloud-browser`]);function needsManageWhenUnattended(e){return Ue.has(e)||isResourceGrant(e)}function isNativeToolGroup(e){return h.includes(e)}function parseToolGroupGrant(e){if(isNativeToolGroup(e))return{type:`native`,group:e};let t=e.indexOf(`:`);if(t<=0)return null;let n=e.slice(0,t),r=e.slice(t+1);return r.length===0||!g.includes(n)?null:{type:`resource`,kind:n,id:r}}function grantKindOf(e){let t=parseToolGroupGrant(e);return t?.type===`resource`?t.kind:null}function isResourceGrant(e){return parseToolGroupGrant(e)?.type===`resource`}function resourceGrant(e,t){return`${e}:${t}`}function canonicalToolGroups(e){return[...new Set(e)].sort()}const M=[{key:`direct`,icon:`message`,color:`ink`,description:`A message a person wrote to this mailbox: a conversation, a question, a request, a reply.`},{key:`transactional`,icon:`credit-card`,color:`terra`,description:`An automated message about an account or an operation: receipt, invoice, payment, order, shipping, booking, password reset, security alert.`},{key:`notifications`,icon:`bell`,color:`ochre`,description:`An automated alert from a tool or a service: activity on GitHub, Slack, a calendar, a CRM, a monitoring system.`},{key:`newsletters`,icon:`book-open`,color:`stone`,description:`Editorial content the mailbox subscribed to: newsletters, digests, articles, community updates.`},{key:`marketing`,icon:`percentage`,color:`iris`,description:`Promotion or prospecting: offers, discounts, product announcements, cold sales outreach.`}],N={direct:{en:`Direct`,fr:`Direct`},transactional:{en:`Transactional`,fr:`Transactionnel`},notifications:{en:`Notifications`,fr:`Notifications`},newsletters:{en:`Newsletters`,fr:`Newsletters`},marketing:{en:`Marketing`,fr:`Marketing`}},P=`stone`,F=new Set(`gmail.com,googlemail.com,outlook.com,hotmail.com,hotmail.fr,outlook.fr,live.com,live.fr,msn.com,yahoo.com,yahoo.fr,icloud.com,me.com,mac.com,proton.me,protonmail.com,gmx.com,gmx.fr,orange.fr,wanadoo.fr,free.fr,laposte.net,sfr.fr,bbox.fr,numericable.fr,aol.com`.split(`,`)),We=new Set(M.map(e=>e.key)),Ge=new Set(Object.entries(N).flatMap(([e,t])=>[e,t.en,t.fr].map(e=>e.toLowerCase())));function isSystemEmailCategory(e){return We.has(e)}function isSystemEmailCategoryName(e){return Ge.has(e.trim().toLowerCase())}function isPublicMailDomain(e){return F.has(e.toLowerCase())}const I={maxConcurrentRuns:3,retryPolicy:{maxRetries:3,backoffMs:1e3,backoffMultiplier:2}};var AgentBuilder=class{constructor(e){if(!e.name||e.name.trim().length===0)throw new t.ValidationError(`Agent name is required`,[]);this.bp={name:e.name,system:!0,visibility:`workspace`,triggers:[]}}description(e){return this.bp.description=e,this}label(e){return this.bp.label=e,this}avatar(e){return this.bp.avatar={type:e.type,color:e.color,expression:e.expression??`relaxed`},this}starters(e){return e.length===0?delete this.bp.starters:this.bp.starters=[...e],this}systemPrompt(e){return this.bp.systemPrompt=e,this}model(e,t,n){return this.bp.model={provider:e,model:t,...n},this}toolGroups(e){let n=e.find(e=>!isNativeToolGroup(e));if(n!==void 0)throw new t.ToolGroupGrantError(t.SchemaErrorCode.AGENT_TOOL_GROUP_UNKNOWN,n,`Agent "${this.bp.name}": "${n}" is not a native tool group (blueprints cannot grant tenant resources)`);return this.bp.toolGroups=canonicalToolGroups(e),this}schedule(e){return this.bp.schedule={...e,enabled:e.enabled??!0},this}config(e){let t=this.bp.config??I,n=e.inference===void 0?t.inference:{...t.inference,...e.inference};return this.bp.config={...t,...e,...n===void 0?{}:{inference:n}},this}delegation(e){return Object.assign(this.bp,e),this}approval(e){return this.bp.approval={...o,...this.bp.approval,...e},this}visibility(e){return this.bp.visibility=e,this}trigger(e,t,n){return this.bp.triggers.push({name:e,eventType:t,...n,enabled:n?.enabled??!0}),this}runtime(){return this.bp.system=!1,this}build(){if(!this.bp.systemPrompt)throw new t.ValidationError(`Agent "${this.bp.name}": systemPrompt is required`,[]);if(!this.bp.model)throw new t.ValidationError(`Agent "${this.bp.name}": model is required`,[]);if(this.bp.system&&this.bp.visibility===`private`)throw new t.ValidationError(`Agent "${this.bp.name}": system agents must use workspace visibility`,[]);return n.assertUniqueBy(this.bp.triggers,e=>e.name,e=>new t.ValidationError(`Agent "${this.bp.name}": duplicate trigger name "${e}"`,[])),{...this.bp,visibility:this.bp.visibility??`workspace`,toolGroups:this.bp.toolGroups??[...j],config:this.bp.config??I,systemPrompt:this.bp.systemPrompt,model:this.bp.model}}};function agent(e){return new AgentBuilder(e)}const L={issue:{events:[`issues`],actions:[`opened`,`edited`,`closed`,`reopened`,`labeled`,`unlabeled`,`assigned`,`unassigned`,`milestoned`,`demilestoned`,`transferred`,`pinned`],conditions:[`label`,`issueLabels`,`assignees`,`milestone`,`issueType`,`text`]},pull_request:{events:[`pull_request`],actions:[`opened`,`ready_for_review`,`synchronize`,`review_requested`,`merged`,`closed`,`reopened`,`converted_to_draft`,`labeled`,`assigned`,`edited`],conditions:[`baseBranch`,`headBranch`,`draft`,`issueLabels`,`changedPaths`,`prAuthor`]},review:{events:[`pull_request_review`],actions:[`submitted`,`edited`,`dismissed`],conditions:[`reviewState`,`prAuthor`]},comment:{events:[`issue_comment`,`pull_request_review_comment`,`commit_comment`],actions:[`created`,`edited`,`deleted`],conditions:[`text`,`issueAuthor`,`prAuthor`]},push:{events:[`push`],actions:[`pushed`],conditions:[`branch`,`changedPaths`,`forced`]},ref:{events:[`create`,`delete`],actions:[`created`,`deleted`],conditions:[`refType`,`branch`,`tag`]},workflow:{events:[`workflow_run`],actions:[`requested`,`in_progress`,`completed`],conditions:[`workflowName`,`conclusion`,`branch`,`originEvent`]},check:{events:[`check_suite`,`check_run`],actions:[`completed`,`rerequested`],conditions:[`checkApp`,`checkName`,`conclusion`]},project_item:{events:[`projects_v2_item`],actions:[`created`,`edited`,`archived`,`restored`,`deleted`],conditions:[`project`,`projectField`,`from`,`to`,`itemType`]},release:{events:[`release`],actions:[`published`,`created`,`edited`,`prereleased`,`deleted`],conditions:[`prerelease`,`tag`]},discussion:{events:[`discussion`,`discussion_comment`],actions:[`created`,`commented`,`answered`,`labeled`,`closed`],conditions:[`category`,`issueLabels`,`text`]},repository:{events:[`star`,`fork`,`repository`],actions:[`starred`,`forked`,`created`,`archived`],conditions:[]}},R={mention:{events:[`app_mention`],conditions:[`text`]},message:{events:[`message`],conditions:[`position`,`text`,`hasFile`]},dm:{events:[`message`],conditions:[`text`,`hasFile`]},reaction:{events:[`reaction_added`],conditions:[`messageAuthor`]},member_joined:{events:[`member_joined_channel`],conditions:[]}},z=r.object({field:r.literal(`text`),operator:r.enum([`contains`,`starts_with`]),value:r.string().min(1)}).strict();function stringCondition(e){return r.object({field:r.literal(e),value:r.string().min(1)}).strict()}function booleanCondition(e){return r.object({field:r.literal(e),value:r.boolean()}).strict()}function listCondition(e){return r.object({field:r.literal(e),operator:r.enum([`any`,`all`]).default(`any`),value:r.array(r.string().min(1)).min(1)}).strict()}const Ke=r.discriminatedUnion(`field`,[z,stringCondition(`label`),listCondition(`issueLabels`),listCondition(`assignees`),stringCondition(`milestone`),stringCondition(`issueType`),stringCondition(`baseBranch`),stringCondition(`headBranch`),stringCondition(`branch`),booleanCondition(`draft`),stringCondition(`changedPaths`),booleanCondition(`forced`),stringCondition(`prAuthor`),stringCondition(`issueAuthor`),r.object({field:r.literal(`reviewState`),value:r.enum([`approved`,`changes_requested`,`commented`])}).strict(),stringCondition(`workflowName`),stringCondition(`checkApp`),stringCondition(`checkName`),stringCondition(`conclusion`),stringCondition(`originEvent`),stringCondition(`project`),stringCondition(`projectField`),r.object({field:r.literal(`from`),value:r.string().nullable()}).strict(),r.object({field:r.literal(`to`),value:r.string().nullable()}).strict(),r.object({field:r.literal(`itemType`),value:r.enum([`issue`,`pull_request`,`draft`])}).strict(),booleanCondition(`prerelease`),stringCondition(`tag`),r.object({field:r.literal(`refType`),value:r.enum([`branch`,`tag`])}).strict(),stringCondition(`category`)]),qe=r.discriminatedUnion(`field`,[z,r.object({field:r.literal(`position`),value:r.enum([`top_level`,`reply`])}).strict(),booleanCondition(`hasFile`),stringCondition(`messageAuthor`)]),Je=r.string().regex(/^[A-Za-z0-9_.-]+\/[A-Za-z0-9_.-]+$/),Ye=r.enum([`human`,`me`,`any`]),Xe=r.object({family:r.enum(Object.keys(L)),actions:r.array(r.string()).default([]),repositories:r.array(Je).default([]),sender:r.union([Ye,r.object({logins:r.array(r.string().min(1)).min(1)}).strict()]).default(`human`),conditions:r.array(Ke).default([])}).strict().superRefine((e,t)=>{let n=L[e.family];e.actions.forEach((r,i)=>{n.actions.includes(r)||t.addIssue({code:`custom`,path:[`actions`,i],message:`Action ${r} is not supported by ${e.family}`})}),e.conditions.forEach((r,i)=>{n.conditions.includes(r.field)||t.addIssue({code:`custom`,path:[`conditions`,i,`field`],message:`Condition ${r.field} is not supported by ${e.family}`})})}).transform(e=>e),Ze=r.object({on:r.enum([`mention`,`message`,`dm`,`reaction`,`member_joined`]),channels:r.array(r.string().min(1)).default([]),reactions:r.array(r.string().min(1)).optional(),sender:r.union([Ye,r.object({users:r.array(r.string().min(1)).min(1)}).strict()]).default(`human`),conditions:r.array(qe).default([])}).strict().superRefine((e,t)=>{e.conditions.forEach((n,r)=>{R[e.on].conditions.includes(n.field)||t.addIssue({code:`custom`,path:[`conditions`,r,`field`],message:`Condition ${n.field} is not supported by ${e.on}`})}),e.reactions!==void 0&&e.on!==`reaction`&&t.addIssue({code:`custom`,path:[`reactions`],message:`reactions requires on=reaction`})}).transform(e=>e),B=r.union([Xe,Ze]),Qe=[`read`,`write`,`full`],$e=[`accepted`,`declined`,`tentative`],et=[`force`,`skip`],tt=[`none`,`all`,`external_only`],nt={override:null,status:`none`,failureReason:null,botId:null},rt=r.object({speaker:r.string().nullable(),startsAtMs:r.number(),endsAtMs:r.number(),text:r.string()}),it=r.object({fullText:r.string(),segments:r.array(rt),language:r.string().nullable(),startedAt:r.string().nullable(),endedAt:r.string().nullable()}),at={width:1280,height:720,maxBytes:13e5,mimeType:`image/jpeg`},ot=Math.ceil(at.maxBytes/3)*4,st=r.object({conferenceJoinUrl:r.string().min(1),botDisplayName:r.string().min(1),startsAt:r.string().nullable(),callbackUrl:r.url(),botImageJpeg:r.string().max(ot).optional()}),ct=r.object({botId:r.string().min(1)}),lt=r.discriminatedUnion(`kind`,[r.object({kind:r.literal(`transcript-ready`),botId:r.string().min(1)}),r.object({kind:r.literal(`failure`),botId:r.string().min(1),reason:r.string()})]);let ut=function(e){return e.Desktop=`desktop`,e}({});function isMailProvider(e){return e===`gmail`||e===`outlook`}const dt=`DRAFT`;function isProviderDraft(e){return e.includes(dt)}const ft=[`read`,`unread`,`archive`,`trash`,`restore`],pt=[`threads`,`messages`];function isMailboxListMode(e){return pt.includes(e)}const mt=[`reply`,`reply_all`];function isReplyMode(e){return mt.includes(e)}const V=r.number().finite().nonnegative(),H=r.enum(s),U=r.enum(c),W=r.enum(ne),G=r.enum(ae),K=r.object({provider:H,model:r.string().min(1)}).strict(),ht=r.object({speed:U.optional(),reasoning:W.optional(),routing:G.optional()}).strict(),q=r.string().regex(/^[a-z0-9][a-z0-9-]*\/[a-z0-9][a-z0-9._-]*$/),gt=r.object({model:K.optional(),speed:U.optional(),reasoning:W.optional(),imageModel:q.optional(),routing:G.optional()}).strict(),_t=gt.refine(e=>l.some(t=>e[t]!==void 0),{message:`At least one inference override is required`});function isSessionInferencePatch(e){return Object.keys(e).length>0&&Object.values(e).every(e=>e!==void 0)}const vt=r.object({model:K.nullable().optional(),speed:U.nullable().optional(),reasoning:W.nullable().optional(),imageModel:q.nullable().optional(),routing:G.nullable().optional()}).strict().refine(isSessionInferencePatch,{message:`At least one inference override is required`}),yt=r.object({model:r.string().min(1),routing:r.object({mode:r.literal(`auto`),tasks:r.array(r.enum(re)).optional(),demand:r.enum(ie).optional(),reason:r.enum([`selected`,`retained`,`fallback`]).optional(),relation:r.enum([`continue`,`modify`,`new`,`aside`,`unknown`]).optional(),anchorMessageId:r.string().min(1).optional()})}),J=r.object({label:r.string(),denied:r.boolean().optional(),deletion:r.object({target:r.string().optional(),count:V.optional(),restorableDays:V.optional()}).strict().optional(),record:r.object({objectName:r.string(),id:r.string(),label:r.string(),objectIcon:r.string().optional()}).strict().optional(),object:r.object({name:r.string(),label:r.string()}).strict().optional(),email:r.object({from:r.string(),to:r.array(r.string()),cc:r.array(r.string()),bcc:r.array(r.string()),subject:r.string().nullable(),text:r.string(),truncatedChars:V,outsideThread:r.array(r.string()),attachments:r.array(r.object({name:r.string(),size:V}).strict()),updatedAt:r.string(),forwarded:r.object({from:r.string(),subject:r.string().nullable(),quote:r.string(),quoteTruncatedChars:V}).strict().optional()}).strict().optional(),counts:r.record(r.string(),V).optional(),warnings:r.array(r.string()).optional()}).strict(),bt=r.union([r.object({type:r.literal(`text`),text:r.string()}).strict(),r.object({type:r.literal(`reasoning`),text:r.string()}).strict(),r.object({type:r.literal(`system`),code:r.enum(d)}).strict(),r.object({type:r.literal(`error`),error:r.string(),errorClass:r.string().optional()}).strict(),r.object({type:r.literal(`tool`),toolCallId:r.string(),name:r.string(),args:r.record(r.string(),r.unknown()),result:r.unknown().optional(),error:r.string().optional(),errorCode:r.enum([`output_limit_reached`,`interrupted`,t.SchemaErrorCode.INVALID_TOOL_INPUT,`external_outcome_unknown`,`external_not_dispatched`]).optional(),state:r.enum([`streaming`,`running`,`completed`,`error`,`pending`,`approval-requested`,`approval-responded`,`approval-dispatched`]),durationMs:V.optional(),approvalId:r.string().optional(),approvalImpact:J.optional(),approved:r.boolean().optional(),approvalReason:r.string().optional(),approvalDecidedBy:r.string().optional(),approvalDecidedAt:r.string().optional(),approvalRelaxableByAuto:r.boolean().optional()}).strict(),r.object({type:r.literal(`file`),fileId:r.string(),name:r.string(),mimeType:r.string()}).strict(),r.object({type:r.literal(`compaction`),state:r.literal(`in-progress`),reason:r.enum([`preflight_threshold`,`overflow_recovery`]),estimatedTokens:V.optional(),reportedTokens:V.optional()}).strict(),r.object({type:r.literal(`compaction`),state:r.literal(`completed`),tokensBefore:V,tokensAfter:V,tokensSaved:V,strategy:r.enum([`no-op`,`summary`,`truncation`]),durationMs:V,summary:r.string().optional()}).strict(),r.object({type:r.literal(`compaction`),state:r.literal(`failed`),reason:r.string(),durationMs:V.optional()}).strict()]),xt=r.object({id:r.string(),name:r.string(),mimeType:r.string(),size:V}).strict(),St=r.object({id:r.string(),artifactId:r.string(),revision:r.number().int().min(1),selectedText:r.string()}).strict(),Ct=r.object({id:r.string(),type:r.string().transform(e=>e),entityId:r.string(),label:r.string(),objectName:r.string().optional(),startIndex:V,endIndex:V}).strict(),wt=r.object({provider:H,model:r.string(),maxTokens:V.optional(),contextWindow:V.optional()}).strict(),Tt=r.union([r.date(),r.string().datetime({offset:!0}).transform(e=>new Date(e))]),Et=r.object({id:r.string(),sessionId:r.string(),tenantId:r.string().optional(),runId:r.string().optional(),role:r.enum([`user`,`assistant`,`system`,`tool`]),parts:r.array(bt),attachments:r.array(xt).optional(),mentions:r.array(Ct).optional(),quotes:r.array(St).optional(),model:wt.optional(),tokenUsage:r.object({input:V,output:V}).strict().optional(),metadata:r.record(r.string(),r.unknown()).optional(),createdAt:Tt}).strict(),Dt=r.object({id:r.string(),description:r.string(),status:r.enum([`pending`,`in_progress`,`completed`,`blocked`]),result:r.string().optional(),updatedAt:V.optional(),target:r.object({phase:r.enum(m)}).strict().optional()}).strict(),Ot=r.object({id:r.string(),sessionId:r.string(),status:r.enum([`active`,`completed`,`abandoned`]),todos:r.array(Dt),version:V,createdAt:r.string(),updatedAt:r.string(),completedAt:r.string().optional()}).strict(),Y={"compaction-start":r.object({reason:r.enum([`preflight_threshold`,`overflow_recovery`]),estimatedTokens:V.optional(),reportedTokens:V.optional()}).strict(),"compaction-end":r.object({tokensBefore:V,tokensAfter:V,tokensSaved:V,strategy:r.enum([`no-op`,`summary`,`truncation`]),durationMs:V,summary:r.string().optional()}).strict(),"compaction-failed":r.object({reason:r.string()}).strict(),usage:r.object({messageId:r.string().min(1).optional(),inputTokens:V,outputTokens:V,totalTokens:V,cacheReadTokens:V.optional(),cacheCreationTokens:V.optional(),contextWindow:V,residentTokens:V,utilization:r.number().finite().min(0).max(1),costUsd:V.optional()}).strict(),"message-updated":r.object({message:Et}).strict(),"approval-context":r.object({approvalId:r.string(),toolCallId:r.string(),impact:J.optional(),relaxableByAuto:r.boolean().optional()}).strict()};function isAgentUIDataName(e){return e in Y}function agentUIValidationError(e){return new t.ValidationError(`Invalid agent UI message chunk`,e.map(e=>({path:e.path.map(String),message:e.message,code:e.code})))}function assertCustomAgentUIMessageChunk(e){if(typeof e!=`object`||!e||typeof e.type!=`string`)throw new t.ValidationError(`Invalid agent UI message chunk`,[{path:[`type`],message:`Expected UI message chunk type`,code:`invalid_type`}]);let n=e.type;if(!n.startsWith(`data-`))throw new t.ValidationError(`Invalid agent UI message chunk`,[{path:[`type`],message:`Expected agent data chunk type`,code:`invalid_value`}]);let i=n.slice(5);if(!isAgentUIDataName(i))throw new t.ValidationError(`Invalid agent UI message chunk`,[{path:[`type`],message:`Unknown agent UI data type: ${i}`,code:`invalid_value`}]);let a=r.object({type:r.literal(`data-${i}`),id:r.string().optional(),data:Y[i],transient:r.boolean().optional()}).strict().safeParse(e);if(!a.success)throw agentUIValidationError(a.error.issues);return a.data}function agentDataChunk(e,t,n){return assertCustomAgentUIMessageChunk({type:`data-${e}`,...n?.id===void 0?{}:{id:n.id},data:t,...n?.transient===void 0?{}:{transient:n.transient}})}const kt=r.string().trim().min(1).max(24),At=r.string().trim().min(10).max(500),jt=r.enum([`address`,`domain`]),Mt=r.object({scope:r.enum([`personal`,`workspace`]),name:kt,description:At,icon:n.iconNameSchema.default(`tag`),color:n.colorIdSchema.default(P)}),Nt=r.object({name:kt.optional(),description:At.optional(),icon:n.iconNameSchema.optional(),color:n.colorIdSchema.optional()}).refine(e=>Object.values(e).some(e=>e!==void 0),{message:`Nothing to update`}),Pt=r.object({moveTo:r.string().min(1).nullable().default(null)}),Ft=r.object({category:r.string().min(1).optional(),important:r.boolean().optional()}).refine(e=>e.category!==void 0||e.important!==void 0,{message:`Nothing to classify`}),It=r.object({verdict:r.object({category:r.string().min(1).nullable(),important:r.boolean(),classifiedBy:r.enum([`model`,`rule`,`manual`]).nullable()}),ruleId:r.string().uuid().nullable(),previousRule:r.object({scope:jt,match:r.string().trim().toLowerCase().min(1),category:r.string().min(1)}).nullable()}).refine(e=>e.ruleId!==null||e.previousRule===null,{message:`A previous rule needs the rule it restores`}),Lt=r.object({scope:r.literal(`domain`)}),Rt=r.object({scope:r.enum([`personal`,`workspace`])}),zt=r.object({type:r.enum(se),color:r.enum(i.AVATAR_COLOR_IDS),expression:r.enum(ce).default(`relaxed`)}).strict(),Bt=r.array(r.string().trim().min(1).max(200)).max(4);function agentAvatarFromMetadata(e){let t=zt.safeParse(e);return t.success?t.data:void 0}const Vt=[`record.created`,`record.updated`,`record.deleted`,`form.submitted`,`webhook`,`github`,`slack`],Ht=new Set([`record.created`,`record.updated`,`record.deleted`]),Ut=/^[A-Z_][A-Z0-9_]*$/,Wt=r.object({cron:r.string().min(9),timezone:r.string().optional(),enabled:r.boolean(),input:r.record(r.string(),r.unknown()).optional(),runFor:r.enum([`armer`,`audience`]).optional(),continueConversation:r.boolean().optional()}),Gt=/^[A-Za-z0-9_$-]+(\.[A-Za-z0-9_$-]+)*$/,X=r.object({name:r.string().max(120).optional(),eventType:r.enum(Vt),objectId:r.guid().optional(),watchedFields:r.array(r.string()).max(50).optional(),debounceMs:r.number().int().min(0).max(3e5).optional(),filter:r.object({combinator:r.enum([`and`,`or`]).default(`and`),rules:r.array(r.object({attribute:r.string(),operator:r.string(),value:r.unknown().optional()}))}).optional(),formDefinitionId:r.string().optional(),continuationKey:r.string().max(200).regex(Gt).nullable().optional(),connectionId:r.guid().optional(),match:B.optional(),continueConversation:r.boolean().optional(),enabled:r.boolean().optional()});function refineTrigger(e){return e.refine(e=>!e.watchedFields?.length||e.eventType===`record.updated`,{message:`watchedFields requires eventType=record.updated`,path:[`watchedFields`]}).refine(e=>!(e.eventType&&Ht.has(e.eventType))||!!e.objectId,{message:`objectId is required for record.* triggers`,path:[`objectId`]}).refine(e=>!(e.continuationKey&&e.eventType)||e.eventType===`webhook`,{message:`continuationKey requires eventType=webhook`,path:[`continuationKey`]}).superRefine((e,t)=>{let n=e.eventType===`github`||e.eventType===`slack`;if(n&&!e.connectionId&&t.addIssue({code:`custom`,path:[`connectionId`],message:`connectionId is required for native connector triggers`}),n&&!e.match&&t.addIssue({code:`custom`,path:[`match`],message:`match is required for native connector triggers`}),e.match&&e.eventType&&((e.eventType===`github`?`family`in e.match:e.eventType===`slack`&&`on`in e.match)||t.addIssue({code:`custom`,path:[`match`],message:`match must belong to the trigger provider`})),e.eventType&&!n)for(let n of[`connectionId`,`continueConversation`])e[n]!==void 0&&t.addIssue({code:`custom`,path:[n],message:`${n} requires a native connector trigger`})})}const Kt=refineTrigger(X).transform(e=>({...e,...e.eventType===`github`||e.eventType===`slack`?{continueConversation:e.continueConversation??!0}:{}})),qt=X.partial();function parseMergedAgentTrigger(e,t){let n=qt.safeParse(t);if(!n.success)throw triggerValidationError(n.error);let r=Object.fromEntries(Object.entries(n.data).filter(([,e])=>e!==void 0)),i=Kt.safeParse({...e,...r});if(!i.success)throw triggerValidationError(i.error);return i.data}function triggerValidationError(e){return new t.ValidationError(`Invalid agent trigger`,e.issues.map(e=>({path:e.path.map(String),message:e.message})))}const Z=r.uuid(),Q=r.record(r.string(),r.unknown()),Jt=r.strictObject({objectName:r.string(),recordId:Z,attribute:r.string(),base:r.unknown(),props:Q.optional()}),Yt=r.strictObject({kind:r.literal(`record.set`),objectId:Z,recordId:Z,values:Q,base:Q.optional()}),Xt=r.strictObject({kind:r.literal(`record.create`),objectId:Z,recordId:Z,values:Q,options:r.strictObject({visibility:r.enum([`workspace`,`private`]).optional(),allowDraft:r.boolean().optional(),linkTo:Jt.optional()}).optional()}),Zt=r.strictObject({kind:r.literal(`record.delete`),objectId:Z,recordId:Z}),Qt=r.strictObject({kind:r.literal(`record.restore`),objectId:Z,recordId:Z}),$=r.string().min(1),$t=r.discriminatedUnion(`command`,[r.strictObject({command:r.literal(`replace`),oldText:$,newText:r.string(),replaceAll:r.boolean().optional()}),r.strictObject({command:r.literal(`insert`),text:$,after:$.optional()})]),en=r.strictObject({kind:r.literal(`record.patch`),objectId:Z,recordId:Z,attribute:r.string(),edit:$t}),tn=r.discriminatedUnion(`kind`,[Yt,Xt,Zt,Qt,en]),nn=r.strictObject({opId:Z,steps:r.array(tn).min(1).max(100)}).superRefine((e,t)=>{let n=new Set;for(let r of e.steps){if(n.has(r.recordId)){t.addIssue({code:`custom`,message:`one step per record`,path:[`steps`]});return}n.add(r.recordId)}});Object.defineProperty(exports,"ACCESS_LEVELS",{enumerable:!0,get:function(){return Qe}}),Object.defineProperty(exports,"ACCESS_ROLES",{enumerable:!0,get:function(){return me}}),Object.defineProperty(exports,"AGENT_ASIDE_ANSWER_MAX_LENGTH",{enumerable:!0,get:function(){return 32e3}}),Object.defineProperty(exports,"AGENT_ASIDE_HISTORY_LIMIT",{enumerable:!0,get:function(){return 20}}),Object.defineProperty(exports,"AGENT_ASIDE_QUESTION_MAX_LENGTH",{enumerable:!0,get:function(){return 4e3}}),Object.defineProperty(exports,"AGENT_AVATAR_EXPRESSIONS",{enumerable:!0,get:function(){return ce}}),Object.defineProperty(exports,"AGENT_AVATAR_TYPES",{enumerable:!0,get:function(){return se}}),Object.defineProperty(exports,"AGENT_MESSAGE_KIND",{enumerable:!0,get:function(){return ue}}),Object.defineProperty(exports,"AGENT_NOTIFICATION_KIND",{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,"AGENT_SESSION_LIST_ORDERS",{enumerable:!0,get:function(){return ee}}),Object.defineProperty(exports,"AGENT_SESSION_ORIGINS",{enumerable:!0,get:function(){return fe}}),Object.defineProperty(exports,"AGENT_STARTERS_MAX",{enumerable:!0,get:function(){return 4}}),Object.defineProperty(exports,"AGENT_STARTER_MAX_LENGTH",{enumerable:!0,get:function(){return 200}}),Object.defineProperty(exports,"AGENT_TASK_KINDS",{enumerable:!0,get:function(){return re}}),Object.defineProperty(exports,"ALL_CATALOG_TOOL_NAMES",{enumerable:!0,get:function(){return Be}}),Object.defineProperty(exports,"ALWAYS_KINDS",{enumerable:!0,get:function(){return Le}}),Object.defineProperty(exports,"APPROVAL_FAMILY_TOOL_NAMES",{enumerable:!0,get:function(){return Ce}}),Object.defineProperty(exports,"ARCHITECT_PUBLICATION_KIND",{enumerable:!0,get:function(){return p}}),Object.defineProperty(exports,"ASK_QUESTIONS_ANSWER_MAX_LENGTH",{enumerable:!0,get:function(){return 2e3}}),Object.defineProperty(exports,"ASK_QUESTIONS_ANSWER_MAX_VALUES",{enumerable:!0,get:function(){return 50}}),Object.defineProperty(exports,"ASK_QUESTIONS_MAX_BATCH",{enumerable:!0,get:function(){return 4}}),Object.defineProperty(exports,"ASK_QUESTIONS_TOOL_NAME",{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,"AUDIT_ACTIONS",{enumerable:!0,get:function(){return ye}}),Object.defineProperty(exports,"AUDIT_AGENT_SESSION_METADATA_KEY",{enumerable:!0,get:function(){return`agentSessionId`}}),Object.defineProperty(exports,"AUDIT_RESOURCE_TYPES",{enumerable:!0,get:function(){return ve}}),Object.defineProperty(exports,"AgentBuilder",{enumerable:!0,get:function(){return AgentBuilder}}),Object.defineProperty(exports,"BROWSER_LAUNCH_TOOL_NAME",{enumerable:!0,get:function(){return`browser_launch`}}),Object.defineProperty(exports,"BUNDLE_LOCALES",{enumerable:!0,get:function(){return _e}}),Object.defineProperty(exports,"CONNECTION_GRANT_PROVIDERS",{enumerable:!0,get:function(){return Ve}}),Object.defineProperty(exports,"CONTINUATION_KEY_PATTERN",{enumerable:!0,get:function(){return Gt}}),Object.defineProperty(exports,"CONVERSATION_SURFACES",{enumerable:!0,get:function(){return je}}),Object.defineProperty(exports,"CORE_RECORD_TOOL_NAMES",{enumerable:!0,get:function(){return T}}),Object.defineProperty(exports,"CORE_TOOL_NAMES",{enumerable:!0,get:function(){return E}}),Object.defineProperty(exports,"COUNT_MODES",{enumerable:!0,get:function(){return v}}),Object.defineProperty(exports,"DEFAULT_AGENT_EXECUTION_CONFIG",{enumerable:!0,get:function(){return I}}),Object.defineProperty(exports,"DEFAULT_AGENT_TOOL_GROUPS",{enumerable:!0,get:function(){return He}}),Object.defineProperty(exports,"DEFAULT_APPROVAL_POLICY",{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,"DEFAULT_BLUEPRINT_TOOL_GROUPS",{enumerable:!0,get:function(){return j}}),Object.defineProperty(exports,"DEFAULT_DAILY_ACTIVITY_DAYS",{enumerable:!0,get:function(){return 182}}),Object.defineProperty(exports,"DEFAULT_MEETING_BOT_DISPLAY_NAME",{enumerable:!0,get:function(){return Ee}}),Object.defineProperty(exports,"DEFAULT_TENANT_SETTINGS",{enumerable:!0,get:function(){return Oe}}),Object.defineProperty(exports,"DISCARD_ARCHITECT_DRAFT_TOOL_NAME",{enumerable:!0,get:function(){return`discard_architect_draft`}}),Object.defineProperty(exports,"DOCUMENT_SORT_MODES",{enumerable:!0,get:function(){return pe}}),Object.defineProperty(exports,"DRAFT_WRITE_TOOL_NAMES",{enumerable:!0,get:function(){return be}}),Object.defineProperty(exports,"EMAIL_CATEGORY_DEFAULT_COLOR",{enumerable:!0,get:function(){return P}}),Object.defineProperty(exports,"EMAIL_CATEGORY_DEFAULT_ICON",{enumerable:!0,get:function(){return`tag`}}),Object.defineProperty(exports,"EMAIL_CATEGORY_DESCRIPTION_MAX",{enumerable:!0,get:function(){return 500}}),Object.defineProperty(exports,"EMAIL_CATEGORY_DESCRIPTION_MIN",{enumerable:!0,get:function(){return 10}}),Object.defineProperty(exports,"EMAIL_CATEGORY_LIMIT",{enumerable:!0,get:function(){return 8}}),Object.defineProperty(exports,"EMAIL_CATEGORY_NAME_MAX",{enumerable:!0,get:function(){return 24}}),Object.defineProperty(exports,"ENVIRONMENT_HARNESSES",{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,"ENVIRONMENT_HARNESS_SANDBOX_WORKDIR",{enumerable:!0,get:function(){return Pe}}),Object.defineProperty(exports,"ENVIRONMENT_HARNESS_WORKDIR",{enumerable:!0,get:function(){return Fe}}),Object.defineProperty(exports,"ENVIRONMENT_NAME_MAX_CHARS",{enumerable:!0,get:function(){return 100}}),Object.defineProperty(exports,"ENVIRONMENT_STANDARDS_WORKDIR",{enumerable:!0,get:function(){return Ie}}),Object.defineProperty(exports,"ENV_VAR_KEY_PATTERN",{enumerable:!0,get:function(){return Ut}}),Object.defineProperty(exports,"ESTIMATED_COUNT_CAP",{enumerable:!0,get:function(){return 1e4}}),Object.defineProperty(exports,"FILE_URLS_MAX_IDS",{enumerable:!0,get:function(){return 200}}),Object.defineProperty(exports,"GET_ARCHITECT_DRAFT_TOOL_NAME",{enumerable:!0,get:function(){return`get_architect_draft`}}),Object.defineProperty(exports,"GITHUB_TRIGGER_CATALOG",{enumerable:!0,get:function(){return L}}),Object.defineProperty(exports,"GRANT_ENABLES",{enumerable:!0,get:function(){return Re}}),Object.defineProperty(exports,"HITL_TOOL_NAMES",{enumerable:!0,get:function(){return xe}}),Object.defineProperty(exports,"INFERENCE_REASONING_OPTIONS",{enumerable:!0,get:function(){return ne}}),Object.defineProperty(exports,"INFERENCE_ROUTING_MODES",{enumerable:!0,get:function(){return ae}}),Object.defineProperty(exports,"INFERENCE_SPEEDS",{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,"LAST_RUN_ERROR_MAX_LENGTH",{enumerable:!0,get:function(){return 200}}),Object.defineProperty(exports,"MAILBOX_LIST_MODES",{enumerable:!0,get:function(){return pt}}),Object.defineProperty(exports,"MAIL_DRAFT_BODY_MAX_CHARS",{enumerable:!0,get:function(){return 2e5}}),Object.defineProperty(exports,"MAIL_SIGNATURE_MAX_CHARS",{enumerable:!0,get:function(){return 2e4}}),Object.defineProperty(exports,"MAIL_SUBJECT_MAX_CHARS",{enumerable:!0,get:function(){return 998}}),Object.defineProperty(exports,"MAX_DAILY_ACTIVITY_DAYS",{enumerable:!0,get:function(){return 366}}),Object.defineProperty(exports,"MAX_TODOS",{enumerable:!0,get:function(){return 50}}),Object.defineProperty(exports,"MAX_TODO_DESCRIPTION_CHARS",{enumerable:!0,get:function(){return 500}}),Object.defineProperty(exports,"MAX_TODO_ID_CHARS",{enumerable:!0,get:function(){return 80}}),Object.defineProperty(exports,"MCP_SERVER_NAME_MAX_LENGTH",{enumerable:!0,get:function(){return 100}}),Object.defineProperty(exports,"MEETING_BOT_IMAGE",{enumerable:!0,get:function(){return at}}),Object.defineProperty(exports,"MEETING_BOT_IMAGE_BASE64_MAX_LENGTH",{enumerable:!0,get:function(){return ot}}),Object.defineProperty(exports,"MEETING_RESPONSES",{enumerable:!0,get:function(){return $e}}),Object.defineProperty(exports,"MEMORY_SPEND_LIMIT_PATTERN",{enumerable:!0,get:function(){return De}}),Object.defineProperty(exports,"McpOAuthCompletionMode",{enumerable:!0,get:function(){return ut}}),Object.defineProperty(exports,"NATIVE_TOOL_GROUPS",{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,"NATIVE_TOOL_GROUP_CATALOG",{enumerable:!0,get:function(){return k}}),Object.defineProperty(exports,"NO_RECORDING",{enumerable:!0,get:function(){return nt}}),Object.defineProperty(exports,"OPEN_TOOL_PART_STATES",{enumerable:!0,get:function(){return le}}),Object.defineProperty(exports,"OPERATION_MAX_STEPS",{enumerable:!0,get:function(){return 100}}),Object.defineProperty(exports,"PROVIDER_DRAFT_LABEL",{enumerable:!0,get:function(){return dt}}),Object.defineProperty(exports,"PROVIDER_NAMES",{enumerable:!0,get:function(){return s}}),Object.defineProperty(exports,"PUBLIC_MAIL_DOMAINS",{enumerable:!0,get:function(){return F}}),Object.defineProperty(exports,"QUESTION_FAMILY_TOOL_NAMES",{enumerable:!0,get:function(){return Se}}),Object.defineProperty(exports,"RECENT_ACTIVITY_LEDGER_LIMIT",{enumerable:!0,get:function(){return 50}}),Object.defineProperty(exports,"RECORDING_OVERRIDES",{enumerable:!0,get:function(){return et}}),Object.defineProperty(exports,"RECORDING_POLICIES",{enumerable:!0,get:function(){return tt}}),Object.defineProperty(exports,"RECORD_ACCESS_ROLES",{enumerable:!0,get:function(){return _}}),Object.defineProperty(exports,"RECORD_ACCESS_SOURCES",{enumerable:!0,get:function(){return he}}),Object.defineProperty(exports,"RECORD_DRIVE_CURSOR_MAX_LENGTH",{enumerable:!0,get:function(){return 2048}}),Object.defineProperty(exports,"RECORD_DRIVE_PAGE_DEFAULT_LIMIT",{enumerable:!0,get:function(){return 100}}),Object.defineProperty(exports,"RECORD_DRIVE_PAGE_MAX_LIMIT",{enumerable:!0,get:function(){return 500}}),Object.defineProperty(exports,"RECORD_GRAPH_DEFAULT_LIMIT_PER_NODE",{enumerable:!0,get:function(){return 50}}),Object.defineProperty(exports,"RECORD_GRAPH_MAX_LIMIT_PER_NODE",{enumerable:!0,get:function(){return 200}}),Object.defineProperty(exports,"RECORD_GRAPH_MAX_NODES",{enumerable:!0,get:function(){return 50}}),Object.defineProperty(exports,"RECORD_IMAGE_MAX_BYTES",{enumerable:!0,get:function(){return 5242880}}),Object.defineProperty(exports,"REPLY_MODES",{enumerable:!0,get:function(){return mt}}),Object.defineProperty(exports,"REQUEST_DESIGN_REVIEW_TOOL_NAME",{enumerable:!0,get:function(){return y}}),Object.defineProperty(exports,"REQUEST_SETUP_TOOL_NAME",{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,"RESOURCE_GRANT_KINDS",{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,"RESOURCE_KIND_CATALOG",{enumerable:!0,get:function(){return A}}),Object.defineProperty(exports,"ROUTING_PRICE_CEILINGS",{enumerable:!0,get:function(){return oe}}),Object.defineProperty(exports,"SESSION_INFERENCE_PATCH_KEYS",{enumerable:!0,get:function(){return l}}),Object.defineProperty(exports,"SETUP_SCRIPT_MAX_CHARS",{enumerable:!0,get:function(){return 64e3}}),Object.defineProperty(exports,"SLACK_TRIGGER_CATALOG",{enumerable:!0,get:function(){return R}}),Object.defineProperty(exports,"SURFACE_TOOL_NAMES",{enumerable:!0,get:function(){return ze}}),Object.defineProperty(exports,"SYSTEM_EMAIL_CATEGORIES",{enumerable:!0,get:function(){return M}}),Object.defineProperty(exports,"SYSTEM_EMAIL_CATEGORY_NAMES",{enumerable:!0,get:function(){return N}}),Object.defineProperty(exports,"SYSTEM_PART_CODES",{enumerable:!0,get:function(){return d}}),Object.defineProperty(exports,"TASK_DEMAND_LEVELS",{enumerable:!0,get:function(){return ie}}),Object.defineProperty(exports,"TODO_PHASES",{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,"TODO_PLAN_STATUSES",{enumerable:!0,get:function(){return te}}),Object.defineProperty(exports,"TODO_STATUSES",{enumerable:!0,get:function(){return de}}),Object.defineProperty(exports,"TOOL_APPROVAL_STATES",{enumerable:!0,get:function(){return u}}),Object.defineProperty(exports,"TRIAGE_ACTIONS",{enumerable:!0,get:function(){return ft}}),Object.defineProperty(exports,"TRIGGER_EVENT_TYPES",{enumerable:!0,get:function(){return Vt}}),Object.defineProperty(exports,"TURN_OUTCOMES",{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,"UNSHAREABLE_OBJECT_NAMES",{enumerable:!0,get:function(){return ge}}),Object.defineProperty(exports,"USER_STATUSES",{enumerable:!0,get:function(){return ke}}),Object.defineProperty(exports,"USER_WORK_POSTURES",{enumerable:!0,get:function(){return Ae}}),Object.defineProperty(exports,"VERB_NAMES",{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,"agent",{enumerable:!0,get:function(){return agent}}),Object.defineProperty(exports,"agentAvatarFromMetadata",{enumerable:!0,get:function(){return agentAvatarFromMetadata}}),Object.defineProperty(exports,"agentAvatarSchema",{enumerable:!0,get:function(){return zt}}),Object.defineProperty(exports,"agentDataChunk",{enumerable:!0,get:function(){return agentDataChunk}}),Object.defineProperty(exports,"agentDisplayName",{enumerable:!0,get:function(){return agentDisplayName}}),Object.defineProperty(exports,"agentInferencePreferencesSchema",{enumerable:!0,get:function(){return ht}}),Object.defineProperty(exports,"agentMessageAttachmentSchema",{enumerable:!0,get:function(){return xt}}),Object.defineProperty(exports,"agentMessagePartSchema",{enumerable:!0,get:function(){return bt}}),Object.defineProperty(exports,"agentScheduleSchema",{enumerable:!0,get:function(){return Wt}}),Object.defineProperty(exports,"agentSessionInferenceOverridesInputSchema",{enumerable:!0,get:function(){return gt}}),Object.defineProperty(exports,"agentSessionInferenceOverridesSchema",{enumerable:!0,get:function(){return _t}}),Object.defineProperty(exports,"agentSessionMessageSchema",{enumerable:!0,get:function(){return Et}}),Object.defineProperty(exports,"agentStartersSchema",{enumerable:!0,get:function(){return Bt}}),Object.defineProperty(exports,"agentTriggerBaseSchema",{enumerable:!0,get:function(){return X}}),Object.defineProperty(exports,"agentTriggerPatchSchema",{enumerable:!0,get:function(){return qt}}),Object.defineProperty(exports,"agentTriggerSchema",{enumerable:!0,get:function(){return Kt}}),Object.defineProperty(exports,"agentUIValidationError",{enumerable:!0,get:function(){return agentUIValidationError}}),Object.defineProperty(exports,"artifactQuoteSchema",{enumerable:!0,get:function(){return St}}),Object.defineProperty(exports,"askQuestionsOutputSchema",{enumerable:!0,get:function(){return Te}}),Object.defineProperty(exports,"assertCustomAgentUIMessageChunk",{enumerable:!0,get:function(){return assertCustomAgentUIMessageChunk}}),Object.defineProperty(exports,"assertSessionState",{enumerable:!0,get:function(){return assertSessionState}}),Object.defineProperty(exports,"canonicalToolGroups",{enumerable:!0,get:function(){return canonicalToolGroups}}),Object.defineProperty(exports,"classificationRestoreSchema",{enumerable:!0,get:function(){return It}}),Object.defineProperty(exports,"classifyEmailSchema",{enumerable:!0,get:function(){return Ft}}),Object.defineProperty(exports,"cliDefaultModelOf",{enumerable:!0,get:function(){return cliDefaultModelOf}}),Object.defineProperty(exports,"compareAgentSessionMessages",{enumerable:!0,get:function(){return compareAgentSessionMessages}}),Object.defineProperty(exports,"compiledHarnessModels",{enumerable:!0,get:function(){return compiledHarnessModels}}),Object.defineProperty(exports,"connectionGrantKindsOf",{enumerable:!0,get:function(){return connectionGrantKindsOf}}),Object.defineProperty(exports,"connectorTriggerMatchSchema",{enumerable:!0,get:function(){return B}}),Object.defineProperty(exports,"customDataChunkSchemas",{enumerable:!0,get:function(){return Y}}),Object.defineProperty(exports,"deriveViewerAccess",{enumerable:!0,get:function(){return deriveViewerAccess}}),Object.defineProperty(exports,"durableDateSchema",{enumerable:!0,get:function(){return Tt}}),Object.defineProperty(exports,"emailCategoryCreateSchema",{enumerable:!0,get:function(){return Mt}}),Object.defineProperty(exports,"emailCategoryDeleteSchema",{enumerable:!0,get:function(){return Pt}}),Object.defineProperty(exports,"emailCategoryScopeQuerySchema",{enumerable:!0,get:function(){return Rt}}),Object.defineProperty(exports,"emailCategoryUpdateSchema",{enumerable:!0,get:function(){return Nt}}),Object.defineProperty(exports,"emailRuleScopeSchema",{enumerable:!0,get:function(){return Lt}}),Object.defineProperty(exports,"environmentHarness",{enumerable:!0,get:function(){return environmentHarness}}),Object.defineProperty(exports,"environmentWorkdir",{enumerable:!0,get:function(){return environmentWorkdir}}),Object.defineProperty(exports,"findEnvironmentHarness",{enumerable:!0,get:function(){return findEnvironmentHarness}}),Object.defineProperty(exports,"githubConditionSchema",{enumerable:!0,get:function(){return Ke}}),Object.defineProperty(exports,"githubTriggerMatchSchema",{enumerable:!0,get:function(){return Xe}}),Object.defineProperty(exports,"grantKindOf",{enumerable:!0,get:function(){return grantKindOf}}),Object.defineProperty(exports,"harnessModelChoices",{enumerable:!0,get:function(){return harnessModelChoices}}),Object.defineProperty(exports,"humanRequestId",{enumerable:!0,get:function(){return humanRequestId}}),Object.defineProperty(exports,"humanRequestKind",{enumerable:!0,get:function(){return humanRequestKind}}),Object.defineProperty(exports,"imageModelIdSchema",{enumerable:!0,get:function(){return q}}),Object.defineProperty(exports,"inferenceReasoningSchema",{enumerable:!0,get:function(){return W}}),Object.defineProperty(exports,"inferenceRoutingSchema",{enumerable:!0,get:function(){return G}}),Object.defineProperty(exports,"inferenceSpeedSchema",{enumerable:!0,get:function(){return U}}),Object.defineProperty(exports,"isAgentMessageMetadata",{enumerable:!0,get:function(){return isAgentMessageMetadata}}),Object.defineProperty(exports,"isAgentNotificationMetadata",{enumerable:!0,get:function(){return isAgentNotificationMetadata}}),Object.defineProperty(exports,"isAgentUIDataName",{enumerable:!0,get:function(){return isAgentUIDataName}}),Object.defineProperty(exports,"isAgentWrittenAuditEntry",{enumerable:!0,get:function(){return isAgentWrittenAuditEntry}}),Object.defineProperty(exports,"isArchitectPublicationMetadata",{enumerable:!0,get:function(){return isArchitectPublicationMetadata}}),Object.defineProperty(exports,"isAwaitingHuman",{enumerable:!0,get:function(){return isAwaitingHuman}}),Object.defineProperty(exports,"isBlocking",{enumerable:!0,get:function(){return isBlocking}}),Object.defineProperty(exports,"isEnvironmentHarnessId",{enumerable:!0,get:function(){return isEnvironmentHarnessId}}),Object.defineProperty(exports,"isMailProvider",{enumerable:!0,get:function(){return isMailProvider}}),Object.defineProperty(exports,"isMailboxListMode",{enumerable:!0,get:function(){return isMailboxListMode}}),Object.defineProperty(exports,"isNativeToolGroup",{enumerable:!0,get:function(){return isNativeToolGroup}}),Object.defineProperty(exports,"isOpenToolPartState",{enumerable:!0,get:function(){return isOpenToolPartState}}),Object.defineProperty(exports,"isParkedOnHuman",{enumerable:!0,get:function(){return isParkedOnHuman}}),Object.defineProperty(exports,"isProviderDraft",{enumerable:!0,get:function(){return isProviderDraft}}),Object.defineProperty(exports,"isPublicMailDomain",{enumerable:!0,get:function(){return isPublicMailDomain}}),Object.defineProperty(exports,"isReplyMode",{enumerable:!0,get:function(){return isReplyMode}}),Object.defineProperty(exports,"isResourceGrant",{enumerable:!0,get:function(){return isResourceGrant}}),Object.defineProperty(exports,"isRoutineActorMetadata",{enumerable:!0,get:function(){return isRoutineActorMetadata}}),Object.defineProperty(exports,"isSessionInferencePatch",{enumerable:!0,get:function(){return isSessionInferencePatch}}),Object.defineProperty(exports,"isSystemEmailCategory",{enumerable:!0,get:function(){return isSystemEmailCategory}}),Object.defineProperty(exports,"isSystemEmailCategoryName",{enumerable:!0,get:function(){return isSystemEmailCategoryName}}),Object.defineProperty(exports,"isSystemPartCode",{enumerable:!0,get:function(){return isSystemPartCode}}),Object.defineProperty(exports,"isToolApprovalState",{enumerable:!0,get:function(){return isToolApprovalState}}),Object.defineProperty(exports,"meetingBotDispatchRequestSchema",{enumerable:!0,get:function(){return st}}),Object.defineProperty(exports,"meetingBotDispatchResponseSchema",{enumerable:!0,get:function(){return ct}}),Object.defineProperty(exports,"meetingBotNotificationSchema",{enumerable:!0,get:function(){return lt}}),Object.defineProperty(exports,"meetingTranscriptSegmentSchema",{enumerable:!0,get:function(){return rt}}),Object.defineProperty(exports,"mentionReferenceSchema",{enumerable:!0,get:function(){return Ct}}),Object.defineProperty(exports,"mergeSessionInferencePatch",{enumerable:!0,get:function(){return mergeSessionInferencePatch}}),Object.defineProperty(exports,"modelDefinitionSchema",{enumerable:!0,get:function(){return wt}}),Object.defineProperty(exports,"modelReferenceSchema",{enumerable:!0,get:function(){return K}}),Object.defineProperty(exports,"needsManageWhenUnattended",{enumerable:!0,get:function(){return needsManageWhenUnattended}}),Object.defineProperty(exports,"normalizedMeetingTranscriptSchema",{enumerable:!0,get:function(){return it}}),Object.defineProperty(exports,"openRequests",{enumerable:!0,get:function(){return openRequests}}),Object.defineProperty(exports,"orderAgentSessionMessages",{enumerable:!0,get:function(){return orderAgentSessionMessages}}),Object.defineProperty(exports,"parseAgentDefinitionAccessRole",{enumerable:!0,get:function(){return parseAgentDefinitionAccessRole}}),Object.defineProperty(exports,"parseCountMode",{enumerable:!0,get:function(){return parseCountMode}}),Object.defineProperty(exports,"parseMergedAgentTrigger",{enumerable:!0,get:function(){return parseMergedAgentTrigger}}),Object.defineProperty(exports,"parseOptionalCountMode",{enumerable:!0,get:function(){return parseOptionalCountMode}}),Object.defineProperty(exports,"parsePageAccessRole",{enumerable:!0,get:function(){return parsePageAccessRole}}),Object.defineProperty(exports,"parseRecordAccessRole",{enumerable:!0,get:function(){return parseRecordAccessRole}}),Object.defineProperty(exports,"parseToolGroupGrant",{enumerable:!0,get:function(){return parseToolGroupGrant}}),Object.defineProperty(exports,"providerNameSchema",{enumerable:!0,get:function(){return H}}),Object.defineProperty(exports,"readAskQuestionsResult",{enumerable:!0,get:function(){return readAskQuestionsResult}}),Object.defineProperty(exports,"recentActivityEntryKey",{enumerable:!0,get:function(){return recentActivityEntryKey}}),Object.defineProperty(exports,"recordGraphNodeKey",{enumerable:!0,get:function(){return recordGraphNodeKey}}),Object.defineProperty(exports,"recordGraphRequestSchema",{enumerable:!0,get:function(){return Ne}}),Object.defineProperty(exports,"recordOperationSchema",{enumerable:!0,get:function(){return nn}}),Object.defineProperty(exports,"refineTrigger",{enumerable:!0,get:function(){return refineTrigger}}),Object.defineProperty(exports,"resourceGrant",{enumerable:!0,get:function(){return resourceGrant}}),Object.defineProperty(exports,"routedMessageInferenceSchema",{enumerable:!0,get:function(){return yt}}),Object.defineProperty(exports,"sessionInferencePatchSchema",{enumerable:!0,get:function(){return vt}}),Object.defineProperty(exports,"slackConditionSchema",{enumerable:!0,get:function(){return qe}}),Object.defineProperty(exports,"slackTriggerMatchSchema",{enumerable:!0,get:function(){return Ze}}),Object.defineProperty(exports,"todoItemSchema",{enumerable:!0,get:function(){return Dt}}),Object.defineProperty(exports,"todoPlanSchema",{enumerable:!0,get:function(){return Ot}}),Object.defineProperty(exports,"toolImpactSchema",{enumerable:!0,get:function(){return J}});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { TextAttribute } from "./attributes-
|
|
3
|
-
import { ValidationMessages } from "./index-
|
|
2
|
+
import { TextAttribute } from "./attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "./index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/primitives/text.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { TextAttribute } from "./attributes-
|
|
3
|
-
import { ValidationMessages } from "./index-
|
|
2
|
+
import { TextAttribute } from "./attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "./index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/primitives/text.d.ts
|
|
6
6
|
/**
|
package/dist/utils.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { TenantId, UserId, Uuid, asTenantId, asUserId, canonicalStringify, deepEqual, generateId, indexBy } from "./utils-
|
|
2
|
+
import { TenantId, UserId, Uuid, asTenantId, asUserId, canonicalStringify, deepEqual, generateId, indexBy } from "./utils-C8viP5ET.mjs";
|
|
3
3
|
export { TenantId, UserId, Uuid, asTenantId, asUserId, canonicalStringify, deepEqual, generateId, indexBy };
|
package/dist/utils.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { TenantId, UserId, Uuid, asTenantId, asUserId, canonicalStringify, deepEqual, generateId, indexBy } from "./utils-
|
|
2
|
+
import { TenantId, UserId, Uuid, asTenantId, asUserId, canonicalStringify, deepEqual, generateId, indexBy } from "./utils-Brab7BhE.js";
|
|
3
3
|
export { TenantId, UserId, Uuid, asTenantId, asUserId, canonicalStringify, deepEqual, generateId, indexBy };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { SCHEMA_LIMITS, collectionContentSourceSchema, colorIdSchema, contentViewDefinitionSchema, draftContentViewDefinitionSchema, iconNameSchema, publishedViewContentDefinitionSchema } from "../all-
|
|
3
|
-
import { SIMPLE_PROPERTY_TYPES, WIRE_OFFERED_BASE_CONFIG, WIRE_OMITTED_CONFIG_KEYS, attributeConfigSchemas, getAttributeConfigSchema, getAttributeConfigWriteSchema, multiselectOptionWriteSchema, parseAttributeConfig, parseAttributeConfigForCreate, parseAttributeConfigForUpdate, propertyAttributeSchema, propertyAttributeWireSchema, propertySchemaSchema, propertySchemaWireSchema, refuseForeignKeys, selectOptionWriteSchema, statusGroupSchema, statusOptionWriteSchema, wireHiddenTypeConfigMask, wireOmittedConfigKeysFor, withoutUnknownOptionKeys } from "../index-
|
|
4
|
-
import { DEFAULT_VALIDATION_MESSAGES, ValidationMessages, ValidationResult, formatZodErrors } from "../index-
|
|
5
|
-
import { createAttributeValidator, createFormAttributeValidator, rejectUnknownAttributesOrThrow, validateAttribute, validateDraft, validateDraftOrThrow, validateObject, validateObjectOrThrow } from "../index-
|
|
2
|
+
import { SCHEMA_LIMITS, collectionContentSourceSchema, colorIdSchema, contentViewDefinitionSchema, draftContentViewDefinitionSchema, iconNameSchema, publishedViewContentDefinitionSchema } from "../all-Y3tO-bfa.mjs";
|
|
3
|
+
import { SIMPLE_PROPERTY_TYPES, WIRE_OFFERED_BASE_CONFIG, WIRE_OMITTED_CONFIG_KEYS, attributeConfigSchemas, getAttributeConfigSchema, getAttributeConfigWriteSchema, multiselectOptionWriteSchema, parseAttributeConfig, parseAttributeConfigForCreate, parseAttributeConfigForUpdate, propertyAttributeSchema, propertyAttributeWireSchema, propertySchemaSchema, propertySchemaWireSchema, refuseForeignKeys, selectOptionWriteSchema, statusGroupSchema, statusOptionWriteSchema, wireHiddenTypeConfigMask, wireOmittedConfigKeysFor, withoutUnknownOptionKeys } from "../index-ColQV1OG.mjs";
|
|
4
|
+
import { DEFAULT_VALIDATION_MESSAGES, ValidationMessages, ValidationResult, formatZodErrors } from "../index-CiKELB3w.mjs";
|
|
5
|
+
import { createAttributeValidator, createFormAttributeValidator, rejectUnknownAttributesOrThrow, validateAttribute, validateDraft, validateDraftOrThrow, validateObject, validateObjectOrThrow } from "../index-BC5mEVkb.mjs";
|
|
6
6
|
export { DEFAULT_VALIDATION_MESSAGES, SCHEMA_LIMITS, SIMPLE_PROPERTY_TYPES, type ValidationMessages, type ValidationResult, WIRE_OFFERED_BASE_CONFIG, WIRE_OMITTED_CONFIG_KEYS, attributeConfigSchemas, collectionContentSourceSchema, colorIdSchema, contentViewDefinitionSchema, createAttributeValidator, createFormAttributeValidator, draftContentViewDefinitionSchema, formatZodErrors, getAttributeConfigSchema, getAttributeConfigWriteSchema, iconNameSchema, multiselectOptionWriteSchema, parseAttributeConfig, parseAttributeConfigForCreate, parseAttributeConfigForUpdate, propertyAttributeSchema, propertyAttributeWireSchema, propertySchemaSchema, propertySchemaWireSchema, publishedViewContentDefinitionSchema, refuseForeignKeys, rejectUnknownAttributesOrThrow, selectOptionWriteSchema, statusGroupSchema, statusOptionWriteSchema, validateAttribute, validateDraft, validateDraftOrThrow, validateObject, validateObjectOrThrow, wireHiddenTypeConfigMask, wireOmittedConfigKeysFor, withoutUnknownOptionKeys };
|
package/dist/validation/all.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { SCHEMA_LIMITS, collectionContentSourceSchema, colorIdSchema, contentViewDefinitionSchema, draftContentViewDefinitionSchema, iconNameSchema, publishedViewContentDefinitionSchema } from "../all-
|
|
3
|
-
import { SIMPLE_PROPERTY_TYPES, WIRE_OFFERED_BASE_CONFIG, WIRE_OMITTED_CONFIG_KEYS, attributeConfigSchemas, getAttributeConfigSchema, getAttributeConfigWriteSchema, multiselectOptionWriteSchema, parseAttributeConfig, parseAttributeConfigForCreate, parseAttributeConfigForUpdate, propertyAttributeSchema, propertyAttributeWireSchema, propertySchemaSchema, propertySchemaWireSchema, refuseForeignKeys, selectOptionWriteSchema, statusGroupSchema, statusOptionWriteSchema, wireHiddenTypeConfigMask, wireOmittedConfigKeysFor, withoutUnknownOptionKeys } from "../index-
|
|
4
|
-
import { DEFAULT_VALIDATION_MESSAGES, ValidationMessages, ValidationResult, formatZodErrors } from "../index-
|
|
5
|
-
import { createAttributeValidator, createFormAttributeValidator, rejectUnknownAttributesOrThrow, validateAttribute, validateDraft, validateDraftOrThrow, validateObject, validateObjectOrThrow } from "../index-
|
|
2
|
+
import { SCHEMA_LIMITS, collectionContentSourceSchema, colorIdSchema, contentViewDefinitionSchema, draftContentViewDefinitionSchema, iconNameSchema, publishedViewContentDefinitionSchema } from "../all-o498zQ_Z.js";
|
|
3
|
+
import { SIMPLE_PROPERTY_TYPES, WIRE_OFFERED_BASE_CONFIG, WIRE_OMITTED_CONFIG_KEYS, attributeConfigSchemas, getAttributeConfigSchema, getAttributeConfigWriteSchema, multiselectOptionWriteSchema, parseAttributeConfig, parseAttributeConfigForCreate, parseAttributeConfigForUpdate, propertyAttributeSchema, propertyAttributeWireSchema, propertySchemaSchema, propertySchemaWireSchema, refuseForeignKeys, selectOptionWriteSchema, statusGroupSchema, statusOptionWriteSchema, wireHiddenTypeConfigMask, wireOmittedConfigKeysFor, withoutUnknownOptionKeys } from "../index-BsOZnVmp.js";
|
|
4
|
+
import { DEFAULT_VALIDATION_MESSAGES, ValidationMessages, ValidationResult, formatZodErrors } from "../index-CFXgKvOC.js";
|
|
5
|
+
import { createAttributeValidator, createFormAttributeValidator, rejectUnknownAttributesOrThrow, validateAttribute, validateDraft, validateDraftOrThrow, validateObject, validateObjectOrThrow } from "../index-DMBl9Ahc.js";
|
|
6
6
|
export { DEFAULT_VALIDATION_MESSAGES, SCHEMA_LIMITS, SIMPLE_PROPERTY_TYPES, type ValidationMessages, type ValidationResult, WIRE_OFFERED_BASE_CONFIG, WIRE_OMITTED_CONFIG_KEYS, attributeConfigSchemas, collectionContentSourceSchema, colorIdSchema, contentViewDefinitionSchema, createAttributeValidator, createFormAttributeValidator, draftContentViewDefinitionSchema, formatZodErrors, getAttributeConfigSchema, getAttributeConfigWriteSchema, iconNameSchema, multiselectOptionWriteSchema, parseAttributeConfig, parseAttributeConfigForCreate, parseAttributeConfigForUpdate, propertyAttributeSchema, propertyAttributeWireSchema, propertySchemaSchema, propertySchemaWireSchema, publishedViewContentDefinitionSchema, refuseForeignKeys, rejectUnknownAttributesOrThrow, selectOptionWriteSchema, statusGroupSchema, statusOptionWriteSchema, validateAttribute, validateDraft, validateDraftOrThrow, validateObject, validateObjectOrThrow, wireHiddenTypeConfigMask, wireOmittedConfigKeysFor, withoutUnknownOptionKeys };
|
package/dist/validation/all.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! © 2025-2026 AND YOU CREATE SAS (RCS Paris 940 190 614). Proprietary — see LICENSE (Standards SDK License 1.0). */
|
|
2
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../view-config.schema-
|
|
2
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../view-config.schema-Cyl6PedI.js"),t=require("../primitives-BBtVhLdq.js"),n=require("../config-oKDg40Iz.js"),r=require("../object-5-wnsH0o.js"),i=require("../core-DAxRlJ5i.js");exports.DEFAULT_VALIDATION_MESSAGES=i.DEFAULT_VALIDATION_MESSAGES,exports.SCHEMA_LIMITS=t.SCHEMA_LIMITS,exports.SIMPLE_PROPERTY_TYPES=n.SIMPLE_PROPERTY_TYPES,exports.WIRE_OFFERED_BASE_CONFIG=n.WIRE_OFFERED_BASE_CONFIG,exports.WIRE_OMITTED_CONFIG_KEYS=n.WIRE_OMITTED_CONFIG_KEYS,exports.attributeConfigSchemas=n.attributeConfigSchemas,exports.collectionContentSourceSchema=e.collectionContentSourceSchema,exports.colorIdSchema=t.colorIdSchema,exports.contentViewDefinitionSchema=e.contentViewDefinitionSchema,exports.createAttributeValidator=r.createAttributeValidator,exports.createFormAttributeValidator=r.createFormAttributeValidator,exports.draftContentViewDefinitionSchema=e.draftContentViewDefinitionSchema,exports.formatZodErrors=i.formatZodErrors,exports.getAttributeConfigSchema=n.getAttributeConfigSchema,exports.getAttributeConfigWriteSchema=n.getAttributeConfigWriteSchema,exports.iconNameSchema=t.iconNameSchema,exports.multiselectOptionWriteSchema=n.multiselectOptionWriteSchema,exports.parseAttributeConfig=n.parseAttributeConfig,exports.parseAttributeConfigForCreate=n.parseAttributeConfigForCreate,exports.parseAttributeConfigForUpdate=n.parseAttributeConfigForUpdate,exports.propertyAttributeSchema=n.propertyAttributeSchema,exports.propertyAttributeWireSchema=n.propertyAttributeWireSchema,exports.propertySchemaSchema=n.propertySchemaSchema,exports.propertySchemaWireSchema=n.propertySchemaWireSchema,exports.publishedViewContentDefinitionSchema=e.publishedViewContentDefinitionSchema,exports.refuseForeignKeys=n.refuseForeignKeys,exports.rejectUnknownAttributesOrThrow=r.rejectUnknownAttributesOrThrow,exports.selectOptionWriteSchema=n.selectOptionWriteSchema,exports.statusGroupSchema=n.statusGroupSchema,exports.statusOptionWriteSchema=n.statusOptionWriteSchema,exports.validateAttribute=r.validateAttribute,exports.validateDraft=r.validateDraft,exports.validateDraftOrThrow=r.validateDraftOrThrow,exports.validateObject=r.validateObject,exports.validateObjectOrThrow=r.validateObjectOrThrow,exports.wireHiddenTypeConfigMask=n.wireHiddenTypeConfigMask,exports.wireOmittedConfigKeysFor=n.wireOmittedConfigKeysFor,exports.withoutUnknownOptionKeys=n.withoutUnknownOptionKeys;
|
package/dist/validation/all.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! © 2025-2026 AND YOU CREATE SAS (RCS Paris 940 190 614). Proprietary — see LICENSE (Standards SDK License 1.0). */
|
|
2
|
-
import{collectionContentSourceSchema as e,contentViewDefinitionSchema as t,draftContentViewDefinitionSchema as n,publishedViewContentDefinitionSchema as r}from"../view-config.schema-
|
|
2
|
+
import{collectionContentSourceSchema as e,contentViewDefinitionSchema as t,draftContentViewDefinitionSchema as n,publishedViewContentDefinitionSchema as r}from"../view-config.schema-B9y7-OCJ.mjs";import{SCHEMA_LIMITS as i,colorIdSchema as a,iconNameSchema as o}from"../primitives-D9A6pmXV.mjs";import{SIMPLE_PROPERTY_TYPES as s,WIRE_OFFERED_BASE_CONFIG as c,WIRE_OMITTED_CONFIG_KEYS as l,attributeConfigSchemas as u,getAttributeConfigSchema as d,getAttributeConfigWriteSchema as f,multiselectOptionWriteSchema as p,parseAttributeConfig as m,parseAttributeConfigForCreate as h,parseAttributeConfigForUpdate as g,propertyAttributeSchema as _,propertyAttributeWireSchema as v,propertySchemaSchema as y,propertySchemaWireSchema as b,refuseForeignKeys as x,selectOptionWriteSchema as S,statusGroupSchema as C,statusOptionWriteSchema as w,wireHiddenTypeConfigMask as T,wireOmittedConfigKeysFor as E,withoutUnknownOptionKeys as D}from"../config-DqidiszP.mjs";import{createAttributeValidator as O,createFormAttributeValidator as k,rejectUnknownAttributesOrThrow as A,validateAttribute as j,validateDraft as M,validateDraftOrThrow as N,validateObject as P,validateObjectOrThrow as F}from"../object-BF5y6bgs.mjs";import{DEFAULT_VALIDATION_MESSAGES as I,formatZodErrors as L}from"../core-rKI7Q9_U.mjs";export{I as DEFAULT_VALIDATION_MESSAGES,i as SCHEMA_LIMITS,s as SIMPLE_PROPERTY_TYPES,c as WIRE_OFFERED_BASE_CONFIG,l as WIRE_OMITTED_CONFIG_KEYS,u as attributeConfigSchemas,e as collectionContentSourceSchema,a as colorIdSchema,t as contentViewDefinitionSchema,O as createAttributeValidator,k as createFormAttributeValidator,n as draftContentViewDefinitionSchema,L as formatZodErrors,d as getAttributeConfigSchema,f as getAttributeConfigWriteSchema,o as iconNameSchema,p as multiselectOptionWriteSchema,m as parseAttributeConfig,h as parseAttributeConfigForCreate,g as parseAttributeConfigForUpdate,_ as propertyAttributeSchema,v as propertyAttributeWireSchema,y as propertySchemaSchema,b as propertySchemaWireSchema,r as publishedViewContentDefinitionSchema,x as refuseForeignKeys,A as rejectUnknownAttributesOrThrow,S as selectOptionWriteSchema,C as statusGroupSchema,w as statusOptionWriteSchema,j as validateAttribute,M as validateDraft,N as validateDraftOrThrow,P as validateObject,F as validateObjectOrThrow,T as wireHiddenTypeConfigMask,E as wireOmittedConfigKeysFor,D as withoutUnknownOptionKeys};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { CurrencyAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { CurrencyAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/currency.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { CurrencyAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { CurrencyAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/currency.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { LocationAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { LocationAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/location.d.ts
|
|
6
6
|
type LocationShape = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { LocationAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { LocationAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/location.d.ts
|
|
6
6
|
type LocationShape = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { PhoneAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { PhoneAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/phone.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { PhoneAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { PhoneAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/phone.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { MultiRelationAttribute, RelationAttribute, SingleRelationAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { MultiRelationAttribute, RelationAttribute, SingleRelationAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/relation.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { MultiRelationAttribute, RelationAttribute, SingleRelationAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { MultiRelationAttribute, RelationAttribute, SingleRelationAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/relation.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { RichtextAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { RichtextAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/richtext.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { RichtextAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { RichtextAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/richtext.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { MultiselectAttribute, SelectAttribute, StatusAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { MultiselectAttribute, SelectAttribute, StatusAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/select.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { MultiselectAttribute, SelectAttribute, StatusAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { MultiselectAttribute, SelectAttribute, StatusAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/select.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { UserAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { UserAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/user.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { UserAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { UserAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/complex/user.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { FormulaAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { FormulaAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/computed/formula.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { FormulaAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { FormulaAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/computed/formula.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { RollupAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { RollupAttribute } from "../../attributes-CAYOHQLt.mjs";
|
|
3
|
+
import { ValidationMessages } from "../../index-CiKELB3w.mjs";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/computed/rollup.d.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { RollupAttribute } from "../../attributes-
|
|
3
|
-
import { ValidationMessages } from "../../index-
|
|
2
|
+
import { RollupAttribute } from "../../attributes-BOIIZZpP.js";
|
|
3
|
+
import { ValidationMessages } from "../../index-CFXgKvOC.js";
|
|
4
4
|
import * as z$2 from "zod";
|
|
5
5
|
//#region src/validation/computed/rollup.d.ts
|
|
6
6
|
/**
|