id: orpc-error-required language: typescript severity: error message: Use ORPCError instead of Error in API procedures for proper error handling note: | In oRPC procedures, always use ORPCError from @orpc/server to ensure errors are properly serialized with correct HTTP status codes. Example: throw new ORPCError("BAD_REQUEST", { message: "..." }); Available error codes: UNAUTHORIZED, FORBIDDEN, BAD_REQUEST, NOT_FOUND, INTERNAL_SERVER_ERROR, etc. rule: pattern: throw new Error($MSG) inside: kind: arrow_function stopBy: end files: - "apps/api-server/src/procedures/**/*.ts" - "apps/api-server/src/router.ts"