PageSourceSearch

https://www.rovetravel.com/_next/static/chunks/pages/admin/organizations/[id]/agents-64ca27012b1d6d0f.js

js rovetravel.com collected 2026-10-06 19:21:02 UTC 10,947 bytes, 1 lines download raw bytes

1try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},a=(new e.Error).stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="cc373421-719e-4974-913c-eb264e499bb1",e._sentryDebugIdIdentifier="sentry-dbid-cc373421-719e-4974-913c-eb264e499bb1")}catch(e){}{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[new e.Error().stack]=Object.assign({},e._sentryModuleMetadata[new e.Error().stack],{"_sentryBundlerPluginAppKey:rove-web":!0})}(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6391],{1331:(e,a,t)=>{"use strict";t.r(a),t.d(a,{default:()=>x});var s=t(6029),l=t(55729),n=t(81278),r=t(25076),i=t(50212),d=t(52734),c=t(24890),o=t(81329),u=t(2729),_=t(23224),b=t(8353),m=t(17520),h=t(79491),p=t(51566),y=t.n(p);let g=[{key:"enabled",label:"Production response"},{key:"owner_enabled",label:"Owner consent"},{key:"shadow_enabled",label:"Shadow eval"},{key:"training_enabled",label:"Training / QA extraction"}],f={kill_switch:"Disabled (global kill switch)",explicit_on:"Enabled (explicit)",explicit_off:"Disabled (explicit opt-out)",default_on:"Enabled (via system default)",default_off:"Disabled (via system default)",unset:"No owner consent recorded"},x=(0,d.ix)(()=>{var e,a;let{id:t}=(0,n.useRouter)().query,d="string"==typeof t?t:"",[p,x]=(0,l.useState)(null),[v,w]=(0,l.useState)([]),[j,N]=(0,l.useState)([]),[k,S]=(0,l.useState)(!0),[A,B]=(0,l.useState)(null),[z,C]=(0,l.useState)(new Set),[I,D]=(0,l.useState)({}),E=(0,l.useCallback)(async function(){let{showLoader:e=!0}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(d){e&&S(!0),B(null);try{let[e,a,t]=await Promise.all([(0,c.Sw8)(d),(0,c.vtb)(),(0,c.ABK)(d)]);x(e),w(a.data),N(t.data)}catch(a){console.error("Failed to load organization agents",a),e?B("Failed to load organization agents"):o.default.error("Failed to refresh agents")}finally{e&&S(!1)}}},[d]);(0,l.useEffect)(()=>{E()},[E]);let O=(0,l.useMemo)(()=>{let e=new Map;return j.forEach(a=>e.set(a.agent_id,a)),e},[j]),L=async(e,a,t)=>{if("owner_enabled"===a)return;let s="".concat(e.id,":").concat(a);C(e=>{let a=new Set(e);return a.add(s),a});try{await (0,c.sGq)(d,e.slug,{[a]:t}),await E({showLoader:!1}),o.default.success("Agent setting updated")}catch(e){console.error("Failed to update agent setting",e),o.default.error("Failed to update agent setting")}finally{C(e=>{let a=new Set(e);return a.delete(s),a})}},M=async(e,a)=>{let t=a.trim(),s="".concat(e.id,":agent_display_name");C(e=>{let a=new Set(e);return a.add(s),a});try{await (0,c.sGq)(d,e.slug,{agent_display_name:""===t?null:t}),await E({showLoader:!1}),D(a=>{let t={...a};return delete t[e.id],t}),o.default.success("Display name updated")}catch(e){console.error("Failed to update display name",e),o.default.error("Failed to update display name")}finally{C(e=>{let a=new Set(e);return a.delete(s),a})}},G=(0,l.useMemo)(()=>v.filter(e=>!e.deprecated),[v]);return d?(0,s.jsxs)("div",{className:y().container,children:[(0,s.jsx)(m.w,{breadcrumbs:[{label:"Organizations",href:"/admin/organizations"},{label:null!=(e=null==p?void 0:p.name)?e:d,href:"/admin/organizations/".concat(d)},{label:"Agents"}],title:"Organization Agents",meta:(0,s.jsxs)(s.Fragment,{children:[null!=(a=null==p?void 0:p.name)?a:"—"," \xb7"," ",(0,s.jsx)(h.v,{id:d,label:"Organization ID"})]})}),(0,s.jsx)(_.A,{title:"Agent Settings",children:k?(0,s.jsx)("p",{className:y().noData,children:"Loading..."}):A?(0,s.jsx)("p",{className:y().noData,children:A}):0===G.length?(0,s.jsx)("p",{className:y().noData,children:"No agents configured"}):G.map(e=>{var a,t;let l=O.get(e.id),n=null==(a=e.config)?void 0:a.ai_disclosure,d=null!=(t=null==l?void 0:l.agent_display_name)?t:"",c=I[e.id],o=null!=c?c:d,_=z.has("".concat(e.id,":agent_display_name")),m=void 0!==c&&c.trim()!==d.trim(),h=(0,r.ES)(void 0,null!=n?n:"present_as_assistant"),p=d.trim(),x=""!==p;return(0,s.jsxs)("div",{className:y().agentBlock,children:[(0,s.jsx)("h3",{className:y().agentBlockTitle,children:e.display_name}),(0,s.jsx)(b.A,{items:[{label:"Display name override",hidden:"disclose_ai"===n,value:(0,s.jsxs)("span",{className:y().agentToggleControl,children:[(0,s.jsxs)("span",{className:y().displayNameInputRow,children:[(0,s.jsx)("input",{"aria-label":"Display name override",type:"text",maxLength:120,className:y().displayNameInput,placeholder:h,value:o,disabled:_,onChange:a=>D(t=>
1({...t,[e.id]:a.target.value}))}),(0,s.jsx)("button",{type:"button",className:y().displayNameSaveButton,disabled:!m||_,onClick:()=>M(e,o),children:_?"Saving…":"Save"}),x&&(0,s.jsx)("button",{type:"button",className:y().displayNameClearButton,disabled:_,onClick:()=>M(e,""),children:"Reset to default"})]}),(0,s.jsx)("span",{className:y().displayNameStatus,children:x?(0,s.jsxs)(s.Fragment,{children:["Sending as"," ",(0,s.jsxs)("strong",{children:["“",p,"”"]})]}):(0,s.jsxs)(s.Fragment,{children:["Sending as default"," ",(0,s.jsxs)("strong",{children:["“",h,"”"]})]})})]})},...g.map(a=>{var t;let{key:n,label:r}=a,d=null!=(t=null==l?void 0:l[n])?t:null,c=((e,a,t)=>{if("owner_enabled"===t)return a&&null!=a.owner_enabled?a.owner_enabled?{on:!0,source:"explicit_on"}:{on:!1,source:"explicit_off"}:{on:!1,source:"unset"};if(!1===e[t])return{on:!1,source:"kill_switch"};let s=null==a?void 0:a[t];return!0===s?{on:!0,source:"explicit_on"}:!1===s?{on:!1,source:"explicit_off"}:e["default_listing_".concat(t)]?{on:!0,source:"default_on"}:{on:!1,source:"default_off"}})(e,l,n),o=z.has("".concat(e.id,":").concat(n)),_="owner_enabled"===n;return{label:r,value:(0,s.jsxs)("span",{className:y().agentToggleControl,children:[!_&&(0,s.jsxs)("span",{className:y().triStateGroup,children:[(0,s.jsx)("button",{type:"button",className:(0,i.A)(y().triStateButton,{[y().triStateButtonActive]:null===d}),disabled:o,onClick:()=>L(e,n,null),children:"Inherit"}),(0,s.jsx)("button",{type:"button",className:(0,i.A)(y().triStateButton,{[y().triStateButtonActive]:!0===d}),disabled:o,onClick:()=>L(e,n,!0),children:"On"}),(0,s.jsx)("button",{type:"button",className:(0,i.A)(y().triStateButton,{[y().triStateButtonActive]:!1===d}),disabled:o,onClick:()=>L(e,n,!1),children:"Off"})]}),(0,s.jsx)(u.A,{label:f[c.source],variant:(e=>"kill_switch"===e.source?"danger":"unset"===e.source?"warning":e.on?"success":"neutral")(c)})]})}})]}),(0,s.jsx)("p",{className:y().agentConfigPlaceholder,children:"No per-organization config overrides available for this agent."})]},e.id)})})]}):null})},8353:(e,a,t)=>{"use strict";t.d(a,{A:()=>i});var s=t(6029);t(55729);var l=t(50212),n=t(95727),r=t.n(n);let i=e=>{let{items:a,containerStyle:t}=e;return(0,s.jsx)("dl",{className:(0,l.A)(r().list,t),children:a.filter(e=>!e.hidden).map(e=>{var a;return(0,s.jsxs)("div",{className:(0,l.A)(r().row,e.emphasized&&r().row_emphasized),children:[(0,s.jsx)("dt",{className:r().label,children:e.label}),(0,s.jsxs)("dd",{className:r().value,children:[null!=(a=e.value)?a:"-",null!=e.sub&&(0,s.jsx)("span",{className:r().sub,children:e.sub})]})]},e.label)})})}},17520:(e,a,t)=>{"use strict";t.d(a,{w:()=>u});var s=t(6029),l=t(55729),n=t(82203),r=t.n(n),i=t(81278),d=t(79510),c=t(72040),o=t.n(c);let u=e=>{let{breadcrumbs:a,onBack:t,hideBackButton:n=!1,title:c,badges:u,actions:_,meta:b}=e,m=(0,i.useRouter)();(0,l.useEffect)(()=>{c&&(0,d.fF)(m.asPath,c)},[c,m.asPath]);let h=!!(c||u||_);return(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:o().header,children:[(0,s.jsx)("nav",{className:o().breadcrumbs,"aria-label":"Breadcrumb",children:(0,s.jsx)("ol",{className:o().breadcrumbList,children:a.map((e,t)=>{let l=t===a.length-1;return(0,s.jsxs)("li",{className:o().breadcrumbItem,children:[t>0&&(0,s.jsx)("span",{className:o().separator,"aria-hidden":"true",children:"/"}),l||!e.href?(0,s.jsx)("span",{className:o().breadcrumbCurrent,"aria-current":l?"page":void 0,children:e.label}):(0,s.jsx)(r(),{href:e.href,className:o().breadcrumbLink,children:e.label})]},t)})})}),!n&&(0,s.jsx)("button",{type:"button",onClick:()=>{t?t():m.back()},className:o().backButton,"aria-label":"Go back",children:"← Back"})]}),h&&(0,s.jsxs)("div",{className:o().titleStrip,children:[(0,s.jsxs)("div",{className:o().titleGroup,children:[c&&(0,s.jsx)("h1",{className:o().title,children:c}),u&&(0,s.jsx)("div",{className:o().badgeGroup,children:u})]}),_&&(0,s.jsx)("div",{className:o().titleActions,children:_})]}),b&&(0,s.jsx)("div",{className:o().meta,children:b})]})}},23224:(e,a,t)=>{"use strict";t.d(a,{A:()=>i});var s=t(6029);t(55729);var l=t(50212),n=t(96908),r=t.n(n);let i=e=>{let{title:a,actions:t,accent:n,fullWidth:i,containerStyle:d,children:c}=e;
1return(0,s.jsxs)("section",{className:(0,l.A)(r().card,n&&r()["card_".concat(n)],i&&r().card_fullWidth,d),children:[(a||t)&&(0,s.jsxs)("header",{className:r().header,children:[a&&(0,s.jsx)("h2",{className:r().title,children:a}),t&&(0,s.jsx)("div",{className:r().actions,children:t})]}),c]})}},53915:e=>{e.exports={container:"styles_container__Bk5tL",link:"styles_link__XI_bs"}},72040:e=>{e.exports={header:"styles_header__nbJwd",breadcrumbs:"styles_breadcrumbs__i2t89",breadcrumbList:"styles_breadcrumbList__abRPN",breadcrumbItem:"styles_breadcrumbItem__u4vIQ",separator:"styles_separator__iHrl0",breadcrumbLink:"styles_breadcrumbLink__U6mZO",breadcrumbCurrent:"styles_breadcrumbCurrent__pZLlw",titleStrip:"styles_titleStrip__zOoB_",titleGroup:"styles_titleGroup__7j8_I",title:"styles_title__U_qNz",badgeGroup:"styles_badgeGroup__B55no",titleActions:"styles_titleActions__lG9j5",meta:"styles_meta__iYqJl",backButton:"styles_backButton__CmXrz"}},79491:(e,a,t)=>{"use strict";t.d(a,{A:()=>d,v:()=>i});var s=t(6029);t(55729);var l=t(49609),n=t(53915),r=t.n(n);function i(e){let{id:a,label:t,href:n}=e;return(0,s.jsxs)("span",{className:r().container,children:[t&&"".concat(t,": "),n?(0,s.jsx)("a",{href:n,target:"_blank",rel:"noopener noreferrer",className:r().link,children:a}):a,(0,s.jsx)(l.A,{iconOnly:!0,textToCopy:a,iconSize:12,size:"small"})]})}let d=i},86925:(e,a,t)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/organizations/[id]/agents",function(){return t(1331)}])},95727:e=>{e.exports={list:"styles_list__HMAsj",row:"styles_row__RcSgq",row_emphasized:"styles_row_emphasized__kfQYd",label:"styles_label__rDmVV",value:"styles_value___6VOc",sub:"styles_sub__c6Llr"}},96908:e=>{e.exports={card:"styles_card__SUvjY",card_critical:"styles_card_critical__eIBSv",card_warning:"styles_card_warning__OzapS",card_success:"styles_card_success__IwScu",card_fullWidth:"styles_card_fullWidth__Y_71w",header:"styles_header__t3pZl",title:"styles_title__GwKqM",actions:"styles_actions__aH8ah"}}},e=>{e.O(0,[1530,7035,6651,1464,7651,5076,543,6656,540,8232,9434,9302,1571,8188,8937,636,6593,8792],()=>e(e.s=86925)),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.