openapi: 3.2.0 info: title: User Management Service Password API version: 1.0.0 description: Endpoints to manage user password servers: - url: /airmdrapi tags: - name: Password description: Endpoints to manage user password paths: /set_password: post: tags: - Password operationId: setPasswordAPI summary: set password description: Sets password for an account. parameters: - name: User-ID in: header description: The User ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: Organization-ID in: header description: The Organization ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: X-Request-ID in: header description: The ID associated with the request. If requests are made through API Gateway, this header will be pre filled. schema: type: string security: - SessionCookie: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/SetPasswordRequest' responses: '200': description: password updated successfully content: application/json: schema: $ref: '#/components/schemas/SetPasswordResponse' default: description: unexpected error content: application/json: schema: $ref: '#/components/schemas/Error' /forgot_password: post: tags: - Password operationId: forgotPasswordAPI summary: forgot password description: Updates password for an account. parameters: - name: User-ID in: header description: The User ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: Organization-ID in: header description: The Organization ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: X-Request-ID in: header description: The ID associated with the request. If requests are made through API Gateway, this header will be pre filled. schema: type: string security: - SessionCookie: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/ForgetPasswordRequest' responses: '200': description: forgot password request sent successfully content: application/json: schema: $ref: '#/components/schemas/ForgotPasswordResponse' default: description: unexpected error content: application/json: schema: $ref: '#/components/schemas/Error' /change_password: post: tags: - Password operationId: changePasswordAPI summary: change password description: Changes password for an account. parameters: - name: User-ID in: header description: The User ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: Organization-ID in: header description: The Organization ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: X-Request-ID in: header description: The ID associated with the request. If requests are made through API Gateway, this header will be pre filled. schema: type: string security: - SessionCookie: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/ChangePasswordRequest' responses: '200': description: password changed successfully content: application/json: schema: $ref: '#/components/schemas/Success' default: description: unexpected error content: application/json: schema: $ref: '#/components/schemas/Error' /force_password_reset: post: tags: - Password operationId: forcePasswordResetAPI summary: force password reset description: Resets password for an account. This action can only be performed by superadmin or admin accounts. parameters: - name: User-ID in: header description: The User ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: Organization-ID in: header description: The Organization ID of the requestor. If requests are made through API Gateway, this header will be pre filled. schema: type: string - name: X-Request-ID in: header description: The ID associated with the request. If requests are made through API Gateway, this header will be pre filled. schema: type: string security: - SessionCookie: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/ForcePasswordResetRequest' responses: '200': description: password reset successfully content: application/json: schema: $ref: '#/components/schemas/Success' default: description: unexpected error content: application/json: schema: $ref: '#/components/schemas/Error' components: schemas: ForgotPasswordData: type: object required: - id properties: id: type: string SetPasswordRequest: type: object required: - email_id - password - token - action properties: email_id: type: string password: type: string token: type: string action: type: string SetPasswordResponse: type: object required: - data - message properties: message: type: string data: $ref: '#/components/schemas/SetPasswordData' ForgetPasswordRequest: type: object required: - email_id properties: email_id: type: string skip_email: type: boolean description: If true, the reset link is generated but no email is sent SetPasswordData: type: object required: - id properties: id: type: string ForcePasswordResetRequest: type: object required: - email properties: email: type: string ForgotPasswordResponse: type: object required: - data - message properties: message: type: string data: $ref: '#/components/schemas/ForgotPasswordData' ChangePasswordRequest: type: object required: - current_password - new_password properties: current_password: type: string new_password: type: string Error: type: object required: - message properties: message: type: string description: user friendly error message Success: type: object required: - message properties: message: type: string description: user friendly message securitySchemes: SessionCookie: type: apiKey in: cookie name: Session x-tagGroups: - name: Included APIs tags: - Organization - User - User Group - Token - Permission