def on_post(self, req, resp):
        """ Validate the access token request for spec compliance

        The spec also dictates the JSON based error response
        on failure & is handled in this responder.
        """

        grant_type = req.get_param('grant_type')
        password = req.get_param('password')
        username = req.get_param('username')

        # errors or not, disable client caching along the way
        # per the spec
        resp.disable_caching()

        if not grant_type or not password or not username:
            resp.status = falcon.HTTP_400
            resp.serialize({
                'error': 'invalid_request',
                'error_description': 'A grant_type, username, & password '
                                     'parameters are all required when '
                                     'requesting an OAuth access_token',
                'error_uri': 'tools.ietf.org/html/rfc6749#section-4.3.2',
            })
        elif grant_type != 'password':
            resp.status = falcon.HTTP_400
            resp.serialize({
                'error': 'unsupported_grant_type',
                'error_description': 'The grant_type parameter MUST be set '
                                     'to "password" not "%s"' % grant_type,
                'error_uri': 'tools.ietf.org/html/rfc6749#section-4.3.2',
            })
        else:
            try:
                token = self.auth_creds(username, password)
                resp.serialize({
                    'access_token': token,
                    'token_type': 'Bearer',
                })
            except AuthRejected as exc:
                resp.status = falcon.HTTP_401
                resp.set_header('WWW-Authenticate', self._realm)
                resp.serialize({
                    'error': 'invalid_client',
                    'error_description': exc.detail,
                })
Validate the access token request for spec compliance

        The spec also dictates the JSON based error response
        on failure & is handled in this responder.