Skip to content

Commit

Permalink
Limit 178fcf913a API access to conversations (#2408)
Browse files Browse the repository at this point in the history
  • Loading branch information
spolu authored Nov 6, 2023
1 parent b9ee53e commit 64d219e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions front/pages/api/v1/w/[wId]/assistant/conversations/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,17 @@ async function handler(
});
}

if (owner.sId === "178fcf913a") {
return apiError(req, res, {
status_code: 400,
api_error: {
type: "invalid_request_error",
message:
"You exceedded the rate limit for API access. Please contact team@dust.tt.",
},
});
}

switch (req.method) {
case "POST":
const bodyValidation = PostConversationsRequestBodySchema.decode(
Expand Down

0 comments on commit 64d219e

Please sign in to comment.