mirror of
https://github.com/alkimake/paperclip.git
synced 2026-06-16 19:00:38 +09:00
Enforce 10-minute TTL for generated company invites
This commit is contained in:
parent
c3ac209e5f
commit
0f895a8cf9
6 changed files with 19 additions and 7 deletions
|
|
@ -69,7 +69,6 @@ export const accessApi = {
|
|||
companyId: string,
|
||||
input: {
|
||||
allowedJoinTypes?: "human" | "agent" | "both";
|
||||
expiresInHours?: number;
|
||||
defaultsPayload?: Record<string, unknown> | null;
|
||||
agentMessage?: string | null;
|
||||
} = {},
|
||||
|
|
|
|||
|
|
@ -78,8 +78,7 @@ export function CompanySettings() {
|
|||
const inviteMutation = useMutation({
|
||||
mutationFn: () =>
|
||||
accessApi.createCompanyInvite(selectedCompanyId!, {
|
||||
allowedJoinTypes: "agent",
|
||||
expiresInHours: 72
|
||||
allowedJoinTypes: "agent"
|
||||
}),
|
||||
onSuccess: async (invite) => {
|
||||
setInviteError(null);
|
||||
|
|
@ -320,7 +319,7 @@ export function CompanySettings() {
|
|||
<span className="text-xs text-muted-foreground">
|
||||
Generate an agent snippet for join flows.
|
||||
</span>
|
||||
<HintIcon text="Creates an agent-only invite (72h) and renders a copy-ready snippet." />
|
||||
<HintIcon text="Creates an agent-only invite (10m) and renders a copy-ready snippet." />
|
||||
</div>
|
||||
<div className="flex flex-wrap items-center gap-2">
|
||||
<Button
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue