I have the following self-invoked function which is being utilized by the other functions across the app:

```
var Api = (function() {
  var requestPayload;
  var responsePayload;

  return {
    getRequestPayload: function() {
      return requestPayload;
    },
    setRequestPayload: function(newPayloadStr) {
      requestPayload = JSON.parse(newPayloadStr);
    },
    getResponsePayload: function() { // <-Function's output I need
      return responsePayload;
    },
    setResponsePayload: function(newPayloadStr) {
      responsePayload = JSON.parse(newPayloadStr);
    }
  };           
}());

```

This function is called by other functions in the app like:

```
Api.getResponsePayload();

```

I want to capture the output of `getResponsePayload` function every time this function is called to utilize is for further processing. 

I tried to create another function:

```
function runMe(responsePayload) {
    console.log(responsePayload)
}

```

And it gets called everytime `getResponsePayload` function is called but the output I'm getting is `undefined`:

```
getResponsePayload: function() {
    runMe();
return responsePayload;

```

How can I get the output of `getResponsePayload` function everytime it gets called by any other function in the app?