getDocumentObject is deprecated in favor of $modx->request->getResource() and this is not a public API method anyway, but rather a protected method used by the internal MODx engine. It should not be called directly in add-ons, but can be overridden by extensions (i.e. MyCMSClass extends modX).
getDocumentIdentifier is also deprecated in favor of $modx->request->getResourceIdentifier(), and is also a protected method (not for direct use in add-ons).
An alias is more than just a field on the resource; it is calculated now based on many factors, including content-type extensions, is it a container, and the parent aliases if alias paths are enabled.
You can easily do custom searches for any kind of object using the new xPDO-powered public API’s:
<?php
$resource = $modx->getObject('modResource', array(
'pagetitle' => $pagetitle,
'deleted' => 0,
'published' => 1,
));
?>
Use $modx->sendRedirect() to redirect to another page, or sendForward() to get the response from another page without another request (i.e. url stays the same as original request).
You can get an id from the full alias like so:
<?php
$docid = isset($modx->resourceMap['home/spfresponse.html'])
? $modx->resourceMap['home/spfresponse.html']
: $modx->config['error_page'];
?>
However, I do not understand how the same unique resource path would return different IDs since URL’s must be unique.