• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5  margin: 0;
6  padding: 0;
7  border: 0;
8  font-weight: inherit;
9  font-style: inherit;
10  font-size: 100%;
11  font-family: inherit;
12  vertical-align: baseline;
13}
14
15body {
16  font-size: 13px;
17  padding: 1em;
18}
19
20h1 {
21  font-size: 26px;
22  margin-bottom: 1em;
23}
24
25h2 {
26  font-size: 24px;
27  margin-bottom: 1em;
28}
29
30h3 {
31  font-size: 20px;
32  margin-bottom: 1em;
33  margin-top: 1em;
34}
35
36pre, code {
37  line-height: 1.5;
38  font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42  margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46  font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50  border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54  margin-top: 0.5em;
55}
56
57.firstline {
58  margin-left: 2 em;
59}
60
61.method  {
62  margin-top: 1em;
63  border: solid 1px #CCC;
64  padding: 1em;
65  background: #EEE;
66}
67
68.details {
69  font-weight: bold;
70  font-size: 14px;
71}
72
73</style>
74
75<h1><a href="analytics_v3.html">Google Analytics API</a> . <a href="analytics_v3.management.html">management</a> . <a href="analytics_v3.management.experiments.html">experiments</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78  <code><a href="#delete">delete(accountId, webPropertyId, profileId, experimentId)</a></code></p>
79<p class="firstline">Delete an experiment.</p>
80<p class="toc_element">
81  <code><a href="#get">get(accountId, webPropertyId, profileId, experimentId)</a></code></p>
82<p class="firstline">Returns an experiment to which the user has access.</p>
83<p class="toc_element">
84  <code><a href="#insert">insert(accountId, webPropertyId, profileId, body)</a></code></p>
85<p class="firstline">Create a new experiment.</p>
86<p class="toc_element">
87  <code><a href="#list">list(accountId, webPropertyId, profileId, max_results=None, start_index=None)</a></code></p>
88<p class="firstline">Lists experiments to which the user has access.</p>
89<p class="toc_element">
90  <code><a href="#patch">patch(accountId, webPropertyId, profileId, experimentId, body)</a></code></p>
91<p class="firstline">Update an existing experiment. This method supports patch semantics.</p>
92<p class="toc_element">
93  <code><a href="#update">update(accountId, webPropertyId, profileId, experimentId, body)</a></code></p>
94<p class="firstline">Update an existing experiment.</p>
95<h3>Method Details</h3>
96<div class="method">
97    <code class="details" id="delete">delete(accountId, webPropertyId, profileId, experimentId)</code>
98  <pre>Delete an experiment.
99
100Args:
101  accountId: string, Account ID to which the experiment belongs (required)
102  webPropertyId: string, Web property ID to which the experiment belongs (required)
103  profileId: string, View (Profile) ID to which the experiment belongs (required)
104  experimentId: string, ID of the experiment to delete (required)
105</pre>
106</div>
107
108<div class="method">
109    <code class="details" id="get">get(accountId, webPropertyId, profileId, experimentId)</code>
110  <pre>Returns an experiment to which the user has access.
111
112Args:
113  accountId: string, Account ID to retrieve the experiment for. (required)
114  webPropertyId: string, Web property ID to retrieve the experiment for. (required)
115  profileId: string, View (Profile) ID to retrieve the experiment for. (required)
116  experimentId: string, Experiment ID to retrieve the experiment for. (required)
117
118Returns:
119  An object of the form:
120
121    { # JSON template for Analytics experiment resource.
122      "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
123      "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
124      "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
125      "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
126      "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
127      "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
128      "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
129      "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
130      "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
131      "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
132      "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
133          # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
134          # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
135          # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
136      "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
137      "updated": "A String", # Time the experiment was last modified. This field is read-only.
138      "description": "A String", # Notes about this experiment.
139      "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
140      "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
141      "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
142      "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
143      "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
144      "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
145      "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
146      "created": "A String", # Time the experiment was created. This field is read-only.
147      "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
148        {
149          "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
150          "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
151          "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
152          "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
153          "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
154        },
155      ],
156      "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
157      "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
158      "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
159        "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
160        "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
161      },
162      "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
163      "selfLink": "A String", # Link for this experiment. This field is read-only.
164    }</pre>
165</div>
166
167<div class="method">
168    <code class="details" id="insert">insert(accountId, webPropertyId, profileId, body)</code>
169  <pre>Create a new experiment.
170
171Args:
172  accountId: string, Account ID to create the experiment for. (required)
173  webPropertyId: string, Web property ID to create the experiment for. (required)
174  profileId: string, View (Profile) ID to create the experiment for. (required)
175  body: object, The request body. (required)
176    The object takes the form of:
177
178{ # JSON template for Analytics experiment resource.
179    "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
180    "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
181    "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
182    "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
183    "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
184    "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
185    "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
186    "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
187    "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
188    "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
189    "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
190        # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
191        # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
192        # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
193    "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
194    "updated": "A String", # Time the experiment was last modified. This field is read-only.
195    "description": "A String", # Notes about this experiment.
196    "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
197    "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
198    "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
199    "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
200    "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
201    "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
202    "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
203    "created": "A String", # Time the experiment was created. This field is read-only.
204    "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
205      {
206        "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
207        "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
208        "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
209        "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
210        "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
211      },
212    ],
213    "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
214    "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
215    "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
216      "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
217      "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
218    },
219    "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
220    "selfLink": "A String", # Link for this experiment. This field is read-only.
221  }
222
223
224Returns:
225  An object of the form:
226
227    { # JSON template for Analytics experiment resource.
228      "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
229      "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
230      "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
231      "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
232      "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
233      "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
234      "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
235      "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
236      "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
237      "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
238      "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
239          # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
240          # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
241          # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
242      "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
243      "updated": "A String", # Time the experiment was last modified. This field is read-only.
244      "description": "A String", # Notes about this experiment.
245      "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
246      "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
247      "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
248      "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
249      "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
250      "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
251      "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
252      "created": "A String", # Time the experiment was created. This field is read-only.
253      "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
254        {
255          "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
256          "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
257          "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
258          "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
259          "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
260        },
261      ],
262      "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
263      "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
264      "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
265        "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
266        "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
267      },
268      "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
269      "selfLink": "A String", # Link for this experiment. This field is read-only.
270    }</pre>
271</div>
272
273<div class="method">
274    <code class="details" id="list">list(accountId, webPropertyId, profileId, max_results=None, start_index=None)</code>
275  <pre>Lists experiments to which the user has access.
276
277Args:
278  accountId: string, Account ID to retrieve experiments for. (required)
279  webPropertyId: string, Web property ID to retrieve experiments for. (required)
280  profileId: string, View (Profile) ID to retrieve experiments for. (required)
281  max_results: integer, The maximum number of experiments to include in this response.
282  start_index: integer, An index of the first experiment to retrieve. Use this parameter as a pagination mechanism along with the max-results parameter.
283
284Returns:
285  An object of the form:
286
287    { # An experiment collection lists Analytics experiments to which the user has access. Each view (profile) can have a set of experiments. Each resource in the Experiment collection corresponds to a single Analytics experiment.
288    "username": "A String", # Email ID of the authenticated user
289    "kind": "analytics#experiments", # Collection type.
290    "items": [ # A list of experiments.
291      { # JSON template for Analytics experiment resource.
292          "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
293          "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
294          "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
295          "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
296          "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
297          "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
298          "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
299          "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
300          "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
301          "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
302          "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
303              # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
304              # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
305              # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
306          "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
307          "updated": "A String", # Time the experiment was last modified. This field is read-only.
308          "description": "A String", # Notes about this experiment.
309          "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
310          "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
311          "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
312          "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
313          "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
314          "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
315          "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
316          "created": "A String", # Time the experiment was created. This field is read-only.
317          "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
318            {
319              "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
320              "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
321              "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
322              "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
323              "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
324            },
325          ],
326          "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
327          "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
328          "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
329            "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
330            "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
331          },
332          "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
333          "selfLink": "A String", # Link for this experiment. This field is read-only.
334        },
335    ],
336    "itemsPerPage": 42, # The maximum number of resources the response can contain, regardless of the actual number of resources returned. Its value ranges from 1 to 1000 with a value of 1000 by default, or otherwise specified by the max-results query parameter.
337    "previousLink": "A String", # Link to previous page for this experiment collection.
338    "startIndex": 42, # The starting index of the resources, which is 1 by default or otherwise specified by the start-index query parameter.
339    "nextLink": "A String", # Link to next page for this experiment collection.
340    "totalResults": 42, # The total number of results for the query, regardless of the number of resources in the result.
341  }</pre>
342</div>
343
344<div class="method">
345    <code class="details" id="patch">patch(accountId, webPropertyId, profileId, experimentId, body)</code>
346  <pre>Update an existing experiment. This method supports patch semantics.
347
348Args:
349  accountId: string, Account ID of the experiment to update. (required)
350  webPropertyId: string, Web property ID of the experiment to update. (required)
351  profileId: string, View (Profile) ID of the experiment to update. (required)
352  experimentId: string, Experiment ID of the experiment to update. (required)
353  body: object, The request body. (required)
354    The object takes the form of:
355
356{ # JSON template for Analytics experiment resource.
357    "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
358    "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
359    "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
360    "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
361    "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
362    "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
363    "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
364    "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
365    "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
366    "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
367    "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
368        # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
369        # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
370        # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
371    "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
372    "updated": "A String", # Time the experiment was last modified. This field is read-only.
373    "description": "A String", # Notes about this experiment.
374    "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
375    "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
376    "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
377    "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
378    "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
379    "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
380    "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
381    "created": "A String", # Time the experiment was created. This field is read-only.
382    "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
383      {
384        "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
385        "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
386        "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
387        "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
388        "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
389      },
390    ],
391    "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
392    "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
393    "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
394      "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
395      "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
396    },
397    "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
398    "selfLink": "A String", # Link for this experiment. This field is read-only.
399  }
400
401
402Returns:
403  An object of the form:
404
405    { # JSON template for Analytics experiment resource.
406      "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
407      "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
408      "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
409      "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
410      "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
411      "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
412      "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
413      "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
414      "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
415      "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
416      "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
417          # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
418          # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
419          # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
420      "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
421      "updated": "A String", # Time the experiment was last modified. This field is read-only.
422      "description": "A String", # Notes about this experiment.
423      "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
424      "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
425      "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
426      "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
427      "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
428      "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
429      "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
430      "created": "A String", # Time the experiment was created. This field is read-only.
431      "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
432        {
433          "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
434          "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
435          "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
436          "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
437          "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
438        },
439      ],
440      "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
441      "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
442      "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
443        "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
444        "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
445      },
446      "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
447      "selfLink": "A String", # Link for this experiment. This field is read-only.
448    }</pre>
449</div>
450
451<div class="method">
452    <code class="details" id="update">update(accountId, webPropertyId, profileId, experimentId, body)</code>
453  <pre>Update an existing experiment.
454
455Args:
456  accountId: string, Account ID of the experiment to update. (required)
457  webPropertyId: string, Web property ID of the experiment to update. (required)
458  profileId: string, View (Profile) ID of the experiment to update. (required)
459  experimentId: string, Experiment ID of the experiment to update. (required)
460  body: object, The request body. (required)
461    The object takes the form of:
462
463{ # JSON template for Analytics experiment resource.
464    "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
465    "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
466    "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
467    "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
468    "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
469    "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
470    "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
471    "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
472    "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
473    "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
474    "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
475        # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
476        # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
477        # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
478    "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
479    "updated": "A String", # Time the experiment was last modified. This field is read-only.
480    "description": "A String", # Notes about this experiment.
481    "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
482    "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
483    "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
484    "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
485    "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
486    "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
487    "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
488    "created": "A String", # Time the experiment was created. This field is read-only.
489    "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
490      {
491        "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
492        "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
493        "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
494        "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
495        "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
496      },
497    ],
498    "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
499    "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
500    "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
501      "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
502      "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
503    },
504    "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
505    "selfLink": "A String", # Link for this experiment. This field is read-only.
506  }
507
508
509Returns:
510  An object of the form:
511
512    { # JSON template for Analytics experiment resource.
513      "trafficCoverage": 3.14, # A floating-point number in (0, 1]. Specifies the fraction of the traffic that participates in the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
514      "webPropertyId": "A String", # Web property ID to which this experiment belongs. The web property ID is of the form UA-XXXXX-YY. This field is read-only.
515      "optimizationType": "A String", # Whether the objectiveMetric should be minimized or maximized. Possible values: "MAXIMUM", "MINIMUM". Optional--defaults to "MAXIMUM". Cannot be specified without objectiveMetric. Cannot be modified when status is "RUNNING" or "ENDED".
516      "objectiveMetric": "A String", # The metric that the experiment is optimizing. Valid values: "ga:goal(n)Completions", "ga:adsenseAdsClicks", "ga:adsenseAdsViewed", "ga:adsenseRevenue", "ga:bounces", "ga:pageviews", "ga:sessionDuration", "ga:transactions", "ga:transactionRevenue". This field is required if status is "RUNNING" and servingFramework is one of "REDIRECT" or "API".
517      "id": "A String", # Experiment ID. Required for patch and update. Disallowed for create.
518      "equalWeighting": True or False, # Boolean specifying whether to distribute traffic evenly across all variations. If the value is False, content experiments follows the default behavior of adjusting traffic dynamically based on variation performance. Optional -- defaults to False. This field may not be changed for an experiment whose status is ENDED.
519      "accountId": "A String", # Account ID to which this experiment belongs. This field is read-only.
520      "snippet": "A String", # The snippet of code to include on the control page(s). This field is read-only.
521      "editableInGaUi": True or False, # If true, the end user will be able to edit the experiment via the Google Analytics user interface.
522      "rewriteVariationUrlsAsOriginal": True or False, # Boolean specifying whether variations URLS are rewritten to match those of the original. This field may not be changed for an experiments whose status is ENDED.
523      "servingFramework": "A String", # The framework used to serve the experiment variations and evaluate the results. One of:
524          # - REDIRECT: Google Analytics redirects traffic to different variation pages, reports the chosen variation and evaluates the results.
525          # - API: Google Analytics chooses and reports the variation to serve and evaluates the results; the caller is responsible for serving the selected variation.
526          # - EXTERNAL: The variations will be served externally and the chosen variation reported to Google Analytics. The caller is responsible for serving the selected variation and evaluating the results.
527      "status": "A String", # Experiment status. Possible values: "DRAFT", "READY_TO_RUN", "RUNNING", "ENDED". Experiments can be created in the "DRAFT", "READY_TO_RUN" or "RUNNING" state. This field is required when creating an experiment.
528      "updated": "A String", # Time the experiment was last modified. This field is read-only.
529      "description": "A String", # Notes about this experiment.
530      "reasonExperimentEnded": "A String", # Why the experiment ended. Possible values: "STOPPED_BY_USER", "WINNER_FOUND", "EXPERIMENT_EXPIRED", "ENDED_WITH_NO_WINNER", "GOAL_OBJECTIVE_CHANGED". "ENDED_WITH_NO_WINNER" means that the experiment didn't expire but no winner was projected to be found. If the experiment status is changed via the API to ENDED this field is set to STOPPED_BY_USER. This field is read-only.
531      "internalWebPropertyId": "A String", # Internal ID for the web property to which this experiment belongs. This field is read-only.
532      "winnerConfidenceLevel": 3.14, # A floating-point number in (0, 1). Specifies the necessary confidence level to choose a winner. This field may not be changed for an experiments whose status is ENDED.
533      "startTime": "A String", # The starting time of the experiment (the time the status changed from READY_TO_RUN to RUNNING). This field is present only if the experiment has started. This field is read-only.
534      "winnerFound": True or False, # Boolean specifying whether a winner has been found for this experiment. This field is read-only.
535      "kind": "analytics#experiment", # Resource type for an Analytics experiment. This field is read-only.
536      "name": "A String", # Experiment name. This field may not be changed for an experiment whose status is ENDED. This field is required when creating an experiment.
537      "created": "A String", # Time the experiment was created. This field is read-only.
538      "variations": [ # Array of variations. The first variation in the array is the original. The number of variations may not change once an experiment is in the RUNNING state. At least two variations are required before status can be set to RUNNING.
539        {
540          "status": "A String", # Status of the variation. Possible values: "ACTIVE", "INACTIVE". INACTIVE variations are not served. This field may not be changed for an experiment whose status is ENDED.
541          "url": "A String", # The URL of the variation. This field may not be changed for an experiment whose status is RUNNING or ENDED.
542          "won": True or False, # True if the experiment has ended and this variation performed (statistically) significantly better than the original. This field is read-only.
543          "name": "A String", # The name of the variation. This field is required when creating an experiment. This field may not be changed for an experiment whose status is ENDED.
544          "weight": 3.14, # Weight that this variation should receive. Only present if the experiment is running. This field is read-only.
545        },
546      ],
547      "minimumExperimentLengthInDays": 42, # An integer number in [3, 90]. Specifies the minimum length of the experiment. Can be changed for a running experiment. This field may not be changed for an experiments whose status is ENDED.
548      "profileId": "A String", # View (Profile) ID to which this experiment belongs. This field is read-only.
549      "parentLink": { # Parent link for an experiment. Points to the view (profile) to which this experiment belongs.
550        "href": "A String", # Link to the view (profile) to which this experiment belongs. This field is read-only.
551        "type": "analytics#profile", # Value is "analytics#profile". This field is read-only.
552      },
553      "endTime": "A String", # The ending time of the experiment (the time the status changed from RUNNING to ENDED). This field is present only if the experiment has ended. This field is read-only.
554      "selfLink": "A String", # Link for this experiment. This field is read-only.
555    }</pre>
556</div>
557
558</body></html>