Element API: how can I return entries via username?
Completely untested, but something like this should work:

'dealers/&lt;username:(.*)&gt;.json' =&gt; function($username) {
    $author = craft()-&gt;users-&gt;getUserByUsernameOrEmail($username);

    return [
        'elementType' =&gt; 'Entry',
        'criteria' =&gt; [
            'section' =&gt; 'listings',
            'authorId' =&gt; $author-&gt;id
        ],
        'paginate' =&gt; false,
        'transformer' =&gt; function(EntryModel $entry) {
            ...