Waiting for a request to finish inside a request

I have a code that requests data from another website (fetches links) and after I fetched the links, I will fetch some data from those links. So, I am trying to do 2 requests.

Here is the pseudocode I made.

[first request to the site]
..fetch links and data
....fetch more data from the fetched links
[done]

[another function to fetch data from the links fetched]
..fetch data
[return fetch data]

I am trying to have an output like this:

{
    "chimchar" : {
        "articles" : [{
            "id": id,
            "title": title,
            "url": url
        }]
    }
}

But the value for 'url' is not showing, I try to log it onto the console and the 'url''s value is undefined and it shows up after having made all the requests from the .getHome function.

And here is the code.

var cheerio = require('cheerio');
var requestify = require('requestify');

var _response;

/*
getHome
*/
exports.getHome = function(req, res) {
    requestify.get('http://chimchar.com').then(function(response) {
        var __response = processResponse(response);
        res.send(__response);
    });
}

/*
processResponse
*/
function processResponse(response) {
    var id = 0;
    var title, url;

    _response = {
        'chimchar': {
            'articles': []
        }
    };

    response.getBody();
    $ = cheerio.load(response.body);

    $('#scenesContainer .video_box').each(function() {

        $(this).find('img, a').each(function(i, elem) {
            if ($(this).is('img') && $(this).attr('style') == 'margin-top: 35px;')
                title = $(this).attr('alt');
            if ($(this).is('a') && $(this).attr('class') == 'link_block') {
                fetchPage($(this).attr('href'), function(returnValue) {
                    url = returnValue;
                    console.log(url);
                });
            }
        });

        _response.chimchar.articles.push({
            "id": id,
            "title": title,
            "url": url,
        });

        id = id + 1;
    });

    return _response;
}

var fetchPage = function(page, callback) {
    console.log('fetchPage');
    requestify.get('http://chimchar.com' + page).then(function(response) {
        var r;
        response.getBody();
        $ = cheerio.load(response.body);

        $('.play_video').each(function() {
            $(this).find('a').each(function(i, elem) {
                if ($(this).is('a') && $(this).text().indexOf('MP4') > -1) {
                    r = $(this).attr('href');
                    console.log(r);
                }
            });
        });

        console('fetchPage finished - ' + r);
        callback(r);
    });
};

I think

return _response;

fires earlier then url is obtained in your processResponse function

I think you need to use async, and code will look like this

function processResponse(response, callback) {
    async.each([items], function (item, cb) {
        doSomething(item, function () {
            //Make all operations with response
            cb(null, true)
        });
    },
    function (err, result) {
       callback(_response)
    })
}