Quantcast
Viewing all articles
Browse latest Browse all 13117

Re: Can I filter Visitor Log by CustomVariable dynamically?

I ended up hitting the Live API with this URL:

$api_url = 'http://'.$config->ANALYTICS_URL.'/'.
	'?module=API&method=Live.getLastVisitsDetails'.
	'&idSite='.$config->ANALYTICS_SITE_ID.
	'&date=today&period=week'.
	'&segment=customVariableName1=@User;customVariableValue1=@-'.$customer_id.'-'.
	'&token_auth='.$config->ANALYTICS_USER_TOKEN.
	'&format=PHP';

I set the $customer_id as part of the value for customVariable 1
(note the "-" signs around $customer_id - I don't want every record containing 10 when looking for customer with id=10)

I then un-serialize the data and display it in our interface.

However, this is still not real time - I get delayed data which is annoying. Is there a way to tell the API not to use the cache but get the raw data instead?

Viewing all articles
Browse latest Browse all 13117

Trending Articles