Overview
POST/auth/change-passwordauth

Change password (revokes sessions)

Create a record in change-password.

Auth: bearerAuth — calls run as the authenticated user.

Request body

application/json · optional

  • currentPasswordstring
  • newPasswordstring
Example
{
  "currentPassword": "string",
  "newPassword": "string"
}
Responses
204

changed

No response body.

401

Error

  • erroroptionalobject
Example
{
  "error": {
    "message": "string",
    "code": "string"
  }
}
Code examples
cURL
curl -X POST "https://api.agenticdeveloperhub.com/auth/change-password" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "currentPassword": "string",
  "newPassword": "string"
}'
JavaScript
const res = await fetch("https://api.agenticdeveloperhub.com/auth/change-password", {
  method: "POST",
  headers: {
    "Authorization": "Bearer YOUR_TOKEN",
    "Content-Type": "application/json"
  },
  body: "{\n  \"currentPassword\": \"string\",\n  \"newPassword\": \"string\"\n}",
});
const data = await res.json();