Alter Services JSON Response I have created a view to render all taxonomy terms and displayed it through a service. I have also created an endpoint in the service module to hit the url through firefox add-on RESTer to test the JSON response. Now I want to alter the JSON response to add more key and value programatically. I am sharing all my resources which I have used but nothing changed

This is my JSON response so far:
[
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/1\&quot;&gt;General discussion&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;1&quot;,
            &quot;description&quot;: &quot;&quot;
        },
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/2\&quot;&gt;Miscellaneous - Hangout forums&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;2&quot;,
            &quot;description&quot;: &quot;&quot;
        },
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/3\&quot;&gt;Debt Management and Debt Consolidation&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;3&quot;,
            &quot;description&quot;: &quot;&quot;
        },
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/6\&quot;&gt;Archive&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;6&quot;,
            &quot;description&quot;: &quot;&quot;
        }

But I want my JSON like this:
[
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/1\&quot;&gt;General discussion&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;1&quot;,
            &quot;description&quot;: &quot;&quot;,
            &quot;MY_CUSTOM_KEY&quot;: &quot;MY CUSTOM VALUE&quot;
        },
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/2\&quot;&gt;Miscellaneous - Hangout forums&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;2&quot;,
            &quot;description&quot;: &quot;&quot;,
            &quot;MY_CUSTOM_KEY&quot;: &quot;MY CUSTOM VALUE&quot;
        },
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/3\&quot;&gt;Debt Management and Debt Consolidation&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;3&quot;,
            &quot;description&quot;: &quot;&quot;,
            &quot;MY_CUSTOM_KEY&quot;: &quot;MY CUSTOM VALUE&quot;
        },
        {
            &quot;Name&quot;: &quot;&lt;a href=\&quot;/forum/6\&quot;&gt;Archive&lt;/a&gt;&quot;,
            &quot;tid&quot;: &quot;6&quot;,
            &quot;description&quot;: &quot;&quot;,
            &quot;MY_CUSTOM_KEY&quot;: &quot;MY CUSTOM VALUE&quot;
        }
]

I had used hook_views_pre_render to alter the JSON but couldn't get it:
function MY_MODULE_views_pre_render(&amp;$view) {
    if($view-&gt;name == 'MY_VIEW_NAME') {
        $results = &amp;$view-&gt;result;
        foreach($results as $key=&gt;$value) {
            $value-&gt;MY_CUSTOM_KEY= &quot;MY CUSTOM VALUE&quot;;
        }
    }
}
Try
foreach($results as $key =&gt; &amp;$value) {
    $value-&gt;MY_CUSTOM_KEY= &quot;MY CUSTOM VALUE&quot;;
}