How to get Caller Id from Asterisk using php?

I want to get the Caller Id from Asterisk in php.
Right now, I am able to call to any SIP Account in Asterisk but unable to find any link for getting Caller Id.

I have followed this example but this doesn’t come out fruitful.

In AGI: $agi->request[‘agi_callerid’] … l#$request

In AMI: so many event contain the CallerID property. … AMI+Events