현재 테스트 및 로우데이타 구현하였고, 위젯이나 애드온으로 만들 계획입니다.
Google_Service_Analytics_RealtimeData Object ( [collection_key:protected] => rows [columnHeadersType:protected] => Google_Service_Analytics_RealtimeDataColumnHeaders [columnHeadersDataType:protected] => array [id] => https://www.googleapis.com/analytics/v3/data/realtime?ids=ga:20008646&dimensions=rt:pagePath,rt:country,rt:city,rt:referralPath&metrics=rt:activeUsers [kind] => analytics#realtimeData [profileInfoType:protected] => Google_Service_Analytics_RealtimeDataProfileInfo [profileInfoDataType:protected] => [queryType:protected] => Google_Service_Analytics_RealtimeDataQuery [queryDataType:protected] => [rows] => Array ( [0] => Array ( [0] => /board/2713298 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [1] => Array ( [0] => /board/2716520 [1] => South Korea [2] => Incheon [3] => (not set) [4] => 1 ) [2] => Array ( [0] => /board/3015250 [1] => South Korea [2] => Gwangju [3] => (not set) [4] => 1 ) [3] => Array ( [0] => /board/3139436 [1] => South Korea [2] => Busan [3] => (not set) [4] => 1 ) [4] => Array ( [0] => /board/3382842 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [5] => Array ( [0] => /board/3409386 [1] => South Korea [2] => Seoul [3] => /service/board/park/13008376 [4] => 1 ) [6] => Array ( [0] => /board/34735 [1] => South Korea [2] => Busan [3] => (not set) [4] => 1 ) [7] => Array ( [0] => /fourplace/3006412 [1] => South Korea [2] => Uijeongbu-si [3] => (not set) [4] => 1 ) [8] => Array ( [0] => /fourplace/3407083 [1] => South Korea [2] => Jincheon-gun [3] => (not set) [4] => 1 ) [9] => Array ( [0] => /hymn/2819704 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [10] => Array ( [0] => /hymn/3353335 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [11] => Array ( [0] => /hymn/3379502 [1] => South Korea [2] => Gimpo-si [3] => (not set) [4] => 1 ) [12] => Array ( [0] => /index.php?mid=hymn&listStyle=viewer&page=23&search_target=tag&search_keyword=새찬송가PPT&act=dispBoardDelete&document_srl=0 [1] => South Korea [2] => Namyangju-si [3] => (not set) [4] => 1 ) [13] => Array ( [0] => /index.php?mid=mopds&document_srl=188742&listStyle=viewer [1] => Ireland [2] => Dublin [3] => (not set) [4] => 1 ) [14] => Array ( [0] => /index.php?mid=mopds&document_srl=202223&listStyle=viewer [1] => Ireland [2] => Dublin [3] => (not set) [4] => 2 ) [15] => Array ( [0] => /index.php?mid=mopds&document_srl=2690923&listStyle=viewer [1] => Ireland [2] => Dublin [3] => (not set) [4] => 1 ) [16] => Array ( [0] => /index.php?mid=mopds&page=5469&document_srl=398 [1] => South Korea [2] => Gimhae-si [3] => (not set) [4] => 1 ) [17] => Array ( [0] => /mopds/184872 [1] => South Korea [2] => Namyangju-si [3] => (not set) [4] => 1 ) [18] => Array ( [0] => /mopds/188978 [1] => South Korea [2] => Daejeon [3] => (not set) [4] => 1 ) [19] => Array ( [0] => /mopds/191925 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [20] => Array ( [0] => /mopds/194413 [1] => Canada [2] => Toronto [3] => (not set) [4] => 1 ) [21] => Array ( [0] => /mopds/195521 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [22] => Array ( [0] => /mopds/200797 [1] => South Korea [2] => Daejeon [3] => (not set) [4] => 1 ) [23] => Array ( [0] => /mopds/209142 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [24] => Array ( [0] => /mopds/214604 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [25] => Array ( [0] => /mopds/215671 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [26] => Array ( [0] => /mopds/217505 [1] => United States [2] => Philadelphia [3] => (not set) [4] => 1 ) [27] => Array ( [0] => /mopds/226685 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [28] => Array ( [0] => /mopds/231845 [1] => South Korea [2] => Suncheon-si [3] => (not set) [4] => 1 ) [29] => Array ( [0] => /mopds/233773 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [30] => Array ( [0] => /mopds/234245 [1] => Canada [2] => Toronto [3] => (not set) [4] => 1 ) [31] => Array ( [0] => /mopds/234710 [1] => South Korea [2] => Busan [3] => (not set) [4] => 1 ) [32] => Array ( [0] => /mopds/234770 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [33] => Array ( [0] => /mopds/236716 [1] => South Korea [2] => Busan [3] => (not set) [4] => 1 ) [34] => Array ( [0] => /mopds/239439 [1] => South Korea [2] => Incheon [3] => (not set) [4] => 1 ) [35] => Array ( [0] => /mopds/2738860 [1] => South Korea [2] => Taean-gun [3] => (not set) [4] => 1 ) [36] => Array ( [0] => /mopds/2770192 [1] => South Korea [2] => Wonju-si [3] => (not set) [4] => 1 ) [37] => Array ( [0] => /mopds/2777208 [1] => South Korea [2] => Daegu [3] => (not set) [4] => 1 ) [38] => Array ( [0] => /mopds/2783224 [1] => United States [2] => New York [3] => (not set) [4] => 1 ) [39] => Array ( [0] => /mopds/2787966 [1] => United States [2] => Natick [3] => (not set) [4] => 1 ) [40] => Array ( [0] => /mopds/2919461 [1] => South Korea [2] => Daegu [3] => (not set) [4] => 1 ) [41] => Array ( [0] => /mopds/2965624?napp=mysection&naverapp_paddingtop=0 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [42] => Array ( [0] => /mopds/308719 [1] => South Korea [2] => Cheonan-si [3] => (not set) [4] => 1 ) [43] => Array ( [0] => /mopds/328629 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [44] => Array ( [0] => /mopds/33561 [1] => South Korea [2] => Daejeon [3] => (not set) [4] => 1 ) [45] => Array ( [0] => /mopds/3409206 [1] => South Korea [2] => Incheon [3] => (not set) [4] => 1 ) [46] => Array ( [0] => /mopds/35450 [1] => South Korea [2] => Seoul [3] => (not set) [4] => 1 ) [47] => Array ( [0] => /mopds/397403 [1] => United States [2] => Los Angeles [3] => (not set) [4] => 1 ) [48] => Array ( [0] => /mopds/398979 [1] => South Korea [2] => Daegu [3] => (not set) [4] => 1 ) [49] => Array ( [0] => /mopds/42317 [1] => South Korea [2] => Yangsan-si [3] => (not set) [4] => 1 ) ) .. .. .. .. ..
api 연동에 성공하면, 해당 데이터 형식으로 자료를 받을 수 있습니다.
장점으로는 구글에서 제공하는 실시간 접속자 현황이 바로 적용됩니다.
페이지 정보, 국가, 나라, 위도, 경도까지 한번에 7가지 정보를 가져올 수 있네요.
욕심껏 모든 자료를 가져오려고 했는데, 7개가 넘어가면 에러가 나옵니다.
실시간 제공되는 정보는
https://developers.google.com/analytics/devguides/reporting/realtime/dimsmets/?hl=ko
이 페이지에서 확인이 가능합니다.
단점은 하루 쿼리량이 제한되어 있습니다.
일단, 연동은 성공했으니 XE랑 연동하고 다시 글 올리겠습니다.