To respond to the USERNAME_PASSWORD_REQUIRED flow state, the user initiates the usernamePassword.check action. The flow service calls the POST /{environmentId}/flows/{flowId} endpoint operation and uses the application/vnd.pingidentity.usernamePassword.check+json custom media type in the Content-type HTTP request header to identify the action.

The request body requires the username and password properties, which specify the user’s login credentials. In this workflow, if the usernamePassword.check action completes successfully, the flow proceeds to the next sign-on policy action. The flow status value of AGREEMENT_CONSENT_REQUIRED requires the user’s consent to the agreement.

The response includes a HAL link for the user.consent action as an option for this flow. This option is available because the sign-on policy includes the AGREEMENT policy action to prompt the user to consent to an agreement.