blob: f49a8b885f39e5c91811ef3351d2084934e9027f [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<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">
Bu Sun Kim65020912020-05-20 12:08:20 -070083 <code><a href="#create">create(parent, body=None, sizeBytes=None, versionId=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070084<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">
Bu Sun Kim65020912020-05-20 12:08:20 -070089 <code><a href="#list">list(parent, filter=None, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p>
Dan O'Mearadd494642020-05-01 07:42:23 -070090<p class="firstline">Lists the versions that have been created on the specified site.</p>
91<p class="toc_element">
92 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
93<p class="firstline">Retrieves the next page of results.</p>
94<p class="toc_element">
95 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070096<p class="firstline">Updates the specified metadata for a version. Note that this method will</p>
97<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070098 <code><a href="#populateFiles">populateFiles(parent, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070099<p class="firstline">Adds content files to a version.</p>
100<h3>Method Details</h3>
101<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -0700102 <code class="details" id="create">create(parent, body=None, sizeBytes=None, versionId=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700103 <pre>Creates a new version for a site.
104
105Args:
106 parent: string, Required. The parent to create the version for, in the format:
Dan O'Mearadd494642020-05-01 07:42:23 -0700107&lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;&lt;/code&gt; (required)
108 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700109 The object takes the form of:
110
111{ # A `Version` is the collection of configuration and
112 # [static files](sites.versions.files) that determine how a site is displayed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700113 &quot;fileCount&quot;: &quot;A String&quot;, # Output only. The total number of files associated with the version.
114 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
115 &quot;deleteUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
116 # a release or finalizing a version.
117 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
118 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
119 # changed their email address or deleted their account.
120 },
121 &quot;deleteTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `DELETED`.
122 &quot;finalizeUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
123 # a release or finalizing a version.
124 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
125 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
126 # changed their email address or deleted their account.
127 },
128 &quot;preview&quot;: { # Version preview configuration. If active and unexpired, # Version preview configuration for the site version. This configuration
129 # specfies whether previewing is enabled for this site version. Version
130 # previews allow you to preview your site at a custom URL before
131 # releasing it as the live version.
132 # this version will be accessible via a custom URL even
133 # if it is not the currently released version.
134 &quot;active&quot;: True or False, # If true, preview URLs are enabled for this version.
135 &quot;expireTime&quot;: &quot;A String&quot;, # Indicates the expiration time for previewing this
136 # version; preview URL requests received after this time will 404.
137 },
138 &quot;labels&quot;: { # The labels used for extra metadata and/or filtering.
139 &quot;a_key&quot;: &quot;A String&quot;,
140 },
141 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was created.
142 &quot;versionBytes&quot;: &quot;A String&quot;, # Output only. The total stored bytesize of the version.
143 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
144 &quot;finalizeTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `FINALIZED`.
145 &quot;status&quot;: &quot;A String&quot;, # The deploy status of a version.
Dan O'Mearadd494642020-05-01 07:42:23 -0700146 # &lt;br&gt;
147 # &lt;br&gt;For a successful deploy, call the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700148 # [`CreateVersion`](sites.versions/create) endpoint to make a new version
149 # (`CREATED` status),
150 # [upload all desired files](sites.versions/populateFiles) to the version,
151 # then [update](sites.versions/patch) the version to the `FINALIZED` status.
Dan O'Mearadd494642020-05-01 07:42:23 -0700152 # &lt;br&gt;
153 # &lt;br&gt;Note that if you leave the version in the `CREATED` state for more
154 # than 12&amp;nbsp;hours, the system will automatically mark the version as
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700155 # `ABANDONED`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700156 # &lt;br&gt;
157 # &lt;br&gt;You can also change the status of a version to `DELETED` by calling the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700158 # [`DeleteVersion`](sites.versions/delete) endpoint.
Bu Sun Kim65020912020-05-20 12:08:20 -0700159 &quot;config&quot;: { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700160 # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
161 # processed before serving content. The patterns are matched and applied
162 # according to a specific
163 # [priority order](/docs/hosting/full-config#hosting_priority_order).
Bu Sun Kim65020912020-05-20 12:08:20 -0700164 &quot;headers&quot;: [ # A list of custom response headers that are added to the content if the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700165 # request URL path matches the glob.
166 { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
167 # add to a response should the request URL path match the pattern.
Bu Sun Kim65020912020-05-20 12:08:20 -0700168 &quot;headers&quot;: { # Required. The additional headers to add to the response.
169 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700170 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700171 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
172 # URL path.
173 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700174 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700175 # against the request URL path.
176 },
177 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700178 &quot;appAssociation&quot;: &quot;A String&quot;, # How to handle well known App Association files.
179 &quot;cleanUrls&quot;: True or False, # Defines whether to drop the file extension from uploaded files.
180 &quot;trailingSlashBehavior&quot;: &quot;A String&quot;, # Defines how to handle a trailing slash in the URL path.
181 &quot;rewrites&quot;: [ # A list of rewrites that will act as if the service were given the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700182 # destination URL.
183 { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
184 # content rewrite on the version. If the pattern matches, the request will be
185 # handled as if it were to the destination path specified in the
186 # configuration.
Bu Sun Kim65020912020-05-20 12:08:20 -0700187 &quot;function&quot;: &quot;A String&quot;, # The function to proxy requests to. Must match the exported function
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700188 # name exactly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700189 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
190 # URL path.
191 &quot;dynamicLinks&quot;: True or False, # The request will be forwarded to Firebase Dynamic Links.
192 &quot;run&quot;: { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700193 # Cloud Run service does not exist when setting or updating your Firebase
194 # Hosting configuration, then the request fails. Any errors from the Cloud Run
195 # service are passed to the end user (for example, if you delete a service, any
196 # requests directed to that service receive a `404` error).
Bu Sun Kim65020912020-05-20 12:08:20 -0700197 &quot;region&quot;: &quot;A String&quot;, # Optional. User-provided region where the Cloud Run service is hosted.&lt;br&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700198 # Defaults to `us-central1` if not supplied.
Bu Sun Kim65020912020-05-20 12:08:20 -0700199 &quot;serviceId&quot;: &quot;A String&quot;, # Required. User-defined ID of the Cloud Run service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700200 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700201 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700202 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
203 # against the request URL path.
Bu Sun Kim65020912020-05-20 12:08:20 -0700204 &quot;path&quot;: &quot;A String&quot;, # The URL path to rewrite the request to.
205 },
206 ],
207 &quot;redirects&quot;: [ # A list of globs that will cause the response to redirect to another
208 # location.
209 { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
210 # configuration for returning an HTTP redirect response given a matching
211 # request URL path.
212 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
213 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
214 # against the request URL path.
215 &quot;statusCode&quot;: 42, # Required. The status HTTP code to return in the response. It must be a
216 # valid 3xx status code.
217 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
218 # URL path.
219 &quot;location&quot;: &quot;A String&quot;, # Required. The value to put in the HTTP location header of the response.
220 # &lt;br&gt;The location can contain capture group values from the pattern using
221 # a `:` prefix to identify the segment and an optional `*` to capture the
222 # rest of the URL.
223 # For example:
224 # &lt;code&gt;&quot;glob&quot;: &quot;/:capture*&quot;,
225 # &lt;br&gt;&quot;statusCode&quot;: 301,
226 # &lt;br&gt;&quot;location&quot;: &quot;https://example.com/foo/:capture&quot;&lt;/code&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700227 },
228 ],
229 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700230 &quot;name&quot;: &quot;A String&quot;, # The unique identifier for a version, in the format:
231 # &lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt;
232 # This name is provided in the response body when you call the
233 # [`CreateVersion`](../sites.versions/create) endpoint.
234 &quot;createUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
235 # a release or finalizing a version.
236 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
237 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
238 # changed their email address or deleted their account.
239 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700240}
241
Bu Sun Kim65020912020-05-20 12:08:20 -0700242 sizeBytes: string, The self-reported size of the version. This value is used for a pre-emptive
243quota check for legacy version uploads.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700244 versionId: string, A unique id for the new version. This is only specified for legacy version
245creations.
246 x__xgafv: string, V1 error format.
247 Allowed values
248 1 - v1 error format
249 2 - v2 error format
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700250
251Returns:
252 An object of the form:
253
254 { # A `Version` is the collection of configuration and
255 # [static files](sites.versions.files) that determine how a site is displayed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700256 &quot;fileCount&quot;: &quot;A String&quot;, # Output only. The total number of files associated with the version.
257 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
258 &quot;deleteUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
259 # a release or finalizing a version.
260 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
261 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
262 # changed their email address or deleted their account.
263 },
264 &quot;deleteTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `DELETED`.
265 &quot;finalizeUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
266 # a release or finalizing a version.
267 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
268 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
269 # changed their email address or deleted their account.
270 },
271 &quot;preview&quot;: { # Version preview configuration. If active and unexpired, # Version preview configuration for the site version. This configuration
272 # specfies whether previewing is enabled for this site version. Version
273 # previews allow you to preview your site at a custom URL before
274 # releasing it as the live version.
275 # this version will be accessible via a custom URL even
276 # if it is not the currently released version.
277 &quot;active&quot;: True or False, # If true, preview URLs are enabled for this version.
278 &quot;expireTime&quot;: &quot;A String&quot;, # Indicates the expiration time for previewing this
279 # version; preview URL requests received after this time will 404.
280 },
281 &quot;labels&quot;: { # The labels used for extra metadata and/or filtering.
282 &quot;a_key&quot;: &quot;A String&quot;,
283 },
284 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was created.
285 &quot;versionBytes&quot;: &quot;A String&quot;, # Output only. The total stored bytesize of the version.
286 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
287 &quot;finalizeTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `FINALIZED`.
288 &quot;status&quot;: &quot;A String&quot;, # The deploy status of a version.
Dan O'Mearadd494642020-05-01 07:42:23 -0700289 # &lt;br&gt;
290 # &lt;br&gt;For a successful deploy, call the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700291 # [`CreateVersion`](sites.versions/create) endpoint to make a new version
292 # (`CREATED` status),
293 # [upload all desired files](sites.versions/populateFiles) to the version,
294 # then [update](sites.versions/patch) the version to the `FINALIZED` status.
Dan O'Mearadd494642020-05-01 07:42:23 -0700295 # &lt;br&gt;
296 # &lt;br&gt;Note that if you leave the version in the `CREATED` state for more
297 # than 12&amp;nbsp;hours, the system will automatically mark the version as
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700298 # `ABANDONED`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700299 # &lt;br&gt;
300 # &lt;br&gt;You can also change the status of a version to `DELETED` by calling the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700301 # [`DeleteVersion`](sites.versions/delete) endpoint.
Bu Sun Kim65020912020-05-20 12:08:20 -0700302 &quot;config&quot;: { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700303 # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
304 # processed before serving content. The patterns are matched and applied
305 # according to a specific
306 # [priority order](/docs/hosting/full-config#hosting_priority_order).
Bu Sun Kim65020912020-05-20 12:08:20 -0700307 &quot;headers&quot;: [ # A list of custom response headers that are added to the content if the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700308 # request URL path matches the glob.
309 { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
310 # add to a response should the request URL path match the pattern.
Bu Sun Kim65020912020-05-20 12:08:20 -0700311 &quot;headers&quot;: { # Required. The additional headers to add to the response.
312 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700313 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700314 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
315 # URL path.
316 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700317 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700318 # against the request URL path.
319 },
320 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700321 &quot;appAssociation&quot;: &quot;A String&quot;, # How to handle well known App Association files.
322 &quot;cleanUrls&quot;: True or False, # Defines whether to drop the file extension from uploaded files.
323 &quot;trailingSlashBehavior&quot;: &quot;A String&quot;, # Defines how to handle a trailing slash in the URL path.
324 &quot;rewrites&quot;: [ # A list of rewrites that will act as if the service were given the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700325 # destination URL.
326 { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
327 # content rewrite on the version. If the pattern matches, the request will be
328 # handled as if it were to the destination path specified in the
329 # configuration.
Bu Sun Kim65020912020-05-20 12:08:20 -0700330 &quot;function&quot;: &quot;A String&quot;, # The function to proxy requests to. Must match the exported function
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700331 # name exactly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700332 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
333 # URL path.
334 &quot;dynamicLinks&quot;: True or False, # The request will be forwarded to Firebase Dynamic Links.
335 &quot;run&quot;: { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700336 # Cloud Run service does not exist when setting or updating your Firebase
337 # Hosting configuration, then the request fails. Any errors from the Cloud Run
338 # service are passed to the end user (for example, if you delete a service, any
339 # requests directed to that service receive a `404` error).
Bu Sun Kim65020912020-05-20 12:08:20 -0700340 &quot;region&quot;: &quot;A String&quot;, # Optional. User-provided region where the Cloud Run service is hosted.&lt;br&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700341 # Defaults to `us-central1` if not supplied.
Bu Sun Kim65020912020-05-20 12:08:20 -0700342 &quot;serviceId&quot;: &quot;A String&quot;, # Required. User-defined ID of the Cloud Run service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700343 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700344 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700345 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
346 # against the request URL path.
Bu Sun Kim65020912020-05-20 12:08:20 -0700347 &quot;path&quot;: &quot;A String&quot;, # The URL path to rewrite the request to.
348 },
349 ],
350 &quot;redirects&quot;: [ # A list of globs that will cause the response to redirect to another
351 # location.
352 { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
353 # configuration for returning an HTTP redirect response given a matching
354 # request URL path.
355 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
356 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
357 # against the request URL path.
358 &quot;statusCode&quot;: 42, # Required. The status HTTP code to return in the response. It must be a
359 # valid 3xx status code.
360 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
361 # URL path.
362 &quot;location&quot;: &quot;A String&quot;, # Required. The value to put in the HTTP location header of the response.
363 # &lt;br&gt;The location can contain capture group values from the pattern using
364 # a `:` prefix to identify the segment and an optional `*` to capture the
365 # rest of the URL.
366 # For example:
367 # &lt;code&gt;&quot;glob&quot;: &quot;/:capture*&quot;,
368 # &lt;br&gt;&quot;statusCode&quot;: 301,
369 # &lt;br&gt;&quot;location&quot;: &quot;https://example.com/foo/:capture&quot;&lt;/code&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700370 },
371 ],
372 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700373 &quot;name&quot;: &quot;A String&quot;, # The unique identifier for a version, in the format:
374 # &lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt;
375 # This name is provided in the response body when you call the
376 # [`CreateVersion`](../sites.versions/create) endpoint.
377 &quot;createUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
378 # a release or finalizing a version.
379 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
380 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
381 # changed their email address or deleted their account.
382 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700383 }</pre>
384</div>
385
386<div class="method">
387 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
388 <pre>Deletes the specified version.
389
390Args:
391 name: string, Required. The name of the version to be deleted, in the format:
Dan O'Mearadd494642020-05-01 07:42:23 -0700392&lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt; (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700393 x__xgafv: string, V1 error format.
394 Allowed values
395 1 - v1 error format
396 2 - v2 error format
397
398Returns:
399 An object of the form:
400
401 { # A generic empty message that you can re-use to avoid defining duplicated
402 # empty messages in your APIs. A typical example is to use it as the request
403 # or the response type of an API method. For instance:
404 #
405 # service Foo {
406 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
407 # }
408 #
409 # The JSON representation for `Empty` is empty JSON object `{}`.
410 }</pre>
411</div>
412
413<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -0700414 <code class="details" id="list">list(parent, filter=None, pageToken=None, pageSize=None, x__xgafv=None)</code>
Dan O'Mearadd494642020-05-01 07:42:23 -0700415 <pre>Lists the versions that have been created on the specified site.
416Will include filtering in the future.
417
418Args:
419 parent: string, Required. The parent for which to list files, in the format:
420&lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;&lt;/code&gt; (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700421 filter: string, The filter string used to return a subset of versions in the response.
422Currently supported fields for filtering are: name, status,
423and create_time. Filter processing will be implemented in accordance
424with go/filtering.
Bu Sun Kim65020912020-05-20 12:08:20 -0700425 pageToken: string, The next_page_token from a previous request, if provided.
426 pageSize: integer, The maximum number of versions to return. The service may return fewer than
427this value.
428If unspecified, at most 25 versions will be returned.
429The maximum value is 100; values above 100 will be coerced to 100
430 x__xgafv: string, V1 error format.
431 Allowed values
432 1 - v1 error format
433 2 - v2 error format
Dan O'Mearadd494642020-05-01 07:42:23 -0700434
435Returns:
436 An object of the form:
437
Bu Sun Kim65020912020-05-20 12:08:20 -0700438 {
439 &quot;nextPageToken&quot;: &quot;A String&quot;, # The pagination token, if more results exist
440 &quot;versions&quot;: [ # The list of versions, if any exist.
Dan O'Mearadd494642020-05-01 07:42:23 -0700441 { # A `Version` is the collection of configuration and
442 # [static files](sites.versions.files) that determine how a site is displayed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700443 &quot;fileCount&quot;: &quot;A String&quot;, # Output only. The total number of files associated with the version.
444 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
445 &quot;deleteUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
446 # a release or finalizing a version.
447 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
448 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
449 # changed their email address or deleted their account.
450 },
451 &quot;deleteTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `DELETED`.
452 &quot;finalizeUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
453 # a release or finalizing a version.
454 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
455 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
456 # changed their email address or deleted their account.
457 },
458 &quot;preview&quot;: { # Version preview configuration. If active and unexpired, # Version preview configuration for the site version. This configuration
459 # specfies whether previewing is enabled for this site version. Version
460 # previews allow you to preview your site at a custom URL before
461 # releasing it as the live version.
462 # this version will be accessible via a custom URL even
463 # if it is not the currently released version.
464 &quot;active&quot;: True or False, # If true, preview URLs are enabled for this version.
465 &quot;expireTime&quot;: &quot;A String&quot;, # Indicates the expiration time for previewing this
466 # version; preview URL requests received after this time will 404.
467 },
468 &quot;labels&quot;: { # The labels used for extra metadata and/or filtering.
469 &quot;a_key&quot;: &quot;A String&quot;,
470 },
471 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was created.
472 &quot;versionBytes&quot;: &quot;A String&quot;, # Output only. The total stored bytesize of the version.
473 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
474 &quot;finalizeTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `FINALIZED`.
475 &quot;status&quot;: &quot;A String&quot;, # The deploy status of a version.
Dan O'Mearadd494642020-05-01 07:42:23 -0700476 # &lt;br&gt;
477 # &lt;br&gt;For a successful deploy, call the
478 # [`CreateVersion`](sites.versions/create) endpoint to make a new version
479 # (`CREATED` status),
480 # [upload all desired files](sites.versions/populateFiles) to the version,
481 # then [update](sites.versions/patch) the version to the `FINALIZED` status.
482 # &lt;br&gt;
483 # &lt;br&gt;Note that if you leave the version in the `CREATED` state for more
484 # than 12&amp;nbsp;hours, the system will automatically mark the version as
485 # `ABANDONED`.
486 # &lt;br&gt;
487 # &lt;br&gt;You can also change the status of a version to `DELETED` by calling the
488 # [`DeleteVersion`](sites.versions/delete) endpoint.
Bu Sun Kim65020912020-05-20 12:08:20 -0700489 &quot;config&quot;: { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
Dan O'Mearadd494642020-05-01 07:42:23 -0700490 # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
491 # processed before serving content. The patterns are matched and applied
492 # according to a specific
493 # [priority order](/docs/hosting/full-config#hosting_priority_order).
Bu Sun Kim65020912020-05-20 12:08:20 -0700494 &quot;headers&quot;: [ # A list of custom response headers that are added to the content if the
Dan O'Mearadd494642020-05-01 07:42:23 -0700495 # request URL path matches the glob.
496 { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
497 # add to a response should the request URL path match the pattern.
Bu Sun Kim65020912020-05-20 12:08:20 -0700498 &quot;headers&quot;: { # Required. The additional headers to add to the response.
499 &quot;a_key&quot;: &quot;A String&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -0700500 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700501 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
502 # URL path.
503 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700504 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
505 # against the request URL path.
506 },
507 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700508 &quot;appAssociation&quot;: &quot;A String&quot;, # How to handle well known App Association files.
509 &quot;cleanUrls&quot;: True or False, # Defines whether to drop the file extension from uploaded files.
510 &quot;trailingSlashBehavior&quot;: &quot;A String&quot;, # Defines how to handle a trailing slash in the URL path.
511 &quot;rewrites&quot;: [ # A list of rewrites that will act as if the service were given the
Dan O'Mearadd494642020-05-01 07:42:23 -0700512 # destination URL.
513 { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
514 # content rewrite on the version. If the pattern matches, the request will be
515 # handled as if it were to the destination path specified in the
516 # configuration.
Bu Sun Kim65020912020-05-20 12:08:20 -0700517 &quot;function&quot;: &quot;A String&quot;, # The function to proxy requests to. Must match the exported function
Dan O'Mearadd494642020-05-01 07:42:23 -0700518 # name exactly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700519 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
520 # URL path.
521 &quot;dynamicLinks&quot;: True or False, # The request will be forwarded to Firebase Dynamic Links.
522 &quot;run&quot;: { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
Dan O'Mearadd494642020-05-01 07:42:23 -0700523 # Cloud Run service does not exist when setting or updating your Firebase
524 # Hosting configuration, then the request fails. Any errors from the Cloud Run
525 # service are passed to the end user (for example, if you delete a service, any
526 # requests directed to that service receive a `404` error).
Bu Sun Kim65020912020-05-20 12:08:20 -0700527 &quot;region&quot;: &quot;A String&quot;, # Optional. User-provided region where the Cloud Run service is hosted.&lt;br&gt;
Dan O'Mearadd494642020-05-01 07:42:23 -0700528 # Defaults to `us-central1` if not supplied.
Bu Sun Kim65020912020-05-20 12:08:20 -0700529 &quot;serviceId&quot;: &quot;A String&quot;, # Required. User-defined ID of the Cloud Run service.
Dan O'Mearadd494642020-05-01 07:42:23 -0700530 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700531 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700532 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
533 # against the request URL path.
Bu Sun Kim65020912020-05-20 12:08:20 -0700534 &quot;path&quot;: &quot;A String&quot;, # The URL path to rewrite the request to.
535 },
536 ],
537 &quot;redirects&quot;: [ # A list of globs that will cause the response to redirect to another
538 # location.
539 { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
540 # configuration for returning an HTTP redirect response given a matching
541 # request URL path.
542 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
543 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
544 # against the request URL path.
545 &quot;statusCode&quot;: 42, # Required. The status HTTP code to return in the response. It must be a
546 # valid 3xx status code.
547 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
548 # URL path.
549 &quot;location&quot;: &quot;A String&quot;, # Required. The value to put in the HTTP location header of the response.
550 # &lt;br&gt;The location can contain capture group values from the pattern using
551 # a `:` prefix to identify the segment and an optional `*` to capture the
552 # rest of the URL.
553 # For example:
554 # &lt;code&gt;&quot;glob&quot;: &quot;/:capture*&quot;,
555 # &lt;br&gt;&quot;statusCode&quot;: 301,
556 # &lt;br&gt;&quot;location&quot;: &quot;https://example.com/foo/:capture&quot;&lt;/code&gt;
Dan O'Mearadd494642020-05-01 07:42:23 -0700557 },
558 ],
559 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700560 &quot;name&quot;: &quot;A String&quot;, # The unique identifier for a version, in the format:
561 # &lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt;
562 # This name is provided in the response body when you call the
563 # [`CreateVersion`](../sites.versions/create) endpoint.
564 &quot;createUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
565 # a release or finalizing a version.
566 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
567 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
568 # changed their email address or deleted their account.
569 },
Dan O'Mearadd494642020-05-01 07:42:23 -0700570 },
571 ],
572 }</pre>
573</div>
574
575<div class="method">
576 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
577 <pre>Retrieves the next page of results.
578
579Args:
580 previous_request: The request for the previous page. (required)
581 previous_response: The response from the request for the previous page. (required)
582
583Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700584 A request object that you can call &#x27;execute()&#x27; on to request the next
Dan O'Mearadd494642020-05-01 07:42:23 -0700585 page. Returns None if there are no more items in the collection.
586 </pre>
587</div>
588
589<div class="method">
590 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700591 <pre>Updates the specified metadata for a version. Note that this method will
592fail with `FAILED_PRECONDITION` in the event of an invalid state
593transition. The only valid transition for a version is currently from a
594`CREATED` status to a `FINALIZED` status.
595Use [`DeleteVersion`](../sites.versions/delete) to set the status of a
596version to `DELETED`.
597
598Args:
599 name: string, The unique identifier for a version, in the format:
Dan O'Mearadd494642020-05-01 07:42:23 -0700600&lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700601This name is provided in the response body when you call the
602[`CreateVersion`](../sites.versions/create) endpoint. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700603 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700604 The object takes the form of:
605
606{ # A `Version` is the collection of configuration and
607 # [static files](sites.versions.files) that determine how a site is displayed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700608 &quot;fileCount&quot;: &quot;A String&quot;, # Output only. The total number of files associated with the version.
609 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
610 &quot;deleteUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
611 # a release or finalizing a version.
612 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
613 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
614 # changed their email address or deleted their account.
615 },
616 &quot;deleteTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `DELETED`.
617 &quot;finalizeUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
618 # a release or finalizing a version.
619 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
620 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
621 # changed their email address or deleted their account.
622 },
623 &quot;preview&quot;: { # Version preview configuration. If active and unexpired, # Version preview configuration for the site version. This configuration
624 # specfies whether previewing is enabled for this site version. Version
625 # previews allow you to preview your site at a custom URL before
626 # releasing it as the live version.
627 # this version will be accessible via a custom URL even
628 # if it is not the currently released version.
629 &quot;active&quot;: True or False, # If true, preview URLs are enabled for this version.
630 &quot;expireTime&quot;: &quot;A String&quot;, # Indicates the expiration time for previewing this
631 # version; preview URL requests received after this time will 404.
632 },
633 &quot;labels&quot;: { # The labels used for extra metadata and/or filtering.
634 &quot;a_key&quot;: &quot;A String&quot;,
635 },
636 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was created.
637 &quot;versionBytes&quot;: &quot;A String&quot;, # Output only. The total stored bytesize of the version.
638 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
639 &quot;finalizeTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `FINALIZED`.
640 &quot;status&quot;: &quot;A String&quot;, # The deploy status of a version.
Dan O'Mearadd494642020-05-01 07:42:23 -0700641 # &lt;br&gt;
642 # &lt;br&gt;For a successful deploy, call the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700643 # [`CreateVersion`](sites.versions/create) endpoint to make a new version
644 # (`CREATED` status),
645 # [upload all desired files](sites.versions/populateFiles) to the version,
646 # then [update](sites.versions/patch) the version to the `FINALIZED` status.
Dan O'Mearadd494642020-05-01 07:42:23 -0700647 # &lt;br&gt;
648 # &lt;br&gt;Note that if you leave the version in the `CREATED` state for more
649 # than 12&amp;nbsp;hours, the system will automatically mark the version as
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700650 # `ABANDONED`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700651 # &lt;br&gt;
652 # &lt;br&gt;You can also change the status of a version to `DELETED` by calling the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700653 # [`DeleteVersion`](sites.versions/delete) endpoint.
Bu Sun Kim65020912020-05-20 12:08:20 -0700654 &quot;config&quot;: { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700655 # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
656 # processed before serving content. The patterns are matched and applied
657 # according to a specific
658 # [priority order](/docs/hosting/full-config#hosting_priority_order).
Bu Sun Kim65020912020-05-20 12:08:20 -0700659 &quot;headers&quot;: [ # A list of custom response headers that are added to the content if the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700660 # request URL path matches the glob.
661 { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
662 # add to a response should the request URL path match the pattern.
Bu Sun Kim65020912020-05-20 12:08:20 -0700663 &quot;headers&quot;: { # Required. The additional headers to add to the response.
664 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700665 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700666 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
667 # URL path.
668 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700669 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700670 # against the request URL path.
671 },
672 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700673 &quot;appAssociation&quot;: &quot;A String&quot;, # How to handle well known App Association files.
674 &quot;cleanUrls&quot;: True or False, # Defines whether to drop the file extension from uploaded files.
675 &quot;trailingSlashBehavior&quot;: &quot;A String&quot;, # Defines how to handle a trailing slash in the URL path.
676 &quot;rewrites&quot;: [ # A list of rewrites that will act as if the service were given the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700677 # destination URL.
678 { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
679 # content rewrite on the version. If the pattern matches, the request will be
680 # handled as if it were to the destination path specified in the
681 # configuration.
Bu Sun Kim65020912020-05-20 12:08:20 -0700682 &quot;function&quot;: &quot;A String&quot;, # The function to proxy requests to. Must match the exported function
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700683 # name exactly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700684 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
685 # URL path.
686 &quot;dynamicLinks&quot;: True or False, # The request will be forwarded to Firebase Dynamic Links.
687 &quot;run&quot;: { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700688 # Cloud Run service does not exist when setting or updating your Firebase
689 # Hosting configuration, then the request fails. Any errors from the Cloud Run
690 # service are passed to the end user (for example, if you delete a service, any
691 # requests directed to that service receive a `404` error).
Bu Sun Kim65020912020-05-20 12:08:20 -0700692 &quot;region&quot;: &quot;A String&quot;, # Optional. User-provided region where the Cloud Run service is hosted.&lt;br&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700693 # Defaults to `us-central1` if not supplied.
Bu Sun Kim65020912020-05-20 12:08:20 -0700694 &quot;serviceId&quot;: &quot;A String&quot;, # Required. User-defined ID of the Cloud Run service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700695 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700696 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700697 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
698 # against the request URL path.
Bu Sun Kim65020912020-05-20 12:08:20 -0700699 &quot;path&quot;: &quot;A String&quot;, # The URL path to rewrite the request to.
700 },
701 ],
702 &quot;redirects&quot;: [ # A list of globs that will cause the response to redirect to another
703 # location.
704 { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
705 # configuration for returning an HTTP redirect response given a matching
706 # request URL path.
707 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
708 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
709 # against the request URL path.
710 &quot;statusCode&quot;: 42, # Required. The status HTTP code to return in the response. It must be a
711 # valid 3xx status code.
712 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
713 # URL path.
714 &quot;location&quot;: &quot;A String&quot;, # Required. The value to put in the HTTP location header of the response.
715 # &lt;br&gt;The location can contain capture group values from the pattern using
716 # a `:` prefix to identify the segment and an optional `*` to capture the
717 # rest of the URL.
718 # For example:
719 # &lt;code&gt;&quot;glob&quot;: &quot;/:capture*&quot;,
720 # &lt;br&gt;&quot;statusCode&quot;: 301,
721 # &lt;br&gt;&quot;location&quot;: &quot;https://example.com/foo/:capture&quot;&lt;/code&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700722 },
723 ],
724 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700725 &quot;name&quot;: &quot;A String&quot;, # The unique identifier for a version, in the format:
726 # &lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt;
727 # This name is provided in the response body when you call the
728 # [`CreateVersion`](../sites.versions/create) endpoint.
729 &quot;createUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
730 # a release or finalizing a version.
731 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
732 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
733 # changed their email address or deleted their account.
734 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700735}
736
737 updateMask: string, A set of field names from your [version](../sites.versions) that you want
738to update.
Bu Sun Kim65020912020-05-20 12:08:20 -0700739&lt;br&gt;A field will be overwritten if, and only if, it&#x27;s in the mask.
Dan O'Mearadd494642020-05-01 07:42:23 -0700740&lt;br&gt;If a mask is not provided then a default mask of only
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700741[`status`](../sites.versions#Version.FIELDS.status) will be used.
742 x__xgafv: string, V1 error format.
743 Allowed values
744 1 - v1 error format
745 2 - v2 error format
746
747Returns:
748 An object of the form:
749
750 { # A `Version` is the collection of configuration and
751 # [static files](sites.versions.files) that determine how a site is displayed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700752 &quot;fileCount&quot;: &quot;A String&quot;, # Output only. The total number of files associated with the version.
753 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
754 &quot;deleteUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `DELETED` the version.
755 # a release or finalizing a version.
756 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
757 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
758 # changed their email address or deleted their account.
759 },
760 &quot;deleteTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `DELETED`.
761 &quot;finalizeUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who `FINALIZED` the version.
762 # a release or finalizing a version.
763 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
764 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
765 # changed their email address or deleted their account.
766 },
767 &quot;preview&quot;: { # Version preview configuration. If active and unexpired, # Version preview configuration for the site version. This configuration
768 # specfies whether previewing is enabled for this site version. Version
769 # previews allow you to preview your site at a custom URL before
770 # releasing it as the live version.
771 # this version will be accessible via a custom URL even
772 # if it is not the currently released version.
773 &quot;active&quot;: True or False, # If true, preview URLs are enabled for this version.
774 &quot;expireTime&quot;: &quot;A String&quot;, # Indicates the expiration time for previewing this
775 # version; preview URL requests received after this time will 404.
776 },
777 &quot;labels&quot;: { # The labels used for extra metadata and/or filtering.
778 &quot;a_key&quot;: &quot;A String&quot;,
779 },
780 &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was created.
781 &quot;versionBytes&quot;: &quot;A String&quot;, # Output only. The total stored bytesize of the version.
782 # &lt;br&gt;This value is calculated after a version is `FINALIZED`.
783 &quot;finalizeTime&quot;: &quot;A String&quot;, # Output only. The time at which the version was `FINALIZED`.
784 &quot;status&quot;: &quot;A String&quot;, # The deploy status of a version.
Dan O'Mearadd494642020-05-01 07:42:23 -0700785 # &lt;br&gt;
786 # &lt;br&gt;For a successful deploy, call the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700787 # [`CreateVersion`](sites.versions/create) endpoint to make a new version
788 # (`CREATED` status),
789 # [upload all desired files](sites.versions/populateFiles) to the version,
790 # then [update](sites.versions/patch) the version to the `FINALIZED` status.
Dan O'Mearadd494642020-05-01 07:42:23 -0700791 # &lt;br&gt;
792 # &lt;br&gt;Note that if you leave the version in the `CREATED` state for more
793 # than 12&amp;nbsp;hours, the system will automatically mark the version as
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700794 # `ABANDONED`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700795 # &lt;br&gt;
796 # &lt;br&gt;You can also change the status of a version to `DELETED` by calling the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700797 # [`DeleteVersion`](sites.versions/delete) endpoint.
Bu Sun Kim65020912020-05-20 12:08:20 -0700798 &quot;config&quot;: { # The configuration for how incoming requests to a site should be routed and # The configuration for the behavior of the site. This configuration exists
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700799 # in the [`firebase.json`](/docs/cli/#the_firebasejson_file) file.
800 # processed before serving content. The patterns are matched and applied
801 # according to a specific
802 # [priority order](/docs/hosting/full-config#hosting_priority_order).
Bu Sun Kim65020912020-05-20 12:08:20 -0700803 &quot;headers&quot;: [ # A list of custom response headers that are added to the content if the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700804 # request URL path matches the glob.
805 { # A [`header`](/docs/hosting/full-config#headers) defines custom headers to
806 # add to a response should the request URL path match the pattern.
Bu Sun Kim65020912020-05-20 12:08:20 -0700807 &quot;headers&quot;: { # Required. The additional headers to add to the response.
808 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700809 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700810 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
811 # URL path.
812 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700813 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700814 # against the request URL path.
815 },
816 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700817 &quot;appAssociation&quot;: &quot;A String&quot;, # How to handle well known App Association files.
818 &quot;cleanUrls&quot;: True or False, # Defines whether to drop the file extension from uploaded files.
819 &quot;trailingSlashBehavior&quot;: &quot;A String&quot;, # Defines how to handle a trailing slash in the URL path.
820 &quot;rewrites&quot;: [ # A list of rewrites that will act as if the service were given the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700821 # destination URL.
822 { # A [`rewrite`](/docs/hosting/full-config#rewrites) represents an internal
823 # content rewrite on the version. If the pattern matches, the request will be
824 # handled as if it were to the destination path specified in the
825 # configuration.
Bu Sun Kim65020912020-05-20 12:08:20 -0700826 &quot;function&quot;: &quot;A String&quot;, # The function to proxy requests to. Must match the exported function
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700827 # name exactly.
Bu Sun Kim65020912020-05-20 12:08:20 -0700828 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
829 # URL path.
830 &quot;dynamicLinks&quot;: True or False, # The request will be forwarded to Firebase Dynamic Links.
831 &quot;run&quot;: { # A configured rewrite that directs requests to a Cloud Run service. If the # The request will be forwarded to Cloud Run.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700832 # Cloud Run service does not exist when setting or updating your Firebase
833 # Hosting configuration, then the request fails. Any errors from the Cloud Run
834 # service are passed to the end user (for example, if you delete a service, any
835 # requests directed to that service receive a `404` error).
Bu Sun Kim65020912020-05-20 12:08:20 -0700836 &quot;region&quot;: &quot;A String&quot;, # Optional. User-provided region where the Cloud Run service is hosted.&lt;br&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700837 # Defaults to `us-central1` if not supplied.
Bu Sun Kim65020912020-05-20 12:08:20 -0700838 &quot;serviceId&quot;: &quot;A String&quot;, # Required. User-defined ID of the Cloud Run service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700839 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700840 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
Dan O'Mearadd494642020-05-01 07:42:23 -0700841 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
842 # against the request URL path.
Bu Sun Kim65020912020-05-20 12:08:20 -0700843 &quot;path&quot;: &quot;A String&quot;, # The URL path to rewrite the request to.
844 },
845 ],
846 &quot;redirects&quot;: [ # A list of globs that will cause the response to redirect to another
847 # location.
848 { # A [`redirect`](/docs/hosting/full-config#redirects) represents the
849 # configuration for returning an HTTP redirect response given a matching
850 # request URL path.
851 &quot;glob&quot;: &quot;A String&quot;, # The user-supplied [glob
852 # pattern](/docs/hosting/full-config#glob_pattern_matching) to match
853 # against the request URL path.
854 &quot;statusCode&quot;: 42, # Required. The status HTTP code to return in the response. It must be a
855 # valid 3xx status code.
856 &quot;regex&quot;: &quot;A String&quot;, # The user-supplied RE2 regular expression to match against the request
857 # URL path.
858 &quot;location&quot;: &quot;A String&quot;, # Required. The value to put in the HTTP location header of the response.
859 # &lt;br&gt;The location can contain capture group values from the pattern using
860 # a `:` prefix to identify the segment and an optional `*` to capture the
861 # rest of the URL.
862 # For example:
863 # &lt;code&gt;&quot;glob&quot;: &quot;/:capture*&quot;,
864 # &lt;br&gt;&quot;statusCode&quot;: 301,
865 # &lt;br&gt;&quot;location&quot;: &quot;https://example.com/foo/:capture&quot;&lt;/code&gt;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700866 },
867 ],
868 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700869 &quot;name&quot;: &quot;A String&quot;, # The unique identifier for a version, in the format:
870 # &lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt;
871 # This name is provided in the response body when you call the
872 # [`CreateVersion`](../sites.versions/create) endpoint.
873 &quot;createUser&quot;: { # Contains metadata about the user who performed an action, such as creating # Output only. Identifies the user who created the version.
874 # a release or finalizing a version.
875 &quot;email&quot;: &quot;A String&quot;, # The email address of the user when the user performed the action.
876 &quot;imageUrl&quot;: &quot;A String&quot;, # A profile image URL for the user. May not be present if the user has
877 # changed their email address or deleted their account.
878 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700879 }</pre>
880</div>
881
882<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700883 <code class="details" id="populateFiles">populateFiles(parent, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700884 <pre>Adds content files to a version.
885
886Args:
887 parent: string, Required. The version to add files to, in the format:
Dan O'Mearadd494642020-05-01 07:42:23 -0700888&lt;code&gt;sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;&lt;/code&gt; (required)
889 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700890 The object takes the form of:
891
Bu Sun Kim65020912020-05-20 12:08:20 -0700892{ # The request to populate a Version&#x27;s Files.
893 &quot;files&quot;: { # A set of file paths to the hashes corresponding to assets that should be
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700894 # added to the version. Note that a file path to an empty hash will remove
895 # the path from the version. Calculate a hash by Gzipping the file then
896 # taking the SHA256 hash of the newly compressed file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700897 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700898 },
899 }
900
901 x__xgafv: string, V1 error format.
902 Allowed values
903 1 - v1 error format
904 2 - v2 error format
905
906Returns:
907 An object of the form:
908
Bu Sun Kim65020912020-05-20 12:08:20 -0700909 {
910 &quot;uploadRequiredHashes&quot;: [ # The content hashes of the specified files that need to be uploaded to the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700911 # specified endpoint.
Bu Sun Kim65020912020-05-20 12:08:20 -0700912 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700913 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700914 &quot;uploadUrl&quot;: &quot;A String&quot;, # The URL to which the files should be uploaded, in the format:
915 # &lt;br&gt;&quot;https://upload-firebasehosting.googleapis.com/upload/sites/&lt;var&gt;site-name&lt;/var&gt;/versions/&lt;var&gt;versionID&lt;/var&gt;/files&quot;.
Dan O'Mearadd494642020-05-01 07:42:23 -0700916 # &lt;br&gt;Perform a multipart `POST` of the Gzipped file contents to the URL
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700917 # using a forward slash and the hash of the file appended to the end.
918 }</pre>
919</div>
920
921</body></html>