auth

Request password reset (OTP)

When projectId is provided, sends a 6-digit OTP to the user's email (app reset uses OTP, not link). When projectId is omitted, sends a token link (org/platform local account). Rate limited.

POST/api/auth/local/password-reset

Authentication

Public — No Auth Required

Request Body

Email and optional projectId for app OTP or org token link.

json
{
  "email": "user@example.com",
  "projectId": "685ad30be129932fbb7a1047"
}
{
  "email": "user@example.com",
  "projectId": "685ad30be129932fbb7a1047"
}

SDK setup

Create a client instance. No authentication is required for this endpoint.

import { MudbaseClient } from "mudbase";

const client = new MudbaseClient();
import { MudbaseClient } from "mudbase";

const client = new MudbaseClient();

Example request

Call this endpoint using the client from SDK setup. Use View HTTP for a raw cURL example.

const result = await client.auth.requestPasswordReset({
  email: "caitlyn.jaskolski@northwind.dev",
  projectId: "proj_BueWaPaumHCI"
});
const result = await client.auth.requestPasswordReset({
  email: "caitlyn.jaskolski@northwind.dev",
  projectId: "proj_BueWaPaumHCI"
});

Try It Live

Test this endpoint with your own credentials. Your requests will be sent to the live API.

No Request Yet

Send a request to see the full inspector

Responses

200OTP or reset email sent (generic message to prevent enumeration)
json
{
  "message": "If an account exists, a verification code has been sent to your email"
}
{
  "message": "If an account exists, a verification code has been sent to your email"
}
400Bad request or validation error.
401Authentication required or invalid token.
403Access denied or insufficient permissions.
404Project not found (exact backend message).
429Too many requests (rate limit)
500Internal server error.

Errors

CodeMeaning
400Bad request or validation error.
401Authentication required or invalid token.
403Access denied or insufficient permissions.
404Project not found (exact backend message).
429Too many requests (rate limit)
500Internal server error.
Edit this page on GitHub