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="firebasehosting_v1beta1.html">Firebase Hosting API</a> . <a href="firebasehosting_v1beta1.sites.html">sites</a> . <a href="firebasehosting_v1beta1.sites.versions.html">versions</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78  <code><a href="firebasehosting_v1beta1.sites.versions.files.html">files()</a></code>
79</p>
80<p class="firstline">Returns the files Resource.</p>
81
82<p class="toc_element">
83  <code><a href="#create">create(parent, body, versionId=None, x__xgafv=None, sizeBytes=None)</a></code></p>
84<p class="firstline">Creates a new version for a site.</p>
85<p class="toc_element">
86  <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
87<p class="firstline">Deletes the specified version.</p>
88<p class="toc_element">
89  <code><a href="#patch">patch(name, body, updateMask=None, x__xgafv=None)</a></code></p>
90<p class="firstline">Updates the specified metadata for a version. Note that this method will</p>
91<p class="toc_element">
92  <code><a href="#populateFiles">populateFiles(parent, body, x__xgafv=None)</a></code></p>
93<p class="firstline">Adds content files to a version.</p>
94<h3>Method Details</h3>
95<div class="method">
96    <code class="details" id="create">create(parent, body, versionId=None, x__xgafv=None, sizeBytes=None)</code>
97  <pre>Creates a new version for a site.
98
99Args:
100  parent: string, Required. The parent to create the version for, in the format:
101<code>sites/<var>site-name</var></code> (required)
102  body: object, The request body. (required)
103    The object takes the form of:
104
105{ # A `Version` is the collection of configuration and
106    # [static files](sites.versions.files) that determine how a site is displayed.
107  "status": "A String", # The deploy status of a version.
108      # <br>
109      # <br>For a successful deploy, call the
110      # [`CreateVersion`](sites.versions/create) endpoint to make a new version
111      # (`CREATED` status),
112      # [upload all desired files](sites.versions/populateFiles) to the version,
113      # then [update](sites.versions/patch) the version to the `FINALIZED` status.
114      # <br>
115      # <br>Note that if you leave the version in the `CREATED` state for more
116      # than 12&nbsp;hours, the system will automatically mark the version as
117      # `ABANDONED`.
118      # <br>
119      # <br>You can also change the status of a version to `DELETED` by calling the
120      # [`DeleteVersion`](sites.versions/delete) endpoint.
121  "deleteUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
122      # a release or finalizing a version.
123    "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
124        # changed their email address or deleted their account.
125    "email": "A String", # The email address of the user when the user performed the action.
126  },
127  "name": "A String", # The unique identifier for a version, in the format:
128      # <code>sites/<var>site-name</var>/versions/<var>versionID</var></code>
129      # This name is provided in the response body when you call the
130      # [`CreateVersion`](../sites.versions/create) endpoint.
131  "versionBytes": "A String", # Output only. The total stored bytesize of the version.
132      # <br>This value is calculated after a version is `FINALIZED`.
133  "labels": { # The labels used for extra metadata and/or filtering.
134    "a_key": "A String",
135  },
136  "finalizeUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
137      # a release or finalizing a version.
138    "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
139        # changed their email address or deleted their account.
140    "email": "A String", # The email address of the user when the user performed the action.
141  },
142  "finalizeTime": "A String", # Output only. The time at which the version was `FINALIZED`.
143  "deleteTime": "A String", # Output only. The time at which the version was `DELETED`.
144  "createUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
145      # a release or finalizing a version.
146    "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
147        # changed their email address or deleted their account.
148    "email": "A String", # The email address of the user when the user performed the action.
149  },
150  "config": { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
151      # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
152      # processed before serving content. The patterns are matched and applied
153      # according to a specific
154      # [priority order](/docs/hosting/full-config#hosting_priority_order).
155    "redirects": [ # A list of globs that will cause the response to redirect to another
156        # location.
157      { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
158          # configuration for returning an HTTP redirect response given a matching
159          # request URL path.
160        "glob": "A String", # Required. The user-supplied
161            # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
162            # against the request URL path.
163        "location": "A String", # Required. The value to put in the HTTP location header of the response.
164            # <br>The location can contain capture group values from the pattern using
165            # a `:` prefix to identify the segment and an optional `*` to capture the
166            # rest of the URL.
167            # For example:
168            # <code>"glob": "/:capture*",
169            # <br>"statusCode": 301,
170            # <br>"location": "https://example.com/foo/:capture"</code>
171        "statusCode": 42, # Required. The status HTTP code to return in the response. It must be a
172            # valid 3xx status code.
173      },
174    ],
175    "appAssociation": "A String", # How to handle well known App Association files.
176    "trailingSlashBehavior": "A String", # Defines how to handle a trailing slash in the URL path.
177    "cleanUrls": True or False, # Defines whether to drop the file extension from uploaded files.
178    "headers": [ # A list of custom response headers that are added to the content if the
179        # request URL path matches the glob.
180      { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
181          # add to a response should the request URL path match the pattern.
182        "headers": { # Required. The additional headers to add to the response.
183          "a_key": "A String",
184        },
185        "glob": "A String", # Required. The user-supplied
186            # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
187            # against the request URL path.
188      },
189    ],
190    "rewrites": [ # A list of rewrites that will act as if the service were given the
191        # destination URL.
192      { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
193          # content rewrite on the version. If the pattern matches, the request will be
194          # handled as if it were to the destination path specified in the
195          # configuration.
196        "function": "A String", # The function to proxy requests to. Must match the exported function
197            # name exactly.
198        "path": "A String", # The URL path to rewrite the request to.
199        "glob": "A String", # Required. The user-supplied
200            # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
201            # against the request URL path.
202        "run": { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
203            # Cloud Run service does not exist when setting or updating your Firebase
204            # Hosting configuration, then the request fails. Any errors from the Cloud Run
205            # service are passed to the end user (for example, if you delete a service, any
206            # requests directed to that service receive a `404` error).
207          "region": "A String", # Optional. User-provided region where the Cloud Run service is hosted.<br>
208              # Defaults to `us-central1` if not supplied.
209          "serviceId": "A String", # Required. User-defined ID of the Cloud Run service.
210        },
211        "dynamicLinks": True or False, # The request will be forwarded to Firebase Dynamic Links.
212      },
213    ],
214  },
215  "createTime": "A String", # Output only. The time at which the version was created.
216  "fileCount": "A String", # Output only. The total number of files associated with the version.
217      # <br>This value is calculated after a version is `FINALIZED`.
218}
219
220  versionId: string, A unique id for the new version. This is only specified for legacy version
221creations.
222  x__xgafv: string, V1 error format.
223    Allowed values
224      1 - v1 error format
225      2 - v2 error format
226  sizeBytes: string, The self-reported size of the version. This value is used for a pre-emptive
227quota check for legacy version uploads.
228
229Returns:
230  An object of the form:
231
232    { # A `Version` is the collection of configuration and
233      # [static files](sites.versions.files) that determine how a site is displayed.
234    "status": "A String", # The deploy status of a version.
235        # <br>
236        # <br>For a successful deploy, call the
237        # [`CreateVersion`](sites.versions/create) endpoint to make a new version
238        # (`CREATED` status),
239        # [upload all desired files](sites.versions/populateFiles) to the version,
240        # then [update](sites.versions/patch) the version to the `FINALIZED` status.
241        # <br>
242        # <br>Note that if you leave the version in the `CREATED` state for more
243        # than 12&nbsp;hours, the system will automatically mark the version as
244        # `ABANDONED`.
245        # <br>
246        # <br>You can also change the status of a version to `DELETED` by calling the
247        # [`DeleteVersion`](sites.versions/delete) endpoint.
248    "deleteUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
249        # a release or finalizing a version.
250      "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
251          # changed their email address or deleted their account.
252      "email": "A String", # The email address of the user when the user performed the action.
253    },
254    "name": "A String", # The unique identifier for a version, in the format:
255        # <code>sites/<var>site-name</var>/versions/<var>versionID</var></code>
256        # This name is provided in the response body when you call the
257        # [`CreateVersion`](../sites.versions/create) endpoint.
258    "versionBytes": "A String", # Output only. The total stored bytesize of the version.
259        # <br>This value is calculated after a version is `FINALIZED`.
260    "labels": { # The labels used for extra metadata and/or filtering.
261      "a_key": "A String",
262    },
263    "finalizeUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
264        # a release or finalizing a version.
265      "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
266          # changed their email address or deleted their account.
267      "email": "A String", # The email address of the user when the user performed the action.
268    },
269    "finalizeTime": "A String", # Output only. The time at which the version was `FINALIZED`.
270    "deleteTime": "A String", # Output only. The time at which the version was `DELETED`.
271    "createUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
272        # a release or finalizing a version.
273      "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
274          # changed their email address or deleted their account.
275      "email": "A String", # The email address of the user when the user performed the action.
276    },
277    "config": { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
278        # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
279        # processed before serving content. The patterns are matched and applied
280        # according to a specific
281        # [priority order](/docs/hosting/full-config#hosting_priority_order).
282      "redirects": [ # A list of globs that will cause the response to redirect to another
283          # location.
284        { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
285            # configuration for returning an HTTP redirect response given a matching
286            # request URL path.
287          "glob": "A String", # Required. The user-supplied
288              # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
289              # against the request URL path.
290          "location": "A String", # Required. The value to put in the HTTP location header of the response.
291              # <br>The location can contain capture group values from the pattern using
292              # a `:` prefix to identify the segment and an optional `*` to capture the
293              # rest of the URL.
294              # For example:
295              # <code>"glob": "/:capture*",
296              # <br>"statusCode": 301,
297              # <br>"location": "https://example.com/foo/:capture"</code>
298          "statusCode": 42, # Required. The status HTTP code to return in the response. It must be a
299              # valid 3xx status code.
300        },
301      ],
302      "appAssociation": "A String", # How to handle well known App Association files.
303      "trailingSlashBehavior": "A String", # Defines how to handle a trailing slash in the URL path.
304      "cleanUrls": True or False, # Defines whether to drop the file extension from uploaded files.
305      "headers": [ # A list of custom response headers that are added to the content if the
306          # request URL path matches the glob.
307        { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
308            # add to a response should the request URL path match the pattern.
309          "headers": { # Required. The additional headers to add to the response.
310            "a_key": "A String",
311          },
312          "glob": "A String", # Required. The user-supplied
313              # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
314              # against the request URL path.
315        },
316      ],
317      "rewrites": [ # A list of rewrites that will act as if the service were given the
318          # destination URL.
319        { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
320            # content rewrite on the version. If the pattern matches, the request will be
321            # handled as if it were to the destination path specified in the
322            # configuration.
323          "function": "A String", # The function to proxy requests to. Must match the exported function
324              # name exactly.
325          "path": "A String", # The URL path to rewrite the request to.
326          "glob": "A String", # Required. The user-supplied
327              # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
328              # against the request URL path.
329          "run": { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
330              # Cloud Run service does not exist when setting or updating your Firebase
331              # Hosting configuration, then the request fails. Any errors from the Cloud Run
332              # service are passed to the end user (for example, if you delete a service, any
333              # requests directed to that service receive a `404` error).
334            "region": "A String", # Optional. User-provided region where the Cloud Run service is hosted.<br>
335                # Defaults to `us-central1` if not supplied.
336            "serviceId": "A String", # Required. User-defined ID of the Cloud Run service.
337          },
338          "dynamicLinks": True or False, # The request will be forwarded to Firebase Dynamic Links.
339        },
340      ],
341    },
342    "createTime": "A String", # Output only. The time at which the version was created.
343    "fileCount": "A String", # Output only. The total number of files associated with the version.
344        # <br>This value is calculated after a version is `FINALIZED`.
345  }</pre>
346</div>
347
348<div class="method">
349    <code class="details" id="delete">delete(name, x__xgafv=None)</code>
350  <pre>Deletes the specified version.
351
352Args:
353  name: string, Required. The name of the version to be deleted, in the format:
354<code>sites/<var>site-name</var>/versions/<var>versionID</var></code> (required)
355  x__xgafv: string, V1 error format.
356    Allowed values
357      1 - v1 error format
358      2 - v2 error format
359
360Returns:
361  An object of the form:
362
363    { # A generic empty message that you can re-use to avoid defining duplicated
364      # empty messages in your APIs. A typical example is to use it as the request
365      # or the response type of an API method. For instance:
366      #
367      #     service Foo {
368      #       rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
369      #     }
370      #
371      # The JSON representation for `Empty` is empty JSON object `{}`.
372  }</pre>
373</div>
374
375<div class="method">
376    <code class="details" id="patch">patch(name, body, updateMask=None, x__xgafv=None)</code>
377  <pre>Updates the specified metadata for a version. Note that this method will
378fail with `FAILED_PRECONDITION` in the event of an invalid state
379transition. The only valid transition for a version is currently from a
380`CREATED` status to a `FINALIZED` status.
381Use [`DeleteVersion`](../sites.versions/delete) to set the status of a
382version to `DELETED`.
383
384Args:
385  name: string, The unique identifier for a version, in the format:
386<code>sites/<var>site-name</var>/versions/<var>versionID</var></code>
387This name is provided in the response body when you call the
388[`CreateVersion`](../sites.versions/create) endpoint. (required)
389  body: object, The request body. (required)
390    The object takes the form of:
391
392{ # A `Version` is the collection of configuration and
393    # [static files](sites.versions.files) that determine how a site is displayed.
394  "status": "A String", # The deploy status of a version.
395      # <br>
396      # <br>For a successful deploy, call the
397      # [`CreateVersion`](sites.versions/create) endpoint to make a new version
398      # (`CREATED` status),
399      # [upload all desired files](sites.versions/populateFiles) to the version,
400      # then [update](sites.versions/patch) the version to the `FINALIZED` status.
401      # <br>
402      # <br>Note that if you leave the version in the `CREATED` state for more
403      # than 12&nbsp;hours, the system will automatically mark the version as
404      # `ABANDONED`.
405      # <br>
406      # <br>You can also change the status of a version to `DELETED` by calling the
407      # [`DeleteVersion`](sites.versions/delete) endpoint.
408  "deleteUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
409      # a release or finalizing a version.
410    "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
411        # changed their email address or deleted their account.
412    "email": "A String", # The email address of the user when the user performed the action.
413  },
414  "name": "A String", # The unique identifier for a version, in the format:
415      # <code>sites/<var>site-name</var>/versions/<var>versionID</var></code>
416      # This name is provided in the response body when you call the
417      # [`CreateVersion`](../sites.versions/create) endpoint.
418  "versionBytes": "A String", # Output only. The total stored bytesize of the version.
419      # <br>This value is calculated after a version is `FINALIZED`.
420  "labels": { # The labels used for extra metadata and/or filtering.
421    "a_key": "A String",
422  },
423  "finalizeUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
424      # a release or finalizing a version.
425    "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
426        # changed their email address or deleted their account.
427    "email": "A String", # The email address of the user when the user performed the action.
428  },
429  "finalizeTime": "A String", # Output only. The time at which the version was `FINALIZED`.
430  "deleteTime": "A String", # Output only. The time at which the version was `DELETED`.
431  "createUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
432      # a release or finalizing a version.
433    "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
434        # changed their email address or deleted their account.
435    "email": "A String", # The email address of the user when the user performed the action.
436  },
437  "config": { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
438      # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
439      # processed before serving content. The patterns are matched and applied
440      # according to a specific
441      # [priority order](/docs/hosting/full-config#hosting_priority_order).
442    "redirects": [ # A list of globs that will cause the response to redirect to another
443        # location.
444      { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
445          # configuration for returning an HTTP redirect response given a matching
446          # request URL path.
447        "glob": "A String", # Required. The user-supplied
448            # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
449            # against the request URL path.
450        "location": "A String", # Required. The value to put in the HTTP location header of the response.
451            # <br>The location can contain capture group values from the pattern using
452            # a `:` prefix to identify the segment and an optional `*` to capture the
453            # rest of the URL.
454            # For example:
455            # <code>"glob": "/:capture*",
456            # <br>"statusCode": 301,
457            # <br>"location": "https://example.com/foo/:capture"</code>
458        "statusCode": 42, # Required. The status HTTP code to return in the response. It must be a
459            # valid 3xx status code.
460      },
461    ],
462    "appAssociation": "A String", # How to handle well known App Association files.
463    "trailingSlashBehavior": "A String", # Defines how to handle a trailing slash in the URL path.
464    "cleanUrls": True or False, # Defines whether to drop the file extension from uploaded files.
465    "headers": [ # A list of custom response headers that are added to the content if the
466        # request URL path matches the glob.
467      { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
468          # add to a response should the request URL path match the pattern.
469        "headers": { # Required. The additional headers to add to the response.
470          "a_key": "A String",
471        },
472        "glob": "A String", # Required. The user-supplied
473            # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
474            # against the request URL path.
475      },
476    ],
477    "rewrites": [ # A list of rewrites that will act as if the service were given the
478        # destination URL.
479      { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
480          # content rewrite on the version. If the pattern matches, the request will be
481          # handled as if it were to the destination path specified in the
482          # configuration.
483        "function": "A String", # The function to proxy requests to. Must match the exported function
484            # name exactly.
485        "path": "A String", # The URL path to rewrite the request to.
486        "glob": "A String", # Required. The user-supplied
487            # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
488            # against the request URL path.
489        "run": { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
490            # Cloud Run service does not exist when setting or updating your Firebase
491            # Hosting configuration, then the request fails. Any errors from the Cloud Run
492            # service are passed to the end user (for example, if you delete a service, any
493            # requests directed to that service receive a `404` error).
494          "region": "A String", # Optional. User-provided region where the Cloud Run service is hosted.<br>
495              # Defaults to `us-central1` if not supplied.
496          "serviceId": "A String", # Required. User-defined ID of the Cloud Run service.
497        },
498        "dynamicLinks": True or False, # The request will be forwarded to Firebase Dynamic Links.
499      },
500    ],
501  },
502  "createTime": "A String", # Output only. The time at which the version was created.
503  "fileCount": "A String", # Output only. The total number of files associated with the version.
504      # <br>This value is calculated after a version is `FINALIZED`.
505}
506
507  updateMask: string, A set of field names from your [version](../sites.versions) that you want
508to update.
509<br>A field will be overwritten if, and only if, it's in the mask.
510<br>If a mask is not provided then a default mask of only
511[`status`](../sites.versions#Version.FIELDS.status) will be used.
512  x__xgafv: string, V1 error format.
513    Allowed values
514      1 - v1 error format
515      2 - v2 error format
516
517Returns:
518  An object of the form:
519
520    { # A `Version` is the collection of configuration and
521      # [static files](sites.versions.files) that determine how a site is displayed.
522    "status": "A String", # The deploy status of a version.
523        # <br>
524        # <br>For a successful deploy, call the
525        # [`CreateVersion`](sites.versions/create) endpoint to make a new version
526        # (`CREATED` status),
527        # [upload all desired files](sites.versions/populateFiles) to the version,
528        # then [update](sites.versions/patch) the version to the `FINALIZED` status.
529        # <br>
530        # <br>Note that if you leave the version in the `CREATED` state for more
531        # than 12&nbsp;hours, the system will automatically mark the version as
532        # `ABANDONED`.
533        # <br>
534        # <br>You can also change the status of a version to `DELETED` by calling the
535        # [`DeleteVersion`](sites.versions/delete) endpoint.
536    "deleteUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
537        # a release or finalizing a version.
538      "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
539          # changed their email address or deleted their account.
540      "email": "A String", # The email address of the user when the user performed the action.
541    },
542    "name": "A String", # The unique identifier for a version, in the format:
543        # <code>sites/<var>site-name</var>/versions/<var>versionID</var></code>
544        # This name is provided in the response body when you call the
545        # [`CreateVersion`](../sites.versions/create) endpoint.
546    "versionBytes": "A String", # Output only. The total stored bytesize of the version.
547        # <br>This value is calculated after a version is `FINALIZED`.
548    "labels": { # The labels used for extra metadata and/or filtering.
549      "a_key": "A String",
550    },
551    "finalizeUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
552        # a release or finalizing a version.
553      "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
554          # changed their email address or deleted their account.
555      "email": "A String", # The email address of the user when the user performed the action.
556    },
557    "finalizeTime": "A String", # Output only. The time at which the version was `FINALIZED`.
558    "deleteTime": "A String", # Output only. The time at which the version was `DELETED`.
559    "createUser": { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
560        # a release or finalizing a version.
561      "imageUrl": "A String", # A profile image URL for the user. May not be present if the user has
562          # changed their email address or deleted their account.
563      "email": "A String", # The email address of the user when the user performed the action.
564    },
565    "config": { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
566        # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
567        # processed before serving content. The patterns are matched and applied
568        # according to a specific
569        # [priority order](/docs/hosting/full-config#hosting_priority_order).
570      "redirects": [ # A list of globs that will cause the response to redirect to another
571          # location.
572        { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
573            # configuration for returning an HTTP redirect response given a matching
574            # request URL path.
575          "glob": "A String", # Required. The user-supplied
576              # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
577              # against the request URL path.
578          "location": "A String", # Required. The value to put in the HTTP location header of the response.
579              # <br>The location can contain capture group values from the pattern using
580              # a `:` prefix to identify the segment and an optional `*` to capture the
581              # rest of the URL.
582              # For example:
583              # <code>"glob": "/:capture*",
584              # <br>"statusCode": 301,
585              # <br>"location": "https://example.com/foo/:capture"</code>
586          "statusCode": 42, # Required. The status HTTP code to return in the response. It must be a
587              # valid 3xx status code.
588        },
589      ],
590      "appAssociation": "A String", # How to handle well known App Association files.
591      "trailingSlashBehavior": "A String", # Defines how to handle a trailing slash in the URL path.
592      "cleanUrls": True or False, # Defines whether to drop the file extension from uploaded files.
593      "headers": [ # A list of custom response headers that are added to the content if the
594          # request URL path matches the glob.
595        { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
596            # add to a response should the request URL path match the pattern.
597          "headers": { # Required. The additional headers to add to the response.
598            "a_key": "A String",
599          },
600          "glob": "A String", # Required. The user-supplied
601              # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
602              # against the request URL path.
603        },
604      ],
605      "rewrites": [ # A list of rewrites that will act as if the service were given the
606          # destination URL.
607        { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
608            # content rewrite on the version. If the pattern matches, the request will be
609            # handled as if it were to the destination path specified in the
610            # configuration.
611          "function": "A String", # The function to proxy requests to. Must match the exported function
612              # name exactly.
613          "path": "A String", # The URL path to rewrite the request to.
614          "glob": "A String", # Required. The user-supplied
615              # [glob pattern](/docs/hosting/full-config#glob_pattern_matching) to match
616              # against the request URL path.
617          "run": { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
618              # Cloud Run service does not exist when setting or updating your Firebase
619              # Hosting configuration, then the request fails. Any errors from the Cloud Run
620              # service are passed to the end user (for example, if you delete a service, any
621              # requests directed to that service receive a `404` error).
622            "region": "A String", # Optional. User-provided region where the Cloud Run service is hosted.<br>
623                # Defaults to `us-central1` if not supplied.
624            "serviceId": "A String", # Required. User-defined ID of the Cloud Run service.
625          },
626          "dynamicLinks": True or False, # The request will be forwarded to Firebase Dynamic Links.
627        },
628      ],
629    },
630    "createTime": "A String", # Output only. The time at which the version was created.
631    "fileCount": "A String", # Output only. The total number of files associated with the version.
632        # <br>This value is calculated after a version is `FINALIZED`.
633  }</pre>
634</div>
635
636<div class="method">
637    <code class="details" id="populateFiles">populateFiles(parent, body, x__xgafv=None)</code>
638  <pre>Adds content files to a version.
639
640Args:
641  parent: string, Required. The version to add files to, in the format:
642<code>sites/<var>site-name</var>/versions/<var>versionID</var></code> (required)
643  body: object, The request body. (required)
644    The object takes the form of:
645
646{
647    "files": { # A set of file paths to the hashes corresponding to assets that should be
648        # added to the version. Note that a file path to an empty hash will remove
649        # the path from the version. Calculate a hash by Gzipping the file then
650        # taking the SHA256 hash of the newly compressed file.
651      "a_key": "A String",
652    },
653  }
654
655  x__xgafv: string, V1 error format.
656    Allowed values
657      1 - v1 error format
658      2 - v2 error format
659
660Returns:
661  An object of the form:
662
663    {
664    "uploadRequiredHashes": [ # The content hashes of the specified files that need to be uploaded to the
665        # specified endpoint.
666      "A String",
667    ],
668    "uploadUrl": "A String", # The URL to which the files should be uploaded, in the format:
669        # <br>"https://upload-firebasehosting.googleapis.com/upload/sites/<var>site-name</var>/versions/<var>versionID</var>/files".
670        # <br>Perform a multipart `POST` of the Gzipped file contents to the URL
671        # using a forward slash and the hash of the file appended to the end.
672  }</pre>
673</div>
674
675</body></html>