669 lines
106 KiB
HTML
669 lines
106 KiB
HTML
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html><head><title>Python: class Resource</title>
|
|
</head><body bgcolor="#f0f0f8">
|
|
<p>
|
|
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
|
<tr bgcolor="#ffc8d8">
|
|
<td colspan=3 valign=bottom> <br>
|
|
<font color="#000000" face="helvetica, arial"><a name="Resource">class <strong>Resource</strong></a>(<a href="__builtin__.html#object">__builtin__.object</a>)</font></td></tr>
|
|
|
|
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
|
<td colspan=2><tt>A class for interacting with a resource.<br> </tt></td></tr>
|
|
<tr><td> </td>
|
|
<td width="100%">Methods defined here:<br>
|
|
<dl><dt><a name="Resource-__init__"><strong>__init__</strong></a>(self)</dt></dl>
|
|
|
|
<dl><dt><a name="Resource-get"><strong>get</strong></a> = method(self, **kwargs)</dt><dd><tt>Expands a short URL or gets creation time and analytics.<br>
|
|
<br>
|
|
Args:<br>
|
|
projection: string, Additional information to return.<br>
|
|
Allowed values<br>
|
|
ANALYTICS_CLICKS - Returns only click counts.<br>
|
|
ANALYTICS_TOP_STRINGS - Returns only top string counts.<br>
|
|
FULL - Returns the creation timestamp and all available analytics.<br>
|
|
shortUrl: string, The short URL, including the protocol. (required)<br>
|
|
<br>
|
|
Returns:<br>
|
|
An object of the form<br>
|
|
<br>
|
|
{<br>
|
|
"status": "A String", # Status of the target URL. Possible values: "OK", "MALWARE", "PHISHING", or "REMOVED". A URL might be marked "REMOVED" if it was flagged as spam, for example.<br>
|
|
"kind": "urlshortener#url", # The fixed string "urlshortener#url".<br>
|
|
"created": "A String", # Time the short URL was created; ISO 8601 representation using the yyyy-MM-dd'T'HH:mm:ss.SSSZZ format, e.g. "2010-10-14T19:01:24.944+00:00".<br>
|
|
"analytics": { # A summary of the click analytics for the short and long URL. Might not be present if not requested or currently unavailable.<br>
|
|
"week": { # Click analytics over the last week.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"allTime": { # Click analytics over all time.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"twoHours": { # Click analytics over the last two hours.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"day": { # Click analytics over the last day.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"month": { # Click analytics over the last month.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
},<br>
|
|
"longUrl": "A String", # Long URL, e.g. "<a href="http://www.google.com/">http://www.google.com/</a>". Might not be present if the status is "REMOVED".<br>
|
|
"id": "A String", # Short URL, e.g. "<a href="http://goo.gl/l6MS">http://goo.gl/l6MS</a>".<br>
|
|
}</tt></dd></dl>
|
|
|
|
<dl><dt><a name="Resource-insert"><strong>insert</strong></a> = method(self, **kwargs)</dt><dd><tt>Creates a new short URL.<br>
|
|
<br>
|
|
Args:<br>
|
|
body: object, The request body. (required)<br>
|
|
The object takes the form of:<br>
|
|
<br>
|
|
{<br>
|
|
"status": "A String", # Status of the target URL. Possible values: "OK", "MALWARE", "PHISHING", or "REMOVED". A URL might be marked "REMOVED" if it was flagged as spam, for example.<br>
|
|
"kind": "urlshortener#url", # The fixed string "urlshortener#url".<br>
|
|
"created": "A String", # Time the short URL was created; ISO 8601 representation using the yyyy-MM-dd'T'HH:mm:ss.SSSZZ format, e.g. "2010-10-14T19:01:24.944+00:00".<br>
|
|
"analytics": { # A summary of the click analytics for the short and long URL. Might not be present if not requested or currently unavailable.<br>
|
|
"week": { # Click analytics over the last week.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"allTime": { # Click analytics over all time.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"twoHours": { # Click analytics over the last two hours.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"day": { # Click analytics over the last day.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"month": { # Click analytics over the last month.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
},<br>
|
|
"longUrl": "A String", # Long URL, e.g. "<a href="http://www.google.com/">http://www.google.com/</a>". Might not be present if the status is "REMOVED".<br>
|
|
"id": "A String", # Short URL, e.g. "<a href="http://goo.gl/l6MS">http://goo.gl/l6MS</a>".<br>
|
|
}<br>
|
|
<br>
|
|
<br>
|
|
Returns:<br>
|
|
An object of the form<br>
|
|
<br>
|
|
{<br>
|
|
"status": "A String", # Status of the target URL. Possible values: "OK", "MALWARE", "PHISHING", or "REMOVED". A URL might be marked "REMOVED" if it was flagged as spam, for example.<br>
|
|
"kind": "urlshortener#url", # The fixed string "urlshortener#url".<br>
|
|
"created": "A String", # Time the short URL was created; ISO 8601 representation using the yyyy-MM-dd'T'HH:mm:ss.SSSZZ format, e.g. "2010-10-14T19:01:24.944+00:00".<br>
|
|
"analytics": { # A summary of the click analytics for the short and long URL. Might not be present if not requested or currently unavailable.<br>
|
|
"week": { # Click analytics over the last week.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"allTime": { # Click analytics over all time.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"twoHours": { # Click analytics over the last two hours.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"day": { # Click analytics over the last day.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"month": { # Click analytics over the last month.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
},<br>
|
|
"longUrl": "A String", # Long URL, e.g. "<a href="http://www.google.com/">http://www.google.com/</a>". Might not be present if the status is "REMOVED".<br>
|
|
"id": "A String", # Short URL, e.g. "<a href="http://goo.gl/l6MS">http://goo.gl/l6MS</a>".<br>
|
|
}</tt></dd></dl>
|
|
|
|
<dl><dt><a name="Resource-list"><strong>list</strong></a> = method(self, **kwargs)</dt><dd><tt>Retrieves a list of URLs shortened by a user.<br>
|
|
<br>
|
|
Args:<br>
|
|
start_token: string, Token for requesting successive pages of results.<br>
|
|
projection: string, Additional information to return.<br>
|
|
Allowed values<br>
|
|
ANALYTICS_CLICKS - Returns short URL click counts.<br>
|
|
FULL - Returns short URL click counts.<br>
|
|
<br>
|
|
Returns:<br>
|
|
An object of the form<br>
|
|
<br>
|
|
{<br>
|
|
"nextPageToken": "A String", # A token to provide to get the next page of results.<br>
|
|
"items": [ # A list of URL resources.<br>
|
|
{<br>
|
|
"status": "A String", # Status of the target URL. Possible values: "OK", "MALWARE", "PHISHING", or "REMOVED". A URL might be marked "REMOVED" if it was flagged as spam, for example.<br>
|
|
"kind": "urlshortener#url", # The fixed string "urlshortener#url".<br>
|
|
"created": "A String", # Time the short URL was created; ISO 8601 representation using the yyyy-MM-dd'T'HH:mm:ss.SSSZZ format, e.g. "2010-10-14T19:01:24.944+00:00".<br>
|
|
"analytics": { # A summary of the click analytics for the short and long URL. Might not be present if not requested or currently unavailable.<br>
|
|
"week": { # Click analytics over the last week.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"allTime": { # Click analytics over all time.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"twoHours": { # Click analytics over the last two hours.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"day": { # Click analytics over the last day.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
"month": { # Click analytics over the last month.<br>
|
|
"shortUrlClicks": "A String", # Number of clicks on this short URL.<br>
|
|
"countries": [ # Top countries (expressed as country codes), e.g. "US" or "DE"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"platforms": [ # Top platforms or OSes, e.g. "Windows"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"browsers": [ # Top browsers, e.g. "Chrome"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"referrers": [ # Top referring hosts, e.g. "www.google.com"; sorted by (descending) click counts. Only present if this data is available.<br>
|
|
{<br>
|
|
"count": "A String", # Number of clicks for this top entry, e.g. for this particular country or browser.<br>
|
|
"id": "A String", # Label assigned to this top entry, e.g. "US" or "Chrome".<br>
|
|
},<br>
|
|
],<br>
|
|
"longUrlClicks": "A String", # Number of clicks on all goo.gl short URLs pointing to this long URL.<br>
|
|
},<br>
|
|
},<br>
|
|
"longUrl": "A String", # Long URL, e.g. "<a href="http://www.google.com/">http://www.google.com/</a>". Might not be present if the status is "REMOVED".<br>
|
|
"id": "A String", # Short URL, e.g. "<a href="http://goo.gl/l6MS">http://goo.gl/l6MS</a>".<br>
|
|
},<br>
|
|
],<br>
|
|
"kind": "urlshortener#urlHistory", # The fixed string "urlshortener#urlHistory".<br>
|
|
"itemsPerPage": 42, # Number of items returned with each full "page" of results. Note that the last page could have fewer items than the "itemsPerPage" value.<br>
|
|
"totalItems": 42, # Total number of short URLs associated with this user (may be approximate).<br>
|
|
}</tt></dd></dl>
|
|
|
|
<hr>
|
|
Data descriptors defined here:<br>
|
|
<dl><dt><strong>__dict__</strong></dt>
|
|
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
|
</dl>
|
|
<dl><dt><strong>__weakref__</strong></dt>
|
|
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
|
</dl>
|
|
</td></tr></table>
|
|
</body></html> |