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="sqladmin_v1.html">Cloud SQL Admin API</a> . <a href="sqladmin_v1.instances.html">instances</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78  <code><a href="#addServerCa">addServerCa(project, instance, x__xgafv=None)</a></code></p>
79<p class="firstline">Adds a new trusted Certificate Authority (CA) version for the specified instance. Required to prepare for a certificate rotation. If a CA version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one CA version waiting to be rotated in.</p>
80<p class="toc_element">
81  <code><a href="#clone">clone(project, instance, body=None, x__xgafv=None)</a></code></p>
82<p class="firstline">Creates a Cloud SQL instance as a clone of the source instance. Using this operation might cause your instance to restart.</p>
83<p class="toc_element">
84  <code><a href="#close">close()</a></code></p>
85<p class="firstline">Close httplib2 connections.</p>
86<p class="toc_element">
87  <code><a href="#delete">delete(project, instance, x__xgafv=None)</a></code></p>
88<p class="firstline">Deletes a Cloud SQL instance.</p>
89<p class="toc_element">
90  <code><a href="#demoteMaster">demoteMaster(project, instance, body=None, x__xgafv=None)</a></code></p>
91<p class="firstline">Demotes the stand-alone instance to be a Cloud SQL read replica for an external database server.</p>
92<p class="toc_element">
93  <code><a href="#export">export(project, instance, body=None, x__xgafv=None)</a></code></p>
94<p class="firstline">Exports data from a Cloud SQL instance to a Cloud Storage bucket as a SQL dump or CSV file.</p>
95<p class="toc_element">
96  <code><a href="#failover">failover(project, instance, body=None, x__xgafv=None)</a></code></p>
97<p class="firstline">Initiates a manual failover of a high availability (HA) primary instance to a standby instance, which becomes the primary instance. Users are then rerouted to the new primary. For more information, see the [Overview of high availability](https://cloud.google.com/sql/docs/mysql/high-availability) page in the Cloud SQL documentation. If using Legacy HA (MySQL only), this causes the instance to failover to its failover replica instance.</p>
98<p class="toc_element">
99  <code><a href="#get">get(project, instance, x__xgafv=None)</a></code></p>
100<p class="firstline">Retrieves a resource containing information about a Cloud SQL instance.</p>
101<p class="toc_element">
102  <code><a href="#import_">import_(project, instance, body=None, x__xgafv=None)</a></code></p>
103<p class="firstline">Imports data into a Cloud SQL instance from a SQL dump or CSV file in Cloud Storage.</p>
104<p class="toc_element">
105  <code><a href="#insert">insert(project, body=None, x__xgafv=None)</a></code></p>
106<p class="firstline">Creates a new Cloud SQL instance.</p>
107<p class="toc_element">
108  <code><a href="#list">list(project, filter=None, maxResults=None, pageToken=None, x__xgafv=None)</a></code></p>
109<p class="firstline">Lists instances under a given project.</p>
110<p class="toc_element">
111  <code><a href="#listServerCas">listServerCas(project, instance, x__xgafv=None)</a></code></p>
112<p class="firstline">Lists all of the trusted Certificate Authorities (CAs) for the specified instance. There can be up to three CAs listed: the CA that was used to sign the certificate that is currently in use, a CA that has been added but not yet used to sign a certificate, and a CA used to sign a certificate that has previously rotated out.</p>
113<p class="toc_element">
114  <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
115<p class="firstline">Retrieves the next page of results.</p>
116<p class="toc_element">
117  <code><a href="#patch">patch(project, instance, body=None, x__xgafv=None)</a></code></p>
118<p class="firstline">Updates settings of a Cloud SQL instance. This method supports patch semantics.</p>
119<p class="toc_element">
120  <code><a href="#promoteReplica">promoteReplica(project, instance, x__xgafv=None)</a></code></p>
121<p class="firstline">Promotes the read replica instance to be a stand-alone Cloud SQL instance. Using this operation might cause your instance to restart.</p>
122<p class="toc_element">
123  <code><a href="#resetSslConfig">resetSslConfig(project, instance, x__xgafv=None)</a></code></p>
124<p class="firstline">Deletes all client certificates and generates a new server SSL certificate for the instance.</p>
125<p class="toc_element">
126  <code><a href="#restart">restart(project, instance, x__xgafv=None)</a></code></p>
127<p class="firstline">Restarts a Cloud SQL instance.</p>
128<p class="toc_element">
129  <code><a href="#restoreBackup">restoreBackup(project, instance, body=None, x__xgafv=None)</a></code></p>
130<p class="firstline">Restores a backup of a Cloud SQL instance. Using this operation might cause your instance to restart.</p>
131<p class="toc_element">
132  <code><a href="#rotateServerCa">rotateServerCa(project, instance, body=None, x__xgafv=None)</a></code></p>
133<p class="firstline">Rotates the server certificate to one signed by the Certificate Authority (CA) version previously added with the addServerCA method.</p>
134<p class="toc_element">
135  <code><a href="#startReplica">startReplica(project, instance, x__xgafv=None)</a></code></p>
136<p class="firstline">Starts the replication in the read replica instance.</p>
137<p class="toc_element">
138  <code><a href="#stopReplica">stopReplica(project, instance, x__xgafv=None)</a></code></p>
139<p class="firstline">Stops the replication in the read replica instance.</p>
140<p class="toc_element">
141  <code><a href="#truncateLog">truncateLog(project, instance, body=None, x__xgafv=None)</a></code></p>
142<p class="firstline">Truncate MySQL general and slow query log tables MySQL only.</p>
143<p class="toc_element">
144  <code><a href="#update">update(project, instance, body=None, x__xgafv=None)</a></code></p>
145<p class="firstline">Updates settings of a Cloud SQL instance. Using this operation might cause your instance to restart.</p>
146<h3>Method Details</h3>
147<div class="method">
148    <code class="details" id="addServerCa">addServerCa(project, instance, x__xgafv=None)</code>
149  <pre>Adds a new trusted Certificate Authority (CA) version for the specified instance. Required to prepare for a certificate rotation. If a CA version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one CA version waiting to be rotated in.
150
151Args:
152  project: string, Project ID of the project that contains the instance. (required)
153  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
154  x__xgafv: string, V1 error format.
155    Allowed values
156      1 - v1 error format
157      2 - v2 error format
158
159Returns:
160  An object of the form:
161
162    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
163  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
164    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
165    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
166  },
167  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
168  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
169    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
170      { # Database instance operation error.
171        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
172        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
173        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
174      },
175    ],
176    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
177  },
178  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
179    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
180      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
181      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
182      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
183      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
184      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
185    },
186    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
187      &quot;A String&quot;,
188    ],
189    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
190    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
191    &quot;offload&quot;: True or False, # Option for export offload.
192    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
193      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
194        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
195      },
196      &quot;schemaOnly&quot;: True or False, # Export only schemas.
197      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
198        &quot;A String&quot;,
199      ],
200    },
201    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
202  },
203  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
204    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
205      &quot;encryptionOptions&quot;: {
206        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
207        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
208        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
209      },
210    },
211    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
212      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
213        &quot;A String&quot;,
214      ],
215      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
216      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
217      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
218      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
219      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
220    },
221    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
222    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
223    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
224    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
225    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
226  },
227  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
228  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
229  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
230  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
231  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
232  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
233  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
234  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
235  &quot;targetLink&quot;: &quot;A String&quot;,
236  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
237  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
238}</pre>
239</div>
240
241<div class="method">
242    <code class="details" id="clone">clone(project, instance, body=None, x__xgafv=None)</code>
243  <pre>Creates a Cloud SQL instance as a clone of the source instance. Using this operation might cause your instance to restart.
244
245Args:
246  project: string, Project ID of the source as well as the clone Cloud SQL instance. (required)
247  instance: string, The ID of the Cloud SQL instance to be cloned (source). This does not include the project ID. (required)
248  body: object, The request body.
249    The object takes the form of:
250
251{ # Database instance clone request.
252  &quot;cloneContext&quot;: { # Database instance clone context. # Contains details about the clone operation.
253    &quot;binLogCoordinates&quot;: { # Binary log coordinates. # Binary log coordinates, if specified, identify the position up to which the source instance is cloned. If not specified, the source instance is cloned up to the most recent binary log coordinates.
254      &quot;binLogFileName&quot;: &quot;A String&quot;, # Name of the binary log file for a Cloud SQL instance.
255      &quot;binLogPosition&quot;: &quot;A String&quot;, # Position (offset) within the binary log file.
256      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#binLogCoordinates**.
257    },
258    &quot;destinationInstanceName&quot;: &quot;A String&quot;, # Name of the Cloud SQL instance to be created as a clone.
259    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#cloneContext**.
260    &quot;pitrTimestampMs&quot;: &quot;A String&quot;, # Reserved for future use.
261    &quot;pointInTime&quot;: &quot;A String&quot;, # Timestamp, if specified, identifies the time to which the source instance is cloned.
262  },
263}
264
265  x__xgafv: string, V1 error format.
266    Allowed values
267      1 - v1 error format
268      2 - v2 error format
269
270Returns:
271  An object of the form:
272
273    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
274  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
275    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
276    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
277  },
278  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
279  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
280    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
281      { # Database instance operation error.
282        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
283        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
284        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
285      },
286    ],
287    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
288  },
289  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
290    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
291      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
292      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
293      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
294      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
295      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
296    },
297    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
298      &quot;A String&quot;,
299    ],
300    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
301    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
302    &quot;offload&quot;: True or False, # Option for export offload.
303    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
304      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
305        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
306      },
307      &quot;schemaOnly&quot;: True or False, # Export only schemas.
308      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
309        &quot;A String&quot;,
310      ],
311    },
312    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
313  },
314  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
315    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
316      &quot;encryptionOptions&quot;: {
317        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
318        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
319        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
320      },
321    },
322    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
323      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
324        &quot;A String&quot;,
325      ],
326      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
327      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
328      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
329      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
330      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
331    },
332    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
333    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
334    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
335    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
336    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
337  },
338  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
339  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
340  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
341  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
342  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
343  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
344  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
345  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
346  &quot;targetLink&quot;: &quot;A String&quot;,
347  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
348  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
349}</pre>
350</div>
351
352<div class="method">
353    <code class="details" id="close">close()</code>
354  <pre>Close httplib2 connections.</pre>
355</div>
356
357<div class="method">
358    <code class="details" id="delete">delete(project, instance, x__xgafv=None)</code>
359  <pre>Deletes a Cloud SQL instance.
360
361Args:
362  project: string, Project ID of the project that contains the instance to be deleted. (required)
363  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
364  x__xgafv: string, V1 error format.
365    Allowed values
366      1 - v1 error format
367      2 - v2 error format
368
369Returns:
370  An object of the form:
371
372    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
373  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
374    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
375    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
376  },
377  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
378  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
379    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
380      { # Database instance operation error.
381        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
382        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
383        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
384      },
385    ],
386    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
387  },
388  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
389    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
390      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
391      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
392      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
393      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
394      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
395    },
396    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
397      &quot;A String&quot;,
398    ],
399    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
400    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
401    &quot;offload&quot;: True or False, # Option for export offload.
402    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
403      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
404        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
405      },
406      &quot;schemaOnly&quot;: True or False, # Export only schemas.
407      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
408        &quot;A String&quot;,
409      ],
410    },
411    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
412  },
413  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
414    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
415      &quot;encryptionOptions&quot;: {
416        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
417        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
418        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
419      },
420    },
421    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
422      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
423        &quot;A String&quot;,
424      ],
425      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
426      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
427      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
428      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
429      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
430    },
431    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
432    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
433    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
434    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
435    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
436  },
437  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
438  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
439  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
440  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
441  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
442  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
443  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
444  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
445  &quot;targetLink&quot;: &quot;A String&quot;,
446  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
447  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
448}</pre>
449</div>
450
451<div class="method">
452    <code class="details" id="demoteMaster">demoteMaster(project, instance, body=None, x__xgafv=None)</code>
453  <pre>Demotes the stand-alone instance to be a Cloud SQL read replica for an external database server.
454
455Args:
456  project: string, ID of the project that contains the instance. (required)
457  instance: string, Cloud SQL instance name. (required)
458  body: object, The request body.
459    The object takes the form of:
460
461{ # Database demote primary instance request.
462  &quot;demoteMasterContext&quot;: { # Database instance demote primary instance context. # Contains details about the demoteMaster operation.
463    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#demoteMasterContext**.
464    &quot;masterInstanceName&quot;: &quot;A String&quot;, # The name of the instance which will act as on-premises primary instance in the replication setup.
465    &quot;replicaConfiguration&quot;: { # Read-replica configuration for connecting to the on-premises primary instance. # Configuration specific to read-replicas replicating from the on-premises primary instance.
466      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#demoteMasterConfiguration**.
467      &quot;mysqlReplicaConfiguration&quot;: { # Read-replica configuration specific to MySQL databases. # MySQL specific configuration when replicating from a MySQL on-premises primary instance. Replication configuration information such as the username, password, certificates, and keys are not stored in the instance metadata. The configuration information is used only to set up the replication connection and is stored by MySQL in a file named **master.info** in the data directory.
468        &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
469        &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
470        &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate. The format of the replica&#x27;s private key can be either PKCS #1 or PKCS #8.
471        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#demoteMasterMysqlReplicaConfiguration**.
472        &quot;password&quot;: &quot;A String&quot;, # The password for the replication connection.
473        &quot;username&quot;: &quot;A String&quot;, # The username for the replication connection.
474      },
475    },
476    &quot;skipReplicationSetup&quot;: True or False, # Flag to skip replication setup on the instance.
477    &quot;verifyGtidConsistency&quot;: True or False, # Verify GTID consistency for demote operation. Default value: **True**. Setting this flag to false enables you to bypass GTID consistency check between on-premises primary instance and Cloud SQL instance during the demotion operation but also exposes you to the risk of future replication failures. Change the value only if you know the reason for the GTID divergence and are confident that doing so will not cause any replication issues.
478  },
479}
480
481  x__xgafv: string, V1 error format.
482    Allowed values
483      1 - v1 error format
484      2 - v2 error format
485
486Returns:
487  An object of the form:
488
489    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
490  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
491    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
492    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
493  },
494  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
495  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
496    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
497      { # Database instance operation error.
498        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
499        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
500        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
501      },
502    ],
503    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
504  },
505  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
506    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
507      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
508      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
509      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
510      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
511      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
512    },
513    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
514      &quot;A String&quot;,
515    ],
516    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
517    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
518    &quot;offload&quot;: True or False, # Option for export offload.
519    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
520      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
521        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
522      },
523      &quot;schemaOnly&quot;: True or False, # Export only schemas.
524      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
525        &quot;A String&quot;,
526      ],
527    },
528    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
529  },
530  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
531    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
532      &quot;encryptionOptions&quot;: {
533        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
534        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
535        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
536      },
537    },
538    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
539      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
540        &quot;A String&quot;,
541      ],
542      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
543      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
544      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
545      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
546      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
547    },
548    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
549    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
550    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
551    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
552    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
553  },
554  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
555  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
556  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
557  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
558  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
559  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
560  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
561  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
562  &quot;targetLink&quot;: &quot;A String&quot;,
563  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
564  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
565}</pre>
566</div>
567
568<div class="method">
569    <code class="details" id="export">export(project, instance, body=None, x__xgafv=None)</code>
570  <pre>Exports data from a Cloud SQL instance to a Cloud Storage bucket as a SQL dump or CSV file.
571
572Args:
573  project: string, Project ID of the project that contains the instance to be exported. (required)
574  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
575  body: object, The request body.
576    The object takes the form of:
577
578{ # Database instance export request.
579  &quot;exportContext&quot;: { # Database instance export context. # Contains details about the export operation.
580    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
581      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
582      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
583      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
584      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
585      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
586    },
587    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
588      &quot;A String&quot;,
589    ],
590    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
591    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
592    &quot;offload&quot;: True or False, # Option for export offload.
593    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
594      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
595        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
596      },
597      &quot;schemaOnly&quot;: True or False, # Export only schemas.
598      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
599        &quot;A String&quot;,
600      ],
601    },
602    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
603  },
604}
605
606  x__xgafv: string, V1 error format.
607    Allowed values
608      1 - v1 error format
609      2 - v2 error format
610
611Returns:
612  An object of the form:
613
614    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
615  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
616    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
617    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
618  },
619  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
620  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
621    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
622      { # Database instance operation error.
623        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
624        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
625        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
626      },
627    ],
628    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
629  },
630  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
631    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
632      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
633      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
634      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
635      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
636      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
637    },
638    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
639      &quot;A String&quot;,
640    ],
641    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
642    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
643    &quot;offload&quot;: True or False, # Option for export offload.
644    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
645      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
646        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
647      },
648      &quot;schemaOnly&quot;: True or False, # Export only schemas.
649      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
650        &quot;A String&quot;,
651      ],
652    },
653    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
654  },
655  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
656    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
657      &quot;encryptionOptions&quot;: {
658        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
659        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
660        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
661      },
662    },
663    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
664      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
665        &quot;A String&quot;,
666      ],
667      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
668      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
669      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
670      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
671      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
672    },
673    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
674    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
675    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
676    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
677    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
678  },
679  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
680  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
681  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
682  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
683  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
684  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
685  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
686  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
687  &quot;targetLink&quot;: &quot;A String&quot;,
688  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
689  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
690}</pre>
691</div>
692
693<div class="method">
694    <code class="details" id="failover">failover(project, instance, body=None, x__xgafv=None)</code>
695  <pre>Initiates a manual failover of a high availability (HA) primary instance to a standby instance, which becomes the primary instance. Users are then rerouted to the new primary. For more information, see the [Overview of high availability](https://cloud.google.com/sql/docs/mysql/high-availability) page in the Cloud SQL documentation. If using Legacy HA (MySQL only), this causes the instance to failover to its failover replica instance.
696
697Args:
698  project: string, ID of the project that contains the read replica. (required)
699  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
700  body: object, The request body.
701    The object takes the form of:
702
703{ # Instance failover request.
704  &quot;failoverContext&quot;: { # Database instance failover context. # Failover Context.
705    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#failoverContext**.
706    &quot;settingsVersion&quot;: &quot;A String&quot;, # The current settings version of this instance. Request will be rejected if this version doesn&#x27;t match the current settings version.
707  },
708}
709
710  x__xgafv: string, V1 error format.
711    Allowed values
712      1 - v1 error format
713      2 - v2 error format
714
715Returns:
716  An object of the form:
717
718    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
719  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
720    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
721    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
722  },
723  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
724  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
725    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
726      { # Database instance operation error.
727        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
728        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
729        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
730      },
731    ],
732    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
733  },
734  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
735    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
736      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
737      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
738      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
739      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
740      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
741    },
742    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
743      &quot;A String&quot;,
744    ],
745    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
746    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
747    &quot;offload&quot;: True or False, # Option for export offload.
748    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
749      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
750        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
751      },
752      &quot;schemaOnly&quot;: True or False, # Export only schemas.
753      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
754        &quot;A String&quot;,
755      ],
756    },
757    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
758  },
759  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
760    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
761      &quot;encryptionOptions&quot;: {
762        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
763        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
764        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
765      },
766    },
767    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
768      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
769        &quot;A String&quot;,
770      ],
771      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
772      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
773      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
774      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
775      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
776    },
777    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
778    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
779    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
780    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
781    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
782  },
783  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
784  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
785  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
786  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
787  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
788  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
789  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
790  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
791  &quot;targetLink&quot;: &quot;A String&quot;,
792  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
793  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
794}</pre>
795</div>
796
797<div class="method">
798    <code class="details" id="get">get(project, instance, x__xgafv=None)</code>
799  <pre>Retrieves a resource containing information about a Cloud SQL instance.
800
801Args:
802  project: string, Project ID of the project that contains the instance. (required)
803  instance: string, Database instance ID. This does not include the project ID. (required)
804  x__xgafv: string, V1 error format.
805    Allowed values
806      1 - v1 error format
807      2 - v2 error format
808
809Returns:
810  An object of the form:
811
812    { # A Cloud SQL instance resource.
813  &quot;backendType&quot;: &quot;A String&quot;, # The backend type. **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A database server that is not managed by Google. This property is read-only; use the **tier** property in the **settings** object to determine the database type.
814  &quot;connectionName&quot;: &quot;A String&quot;, # Connection name of the Cloud SQL instance used in connection strings.
815  &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time when the instance was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
816  &quot;currentDiskSize&quot;: &quot;A String&quot;, # The current disk usage of the instance in bytes. This property has been deprecated. Use the &quot;cloudsql.googleapis.com/database/disk/bytes_used&quot; metric in Cloud Monitoring API instead. Please see [this announcement](https://groups.google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ) for details.
817  &quot;databaseInstalledVersion&quot;: &quot;A String&quot;, # Output only. Stores the current database version running on the instance including minor version such as **MYSQL_8_0_18**.
818  &quot;databaseVersion&quot;: &quot;A String&quot;, # The database engine type and version. The **databaseVersion** field cannot be changed after instance creation.
819  &quot;diskEncryptionConfiguration&quot;: { # Disk encryption configuration for an instance. # Disk encryption configuration specific to an instance.
820    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionConfiguration**.
821    &quot;kmsKeyName&quot;: &quot;A String&quot;, # Resource name of KMS key for disk encryption
822  },
823  &quot;diskEncryptionStatus&quot;: { # Disk encryption status for an instance. # Disk encryption status specific to an instance.
824    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionStatus**.
825    &quot;kmsKeyVersionName&quot;: &quot;A String&quot;, # KMS key version used to encrypt the Cloud SQL instance resource
826  },
827  &quot;etag&quot;: &quot;A String&quot;, # This field is deprecated and will be removed from a future version of the API. Use the **settings.settingsVersion** field instead.
828  &quot;failoverReplica&quot;: { # The name and status of the failover replica.
829    &quot;available&quot;: True or False, # The availability status of the failover replica. A false status indicates that the failover replica is out of sync. The primary instance can only failover to the failover replica when the status is true.
830    &quot;name&quot;: &quot;A String&quot;, # The name of the failover replica. If specified at instance creation, a failover replica is created for the instance. The name doesn&#x27;t include the project ID.
831  },
832  &quot;gceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the instance is currently serving from. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary zone. WARNING: Changing this might restart the instance.
833  &quot;instanceType&quot;: &quot;A String&quot;, # The instance type.
834  &quot;ipAddresses&quot;: [ # The assigned IP addresses for the instance.
835    { # Database instance IP Mapping.
836      &quot;ipAddress&quot;: &quot;A String&quot;, # The IP address assigned.
837      &quot;timeToRetire&quot;: &quot;A String&quot;, # The due time for this IP to be retired in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**. This field is only available when the IP is scheduled to be retired.
838      &quot;type&quot;: &quot;A String&quot;, # The type of this IP address. A **PRIMARY** address is a public address that can accept incoming connections. A **PRIVATE** address is a private address that can accept incoming connections. An **OUTGOING** address is the source address of connections originating from the instance, if supported.
839    },
840  ],
841  &quot;ipv6Address&quot;: &quot;A String&quot;, # The IPv6 address assigned to the instance. (Deprecated) This property was applicable only to First Generation instances.
842  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instance**.
843  &quot;masterInstanceName&quot;: &quot;A String&quot;, # The name of the instance which will act as primary in the replication setup.
844  &quot;maxDiskSize&quot;: &quot;A String&quot;, # The maximum disk size of the instance in bytes.
845  &quot;name&quot;: &quot;A String&quot;, # Name of the Cloud SQL instance. This does not include the project ID.
846  &quot;onPremisesConfiguration&quot;: { # On-premises instance configuration. # Configuration specific to on-premises instances.
847    &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
848    &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
849    &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
850    &quot;dumpFilePath&quot;: &quot;A String&quot;, # The dump file to create the Cloud SQL replica.
851    &quot;hostPort&quot;: &quot;A String&quot;, # The host and port of the on-premises instance in host:port format
852    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#onPremisesConfiguration**.
853    &quot;password&quot;: &quot;A String&quot;, # The password for connecting to on-premises instance.
854    &quot;sourceInstance&quot;: { # Reference to another Cloud SQL instance. # The reference to Cloud SQL instance if the source is Cloud SQL.
855      &quot;name&quot;: &quot;A String&quot;, # The name of the Cloud SQL instance being referenced. This does not include the project ID.
856      &quot;project&quot;: &quot;A String&quot;, # The project ID of the Cloud SQL instance being referenced. The default is the same project ID as the instance references it.
857      &quot;region&quot;: &quot;A String&quot;, # The region of the Cloud SQL instance being referenced.
858    },
859    &quot;username&quot;: &quot;A String&quot;, # The username for connecting to on-premises instance.
860  },
861  &quot;outOfDiskReport&quot;: { # This message wraps up the information written by out-of-disk detection job. # This field represents the report generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
862    &quot;sqlMinRecommendedIncreaseSizeGb&quot;: 42, # The minimum recommended increase size in GigaBytes This field is consumed by the frontend * Writers: * the proactive database wellness job for OOD. * Readers:
863    &quot;sqlOutOfDiskState&quot;: &quot;A String&quot;, # This field represents the state generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
864  },
865  &quot;project&quot;: &quot;A String&quot;, # The project ID of the project containing the Cloud SQL instance. The Google apps domain is prefixed if applicable.
866  &quot;region&quot;: &quot;A String&quot;, # The geographical region. Can be: * **us-central** (**FIRST_GEN** instances only) * **us-central1** (**SECOND_GEN** instances only) * **asia-east1** or **europe-west1**. Defaults to **us-central** or **us-central1** depending on the instance type. The region cannot be changed after instance creation.
867  &quot;replicaConfiguration&quot;: { # Read-replica configuration for connecting to the primary instance. # Configuration specific to failover replicas and read replicas.
868    &quot;failoverTarget&quot;: True or False, # Specifies if the replica is the failover target. If the field is set to **true** the replica will be designated as a failover replica. In case the primary instance fails, the replica instance will be promoted as the new primary instance. Only one replica can be specified as failover target, and the replica has to be in different zone with the primary instance.
869    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#replicaConfiguration**.
870    &quot;mysqlReplicaConfiguration&quot;: { # Read-replica configuration specific to MySQL databases. # MySQL specific configuration when replicating from a MySQL on-premises primary instance. Replication configuration information such as the username, password, certificates, and keys are not stored in the instance metadata. The configuration information is used only to set up the replication connection and is stored by MySQL in a file named **master.info** in the data directory.
871      &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
872      &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
873      &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
874      &quot;connectRetryInterval&quot;: 42, # Seconds to wait between connect retries. MySQL&#x27;s default is 60 seconds.
875      &quot;dumpFilePath&quot;: &quot;A String&quot;, # Path to a SQL dump file in Google Cloud Storage from which the replica instance is to be created. The URI is in the form gs://bucketName/fileName. Compressed gzip files (.gz) are also supported. Dumps have the binlog co-ordinates from which replication begins. This can be accomplished by setting --master-data to 1 when using mysqldump.
876      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#mysqlReplicaConfiguration**.
877      &quot;masterHeartbeatPeriod&quot;: &quot;A String&quot;, # Interval in milliseconds between replication heartbeats.
878      &quot;password&quot;: &quot;A String&quot;, # The password for the replication connection.
879      &quot;sslCipher&quot;: &quot;A String&quot;, # A list of permissible ciphers to use for SSL encryption.
880      &quot;username&quot;: &quot;A String&quot;, # The username for the replication connection.
881      &quot;verifyServerCertificate&quot;: True or False, # Whether or not to check the primary instance&#x27;s Common Name value in the certificate that it sends during the SSL handshake.
882    },
883  },
884  &quot;replicaNames&quot;: [ # The replicas of the instance.
885    &quot;A String&quot;,
886  ],
887  &quot;rootPassword&quot;: &quot;A String&quot;, # Initial root password. Use only on creation.
888  &quot;satisfiesPzs&quot;: True or False, # The status indicating if instance satisfiesPzs. Reserved for future use.
889  &quot;scheduledMaintenance&quot;: { # Any scheduled maintenancce for this instance. # The start time of any upcoming scheduled maintenance for this instance.
890    &quot;canDefer&quot;: True or False,
891    &quot;canReschedule&quot;: True or False, # If the scheduled maintenance can be rescheduled.
892    &quot;scheduleDeadlineTime&quot;: &quot;A String&quot;, # Maintenance cannot be rescheduled to start beyond this deadline.
893    &quot;startTime&quot;: &quot;A String&quot;, # The start time of any upcoming scheduled maintenance for this instance.
894  },
895  &quot;secondaryGceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the failover instance is currently serving from for a regional instance. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary/failover zone. Reserved for future use.
896  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
897  &quot;serverCaCert&quot;: { # SslCerts Resource # SSL configuration.
898    &quot;cert&quot;: &quot;A String&quot;, # PEM representation.
899    &quot;certSerialNumber&quot;: &quot;A String&quot;, # Serial number, as extracted from the certificate.
900    &quot;commonName&quot;: &quot;A String&quot;, # User supplied name. Constrained to [a-zA-Z.-_ ]+.
901    &quot;createTime&quot;: &quot;A String&quot;, # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
902    &quot;expirationTime&quot;: &quot;A String&quot;, # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
903    &quot;instance&quot;: &quot;A String&quot;, # Name of the database instance.
904    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#sslCert**.
905    &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
906    &quot;sha1Fingerprint&quot;: &quot;A String&quot;, # Sha1 Fingerprint.
907  },
908  &quot;serviceAccountEmailAddress&quot;: &quot;A String&quot;, # The service account email address assigned to the instance. This property is read-only.
909  &quot;settings&quot;: { # Database instance settings. # The user settings.
910    &quot;activationPolicy&quot;: &quot;A String&quot;, # The activation policy specifies when the instance is activated; it is applicable only when the instance state is RUNNABLE. Valid values: * **ALWAYS**: The instance is on, and remains so even in the absence of connection requests. * **NEVER**: The instance is off; it is not activated, even if a connection request arrives.
911    &quot;activeDirectoryConfig&quot;: { # Active Directory configuration, relevant only for Cloud SQL for SQL Server. # Active Directory configuration, relevant only for Cloud SQL for SQL Server.
912      &quot;domain&quot;: &quot;A String&quot;, # The name of the domain (e.g., mydomain.com).
913      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#activeDirectoryConfig.
914    },
915    &quot;authorizedGaeApplications&quot;: [ # The App Engine app IDs that can access this instance. (Deprecated) Applied to First Generation instances only.
916      &quot;A String&quot;,
917    ],
918    &quot;availabilityType&quot;: &quot;A String&quot;, # Availability type. Potential values: * **ZONAL**: The instance serves data from only one zone. Outages in that zone affect data accessibility. * **REGIONAL**: The instance can serve data from more than one zone in a region (it is highly available)./ For more information, see [Overview of the High Availability Configuration](https://cloud.google.com/sql/docs/mysql/high-availability).
919    &quot;backupConfiguration&quot;: { # Database instance backup configuration. # The daily backup configuration for the instance.
920      &quot;backupRetentionSettings&quot;: { # We currently only support backup retention by specifying the number of backups we will retain. # Backup retention settings.
921        &quot;retainedBackups&quot;: 42, # Depending on the value of retention_unit, this is used to determine if a backup needs to be deleted. If retention_unit is &#x27;COUNT&#x27;, we will retain this many backups.
922        &quot;retentionUnit&quot;: &quot;A String&quot;, # The unit that &#x27;retained_backups&#x27; represents.
923      },
924      &quot;binaryLogEnabled&quot;: True or False, # (MySQL only) Whether binary log is enabled. If backup configuration is disabled, binarylog must be disabled as well.
925      &quot;enabled&quot;: True or False, # Whether this configuration is enabled.
926      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupConfiguration**.
927      &quot;location&quot;: &quot;A String&quot;, # Location of the backup
928      &quot;pointInTimeRecoveryEnabled&quot;: True or False, # (Postgres only) Whether point in time recovery is enabled.
929      &quot;replicationLogArchivingEnabled&quot;: True or False, # Reserved for future use.
930      &quot;startTime&quot;: &quot;A String&quot;, # Start time for the daily backup configuration in UTC timezone in the 24 hour format - **HH:MM**.
931      &quot;transactionLogRetentionDays&quot;: 42, # The number of days of transaction logs we retain for point in time restore, from 1-7.
932    },
933    &quot;collation&quot;: &quot;A String&quot;, # The name of server Instance collation.
934    &quot;crashSafeReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether database flags for crash-safe replication are enabled. This property was only applicable to First Generation instances.
935    &quot;dataDiskSizeGb&quot;: &quot;A String&quot;, # The size of data disk, in GB. The data disk size minimum is 10GB.
936    &quot;dataDiskType&quot;: &quot;A String&quot;, # The type of data disk: **PD_SSD** (default) or **PD_HDD**. Not used for First Generation instances.
937    &quot;databaseFlags&quot;: [ # The database flags passed to the instance at startup.
938      { # Database flags for Cloud SQL instances.
939        &quot;name&quot;: &quot;A String&quot;, # The name of the flag. These flags are passed at instance startup, so include both server options and system variables. Flags are specified with underscores, not hyphens. For more information, see [Configuring Database Flags](https://cloud.google.com/sql/docs/mysql/flags) in the Cloud SQL documentation.
940        &quot;value&quot;: &quot;A String&quot;, # The value of the flag. Booleans are set to **on** for true and **off** for false. This field must be omitted if the flag doesn&#x27;t take a value.
941      },
942    ],
943    &quot;databaseReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether replication is enabled or not. WARNING: Changing this restarts the instance.
944    &quot;denyMaintenancePeriods&quot;: [ # Deny maintenance periods
945      { # Deny maintenance Periods. This specifies a date range during when all CSA rollout will be denied.
946        &quot;endDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; end date. If the year of the end date is empty, the year of the start date also must be empty. In this case, it means the no maintenance interval recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
947        &quot;startDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; start date. If the year of the start date is empty, the year of the end date also must be empty. In this case, it means the deny maintenance period recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
948        &quot;time&quot;: &quot;A String&quot;, # Time in UTC when the &quot;deny maintenance period&quot; starts on start_date and ends on end_date. The time is in format: HH:mm:SS, i.e., 00:00:00
949      },
950    ],
951    &quot;insightsConfig&quot;: { # Insights configuration. This specifies when Cloud SQL Insights feature is enabled and optional configuration. # Insights configuration, for now relevant only for Postgres.
952      &quot;queryInsightsEnabled&quot;: True or False, # Whether Query Insights feature is enabled.
953      &quot;queryPlansPerMinute&quot;: 42, # Number of query execution plans captured by Insights per minute for all queries combined. Default is 5.
954      &quot;queryStringLength&quot;: 42, # Maximum query length stored in bytes. Default value: 1024 bytes. Range: 256-4500 bytes. Query length more than this field value will be truncated to this value. When unset, query length will be the default value. Changing query length will restart the database.
955      &quot;recordApplicationTags&quot;: True or False, # Whether Query Insights will record application tags from query when enabled.
956      &quot;recordClientAddress&quot;: True or False, # Whether Query Insights will record client address when enabled.
957    },
958    &quot;ipConfiguration&quot;: { # IP Management configuration. # The settings for IP Management. This allows to enable or disable the instance IP and manage which external networks can connect to the instance. The IPv4 address cannot be disabled for Second Generation instances.
959      &quot;allocatedIpRange&quot;: &quot;A String&quot;, # The name of the allocated ip range for the private ip CloudSQL instance. For example: &quot;google-managed-services-default&quot;. If set, the instance ip will be created in the allocated range. The range name must comply with [RFC 1035](https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?.`
960      &quot;authorizedNetworks&quot;: [ # The list of external networks that are allowed to connect to the instance using the IP. In &#x27;CIDR&#x27; notation, also known as &#x27;slash&#x27; notation (for example: **157.197.200.0/24**).
961        { # An entry for an Access Control list.
962          &quot;expirationTime&quot;: &quot;A String&quot;, # The time when this access control entry expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
963          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#aclEntry**.
964          &quot;name&quot;: &quot;A String&quot;, # Optional. A label to identify this entry.
965          &quot;value&quot;: &quot;A String&quot;, # The allowlisted value for the access control list.
966        },
967      ],
968      &quot;ipv4Enabled&quot;: True or False, # Whether the instance is assigned a public IP address or not.
969      &quot;privateNetwork&quot;: &quot;A String&quot;, # The resource link for the VPC network from which the Cloud SQL instance is accessible for private IP. For example, **/projects/myProject/global/networks/default**. This setting can be updated, but it cannot be removed after it is set.
970      &quot;requireSsl&quot;: True or False, # Whether SSL connections over IP are enforced or not.
971    },
972    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#settings**.
973    &quot;locationPreference&quot;: { # Preferred location. This specifies where a Cloud SQL instance is located. Note that if the preferred location is not available, the instance will be located as close as possible within the region. Only one location may be specified. # The location preference settings. This allows the instance to be located as near as possible to either an App Engine app or Compute Engine zone for better performance. App Engine co-location was only applicable to First Generation instances.
974      &quot;followGaeApplication&quot;: &quot;A String&quot;, # The App Engine application to follow, it must be in the same region as the Cloud SQL instance. WARNING: Changing this might restart the instance.
975      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#locationPreference**.
976      &quot;secondaryZone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone for the secondary/failover (for example: us-central1-a, us-central1-b, etc.). Reserved for future use.
977      &quot;zone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone (for example: us-central1-a, us-central1-b, etc.). WARNING: Changing this might restart the instance.
978    },
979    &quot;maintenanceWindow&quot;: { # Maintenance window. This specifies when a Cloud SQL instance is restarted for system maintenance purposes. # The maintenance window for this instance. This specifies when the instance can be restarted for maintenance purposes.
980      &quot;day&quot;: 42, # day of week (1-7), starting on Monday.
981      &quot;hour&quot;: 42, # hour of day - 0 to 23.
982      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#maintenanceWindow**.
983      &quot;updateTrack&quot;: &quot;A String&quot;, # Maintenance timing setting: **canary** (Earlier) or **stable** (Later). [Learn more](https://cloud.google.com/sql/docs/mysql/instance-settings#maintenance-timing-2ndgen).
984    },
985    &quot;passwordValidationPolicy&quot;: { # Database instance local user password validation policy # The local user password validation policy of the instance.
986      &quot;complexity&quot;: &quot;A String&quot;, # The complexity of the password.
987      &quot;disallowUsernameSubstring&quot;: True or False, # Disallow username as a part of the password.
988      &quot;minLength&quot;: 42, # Minimum number of characters allowed.
989      &quot;passwordChangeInterval&quot;: &quot;A String&quot;, # Minimum interval after which the password can be changed.
990      &quot;reuseInterval&quot;: 42, # Number of previous passwords that cannot be reused.
991    },
992    &quot;pricingPlan&quot;: &quot;A String&quot;, # The pricing plan for this instance. This can be either **PER_USE** or **PACKAGE**. Only **PER_USE** is supported for Second Generation instances.
993    &quot;replicationType&quot;: &quot;A String&quot;, # The type of replication this instance uses. This can be either **ASYNCHRONOUS** or **SYNCHRONOUS**. (Deprecated) This property was only applicable to First Generation instances.
994    &quot;settingsVersion&quot;: &quot;A String&quot;, # The version of instance settings. This is a required field for update method to make sure concurrent updates are handled properly. During update, use the most recent settingsVersion value for this instance and do not try to update this value.
995    &quot;sqlServerAuditConfig&quot;: { # SQL Server specific audit configuration. # SQL Server specific audit configuration.
996      &quot;bucket&quot;: &quot;A String&quot;, # The name of the destination bucket (e.g., gs://mybucket).
997      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#sqlServerAuditConfig
998    },
999    &quot;storageAutoResize&quot;: True or False, # Configuration to increase storage size automatically. The default value is true.
1000    &quot;storageAutoResizeLimit&quot;: &quot;A String&quot;, # The maximum size to which storage capacity can be automatically increased. The default value is 0, which specifies that there is no limit.
1001    &quot;tier&quot;: &quot;A String&quot;, # The tier (or machine type) for this instance, for example **db-custom-1-3840**. WARNING: Changing this restarts the instance.
1002    &quot;userLabels&quot;: { # User-provided labels, represented as a dictionary where each label is a single key value pair.
1003      &quot;a_key&quot;: &quot;A String&quot;,
1004    },
1005  },
1006  &quot;state&quot;: &quot;A String&quot;, # The current serving state of the Cloud SQL instance.
1007  &quot;suspensionReason&quot;: [ # If the instance state is SUSPENDED, the reason for the suspension.
1008    &quot;A String&quot;,
1009  ],
1010}</pre>
1011</div>
1012
1013<div class="method">
1014    <code class="details" id="import_">import_(project, instance, body=None, x__xgafv=None)</code>
1015  <pre>Imports data into a Cloud SQL instance from a SQL dump or CSV file in Cloud Storage.
1016
1017Args:
1018  project: string, Project ID of the project that contains the instance. (required)
1019  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
1020  body: object, The request body.
1021    The object takes the form of:
1022
1023{ # Database instance import request.
1024  &quot;importContext&quot;: { # Database instance import context. # Contains details about the import operation.
1025    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
1026      &quot;encryptionOptions&quot;: {
1027        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1028        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
1029        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1030      },
1031    },
1032    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
1033      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
1034        &quot;A String&quot;,
1035      ],
1036      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1037      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1038      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1039      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1040      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
1041    },
1042    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
1043    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
1044    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
1045    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
1046    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
1047  },
1048}
1049
1050  x__xgafv: string, V1 error format.
1051    Allowed values
1052      1 - v1 error format
1053      2 - v2 error format
1054
1055Returns:
1056  An object of the form:
1057
1058    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
1059  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
1060    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
1061    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
1062  },
1063  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1064  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
1065    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
1066      { # Database instance operation error.
1067        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
1068        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
1069        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
1070      },
1071    ],
1072    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
1073  },
1074  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
1075    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
1076      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1077      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1078      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1079      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1080      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
1081    },
1082    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
1083      &quot;A String&quot;,
1084    ],
1085    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
1086    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
1087    &quot;offload&quot;: True or False, # Option for export offload.
1088    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
1089      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
1090        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
1091      },
1092      &quot;schemaOnly&quot;: True or False, # Export only schemas.
1093      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
1094        &quot;A String&quot;,
1095      ],
1096    },
1097    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
1098  },
1099  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
1100    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
1101      &quot;encryptionOptions&quot;: {
1102        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1103        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
1104        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1105      },
1106    },
1107    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
1108      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
1109        &quot;A String&quot;,
1110      ],
1111      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1112      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1113      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1114      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1115      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
1116    },
1117    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
1118    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
1119    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
1120    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
1121    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
1122  },
1123  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1124  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
1125  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
1126  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
1127  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1128  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1129  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
1130  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
1131  &quot;targetLink&quot;: &quot;A String&quot;,
1132  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
1133  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
1134}</pre>
1135</div>
1136
1137<div class="method">
1138    <code class="details" id="insert">insert(project, body=None, x__xgafv=None)</code>
1139  <pre>Creates a new Cloud SQL instance.
1140
1141Args:
1142  project: string, Project ID of the project to which the newly created Cloud SQL instances should belong. (required)
1143  body: object, The request body.
1144    The object takes the form of:
1145
1146{ # A Cloud SQL instance resource.
1147  &quot;backendType&quot;: &quot;A String&quot;, # The backend type. **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A database server that is not managed by Google. This property is read-only; use the **tier** property in the **settings** object to determine the database type.
1148  &quot;connectionName&quot;: &quot;A String&quot;, # Connection name of the Cloud SQL instance used in connection strings.
1149  &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time when the instance was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1150  &quot;currentDiskSize&quot;: &quot;A String&quot;, # The current disk usage of the instance in bytes. This property has been deprecated. Use the &quot;cloudsql.googleapis.com/database/disk/bytes_used&quot; metric in Cloud Monitoring API instead. Please see [this announcement](https://groups.google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ) for details.
1151  &quot;databaseInstalledVersion&quot;: &quot;A String&quot;, # Output only. Stores the current database version running on the instance including minor version such as **MYSQL_8_0_18**.
1152  &quot;databaseVersion&quot;: &quot;A String&quot;, # The database engine type and version. The **databaseVersion** field cannot be changed after instance creation.
1153  &quot;diskEncryptionConfiguration&quot;: { # Disk encryption configuration for an instance. # Disk encryption configuration specific to an instance.
1154    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionConfiguration**.
1155    &quot;kmsKeyName&quot;: &quot;A String&quot;, # Resource name of KMS key for disk encryption
1156  },
1157  &quot;diskEncryptionStatus&quot;: { # Disk encryption status for an instance. # Disk encryption status specific to an instance.
1158    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionStatus**.
1159    &quot;kmsKeyVersionName&quot;: &quot;A String&quot;, # KMS key version used to encrypt the Cloud SQL instance resource
1160  },
1161  &quot;etag&quot;: &quot;A String&quot;, # This field is deprecated and will be removed from a future version of the API. Use the **settings.settingsVersion** field instead.
1162  &quot;failoverReplica&quot;: { # The name and status of the failover replica.
1163    &quot;available&quot;: True or False, # The availability status of the failover replica. A false status indicates that the failover replica is out of sync. The primary instance can only failover to the failover replica when the status is true.
1164    &quot;name&quot;: &quot;A String&quot;, # The name of the failover replica. If specified at instance creation, a failover replica is created for the instance. The name doesn&#x27;t include the project ID.
1165  },
1166  &quot;gceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the instance is currently serving from. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary zone. WARNING: Changing this might restart the instance.
1167  &quot;instanceType&quot;: &quot;A String&quot;, # The instance type.
1168  &quot;ipAddresses&quot;: [ # The assigned IP addresses for the instance.
1169    { # Database instance IP Mapping.
1170      &quot;ipAddress&quot;: &quot;A String&quot;, # The IP address assigned.
1171      &quot;timeToRetire&quot;: &quot;A String&quot;, # The due time for this IP to be retired in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**. This field is only available when the IP is scheduled to be retired.
1172      &quot;type&quot;: &quot;A String&quot;, # The type of this IP address. A **PRIMARY** address is a public address that can accept incoming connections. A **PRIVATE** address is a private address that can accept incoming connections. An **OUTGOING** address is the source address of connections originating from the instance, if supported.
1173    },
1174  ],
1175  &quot;ipv6Address&quot;: &quot;A String&quot;, # The IPv6 address assigned to the instance. (Deprecated) This property was applicable only to First Generation instances.
1176  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instance**.
1177  &quot;masterInstanceName&quot;: &quot;A String&quot;, # The name of the instance which will act as primary in the replication setup.
1178  &quot;maxDiskSize&quot;: &quot;A String&quot;, # The maximum disk size of the instance in bytes.
1179  &quot;name&quot;: &quot;A String&quot;, # Name of the Cloud SQL instance. This does not include the project ID.
1180  &quot;onPremisesConfiguration&quot;: { # On-premises instance configuration. # Configuration specific to on-premises instances.
1181    &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
1182    &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
1183    &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
1184    &quot;dumpFilePath&quot;: &quot;A String&quot;, # The dump file to create the Cloud SQL replica.
1185    &quot;hostPort&quot;: &quot;A String&quot;, # The host and port of the on-premises instance in host:port format
1186    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#onPremisesConfiguration**.
1187    &quot;password&quot;: &quot;A String&quot;, # The password for connecting to on-premises instance.
1188    &quot;sourceInstance&quot;: { # Reference to another Cloud SQL instance. # The reference to Cloud SQL instance if the source is Cloud SQL.
1189      &quot;name&quot;: &quot;A String&quot;, # The name of the Cloud SQL instance being referenced. This does not include the project ID.
1190      &quot;project&quot;: &quot;A String&quot;, # The project ID of the Cloud SQL instance being referenced. The default is the same project ID as the instance references it.
1191      &quot;region&quot;: &quot;A String&quot;, # The region of the Cloud SQL instance being referenced.
1192    },
1193    &quot;username&quot;: &quot;A String&quot;, # The username for connecting to on-premises instance.
1194  },
1195  &quot;outOfDiskReport&quot;: { # This message wraps up the information written by out-of-disk detection job. # This field represents the report generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
1196    &quot;sqlMinRecommendedIncreaseSizeGb&quot;: 42, # The minimum recommended increase size in GigaBytes This field is consumed by the frontend * Writers: * the proactive database wellness job for OOD. * Readers:
1197    &quot;sqlOutOfDiskState&quot;: &quot;A String&quot;, # This field represents the state generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
1198  },
1199  &quot;project&quot;: &quot;A String&quot;, # The project ID of the project containing the Cloud SQL instance. The Google apps domain is prefixed if applicable.
1200  &quot;region&quot;: &quot;A String&quot;, # The geographical region. Can be: * **us-central** (**FIRST_GEN** instances only) * **us-central1** (**SECOND_GEN** instances only) * **asia-east1** or **europe-west1**. Defaults to **us-central** or **us-central1** depending on the instance type. The region cannot be changed after instance creation.
1201  &quot;replicaConfiguration&quot;: { # Read-replica configuration for connecting to the primary instance. # Configuration specific to failover replicas and read replicas.
1202    &quot;failoverTarget&quot;: True or False, # Specifies if the replica is the failover target. If the field is set to **true** the replica will be designated as a failover replica. In case the primary instance fails, the replica instance will be promoted as the new primary instance. Only one replica can be specified as failover target, and the replica has to be in different zone with the primary instance.
1203    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#replicaConfiguration**.
1204    &quot;mysqlReplicaConfiguration&quot;: { # Read-replica configuration specific to MySQL databases. # MySQL specific configuration when replicating from a MySQL on-premises primary instance. Replication configuration information such as the username, password, certificates, and keys are not stored in the instance metadata. The configuration information is used only to set up the replication connection and is stored by MySQL in a file named **master.info** in the data directory.
1205      &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
1206      &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
1207      &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
1208      &quot;connectRetryInterval&quot;: 42, # Seconds to wait between connect retries. MySQL&#x27;s default is 60 seconds.
1209      &quot;dumpFilePath&quot;: &quot;A String&quot;, # Path to a SQL dump file in Google Cloud Storage from which the replica instance is to be created. The URI is in the form gs://bucketName/fileName. Compressed gzip files (.gz) are also supported. Dumps have the binlog co-ordinates from which replication begins. This can be accomplished by setting --master-data to 1 when using mysqldump.
1210      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#mysqlReplicaConfiguration**.
1211      &quot;masterHeartbeatPeriod&quot;: &quot;A String&quot;, # Interval in milliseconds between replication heartbeats.
1212      &quot;password&quot;: &quot;A String&quot;, # The password for the replication connection.
1213      &quot;sslCipher&quot;: &quot;A String&quot;, # A list of permissible ciphers to use for SSL encryption.
1214      &quot;username&quot;: &quot;A String&quot;, # The username for the replication connection.
1215      &quot;verifyServerCertificate&quot;: True or False, # Whether or not to check the primary instance&#x27;s Common Name value in the certificate that it sends during the SSL handshake.
1216    },
1217  },
1218  &quot;replicaNames&quot;: [ # The replicas of the instance.
1219    &quot;A String&quot;,
1220  ],
1221  &quot;rootPassword&quot;: &quot;A String&quot;, # Initial root password. Use only on creation.
1222  &quot;satisfiesPzs&quot;: True or False, # The status indicating if instance satisfiesPzs. Reserved for future use.
1223  &quot;scheduledMaintenance&quot;: { # Any scheduled maintenancce for this instance. # The start time of any upcoming scheduled maintenance for this instance.
1224    &quot;canDefer&quot;: True or False,
1225    &quot;canReschedule&quot;: True or False, # If the scheduled maintenance can be rescheduled.
1226    &quot;scheduleDeadlineTime&quot;: &quot;A String&quot;, # Maintenance cannot be rescheduled to start beyond this deadline.
1227    &quot;startTime&quot;: &quot;A String&quot;, # The start time of any upcoming scheduled maintenance for this instance.
1228  },
1229  &quot;secondaryGceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the failover instance is currently serving from for a regional instance. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary/failover zone. Reserved for future use.
1230  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1231  &quot;serverCaCert&quot;: { # SslCerts Resource # SSL configuration.
1232    &quot;cert&quot;: &quot;A String&quot;, # PEM representation.
1233    &quot;certSerialNumber&quot;: &quot;A String&quot;, # Serial number, as extracted from the certificate.
1234    &quot;commonName&quot;: &quot;A String&quot;, # User supplied name. Constrained to [a-zA-Z.-_ ]+.
1235    &quot;createTime&quot;: &quot;A String&quot;, # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
1236    &quot;expirationTime&quot;: &quot;A String&quot;, # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1237    &quot;instance&quot;: &quot;A String&quot;, # Name of the database instance.
1238    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#sslCert**.
1239    &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1240    &quot;sha1Fingerprint&quot;: &quot;A String&quot;, # Sha1 Fingerprint.
1241  },
1242  &quot;serviceAccountEmailAddress&quot;: &quot;A String&quot;, # The service account email address assigned to the instance. This property is read-only.
1243  &quot;settings&quot;: { # Database instance settings. # The user settings.
1244    &quot;activationPolicy&quot;: &quot;A String&quot;, # The activation policy specifies when the instance is activated; it is applicable only when the instance state is RUNNABLE. Valid values: * **ALWAYS**: The instance is on, and remains so even in the absence of connection requests. * **NEVER**: The instance is off; it is not activated, even if a connection request arrives.
1245    &quot;activeDirectoryConfig&quot;: { # Active Directory configuration, relevant only for Cloud SQL for SQL Server. # Active Directory configuration, relevant only for Cloud SQL for SQL Server.
1246      &quot;domain&quot;: &quot;A String&quot;, # The name of the domain (e.g., mydomain.com).
1247      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#activeDirectoryConfig.
1248    },
1249    &quot;authorizedGaeApplications&quot;: [ # The App Engine app IDs that can access this instance. (Deprecated) Applied to First Generation instances only.
1250      &quot;A String&quot;,
1251    ],
1252    &quot;availabilityType&quot;: &quot;A String&quot;, # Availability type. Potential values: * **ZONAL**: The instance serves data from only one zone. Outages in that zone affect data accessibility. * **REGIONAL**: The instance can serve data from more than one zone in a region (it is highly available)./ For more information, see [Overview of the High Availability Configuration](https://cloud.google.com/sql/docs/mysql/high-availability).
1253    &quot;backupConfiguration&quot;: { # Database instance backup configuration. # The daily backup configuration for the instance.
1254      &quot;backupRetentionSettings&quot;: { # We currently only support backup retention by specifying the number of backups we will retain. # Backup retention settings.
1255        &quot;retainedBackups&quot;: 42, # Depending on the value of retention_unit, this is used to determine if a backup needs to be deleted. If retention_unit is &#x27;COUNT&#x27;, we will retain this many backups.
1256        &quot;retentionUnit&quot;: &quot;A String&quot;, # The unit that &#x27;retained_backups&#x27; represents.
1257      },
1258      &quot;binaryLogEnabled&quot;: True or False, # (MySQL only) Whether binary log is enabled. If backup configuration is disabled, binarylog must be disabled as well.
1259      &quot;enabled&quot;: True or False, # Whether this configuration is enabled.
1260      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupConfiguration**.
1261      &quot;location&quot;: &quot;A String&quot;, # Location of the backup
1262      &quot;pointInTimeRecoveryEnabled&quot;: True or False, # (Postgres only) Whether point in time recovery is enabled.
1263      &quot;replicationLogArchivingEnabled&quot;: True or False, # Reserved for future use.
1264      &quot;startTime&quot;: &quot;A String&quot;, # Start time for the daily backup configuration in UTC timezone in the 24 hour format - **HH:MM**.
1265      &quot;transactionLogRetentionDays&quot;: 42, # The number of days of transaction logs we retain for point in time restore, from 1-7.
1266    },
1267    &quot;collation&quot;: &quot;A String&quot;, # The name of server Instance collation.
1268    &quot;crashSafeReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether database flags for crash-safe replication are enabled. This property was only applicable to First Generation instances.
1269    &quot;dataDiskSizeGb&quot;: &quot;A String&quot;, # The size of data disk, in GB. The data disk size minimum is 10GB.
1270    &quot;dataDiskType&quot;: &quot;A String&quot;, # The type of data disk: **PD_SSD** (default) or **PD_HDD**. Not used for First Generation instances.
1271    &quot;databaseFlags&quot;: [ # The database flags passed to the instance at startup.
1272      { # Database flags for Cloud SQL instances.
1273        &quot;name&quot;: &quot;A String&quot;, # The name of the flag. These flags are passed at instance startup, so include both server options and system variables. Flags are specified with underscores, not hyphens. For more information, see [Configuring Database Flags](https://cloud.google.com/sql/docs/mysql/flags) in the Cloud SQL documentation.
1274        &quot;value&quot;: &quot;A String&quot;, # The value of the flag. Booleans are set to **on** for true and **off** for false. This field must be omitted if the flag doesn&#x27;t take a value.
1275      },
1276    ],
1277    &quot;databaseReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether replication is enabled or not. WARNING: Changing this restarts the instance.
1278    &quot;denyMaintenancePeriods&quot;: [ # Deny maintenance periods
1279      { # Deny maintenance Periods. This specifies a date range during when all CSA rollout will be denied.
1280        &quot;endDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; end date. If the year of the end date is empty, the year of the start date also must be empty. In this case, it means the no maintenance interval recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
1281        &quot;startDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; start date. If the year of the start date is empty, the year of the end date also must be empty. In this case, it means the deny maintenance period recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
1282        &quot;time&quot;: &quot;A String&quot;, # Time in UTC when the &quot;deny maintenance period&quot; starts on start_date and ends on end_date. The time is in format: HH:mm:SS, i.e., 00:00:00
1283      },
1284    ],
1285    &quot;insightsConfig&quot;: { # Insights configuration. This specifies when Cloud SQL Insights feature is enabled and optional configuration. # Insights configuration, for now relevant only for Postgres.
1286      &quot;queryInsightsEnabled&quot;: True or False, # Whether Query Insights feature is enabled.
1287      &quot;queryPlansPerMinute&quot;: 42, # Number of query execution plans captured by Insights per minute for all queries combined. Default is 5.
1288      &quot;queryStringLength&quot;: 42, # Maximum query length stored in bytes. Default value: 1024 bytes. Range: 256-4500 bytes. Query length more than this field value will be truncated to this value. When unset, query length will be the default value. Changing query length will restart the database.
1289      &quot;recordApplicationTags&quot;: True or False, # Whether Query Insights will record application tags from query when enabled.
1290      &quot;recordClientAddress&quot;: True or False, # Whether Query Insights will record client address when enabled.
1291    },
1292    &quot;ipConfiguration&quot;: { # IP Management configuration. # The settings for IP Management. This allows to enable or disable the instance IP and manage which external networks can connect to the instance. The IPv4 address cannot be disabled for Second Generation instances.
1293      &quot;allocatedIpRange&quot;: &quot;A String&quot;, # The name of the allocated ip range for the private ip CloudSQL instance. For example: &quot;google-managed-services-default&quot;. If set, the instance ip will be created in the allocated range. The range name must comply with [RFC 1035](https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?.`
1294      &quot;authorizedNetworks&quot;: [ # The list of external networks that are allowed to connect to the instance using the IP. In &#x27;CIDR&#x27; notation, also known as &#x27;slash&#x27; notation (for example: **157.197.200.0/24**).
1295        { # An entry for an Access Control list.
1296          &quot;expirationTime&quot;: &quot;A String&quot;, # The time when this access control entry expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1297          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#aclEntry**.
1298          &quot;name&quot;: &quot;A String&quot;, # Optional. A label to identify this entry.
1299          &quot;value&quot;: &quot;A String&quot;, # The allowlisted value for the access control list.
1300        },
1301      ],
1302      &quot;ipv4Enabled&quot;: True or False, # Whether the instance is assigned a public IP address or not.
1303      &quot;privateNetwork&quot;: &quot;A String&quot;, # The resource link for the VPC network from which the Cloud SQL instance is accessible for private IP. For example, **/projects/myProject/global/networks/default**. This setting can be updated, but it cannot be removed after it is set.
1304      &quot;requireSsl&quot;: True or False, # Whether SSL connections over IP are enforced or not.
1305    },
1306    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#settings**.
1307    &quot;locationPreference&quot;: { # Preferred location. This specifies where a Cloud SQL instance is located. Note that if the preferred location is not available, the instance will be located as close as possible within the region. Only one location may be specified. # The location preference settings. This allows the instance to be located as near as possible to either an App Engine app or Compute Engine zone for better performance. App Engine co-location was only applicable to First Generation instances.
1308      &quot;followGaeApplication&quot;: &quot;A String&quot;, # The App Engine application to follow, it must be in the same region as the Cloud SQL instance. WARNING: Changing this might restart the instance.
1309      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#locationPreference**.
1310      &quot;secondaryZone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone for the secondary/failover (for example: us-central1-a, us-central1-b, etc.). Reserved for future use.
1311      &quot;zone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone (for example: us-central1-a, us-central1-b, etc.). WARNING: Changing this might restart the instance.
1312    },
1313    &quot;maintenanceWindow&quot;: { # Maintenance window. This specifies when a Cloud SQL instance is restarted for system maintenance purposes. # The maintenance window for this instance. This specifies when the instance can be restarted for maintenance purposes.
1314      &quot;day&quot;: 42, # day of week (1-7), starting on Monday.
1315      &quot;hour&quot;: 42, # hour of day - 0 to 23.
1316      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#maintenanceWindow**.
1317      &quot;updateTrack&quot;: &quot;A String&quot;, # Maintenance timing setting: **canary** (Earlier) or **stable** (Later). [Learn more](https://cloud.google.com/sql/docs/mysql/instance-settings#maintenance-timing-2ndgen).
1318    },
1319    &quot;passwordValidationPolicy&quot;: { # Database instance local user password validation policy # The local user password validation policy of the instance.
1320      &quot;complexity&quot;: &quot;A String&quot;, # The complexity of the password.
1321      &quot;disallowUsernameSubstring&quot;: True or False, # Disallow username as a part of the password.
1322      &quot;minLength&quot;: 42, # Minimum number of characters allowed.
1323      &quot;passwordChangeInterval&quot;: &quot;A String&quot;, # Minimum interval after which the password can be changed.
1324      &quot;reuseInterval&quot;: 42, # Number of previous passwords that cannot be reused.
1325    },
1326    &quot;pricingPlan&quot;: &quot;A String&quot;, # The pricing plan for this instance. This can be either **PER_USE** or **PACKAGE**. Only **PER_USE** is supported for Second Generation instances.
1327    &quot;replicationType&quot;: &quot;A String&quot;, # The type of replication this instance uses. This can be either **ASYNCHRONOUS** or **SYNCHRONOUS**. (Deprecated) This property was only applicable to First Generation instances.
1328    &quot;settingsVersion&quot;: &quot;A String&quot;, # The version of instance settings. This is a required field for update method to make sure concurrent updates are handled properly. During update, use the most recent settingsVersion value for this instance and do not try to update this value.
1329    &quot;sqlServerAuditConfig&quot;: { # SQL Server specific audit configuration. # SQL Server specific audit configuration.
1330      &quot;bucket&quot;: &quot;A String&quot;, # The name of the destination bucket (e.g., gs://mybucket).
1331      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#sqlServerAuditConfig
1332    },
1333    &quot;storageAutoResize&quot;: True or False, # Configuration to increase storage size automatically. The default value is true.
1334    &quot;storageAutoResizeLimit&quot;: &quot;A String&quot;, # The maximum size to which storage capacity can be automatically increased. The default value is 0, which specifies that there is no limit.
1335    &quot;tier&quot;: &quot;A String&quot;, # The tier (or machine type) for this instance, for example **db-custom-1-3840**. WARNING: Changing this restarts the instance.
1336    &quot;userLabels&quot;: { # User-provided labels, represented as a dictionary where each label is a single key value pair.
1337      &quot;a_key&quot;: &quot;A String&quot;,
1338    },
1339  },
1340  &quot;state&quot;: &quot;A String&quot;, # The current serving state of the Cloud SQL instance.
1341  &quot;suspensionReason&quot;: [ # If the instance state is SUSPENDED, the reason for the suspension.
1342    &quot;A String&quot;,
1343  ],
1344}
1345
1346  x__xgafv: string, V1 error format.
1347    Allowed values
1348      1 - v1 error format
1349      2 - v2 error format
1350
1351Returns:
1352  An object of the form:
1353
1354    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
1355  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
1356    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
1357    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
1358  },
1359  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1360  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
1361    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
1362      { # Database instance operation error.
1363        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
1364        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
1365        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
1366      },
1367    ],
1368    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
1369  },
1370  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
1371    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
1372      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1373      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1374      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1375      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1376      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
1377    },
1378    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
1379      &quot;A String&quot;,
1380    ],
1381    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
1382    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
1383    &quot;offload&quot;: True or False, # Option for export offload.
1384    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
1385      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
1386        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
1387      },
1388      &quot;schemaOnly&quot;: True or False, # Export only schemas.
1389      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
1390        &quot;A String&quot;,
1391      ],
1392    },
1393    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
1394  },
1395  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
1396    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
1397      &quot;encryptionOptions&quot;: {
1398        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1399        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
1400        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1401      },
1402    },
1403    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
1404      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
1405        &quot;A String&quot;,
1406      ],
1407      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1408      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1409      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1410      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1411      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
1412    },
1413    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
1414    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
1415    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
1416    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
1417    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
1418  },
1419  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1420  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
1421  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
1422  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
1423  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1424  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1425  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
1426  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
1427  &quot;targetLink&quot;: &quot;A String&quot;,
1428  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
1429  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
1430}</pre>
1431</div>
1432
1433<div class="method">
1434    <code class="details" id="list">list(project, filter=None, maxResults=None, pageToken=None, x__xgafv=None)</code>
1435  <pre>Lists instances under a given project.
1436
1437Args:
1438  project: string, Project ID of the project for which to list Cloud SQL instances. (required)
1439  filter: string, A filter expression that filters resources listed in the response. The expression is in the form of field:value. For example, &#x27;instanceType:CLOUD_SQL_INSTANCE&#x27;. Fields can be nested as needed as per their JSON representation, such as &#x27;settings.userLabels.auto_start:true&#x27;. Multiple filter queries are space-separated. For example. &#x27;state:RUNNABLE instanceType:CLOUD_SQL_INSTANCE&#x27;. By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly.
1440  maxResults: integer, The maximum number of results to return per response.
1441  pageToken: string, A previously-returned page token representing part of the larger set of results to view.
1442  x__xgafv: string, V1 error format.
1443    Allowed values
1444      1 - v1 error format
1445      2 - v2 error format
1446
1447Returns:
1448  An object of the form:
1449
1450    { # Database instances list response.
1451  &quot;items&quot;: [ # List of database instance resources.
1452    { # A Cloud SQL instance resource.
1453      &quot;backendType&quot;: &quot;A String&quot;, # The backend type. **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A database server that is not managed by Google. This property is read-only; use the **tier** property in the **settings** object to determine the database type.
1454      &quot;connectionName&quot;: &quot;A String&quot;, # Connection name of the Cloud SQL instance used in connection strings.
1455      &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time when the instance was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1456      &quot;currentDiskSize&quot;: &quot;A String&quot;, # The current disk usage of the instance in bytes. This property has been deprecated. Use the &quot;cloudsql.googleapis.com/database/disk/bytes_used&quot; metric in Cloud Monitoring API instead. Please see [this announcement](https://groups.google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ) for details.
1457      &quot;databaseInstalledVersion&quot;: &quot;A String&quot;, # Output only. Stores the current database version running on the instance including minor version such as **MYSQL_8_0_18**.
1458      &quot;databaseVersion&quot;: &quot;A String&quot;, # The database engine type and version. The **databaseVersion** field cannot be changed after instance creation.
1459      &quot;diskEncryptionConfiguration&quot;: { # Disk encryption configuration for an instance. # Disk encryption configuration specific to an instance.
1460        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionConfiguration**.
1461        &quot;kmsKeyName&quot;: &quot;A String&quot;, # Resource name of KMS key for disk encryption
1462      },
1463      &quot;diskEncryptionStatus&quot;: { # Disk encryption status for an instance. # Disk encryption status specific to an instance.
1464        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionStatus**.
1465        &quot;kmsKeyVersionName&quot;: &quot;A String&quot;, # KMS key version used to encrypt the Cloud SQL instance resource
1466      },
1467      &quot;etag&quot;: &quot;A String&quot;, # This field is deprecated and will be removed from a future version of the API. Use the **settings.settingsVersion** field instead.
1468      &quot;failoverReplica&quot;: { # The name and status of the failover replica.
1469        &quot;available&quot;: True or False, # The availability status of the failover replica. A false status indicates that the failover replica is out of sync. The primary instance can only failover to the failover replica when the status is true.
1470        &quot;name&quot;: &quot;A String&quot;, # The name of the failover replica. If specified at instance creation, a failover replica is created for the instance. The name doesn&#x27;t include the project ID.
1471      },
1472      &quot;gceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the instance is currently serving from. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary zone. WARNING: Changing this might restart the instance.
1473      &quot;instanceType&quot;: &quot;A String&quot;, # The instance type.
1474      &quot;ipAddresses&quot;: [ # The assigned IP addresses for the instance.
1475        { # Database instance IP Mapping.
1476          &quot;ipAddress&quot;: &quot;A String&quot;, # The IP address assigned.
1477          &quot;timeToRetire&quot;: &quot;A String&quot;, # The due time for this IP to be retired in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**. This field is only available when the IP is scheduled to be retired.
1478          &quot;type&quot;: &quot;A String&quot;, # The type of this IP address. A **PRIMARY** address is a public address that can accept incoming connections. A **PRIVATE** address is a private address that can accept incoming connections. An **OUTGOING** address is the source address of connections originating from the instance, if supported.
1479        },
1480      ],
1481      &quot;ipv6Address&quot;: &quot;A String&quot;, # The IPv6 address assigned to the instance. (Deprecated) This property was applicable only to First Generation instances.
1482      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instance**.
1483      &quot;masterInstanceName&quot;: &quot;A String&quot;, # The name of the instance which will act as primary in the replication setup.
1484      &quot;maxDiskSize&quot;: &quot;A String&quot;, # The maximum disk size of the instance in bytes.
1485      &quot;name&quot;: &quot;A String&quot;, # Name of the Cloud SQL instance. This does not include the project ID.
1486      &quot;onPremisesConfiguration&quot;: { # On-premises instance configuration. # Configuration specific to on-premises instances.
1487        &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
1488        &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
1489        &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
1490        &quot;dumpFilePath&quot;: &quot;A String&quot;, # The dump file to create the Cloud SQL replica.
1491        &quot;hostPort&quot;: &quot;A String&quot;, # The host and port of the on-premises instance in host:port format
1492        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#onPremisesConfiguration**.
1493        &quot;password&quot;: &quot;A String&quot;, # The password for connecting to on-premises instance.
1494        &quot;sourceInstance&quot;: { # Reference to another Cloud SQL instance. # The reference to Cloud SQL instance if the source is Cloud SQL.
1495          &quot;name&quot;: &quot;A String&quot;, # The name of the Cloud SQL instance being referenced. This does not include the project ID.
1496          &quot;project&quot;: &quot;A String&quot;, # The project ID of the Cloud SQL instance being referenced. The default is the same project ID as the instance references it.
1497          &quot;region&quot;: &quot;A String&quot;, # The region of the Cloud SQL instance being referenced.
1498        },
1499        &quot;username&quot;: &quot;A String&quot;, # The username for connecting to on-premises instance.
1500      },
1501      &quot;outOfDiskReport&quot;: { # This message wraps up the information written by out-of-disk detection job. # This field represents the report generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
1502        &quot;sqlMinRecommendedIncreaseSizeGb&quot;: 42, # The minimum recommended increase size in GigaBytes This field is consumed by the frontend * Writers: * the proactive database wellness job for OOD. * Readers:
1503        &quot;sqlOutOfDiskState&quot;: &quot;A String&quot;, # This field represents the state generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
1504      },
1505      &quot;project&quot;: &quot;A String&quot;, # The project ID of the project containing the Cloud SQL instance. The Google apps domain is prefixed if applicable.
1506      &quot;region&quot;: &quot;A String&quot;, # The geographical region. Can be: * **us-central** (**FIRST_GEN** instances only) * **us-central1** (**SECOND_GEN** instances only) * **asia-east1** or **europe-west1**. Defaults to **us-central** or **us-central1** depending on the instance type. The region cannot be changed after instance creation.
1507      &quot;replicaConfiguration&quot;: { # Read-replica configuration for connecting to the primary instance. # Configuration specific to failover replicas and read replicas.
1508        &quot;failoverTarget&quot;: True or False, # Specifies if the replica is the failover target. If the field is set to **true** the replica will be designated as a failover replica. In case the primary instance fails, the replica instance will be promoted as the new primary instance. Only one replica can be specified as failover target, and the replica has to be in different zone with the primary instance.
1509        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#replicaConfiguration**.
1510        &quot;mysqlReplicaConfiguration&quot;: { # Read-replica configuration specific to MySQL databases. # MySQL specific configuration when replicating from a MySQL on-premises primary instance. Replication configuration information such as the username, password, certificates, and keys are not stored in the instance metadata. The configuration information is used only to set up the replication connection and is stored by MySQL in a file named **master.info** in the data directory.
1511          &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
1512          &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
1513          &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
1514          &quot;connectRetryInterval&quot;: 42, # Seconds to wait between connect retries. MySQL&#x27;s default is 60 seconds.
1515          &quot;dumpFilePath&quot;: &quot;A String&quot;, # Path to a SQL dump file in Google Cloud Storage from which the replica instance is to be created. The URI is in the form gs://bucketName/fileName. Compressed gzip files (.gz) are also supported. Dumps have the binlog co-ordinates from which replication begins. This can be accomplished by setting --master-data to 1 when using mysqldump.
1516          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#mysqlReplicaConfiguration**.
1517          &quot;masterHeartbeatPeriod&quot;: &quot;A String&quot;, # Interval in milliseconds between replication heartbeats.
1518          &quot;password&quot;: &quot;A String&quot;, # The password for the replication connection.
1519          &quot;sslCipher&quot;: &quot;A String&quot;, # A list of permissible ciphers to use for SSL encryption.
1520          &quot;username&quot;: &quot;A String&quot;, # The username for the replication connection.
1521          &quot;verifyServerCertificate&quot;: True or False, # Whether or not to check the primary instance&#x27;s Common Name value in the certificate that it sends during the SSL handshake.
1522        },
1523      },
1524      &quot;replicaNames&quot;: [ # The replicas of the instance.
1525        &quot;A String&quot;,
1526      ],
1527      &quot;rootPassword&quot;: &quot;A String&quot;, # Initial root password. Use only on creation.
1528      &quot;satisfiesPzs&quot;: True or False, # The status indicating if instance satisfiesPzs. Reserved for future use.
1529      &quot;scheduledMaintenance&quot;: { # Any scheduled maintenancce for this instance. # The start time of any upcoming scheduled maintenance for this instance.
1530        &quot;canDefer&quot;: True or False,
1531        &quot;canReschedule&quot;: True or False, # If the scheduled maintenance can be rescheduled.
1532        &quot;scheduleDeadlineTime&quot;: &quot;A String&quot;, # Maintenance cannot be rescheduled to start beyond this deadline.
1533        &quot;startTime&quot;: &quot;A String&quot;, # The start time of any upcoming scheduled maintenance for this instance.
1534      },
1535      &quot;secondaryGceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the failover instance is currently serving from for a regional instance. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary/failover zone. Reserved for future use.
1536      &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1537      &quot;serverCaCert&quot;: { # SslCerts Resource # SSL configuration.
1538        &quot;cert&quot;: &quot;A String&quot;, # PEM representation.
1539        &quot;certSerialNumber&quot;: &quot;A String&quot;, # Serial number, as extracted from the certificate.
1540        &quot;commonName&quot;: &quot;A String&quot;, # User supplied name. Constrained to [a-zA-Z.-_ ]+.
1541        &quot;createTime&quot;: &quot;A String&quot;, # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
1542        &quot;expirationTime&quot;: &quot;A String&quot;, # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1543        &quot;instance&quot;: &quot;A String&quot;, # Name of the database instance.
1544        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#sslCert**.
1545        &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1546        &quot;sha1Fingerprint&quot;: &quot;A String&quot;, # Sha1 Fingerprint.
1547      },
1548      &quot;serviceAccountEmailAddress&quot;: &quot;A String&quot;, # The service account email address assigned to the instance. This property is read-only.
1549      &quot;settings&quot;: { # Database instance settings. # The user settings.
1550        &quot;activationPolicy&quot;: &quot;A String&quot;, # The activation policy specifies when the instance is activated; it is applicable only when the instance state is RUNNABLE. Valid values: * **ALWAYS**: The instance is on, and remains so even in the absence of connection requests. * **NEVER**: The instance is off; it is not activated, even if a connection request arrives.
1551        &quot;activeDirectoryConfig&quot;: { # Active Directory configuration, relevant only for Cloud SQL for SQL Server. # Active Directory configuration, relevant only for Cloud SQL for SQL Server.
1552          &quot;domain&quot;: &quot;A String&quot;, # The name of the domain (e.g., mydomain.com).
1553          &quot;kind&quot;: &quot;A String&quot;, # This is always sql#activeDirectoryConfig.
1554        },
1555        &quot;authorizedGaeApplications&quot;: [ # The App Engine app IDs that can access this instance. (Deprecated) Applied to First Generation instances only.
1556          &quot;A String&quot;,
1557        ],
1558        &quot;availabilityType&quot;: &quot;A String&quot;, # Availability type. Potential values: * **ZONAL**: The instance serves data from only one zone. Outages in that zone affect data accessibility. * **REGIONAL**: The instance can serve data from more than one zone in a region (it is highly available)./ For more information, see [Overview of the High Availability Configuration](https://cloud.google.com/sql/docs/mysql/high-availability).
1559        &quot;backupConfiguration&quot;: { # Database instance backup configuration. # The daily backup configuration for the instance.
1560          &quot;backupRetentionSettings&quot;: { # We currently only support backup retention by specifying the number of backups we will retain. # Backup retention settings.
1561            &quot;retainedBackups&quot;: 42, # Depending on the value of retention_unit, this is used to determine if a backup needs to be deleted. If retention_unit is &#x27;COUNT&#x27;, we will retain this many backups.
1562            &quot;retentionUnit&quot;: &quot;A String&quot;, # The unit that &#x27;retained_backups&#x27; represents.
1563          },
1564          &quot;binaryLogEnabled&quot;: True or False, # (MySQL only) Whether binary log is enabled. If backup configuration is disabled, binarylog must be disabled as well.
1565          &quot;enabled&quot;: True or False, # Whether this configuration is enabled.
1566          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupConfiguration**.
1567          &quot;location&quot;: &quot;A String&quot;, # Location of the backup
1568          &quot;pointInTimeRecoveryEnabled&quot;: True or False, # (Postgres only) Whether point in time recovery is enabled.
1569          &quot;replicationLogArchivingEnabled&quot;: True or False, # Reserved for future use.
1570          &quot;startTime&quot;: &quot;A String&quot;, # Start time for the daily backup configuration in UTC timezone in the 24 hour format - **HH:MM**.
1571          &quot;transactionLogRetentionDays&quot;: 42, # The number of days of transaction logs we retain for point in time restore, from 1-7.
1572        },
1573        &quot;collation&quot;: &quot;A String&quot;, # The name of server Instance collation.
1574        &quot;crashSafeReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether database flags for crash-safe replication are enabled. This property was only applicable to First Generation instances.
1575        &quot;dataDiskSizeGb&quot;: &quot;A String&quot;, # The size of data disk, in GB. The data disk size minimum is 10GB.
1576        &quot;dataDiskType&quot;: &quot;A String&quot;, # The type of data disk: **PD_SSD** (default) or **PD_HDD**. Not used for First Generation instances.
1577        &quot;databaseFlags&quot;: [ # The database flags passed to the instance at startup.
1578          { # Database flags for Cloud SQL instances.
1579            &quot;name&quot;: &quot;A String&quot;, # The name of the flag. These flags are passed at instance startup, so include both server options and system variables. Flags are specified with underscores, not hyphens. For more information, see [Configuring Database Flags](https://cloud.google.com/sql/docs/mysql/flags) in the Cloud SQL documentation.
1580            &quot;value&quot;: &quot;A String&quot;, # The value of the flag. Booleans are set to **on** for true and **off** for false. This field must be omitted if the flag doesn&#x27;t take a value.
1581          },
1582        ],
1583        &quot;databaseReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether replication is enabled or not. WARNING: Changing this restarts the instance.
1584        &quot;denyMaintenancePeriods&quot;: [ # Deny maintenance periods
1585          { # Deny maintenance Periods. This specifies a date range during when all CSA rollout will be denied.
1586            &quot;endDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; end date. If the year of the end date is empty, the year of the start date also must be empty. In this case, it means the no maintenance interval recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
1587            &quot;startDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; start date. If the year of the start date is empty, the year of the end date also must be empty. In this case, it means the deny maintenance period recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
1588            &quot;time&quot;: &quot;A String&quot;, # Time in UTC when the &quot;deny maintenance period&quot; starts on start_date and ends on end_date. The time is in format: HH:mm:SS, i.e., 00:00:00
1589          },
1590        ],
1591        &quot;insightsConfig&quot;: { # Insights configuration. This specifies when Cloud SQL Insights feature is enabled and optional configuration. # Insights configuration, for now relevant only for Postgres.
1592          &quot;queryInsightsEnabled&quot;: True or False, # Whether Query Insights feature is enabled.
1593          &quot;queryPlansPerMinute&quot;: 42, # Number of query execution plans captured by Insights per minute for all queries combined. Default is 5.
1594          &quot;queryStringLength&quot;: 42, # Maximum query length stored in bytes. Default value: 1024 bytes. Range: 256-4500 bytes. Query length more than this field value will be truncated to this value. When unset, query length will be the default value. Changing query length will restart the database.
1595          &quot;recordApplicationTags&quot;: True or False, # Whether Query Insights will record application tags from query when enabled.
1596          &quot;recordClientAddress&quot;: True or False, # Whether Query Insights will record client address when enabled.
1597        },
1598        &quot;ipConfiguration&quot;: { # IP Management configuration. # The settings for IP Management. This allows to enable or disable the instance IP and manage which external networks can connect to the instance. The IPv4 address cannot be disabled for Second Generation instances.
1599          &quot;allocatedIpRange&quot;: &quot;A String&quot;, # The name of the allocated ip range for the private ip CloudSQL instance. For example: &quot;google-managed-services-default&quot;. If set, the instance ip will be created in the allocated range. The range name must comply with [RFC 1035](https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?.`
1600          &quot;authorizedNetworks&quot;: [ # The list of external networks that are allowed to connect to the instance using the IP. In &#x27;CIDR&#x27; notation, also known as &#x27;slash&#x27; notation (for example: **157.197.200.0/24**).
1601            { # An entry for an Access Control list.
1602              &quot;expirationTime&quot;: &quot;A String&quot;, # The time when this access control entry expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1603              &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#aclEntry**.
1604              &quot;name&quot;: &quot;A String&quot;, # Optional. A label to identify this entry.
1605              &quot;value&quot;: &quot;A String&quot;, # The allowlisted value for the access control list.
1606            },
1607          ],
1608          &quot;ipv4Enabled&quot;: True or False, # Whether the instance is assigned a public IP address or not.
1609          &quot;privateNetwork&quot;: &quot;A String&quot;, # The resource link for the VPC network from which the Cloud SQL instance is accessible for private IP. For example, **/projects/myProject/global/networks/default**. This setting can be updated, but it cannot be removed after it is set.
1610          &quot;requireSsl&quot;: True or False, # Whether SSL connections over IP are enforced or not.
1611        },
1612        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#settings**.
1613        &quot;locationPreference&quot;: { # Preferred location. This specifies where a Cloud SQL instance is located. Note that if the preferred location is not available, the instance will be located as close as possible within the region. Only one location may be specified. # The location preference settings. This allows the instance to be located as near as possible to either an App Engine app or Compute Engine zone for better performance. App Engine co-location was only applicable to First Generation instances.
1614          &quot;followGaeApplication&quot;: &quot;A String&quot;, # The App Engine application to follow, it must be in the same region as the Cloud SQL instance. WARNING: Changing this might restart the instance.
1615          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#locationPreference**.
1616          &quot;secondaryZone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone for the secondary/failover (for example: us-central1-a, us-central1-b, etc.). Reserved for future use.
1617          &quot;zone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone (for example: us-central1-a, us-central1-b, etc.). WARNING: Changing this might restart the instance.
1618        },
1619        &quot;maintenanceWindow&quot;: { # Maintenance window. This specifies when a Cloud SQL instance is restarted for system maintenance purposes. # The maintenance window for this instance. This specifies when the instance can be restarted for maintenance purposes.
1620          &quot;day&quot;: 42, # day of week (1-7), starting on Monday.
1621          &quot;hour&quot;: 42, # hour of day - 0 to 23.
1622          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#maintenanceWindow**.
1623          &quot;updateTrack&quot;: &quot;A String&quot;, # Maintenance timing setting: **canary** (Earlier) or **stable** (Later). [Learn more](https://cloud.google.com/sql/docs/mysql/instance-settings#maintenance-timing-2ndgen).
1624        },
1625        &quot;passwordValidationPolicy&quot;: { # Database instance local user password validation policy # The local user password validation policy of the instance.
1626          &quot;complexity&quot;: &quot;A String&quot;, # The complexity of the password.
1627          &quot;disallowUsernameSubstring&quot;: True or False, # Disallow username as a part of the password.
1628          &quot;minLength&quot;: 42, # Minimum number of characters allowed.
1629          &quot;passwordChangeInterval&quot;: &quot;A String&quot;, # Minimum interval after which the password can be changed.
1630          &quot;reuseInterval&quot;: 42, # Number of previous passwords that cannot be reused.
1631        },
1632        &quot;pricingPlan&quot;: &quot;A String&quot;, # The pricing plan for this instance. This can be either **PER_USE** or **PACKAGE**. Only **PER_USE** is supported for Second Generation instances.
1633        &quot;replicationType&quot;: &quot;A String&quot;, # The type of replication this instance uses. This can be either **ASYNCHRONOUS** or **SYNCHRONOUS**. (Deprecated) This property was only applicable to First Generation instances.
1634        &quot;settingsVersion&quot;: &quot;A String&quot;, # The version of instance settings. This is a required field for update method to make sure concurrent updates are handled properly. During update, use the most recent settingsVersion value for this instance and do not try to update this value.
1635        &quot;sqlServerAuditConfig&quot;: { # SQL Server specific audit configuration. # SQL Server specific audit configuration.
1636          &quot;bucket&quot;: &quot;A String&quot;, # The name of the destination bucket (e.g., gs://mybucket).
1637          &quot;kind&quot;: &quot;A String&quot;, # This is always sql#sqlServerAuditConfig
1638        },
1639        &quot;storageAutoResize&quot;: True or False, # Configuration to increase storage size automatically. The default value is true.
1640        &quot;storageAutoResizeLimit&quot;: &quot;A String&quot;, # The maximum size to which storage capacity can be automatically increased. The default value is 0, which specifies that there is no limit.
1641        &quot;tier&quot;: &quot;A String&quot;, # The tier (or machine type) for this instance, for example **db-custom-1-3840**. WARNING: Changing this restarts the instance.
1642        &quot;userLabels&quot;: { # User-provided labels, represented as a dictionary where each label is a single key value pair.
1643          &quot;a_key&quot;: &quot;A String&quot;,
1644        },
1645      },
1646      &quot;state&quot;: &quot;A String&quot;, # The current serving state of the Cloud SQL instance.
1647      &quot;suspensionReason&quot;: [ # If the instance state is SUSPENDED, the reason for the suspension.
1648        &quot;A String&quot;,
1649      ],
1650    },
1651  ],
1652  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instancesList**.
1653  &quot;nextPageToken&quot;: &quot;A String&quot;, # The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results.
1654  &quot;warnings&quot;: [ # List of warnings that occurred while handling the request.
1655    { # An Admin API warning message.
1656      &quot;code&quot;: &quot;A String&quot;, # Code to uniquely identify the warning type.
1657      &quot;message&quot;: &quot;A String&quot;, # The warning message.
1658      &quot;region&quot;: &quot;A String&quot;, # The region name for REGION_UNREACHABLE warning.
1659    },
1660  ],
1661}</pre>
1662</div>
1663
1664<div class="method">
1665    <code class="details" id="listServerCas">listServerCas(project, instance, x__xgafv=None)</code>
1666  <pre>Lists all of the trusted Certificate Authorities (CAs) for the specified instance. There can be up to three CAs listed: the CA that was used to sign the certificate that is currently in use, a CA that has been added but not yet used to sign a certificate, and a CA used to sign a certificate that has previously rotated out.
1667
1668Args:
1669  project: string, Project ID of the project that contains the instance. (required)
1670  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
1671  x__xgafv: string, V1 error format.
1672    Allowed values
1673      1 - v1 error format
1674      2 - v2 error format
1675
1676Returns:
1677  An object of the form:
1678
1679    { # Instances ListServerCas response.
1680  &quot;activeVersion&quot;: &quot;A String&quot;,
1681  &quot;certs&quot;: [ # List of server CA certificates for the instance.
1682    { # SslCerts Resource
1683      &quot;cert&quot;: &quot;A String&quot;, # PEM representation.
1684      &quot;certSerialNumber&quot;: &quot;A String&quot;, # Serial number, as extracted from the certificate.
1685      &quot;commonName&quot;: &quot;A String&quot;, # User supplied name. Constrained to [a-zA-Z.-_ ]+.
1686      &quot;createTime&quot;: &quot;A String&quot;, # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
1687      &quot;expirationTime&quot;: &quot;A String&quot;, # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1688      &quot;instance&quot;: &quot;A String&quot;, # Name of the database instance.
1689      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#sslCert**.
1690      &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1691      &quot;sha1Fingerprint&quot;: &quot;A String&quot;, # Sha1 Fingerprint.
1692    },
1693  ],
1694  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instancesListServerCas**.
1695}</pre>
1696</div>
1697
1698<div class="method">
1699    <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
1700  <pre>Retrieves the next page of results.
1701
1702Args:
1703  previous_request: The request for the previous page. (required)
1704  previous_response: The response from the request for the previous page. (required)
1705
1706Returns:
1707  A request object that you can call &#x27;execute()&#x27; on to request the next
1708  page. Returns None if there are no more items in the collection.
1709    </pre>
1710</div>
1711
1712<div class="method">
1713    <code class="details" id="patch">patch(project, instance, body=None, x__xgafv=None)</code>
1714  <pre>Updates settings of a Cloud SQL instance. This method supports patch semantics.
1715
1716Args:
1717  project: string, Project ID of the project that contains the instance. (required)
1718  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
1719  body: object, The request body.
1720    The object takes the form of:
1721
1722{ # A Cloud SQL instance resource.
1723  &quot;backendType&quot;: &quot;A String&quot;, # The backend type. **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A database server that is not managed by Google. This property is read-only; use the **tier** property in the **settings** object to determine the database type.
1724  &quot;connectionName&quot;: &quot;A String&quot;, # Connection name of the Cloud SQL instance used in connection strings.
1725  &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time when the instance was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1726  &quot;currentDiskSize&quot;: &quot;A String&quot;, # The current disk usage of the instance in bytes. This property has been deprecated. Use the &quot;cloudsql.googleapis.com/database/disk/bytes_used&quot; metric in Cloud Monitoring API instead. Please see [this announcement](https://groups.google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ) for details.
1727  &quot;databaseInstalledVersion&quot;: &quot;A String&quot;, # Output only. Stores the current database version running on the instance including minor version such as **MYSQL_8_0_18**.
1728  &quot;databaseVersion&quot;: &quot;A String&quot;, # The database engine type and version. The **databaseVersion** field cannot be changed after instance creation.
1729  &quot;diskEncryptionConfiguration&quot;: { # Disk encryption configuration for an instance. # Disk encryption configuration specific to an instance.
1730    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionConfiguration**.
1731    &quot;kmsKeyName&quot;: &quot;A String&quot;, # Resource name of KMS key for disk encryption
1732  },
1733  &quot;diskEncryptionStatus&quot;: { # Disk encryption status for an instance. # Disk encryption status specific to an instance.
1734    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionStatus**.
1735    &quot;kmsKeyVersionName&quot;: &quot;A String&quot;, # KMS key version used to encrypt the Cloud SQL instance resource
1736  },
1737  &quot;etag&quot;: &quot;A String&quot;, # This field is deprecated and will be removed from a future version of the API. Use the **settings.settingsVersion** field instead.
1738  &quot;failoverReplica&quot;: { # The name and status of the failover replica.
1739    &quot;available&quot;: True or False, # The availability status of the failover replica. A false status indicates that the failover replica is out of sync. The primary instance can only failover to the failover replica when the status is true.
1740    &quot;name&quot;: &quot;A String&quot;, # The name of the failover replica. If specified at instance creation, a failover replica is created for the instance. The name doesn&#x27;t include the project ID.
1741  },
1742  &quot;gceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the instance is currently serving from. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary zone. WARNING: Changing this might restart the instance.
1743  &quot;instanceType&quot;: &quot;A String&quot;, # The instance type.
1744  &quot;ipAddresses&quot;: [ # The assigned IP addresses for the instance.
1745    { # Database instance IP Mapping.
1746      &quot;ipAddress&quot;: &quot;A String&quot;, # The IP address assigned.
1747      &quot;timeToRetire&quot;: &quot;A String&quot;, # The due time for this IP to be retired in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**. This field is only available when the IP is scheduled to be retired.
1748      &quot;type&quot;: &quot;A String&quot;, # The type of this IP address. A **PRIMARY** address is a public address that can accept incoming connections. A **PRIVATE** address is a private address that can accept incoming connections. An **OUTGOING** address is the source address of connections originating from the instance, if supported.
1749    },
1750  ],
1751  &quot;ipv6Address&quot;: &quot;A String&quot;, # The IPv6 address assigned to the instance. (Deprecated) This property was applicable only to First Generation instances.
1752  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instance**.
1753  &quot;masterInstanceName&quot;: &quot;A String&quot;, # The name of the instance which will act as primary in the replication setup.
1754  &quot;maxDiskSize&quot;: &quot;A String&quot;, # The maximum disk size of the instance in bytes.
1755  &quot;name&quot;: &quot;A String&quot;, # Name of the Cloud SQL instance. This does not include the project ID.
1756  &quot;onPremisesConfiguration&quot;: { # On-premises instance configuration. # Configuration specific to on-premises instances.
1757    &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
1758    &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
1759    &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
1760    &quot;dumpFilePath&quot;: &quot;A String&quot;, # The dump file to create the Cloud SQL replica.
1761    &quot;hostPort&quot;: &quot;A String&quot;, # The host and port of the on-premises instance in host:port format
1762    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#onPremisesConfiguration**.
1763    &quot;password&quot;: &quot;A String&quot;, # The password for connecting to on-premises instance.
1764    &quot;sourceInstance&quot;: { # Reference to another Cloud SQL instance. # The reference to Cloud SQL instance if the source is Cloud SQL.
1765      &quot;name&quot;: &quot;A String&quot;, # The name of the Cloud SQL instance being referenced. This does not include the project ID.
1766      &quot;project&quot;: &quot;A String&quot;, # The project ID of the Cloud SQL instance being referenced. The default is the same project ID as the instance references it.
1767      &quot;region&quot;: &quot;A String&quot;, # The region of the Cloud SQL instance being referenced.
1768    },
1769    &quot;username&quot;: &quot;A String&quot;, # The username for connecting to on-premises instance.
1770  },
1771  &quot;outOfDiskReport&quot;: { # This message wraps up the information written by out-of-disk detection job. # This field represents the report generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
1772    &quot;sqlMinRecommendedIncreaseSizeGb&quot;: 42, # The minimum recommended increase size in GigaBytes This field is consumed by the frontend * Writers: * the proactive database wellness job for OOD. * Readers:
1773    &quot;sqlOutOfDiskState&quot;: &quot;A String&quot;, # This field represents the state generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
1774  },
1775  &quot;project&quot;: &quot;A String&quot;, # The project ID of the project containing the Cloud SQL instance. The Google apps domain is prefixed if applicable.
1776  &quot;region&quot;: &quot;A String&quot;, # The geographical region. Can be: * **us-central** (**FIRST_GEN** instances only) * **us-central1** (**SECOND_GEN** instances only) * **asia-east1** or **europe-west1**. Defaults to **us-central** or **us-central1** depending on the instance type. The region cannot be changed after instance creation.
1777  &quot;replicaConfiguration&quot;: { # Read-replica configuration for connecting to the primary instance. # Configuration specific to failover replicas and read replicas.
1778    &quot;failoverTarget&quot;: True or False, # Specifies if the replica is the failover target. If the field is set to **true** the replica will be designated as a failover replica. In case the primary instance fails, the replica instance will be promoted as the new primary instance. Only one replica can be specified as failover target, and the replica has to be in different zone with the primary instance.
1779    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#replicaConfiguration**.
1780    &quot;mysqlReplicaConfiguration&quot;: { # Read-replica configuration specific to MySQL databases. # MySQL specific configuration when replicating from a MySQL on-premises primary instance. Replication configuration information such as the username, password, certificates, and keys are not stored in the instance metadata. The configuration information is used only to set up the replication connection and is stored by MySQL in a file named **master.info** in the data directory.
1781      &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
1782      &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
1783      &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
1784      &quot;connectRetryInterval&quot;: 42, # Seconds to wait between connect retries. MySQL&#x27;s default is 60 seconds.
1785      &quot;dumpFilePath&quot;: &quot;A String&quot;, # Path to a SQL dump file in Google Cloud Storage from which the replica instance is to be created. The URI is in the form gs://bucketName/fileName. Compressed gzip files (.gz) are also supported. Dumps have the binlog co-ordinates from which replication begins. This can be accomplished by setting --master-data to 1 when using mysqldump.
1786      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#mysqlReplicaConfiguration**.
1787      &quot;masterHeartbeatPeriod&quot;: &quot;A String&quot;, # Interval in milliseconds between replication heartbeats.
1788      &quot;password&quot;: &quot;A String&quot;, # The password for the replication connection.
1789      &quot;sslCipher&quot;: &quot;A String&quot;, # A list of permissible ciphers to use for SSL encryption.
1790      &quot;username&quot;: &quot;A String&quot;, # The username for the replication connection.
1791      &quot;verifyServerCertificate&quot;: True or False, # Whether or not to check the primary instance&#x27;s Common Name value in the certificate that it sends during the SSL handshake.
1792    },
1793  },
1794  &quot;replicaNames&quot;: [ # The replicas of the instance.
1795    &quot;A String&quot;,
1796  ],
1797  &quot;rootPassword&quot;: &quot;A String&quot;, # Initial root password. Use only on creation.
1798  &quot;satisfiesPzs&quot;: True or False, # The status indicating if instance satisfiesPzs. Reserved for future use.
1799  &quot;scheduledMaintenance&quot;: { # Any scheduled maintenancce for this instance. # The start time of any upcoming scheduled maintenance for this instance.
1800    &quot;canDefer&quot;: True or False,
1801    &quot;canReschedule&quot;: True or False, # If the scheduled maintenance can be rescheduled.
1802    &quot;scheduleDeadlineTime&quot;: &quot;A String&quot;, # Maintenance cannot be rescheduled to start beyond this deadline.
1803    &quot;startTime&quot;: &quot;A String&quot;, # The start time of any upcoming scheduled maintenance for this instance.
1804  },
1805  &quot;secondaryGceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the failover instance is currently serving from for a regional instance. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary/failover zone. Reserved for future use.
1806  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1807  &quot;serverCaCert&quot;: { # SslCerts Resource # SSL configuration.
1808    &quot;cert&quot;: &quot;A String&quot;, # PEM representation.
1809    &quot;certSerialNumber&quot;: &quot;A String&quot;, # Serial number, as extracted from the certificate.
1810    &quot;commonName&quot;: &quot;A String&quot;, # User supplied name. Constrained to [a-zA-Z.-_ ]+.
1811    &quot;createTime&quot;: &quot;A String&quot;, # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
1812    &quot;expirationTime&quot;: &quot;A String&quot;, # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1813    &quot;instance&quot;: &quot;A String&quot;, # Name of the database instance.
1814    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#sslCert**.
1815    &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
1816    &quot;sha1Fingerprint&quot;: &quot;A String&quot;, # Sha1 Fingerprint.
1817  },
1818  &quot;serviceAccountEmailAddress&quot;: &quot;A String&quot;, # The service account email address assigned to the instance. This property is read-only.
1819  &quot;settings&quot;: { # Database instance settings. # The user settings.
1820    &quot;activationPolicy&quot;: &quot;A String&quot;, # The activation policy specifies when the instance is activated; it is applicable only when the instance state is RUNNABLE. Valid values: * **ALWAYS**: The instance is on, and remains so even in the absence of connection requests. * **NEVER**: The instance is off; it is not activated, even if a connection request arrives.
1821    &quot;activeDirectoryConfig&quot;: { # Active Directory configuration, relevant only for Cloud SQL for SQL Server. # Active Directory configuration, relevant only for Cloud SQL for SQL Server.
1822      &quot;domain&quot;: &quot;A String&quot;, # The name of the domain (e.g., mydomain.com).
1823      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#activeDirectoryConfig.
1824    },
1825    &quot;authorizedGaeApplications&quot;: [ # The App Engine app IDs that can access this instance. (Deprecated) Applied to First Generation instances only.
1826      &quot;A String&quot;,
1827    ],
1828    &quot;availabilityType&quot;: &quot;A String&quot;, # Availability type. Potential values: * **ZONAL**: The instance serves data from only one zone. Outages in that zone affect data accessibility. * **REGIONAL**: The instance can serve data from more than one zone in a region (it is highly available)./ For more information, see [Overview of the High Availability Configuration](https://cloud.google.com/sql/docs/mysql/high-availability).
1829    &quot;backupConfiguration&quot;: { # Database instance backup configuration. # The daily backup configuration for the instance.
1830      &quot;backupRetentionSettings&quot;: { # We currently only support backup retention by specifying the number of backups we will retain. # Backup retention settings.
1831        &quot;retainedBackups&quot;: 42, # Depending on the value of retention_unit, this is used to determine if a backup needs to be deleted. If retention_unit is &#x27;COUNT&#x27;, we will retain this many backups.
1832        &quot;retentionUnit&quot;: &quot;A String&quot;, # The unit that &#x27;retained_backups&#x27; represents.
1833      },
1834      &quot;binaryLogEnabled&quot;: True or False, # (MySQL only) Whether binary log is enabled. If backup configuration is disabled, binarylog must be disabled as well.
1835      &quot;enabled&quot;: True or False, # Whether this configuration is enabled.
1836      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupConfiguration**.
1837      &quot;location&quot;: &quot;A String&quot;, # Location of the backup
1838      &quot;pointInTimeRecoveryEnabled&quot;: True or False, # (Postgres only) Whether point in time recovery is enabled.
1839      &quot;replicationLogArchivingEnabled&quot;: True or False, # Reserved for future use.
1840      &quot;startTime&quot;: &quot;A String&quot;, # Start time for the daily backup configuration in UTC timezone in the 24 hour format - **HH:MM**.
1841      &quot;transactionLogRetentionDays&quot;: 42, # The number of days of transaction logs we retain for point in time restore, from 1-7.
1842    },
1843    &quot;collation&quot;: &quot;A String&quot;, # The name of server Instance collation.
1844    &quot;crashSafeReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether database flags for crash-safe replication are enabled. This property was only applicable to First Generation instances.
1845    &quot;dataDiskSizeGb&quot;: &quot;A String&quot;, # The size of data disk, in GB. The data disk size minimum is 10GB.
1846    &quot;dataDiskType&quot;: &quot;A String&quot;, # The type of data disk: **PD_SSD** (default) or **PD_HDD**. Not used for First Generation instances.
1847    &quot;databaseFlags&quot;: [ # The database flags passed to the instance at startup.
1848      { # Database flags for Cloud SQL instances.
1849        &quot;name&quot;: &quot;A String&quot;, # The name of the flag. These flags are passed at instance startup, so include both server options and system variables. Flags are specified with underscores, not hyphens. For more information, see [Configuring Database Flags](https://cloud.google.com/sql/docs/mysql/flags) in the Cloud SQL documentation.
1850        &quot;value&quot;: &quot;A String&quot;, # The value of the flag. Booleans are set to **on** for true and **off** for false. This field must be omitted if the flag doesn&#x27;t take a value.
1851      },
1852    ],
1853    &quot;databaseReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether replication is enabled or not. WARNING: Changing this restarts the instance.
1854    &quot;denyMaintenancePeriods&quot;: [ # Deny maintenance periods
1855      { # Deny maintenance Periods. This specifies a date range during when all CSA rollout will be denied.
1856        &quot;endDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; end date. If the year of the end date is empty, the year of the start date also must be empty. In this case, it means the no maintenance interval recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
1857        &quot;startDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; start date. If the year of the start date is empty, the year of the end date also must be empty. In this case, it means the deny maintenance period recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
1858        &quot;time&quot;: &quot;A String&quot;, # Time in UTC when the &quot;deny maintenance period&quot; starts on start_date and ends on end_date. The time is in format: HH:mm:SS, i.e., 00:00:00
1859      },
1860    ],
1861    &quot;insightsConfig&quot;: { # Insights configuration. This specifies when Cloud SQL Insights feature is enabled and optional configuration. # Insights configuration, for now relevant only for Postgres.
1862      &quot;queryInsightsEnabled&quot;: True or False, # Whether Query Insights feature is enabled.
1863      &quot;queryPlansPerMinute&quot;: 42, # Number of query execution plans captured by Insights per minute for all queries combined. Default is 5.
1864      &quot;queryStringLength&quot;: 42, # Maximum query length stored in bytes. Default value: 1024 bytes. Range: 256-4500 bytes. Query length more than this field value will be truncated to this value. When unset, query length will be the default value. Changing query length will restart the database.
1865      &quot;recordApplicationTags&quot;: True or False, # Whether Query Insights will record application tags from query when enabled.
1866      &quot;recordClientAddress&quot;: True or False, # Whether Query Insights will record client address when enabled.
1867    },
1868    &quot;ipConfiguration&quot;: { # IP Management configuration. # The settings for IP Management. This allows to enable or disable the instance IP and manage which external networks can connect to the instance. The IPv4 address cannot be disabled for Second Generation instances.
1869      &quot;allocatedIpRange&quot;: &quot;A String&quot;, # The name of the allocated ip range for the private ip CloudSQL instance. For example: &quot;google-managed-services-default&quot;. If set, the instance ip will be created in the allocated range. The range name must comply with [RFC 1035](https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?.`
1870      &quot;authorizedNetworks&quot;: [ # The list of external networks that are allowed to connect to the instance using the IP. In &#x27;CIDR&#x27; notation, also known as &#x27;slash&#x27; notation (for example: **157.197.200.0/24**).
1871        { # An entry for an Access Control list.
1872          &quot;expirationTime&quot;: &quot;A String&quot;, # The time when this access control entry expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1873          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#aclEntry**.
1874          &quot;name&quot;: &quot;A String&quot;, # Optional. A label to identify this entry.
1875          &quot;value&quot;: &quot;A String&quot;, # The allowlisted value for the access control list.
1876        },
1877      ],
1878      &quot;ipv4Enabled&quot;: True or False, # Whether the instance is assigned a public IP address or not.
1879      &quot;privateNetwork&quot;: &quot;A String&quot;, # The resource link for the VPC network from which the Cloud SQL instance is accessible for private IP. For example, **/projects/myProject/global/networks/default**. This setting can be updated, but it cannot be removed after it is set.
1880      &quot;requireSsl&quot;: True or False, # Whether SSL connections over IP are enforced or not.
1881    },
1882    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#settings**.
1883    &quot;locationPreference&quot;: { # Preferred location. This specifies where a Cloud SQL instance is located. Note that if the preferred location is not available, the instance will be located as close as possible within the region. Only one location may be specified. # The location preference settings. This allows the instance to be located as near as possible to either an App Engine app or Compute Engine zone for better performance. App Engine co-location was only applicable to First Generation instances.
1884      &quot;followGaeApplication&quot;: &quot;A String&quot;, # The App Engine application to follow, it must be in the same region as the Cloud SQL instance. WARNING: Changing this might restart the instance.
1885      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#locationPreference**.
1886      &quot;secondaryZone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone for the secondary/failover (for example: us-central1-a, us-central1-b, etc.). Reserved for future use.
1887      &quot;zone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone (for example: us-central1-a, us-central1-b, etc.). WARNING: Changing this might restart the instance.
1888    },
1889    &quot;maintenanceWindow&quot;: { # Maintenance window. This specifies when a Cloud SQL instance is restarted for system maintenance purposes. # The maintenance window for this instance. This specifies when the instance can be restarted for maintenance purposes.
1890      &quot;day&quot;: 42, # day of week (1-7), starting on Monday.
1891      &quot;hour&quot;: 42, # hour of day - 0 to 23.
1892      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#maintenanceWindow**.
1893      &quot;updateTrack&quot;: &quot;A String&quot;, # Maintenance timing setting: **canary** (Earlier) or **stable** (Later). [Learn more](https://cloud.google.com/sql/docs/mysql/instance-settings#maintenance-timing-2ndgen).
1894    },
1895    &quot;passwordValidationPolicy&quot;: { # Database instance local user password validation policy # The local user password validation policy of the instance.
1896      &quot;complexity&quot;: &quot;A String&quot;, # The complexity of the password.
1897      &quot;disallowUsernameSubstring&quot;: True or False, # Disallow username as a part of the password.
1898      &quot;minLength&quot;: 42, # Minimum number of characters allowed.
1899      &quot;passwordChangeInterval&quot;: &quot;A String&quot;, # Minimum interval after which the password can be changed.
1900      &quot;reuseInterval&quot;: 42, # Number of previous passwords that cannot be reused.
1901    },
1902    &quot;pricingPlan&quot;: &quot;A String&quot;, # The pricing plan for this instance. This can be either **PER_USE** or **PACKAGE**. Only **PER_USE** is supported for Second Generation instances.
1903    &quot;replicationType&quot;: &quot;A String&quot;, # The type of replication this instance uses. This can be either **ASYNCHRONOUS** or **SYNCHRONOUS**. (Deprecated) This property was only applicable to First Generation instances.
1904    &quot;settingsVersion&quot;: &quot;A String&quot;, # The version of instance settings. This is a required field for update method to make sure concurrent updates are handled properly. During update, use the most recent settingsVersion value for this instance and do not try to update this value.
1905    &quot;sqlServerAuditConfig&quot;: { # SQL Server specific audit configuration. # SQL Server specific audit configuration.
1906      &quot;bucket&quot;: &quot;A String&quot;, # The name of the destination bucket (e.g., gs://mybucket).
1907      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#sqlServerAuditConfig
1908    },
1909    &quot;storageAutoResize&quot;: True or False, # Configuration to increase storage size automatically. The default value is true.
1910    &quot;storageAutoResizeLimit&quot;: &quot;A String&quot;, # The maximum size to which storage capacity can be automatically increased. The default value is 0, which specifies that there is no limit.
1911    &quot;tier&quot;: &quot;A String&quot;, # The tier (or machine type) for this instance, for example **db-custom-1-3840**. WARNING: Changing this restarts the instance.
1912    &quot;userLabels&quot;: { # User-provided labels, represented as a dictionary where each label is a single key value pair.
1913      &quot;a_key&quot;: &quot;A String&quot;,
1914    },
1915  },
1916  &quot;state&quot;: &quot;A String&quot;, # The current serving state of the Cloud SQL instance.
1917  &quot;suspensionReason&quot;: [ # If the instance state is SUSPENDED, the reason for the suspension.
1918    &quot;A String&quot;,
1919  ],
1920}
1921
1922  x__xgafv: string, V1 error format.
1923    Allowed values
1924      1 - v1 error format
1925      2 - v2 error format
1926
1927Returns:
1928  An object of the form:
1929
1930    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
1931  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
1932    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
1933    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
1934  },
1935  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1936  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
1937    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
1938      { # Database instance operation error.
1939        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
1940        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
1941        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
1942      },
1943    ],
1944    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
1945  },
1946  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
1947    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
1948      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1949      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1950      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1951      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1952      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
1953    },
1954    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
1955      &quot;A String&quot;,
1956    ],
1957    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
1958    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
1959    &quot;offload&quot;: True or False, # Option for export offload.
1960    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
1961      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
1962        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
1963      },
1964      &quot;schemaOnly&quot;: True or False, # Export only schemas.
1965      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
1966        &quot;A String&quot;,
1967      ],
1968    },
1969    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
1970  },
1971  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
1972    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
1973      &quot;encryptionOptions&quot;: {
1974        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1975        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
1976        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
1977      },
1978    },
1979    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
1980      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
1981        &quot;A String&quot;,
1982      ],
1983      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
1984      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
1985      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
1986      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
1987      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
1988    },
1989    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
1990    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
1991    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
1992    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
1993    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
1994  },
1995  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
1996  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
1997  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
1998  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
1999  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2000  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2001  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2002  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2003  &quot;targetLink&quot;: &quot;A String&quot;,
2004  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2005  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2006}</pre>
2007</div>
2008
2009<div class="method">
2010    <code class="details" id="promoteReplica">promoteReplica(project, instance, x__xgafv=None)</code>
2011  <pre>Promotes the read replica instance to be a stand-alone Cloud SQL instance. Using this operation might cause your instance to restart.
2012
2013Args:
2014  project: string, ID of the project that contains the read replica. (required)
2015  instance: string, Cloud SQL read replica instance name. (required)
2016  x__xgafv: string, V1 error format.
2017    Allowed values
2018      1 - v1 error format
2019      2 - v2 error format
2020
2021Returns:
2022  An object of the form:
2023
2024    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2025  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2026    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2027    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2028  },
2029  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2030  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2031    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2032      { # Database instance operation error.
2033        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2034        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2035        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2036      },
2037    ],
2038    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2039  },
2040  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2041    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2042      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2043      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2044      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2045      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2046      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2047    },
2048    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2049      &quot;A String&quot;,
2050    ],
2051    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2052    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2053    &quot;offload&quot;: True or False, # Option for export offload.
2054    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2055      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2056        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2057      },
2058      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2059      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2060        &quot;A String&quot;,
2061      ],
2062    },
2063    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2064  },
2065  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2066    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2067      &quot;encryptionOptions&quot;: {
2068        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2069        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2070        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2071      },
2072    },
2073    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2074      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2075        &quot;A String&quot;,
2076      ],
2077      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2078      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2079      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2080      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2081      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2082    },
2083    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2084    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2085    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2086    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2087    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2088  },
2089  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2090  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2091  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2092  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2093  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2094  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2095  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2096  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2097  &quot;targetLink&quot;: &quot;A String&quot;,
2098  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2099  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2100}</pre>
2101</div>
2102
2103<div class="method">
2104    <code class="details" id="resetSslConfig">resetSslConfig(project, instance, x__xgafv=None)</code>
2105  <pre>Deletes all client certificates and generates a new server SSL certificate for the instance.
2106
2107Args:
2108  project: string, Project ID of the project that contains the instance. (required)
2109  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
2110  x__xgafv: string, V1 error format.
2111    Allowed values
2112      1 - v1 error format
2113      2 - v2 error format
2114
2115Returns:
2116  An object of the form:
2117
2118    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2119  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2120    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2121    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2122  },
2123  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2124  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2125    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2126      { # Database instance operation error.
2127        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2128        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2129        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2130      },
2131    ],
2132    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2133  },
2134  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2135    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2136      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2137      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2138      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2139      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2140      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2141    },
2142    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2143      &quot;A String&quot;,
2144    ],
2145    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2146    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2147    &quot;offload&quot;: True or False, # Option for export offload.
2148    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2149      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2150        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2151      },
2152      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2153      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2154        &quot;A String&quot;,
2155      ],
2156    },
2157    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2158  },
2159  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2160    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2161      &quot;encryptionOptions&quot;: {
2162        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2163        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2164        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2165      },
2166    },
2167    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2168      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2169        &quot;A String&quot;,
2170      ],
2171      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2172      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2173      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2174      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2175      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2176    },
2177    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2178    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2179    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2180    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2181    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2182  },
2183  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2184  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2185  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2186  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2187  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2188  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2189  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2190  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2191  &quot;targetLink&quot;: &quot;A String&quot;,
2192  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2193  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2194}</pre>
2195</div>
2196
2197<div class="method">
2198    <code class="details" id="restart">restart(project, instance, x__xgafv=None)</code>
2199  <pre>Restarts a Cloud SQL instance.
2200
2201Args:
2202  project: string, Project ID of the project that contains the instance to be restarted. (required)
2203  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
2204  x__xgafv: string, V1 error format.
2205    Allowed values
2206      1 - v1 error format
2207      2 - v2 error format
2208
2209Returns:
2210  An object of the form:
2211
2212    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2213  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2214    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2215    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2216  },
2217  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2218  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2219    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2220      { # Database instance operation error.
2221        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2222        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2223        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2224      },
2225    ],
2226    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2227  },
2228  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2229    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2230      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2231      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2232      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2233      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2234      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2235    },
2236    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2237      &quot;A String&quot;,
2238    ],
2239    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2240    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2241    &quot;offload&quot;: True or False, # Option for export offload.
2242    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2243      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2244        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2245      },
2246      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2247      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2248        &quot;A String&quot;,
2249      ],
2250    },
2251    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2252  },
2253  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2254    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2255      &quot;encryptionOptions&quot;: {
2256        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2257        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2258        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2259      },
2260    },
2261    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2262      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2263        &quot;A String&quot;,
2264      ],
2265      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2266      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2267      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2268      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2269      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2270    },
2271    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2272    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2273    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2274    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2275    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2276  },
2277  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2278  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2279  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2280  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2281  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2282  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2283  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2284  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2285  &quot;targetLink&quot;: &quot;A String&quot;,
2286  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2287  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2288}</pre>
2289</div>
2290
2291<div class="method">
2292    <code class="details" id="restoreBackup">restoreBackup(project, instance, body=None, x__xgafv=None)</code>
2293  <pre>Restores a backup of a Cloud SQL instance. Using this operation might cause your instance to restart.
2294
2295Args:
2296  project: string, Project ID of the project that contains the instance. (required)
2297  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
2298  body: object, The request body.
2299    The object takes the form of:
2300
2301{ # Database instance restore backup request.
2302  &quot;restoreBackupContext&quot;: { # Database instance restore from backup context. Backup context contains source instance id and project id. # Parameters required to perform the restore backup operation.
2303    &quot;backupRunId&quot;: &quot;A String&quot;, # The ID of the backup run to restore from.
2304    &quot;instanceId&quot;: &quot;A String&quot;, # The ID of the instance that the backup was taken from.
2305    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#restoreBackupContext**.
2306    &quot;project&quot;: &quot;A String&quot;, # The full project ID of the source instance.
2307  },
2308}
2309
2310  x__xgafv: string, V1 error format.
2311    Allowed values
2312      1 - v1 error format
2313      2 - v2 error format
2314
2315Returns:
2316  An object of the form:
2317
2318    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2319  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2320    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2321    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2322  },
2323  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2324  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2325    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2326      { # Database instance operation error.
2327        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2328        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2329        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2330      },
2331    ],
2332    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2333  },
2334  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2335    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2336      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2337      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2338      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2339      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2340      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2341    },
2342    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2343      &quot;A String&quot;,
2344    ],
2345    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2346    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2347    &quot;offload&quot;: True or False, # Option for export offload.
2348    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2349      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2350        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2351      },
2352      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2353      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2354        &quot;A String&quot;,
2355      ],
2356    },
2357    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2358  },
2359  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2360    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2361      &quot;encryptionOptions&quot;: {
2362        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2363        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2364        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2365      },
2366    },
2367    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2368      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2369        &quot;A String&quot;,
2370      ],
2371      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2372      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2373      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2374      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2375      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2376    },
2377    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2378    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2379    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2380    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2381    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2382  },
2383  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2384  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2385  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2386  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2387  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2388  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2389  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2390  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2391  &quot;targetLink&quot;: &quot;A String&quot;,
2392  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2393  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2394}</pre>
2395</div>
2396
2397<div class="method">
2398    <code class="details" id="rotateServerCa">rotateServerCa(project, instance, body=None, x__xgafv=None)</code>
2399  <pre>Rotates the server certificate to one signed by the Certificate Authority (CA) version previously added with the addServerCA method.
2400
2401Args:
2402  project: string, Project ID of the project that contains the instance. (required)
2403  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
2404  body: object, The request body.
2405    The object takes the form of:
2406
2407{ # Rotate server CA request.
2408  &quot;rotateServerCaContext&quot;: { # Instance rotate server CA context. # Contains details about the rotate server CA operation.
2409    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#rotateServerCaContext**.
2410    &quot;nextVersion&quot;: &quot;A String&quot;, # The fingerprint of the next version to be rotated to. If left unspecified, will be rotated to the most recently added server CA version.
2411  },
2412}
2413
2414  x__xgafv: string, V1 error format.
2415    Allowed values
2416      1 - v1 error format
2417      2 - v2 error format
2418
2419Returns:
2420  An object of the form:
2421
2422    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2423  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2424    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2425    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2426  },
2427  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2428  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2429    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2430      { # Database instance operation error.
2431        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2432        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2433        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2434      },
2435    ],
2436    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2437  },
2438  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2439    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2440      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2441      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2442      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2443      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2444      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2445    },
2446    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2447      &quot;A String&quot;,
2448    ],
2449    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2450    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2451    &quot;offload&quot;: True or False, # Option for export offload.
2452    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2453      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2454        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2455      },
2456      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2457      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2458        &quot;A String&quot;,
2459      ],
2460    },
2461    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2462  },
2463  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2464    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2465      &quot;encryptionOptions&quot;: {
2466        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2467        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2468        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2469      },
2470    },
2471    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2472      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2473        &quot;A String&quot;,
2474      ],
2475      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2476      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2477      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2478      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2479      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2480    },
2481    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2482    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2483    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2484    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2485    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2486  },
2487  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2488  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2489  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2490  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2491  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2492  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2493  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2494  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2495  &quot;targetLink&quot;: &quot;A String&quot;,
2496  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2497  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2498}</pre>
2499</div>
2500
2501<div class="method">
2502    <code class="details" id="startReplica">startReplica(project, instance, x__xgafv=None)</code>
2503  <pre>Starts the replication in the read replica instance.
2504
2505Args:
2506  project: string, ID of the project that contains the read replica. (required)
2507  instance: string, Cloud SQL read replica instance name. (required)
2508  x__xgafv: string, V1 error format.
2509    Allowed values
2510      1 - v1 error format
2511      2 - v2 error format
2512
2513Returns:
2514  An object of the form:
2515
2516    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2517  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2518    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2519    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2520  },
2521  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2522  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2523    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2524      { # Database instance operation error.
2525        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2526        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2527        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2528      },
2529    ],
2530    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2531  },
2532  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2533    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2534      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2535      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2536      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2537      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2538      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2539    },
2540    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2541      &quot;A String&quot;,
2542    ],
2543    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2544    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2545    &quot;offload&quot;: True or False, # Option for export offload.
2546    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2547      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2548        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2549      },
2550      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2551      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2552        &quot;A String&quot;,
2553      ],
2554    },
2555    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2556  },
2557  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2558    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2559      &quot;encryptionOptions&quot;: {
2560        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2561        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2562        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2563      },
2564    },
2565    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2566      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2567        &quot;A String&quot;,
2568      ],
2569      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2570      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2571      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2572      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2573      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2574    },
2575    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2576    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2577    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2578    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2579    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2580  },
2581  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2582  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2583  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2584  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2585  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2586  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2587  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2588  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2589  &quot;targetLink&quot;: &quot;A String&quot;,
2590  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2591  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2592}</pre>
2593</div>
2594
2595<div class="method">
2596    <code class="details" id="stopReplica">stopReplica(project, instance, x__xgafv=None)</code>
2597  <pre>Stops the replication in the read replica instance.
2598
2599Args:
2600  project: string, ID of the project that contains the read replica. (required)
2601  instance: string, Cloud SQL read replica instance name. (required)
2602  x__xgafv: string, V1 error format.
2603    Allowed values
2604      1 - v1 error format
2605      2 - v2 error format
2606
2607Returns:
2608  An object of the form:
2609
2610    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2611  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2612    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2613    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2614  },
2615  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2616  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2617    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2618      { # Database instance operation error.
2619        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2620        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2621        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2622      },
2623    ],
2624    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2625  },
2626  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2627    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2628      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2629      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2630      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2631      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2632      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2633    },
2634    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2635      &quot;A String&quot;,
2636    ],
2637    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2638    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2639    &quot;offload&quot;: True or False, # Option for export offload.
2640    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2641      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2642        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2643      },
2644      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2645      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2646        &quot;A String&quot;,
2647      ],
2648    },
2649    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2650  },
2651  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2652    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2653      &quot;encryptionOptions&quot;: {
2654        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2655        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2656        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2657      },
2658    },
2659    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2660      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2661        &quot;A String&quot;,
2662      ],
2663      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2664      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2665      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2666      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2667      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2668    },
2669    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2670    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2671    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2672    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2673    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2674  },
2675  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2676  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2677  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2678  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2679  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2680  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2681  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2682  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2683  &quot;targetLink&quot;: &quot;A String&quot;,
2684  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2685  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2686}</pre>
2687</div>
2688
2689<div class="method">
2690    <code class="details" id="truncateLog">truncateLog(project, instance, body=None, x__xgafv=None)</code>
2691  <pre>Truncate MySQL general and slow query log tables MySQL only.
2692
2693Args:
2694  project: string, Project ID of the Cloud SQL project. (required)
2695  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
2696  body: object, The request body.
2697    The object takes the form of:
2698
2699{ # Instance truncate log request.
2700  &quot;truncateLogContext&quot;: { # Database Instance truncate log context. # Contains details about the truncate log operation.
2701    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#truncateLogContext**.
2702    &quot;logType&quot;: &quot;A String&quot;, # The type of log to truncate. Valid values are **MYSQL_GENERAL_TABLE** and **MYSQL_SLOW_TABLE**.
2703  },
2704}
2705
2706  x__xgafv: string, V1 error format.
2707    Allowed values
2708      1 - v1 error format
2709      2 - v2 error format
2710
2711Returns:
2712  An object of the form:
2713
2714    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
2715  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
2716    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
2717    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
2718  },
2719  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2720  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
2721    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
2722      { # Database instance operation error.
2723        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
2724        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
2725        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
2726      },
2727    ],
2728    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
2729  },
2730  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
2731    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
2732      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2733      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2734      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2735      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2736      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
2737    },
2738    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
2739      &quot;A String&quot;,
2740    ],
2741    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
2742    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
2743    &quot;offload&quot;: True or False, # Option for export offload.
2744    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
2745      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
2746        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
2747      },
2748      &quot;schemaOnly&quot;: True or False, # Export only schemas.
2749      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
2750        &quot;A String&quot;,
2751      ],
2752    },
2753    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
2754  },
2755  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
2756    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
2757      &quot;encryptionOptions&quot;: {
2758        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2759        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
2760        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
2761      },
2762    },
2763    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
2764      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
2765        &quot;A String&quot;,
2766      ],
2767      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
2768      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
2769      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
2770      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
2771      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
2772    },
2773    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
2774    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
2775    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
2776    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
2777    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
2778  },
2779  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2780  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
2781  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
2782  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
2783  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2784  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2785  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
2786  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
2787  &quot;targetLink&quot;: &quot;A String&quot;,
2788  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
2789  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
2790}</pre>
2791</div>
2792
2793<div class="method">
2794    <code class="details" id="update">update(project, instance, body=None, x__xgafv=None)</code>
2795  <pre>Updates settings of a Cloud SQL instance. Using this operation might cause your instance to restart.
2796
2797Args:
2798  project: string, Project ID of the project that contains the instance. (required)
2799  instance: string, Cloud SQL instance ID. This does not include the project ID. (required)
2800  body: object, The request body.
2801    The object takes the form of:
2802
2803{ # A Cloud SQL instance resource.
2804  &quot;backendType&quot;: &quot;A String&quot;, # The backend type. **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A database server that is not managed by Google. This property is read-only; use the **tier** property in the **settings** object to determine the database type.
2805  &quot;connectionName&quot;: &quot;A String&quot;, # Connection name of the Cloud SQL instance used in connection strings.
2806  &quot;createTime&quot;: &quot;A String&quot;, # Output only. The time when the instance was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2807  &quot;currentDiskSize&quot;: &quot;A String&quot;, # The current disk usage of the instance in bytes. This property has been deprecated. Use the &quot;cloudsql.googleapis.com/database/disk/bytes_used&quot; metric in Cloud Monitoring API instead. Please see [this announcement](https://groups.google.com/d/msg/google-cloud-sql-announce/I_7-F9EBhT0/BtvFtdFeAgAJ) for details.
2808  &quot;databaseInstalledVersion&quot;: &quot;A String&quot;, # Output only. Stores the current database version running on the instance including minor version such as **MYSQL_8_0_18**.
2809  &quot;databaseVersion&quot;: &quot;A String&quot;, # The database engine type and version. The **databaseVersion** field cannot be changed after instance creation.
2810  &quot;diskEncryptionConfiguration&quot;: { # Disk encryption configuration for an instance. # Disk encryption configuration specific to an instance.
2811    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionConfiguration**.
2812    &quot;kmsKeyName&quot;: &quot;A String&quot;, # Resource name of KMS key for disk encryption
2813  },
2814  &quot;diskEncryptionStatus&quot;: { # Disk encryption status for an instance. # Disk encryption status specific to an instance.
2815    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#diskEncryptionStatus**.
2816    &quot;kmsKeyVersionName&quot;: &quot;A String&quot;, # KMS key version used to encrypt the Cloud SQL instance resource
2817  },
2818  &quot;etag&quot;: &quot;A String&quot;, # This field is deprecated and will be removed from a future version of the API. Use the **settings.settingsVersion** field instead.
2819  &quot;failoverReplica&quot;: { # The name and status of the failover replica.
2820    &quot;available&quot;: True or False, # The availability status of the failover replica. A false status indicates that the failover replica is out of sync. The primary instance can only failover to the failover replica when the status is true.
2821    &quot;name&quot;: &quot;A String&quot;, # The name of the failover replica. If specified at instance creation, a failover replica is created for the instance. The name doesn&#x27;t include the project ID.
2822  },
2823  &quot;gceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the instance is currently serving from. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary zone. WARNING: Changing this might restart the instance.
2824  &quot;instanceType&quot;: &quot;A String&quot;, # The instance type.
2825  &quot;ipAddresses&quot;: [ # The assigned IP addresses for the instance.
2826    { # Database instance IP Mapping.
2827      &quot;ipAddress&quot;: &quot;A String&quot;, # The IP address assigned.
2828      &quot;timeToRetire&quot;: &quot;A String&quot;, # The due time for this IP to be retired in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**. This field is only available when the IP is scheduled to be retired.
2829      &quot;type&quot;: &quot;A String&quot;, # The type of this IP address. A **PRIMARY** address is a public address that can accept incoming connections. A **PRIVATE** address is a private address that can accept incoming connections. An **OUTGOING** address is the source address of connections originating from the instance, if supported.
2830    },
2831  ],
2832  &quot;ipv6Address&quot;: &quot;A String&quot;, # The IPv6 address assigned to the instance. (Deprecated) This property was applicable only to First Generation instances.
2833  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#instance**.
2834  &quot;masterInstanceName&quot;: &quot;A String&quot;, # The name of the instance which will act as primary in the replication setup.
2835  &quot;maxDiskSize&quot;: &quot;A String&quot;, # The maximum disk size of the instance in bytes.
2836  &quot;name&quot;: &quot;A String&quot;, # Name of the Cloud SQL instance. This does not include the project ID.
2837  &quot;onPremisesConfiguration&quot;: { # On-premises instance configuration. # Configuration specific to on-premises instances.
2838    &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
2839    &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
2840    &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
2841    &quot;dumpFilePath&quot;: &quot;A String&quot;, # The dump file to create the Cloud SQL replica.
2842    &quot;hostPort&quot;: &quot;A String&quot;, # The host and port of the on-premises instance in host:port format
2843    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#onPremisesConfiguration**.
2844    &quot;password&quot;: &quot;A String&quot;, # The password for connecting to on-premises instance.
2845    &quot;sourceInstance&quot;: { # Reference to another Cloud SQL instance. # The reference to Cloud SQL instance if the source is Cloud SQL.
2846      &quot;name&quot;: &quot;A String&quot;, # The name of the Cloud SQL instance being referenced. This does not include the project ID.
2847      &quot;project&quot;: &quot;A String&quot;, # The project ID of the Cloud SQL instance being referenced. The default is the same project ID as the instance references it.
2848      &quot;region&quot;: &quot;A String&quot;, # The region of the Cloud SQL instance being referenced.
2849    },
2850    &quot;username&quot;: &quot;A String&quot;, # The username for connecting to on-premises instance.
2851  },
2852  &quot;outOfDiskReport&quot;: { # This message wraps up the information written by out-of-disk detection job. # This field represents the report generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
2853    &quot;sqlMinRecommendedIncreaseSizeGb&quot;: 42, # The minimum recommended increase size in GigaBytes This field is consumed by the frontend * Writers: * the proactive database wellness job for OOD. * Readers:
2854    &quot;sqlOutOfDiskState&quot;: &quot;A String&quot;, # This field represents the state generated by the proactive database wellness job for OutOfDisk issues. * Writers: * the proactive database wellness job for OOD. * Readers: * the proactive database wellness job
2855  },
2856  &quot;project&quot;: &quot;A String&quot;, # The project ID of the project containing the Cloud SQL instance. The Google apps domain is prefixed if applicable.
2857  &quot;region&quot;: &quot;A String&quot;, # The geographical region. Can be: * **us-central** (**FIRST_GEN** instances only) * **us-central1** (**SECOND_GEN** instances only) * **asia-east1** or **europe-west1**. Defaults to **us-central** or **us-central1** depending on the instance type. The region cannot be changed after instance creation.
2858  &quot;replicaConfiguration&quot;: { # Read-replica configuration for connecting to the primary instance. # Configuration specific to failover replicas and read replicas.
2859    &quot;failoverTarget&quot;: True or False, # Specifies if the replica is the failover target. If the field is set to **true** the replica will be designated as a failover replica. In case the primary instance fails, the replica instance will be promoted as the new primary instance. Only one replica can be specified as failover target, and the replica has to be in different zone with the primary instance.
2860    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#replicaConfiguration**.
2861    &quot;mysqlReplicaConfiguration&quot;: { # Read-replica configuration specific to MySQL databases. # MySQL specific configuration when replicating from a MySQL on-premises primary instance. Replication configuration information such as the username, password, certificates, and keys are not stored in the instance metadata. The configuration information is used only to set up the replication connection and is stored by MySQL in a file named **master.info** in the data directory.
2862      &quot;caCertificate&quot;: &quot;A String&quot;, # PEM representation of the trusted CA&#x27;s x509 certificate.
2863      &quot;clientCertificate&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s x509 certificate.
2864      &quot;clientKey&quot;: &quot;A String&quot;, # PEM representation of the replica&#x27;s private key. The corresponsing public key is encoded in the client&#x27;s certificate.
2865      &quot;connectRetryInterval&quot;: 42, # Seconds to wait between connect retries. MySQL&#x27;s default is 60 seconds.
2866      &quot;dumpFilePath&quot;: &quot;A String&quot;, # Path to a SQL dump file in Google Cloud Storage from which the replica instance is to be created. The URI is in the form gs://bucketName/fileName. Compressed gzip files (.gz) are also supported. Dumps have the binlog co-ordinates from which replication begins. This can be accomplished by setting --master-data to 1 when using mysqldump.
2867      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#mysqlReplicaConfiguration**.
2868      &quot;masterHeartbeatPeriod&quot;: &quot;A String&quot;, # Interval in milliseconds between replication heartbeats.
2869      &quot;password&quot;: &quot;A String&quot;, # The password for the replication connection.
2870      &quot;sslCipher&quot;: &quot;A String&quot;, # A list of permissible ciphers to use for SSL encryption.
2871      &quot;username&quot;: &quot;A String&quot;, # The username for the replication connection.
2872      &quot;verifyServerCertificate&quot;: True or False, # Whether or not to check the primary instance&#x27;s Common Name value in the certificate that it sends during the SSL handshake.
2873    },
2874  },
2875  &quot;replicaNames&quot;: [ # The replicas of the instance.
2876    &quot;A String&quot;,
2877  ],
2878  &quot;rootPassword&quot;: &quot;A String&quot;, # Initial root password. Use only on creation.
2879  &quot;satisfiesPzs&quot;: True or False, # The status indicating if instance satisfiesPzs. Reserved for future use.
2880  &quot;scheduledMaintenance&quot;: { # Any scheduled maintenancce for this instance. # The start time of any upcoming scheduled maintenance for this instance.
2881    &quot;canDefer&quot;: True or False,
2882    &quot;canReschedule&quot;: True or False, # If the scheduled maintenance can be rescheduled.
2883    &quot;scheduleDeadlineTime&quot;: &quot;A String&quot;, # Maintenance cannot be rescheduled to start beyond this deadline.
2884    &quot;startTime&quot;: &quot;A String&quot;, # The start time of any upcoming scheduled maintenance for this instance.
2885  },
2886  &quot;secondaryGceZone&quot;: &quot;A String&quot;, # The Compute Engine zone that the failover instance is currently serving from for a regional instance. This value could be different from the zone that was specified when the instance was created if the instance has failed over to its secondary/failover zone. Reserved for future use.
2887  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2888  &quot;serverCaCert&quot;: { # SslCerts Resource # SSL configuration.
2889    &quot;cert&quot;: &quot;A String&quot;, # PEM representation.
2890    &quot;certSerialNumber&quot;: &quot;A String&quot;, # Serial number, as extracted from the certificate.
2891    &quot;commonName&quot;: &quot;A String&quot;, # User supplied name. Constrained to [a-zA-Z.-_ ]+.
2892    &quot;createTime&quot;: &quot;A String&quot;, # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
2893    &quot;expirationTime&quot;: &quot;A String&quot;, # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2894    &quot;instance&quot;: &quot;A String&quot;, # Name of the database instance.
2895    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#sslCert**.
2896    &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
2897    &quot;sha1Fingerprint&quot;: &quot;A String&quot;, # Sha1 Fingerprint.
2898  },
2899  &quot;serviceAccountEmailAddress&quot;: &quot;A String&quot;, # The service account email address assigned to the instance. This property is read-only.
2900  &quot;settings&quot;: { # Database instance settings. # The user settings.
2901    &quot;activationPolicy&quot;: &quot;A String&quot;, # The activation policy specifies when the instance is activated; it is applicable only when the instance state is RUNNABLE. Valid values: * **ALWAYS**: The instance is on, and remains so even in the absence of connection requests. * **NEVER**: The instance is off; it is not activated, even if a connection request arrives.
2902    &quot;activeDirectoryConfig&quot;: { # Active Directory configuration, relevant only for Cloud SQL for SQL Server. # Active Directory configuration, relevant only for Cloud SQL for SQL Server.
2903      &quot;domain&quot;: &quot;A String&quot;, # The name of the domain (e.g., mydomain.com).
2904      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#activeDirectoryConfig.
2905    },
2906    &quot;authorizedGaeApplications&quot;: [ # The App Engine app IDs that can access this instance. (Deprecated) Applied to First Generation instances only.
2907      &quot;A String&quot;,
2908    ],
2909    &quot;availabilityType&quot;: &quot;A String&quot;, # Availability type. Potential values: * **ZONAL**: The instance serves data from only one zone. Outages in that zone affect data accessibility. * **REGIONAL**: The instance can serve data from more than one zone in a region (it is highly available)./ For more information, see [Overview of the High Availability Configuration](https://cloud.google.com/sql/docs/mysql/high-availability).
2910    &quot;backupConfiguration&quot;: { # Database instance backup configuration. # The daily backup configuration for the instance.
2911      &quot;backupRetentionSettings&quot;: { # We currently only support backup retention by specifying the number of backups we will retain. # Backup retention settings.
2912        &quot;retainedBackups&quot;: 42, # Depending on the value of retention_unit, this is used to determine if a backup needs to be deleted. If retention_unit is &#x27;COUNT&#x27;, we will retain this many backups.
2913        &quot;retentionUnit&quot;: &quot;A String&quot;, # The unit that &#x27;retained_backups&#x27; represents.
2914      },
2915      &quot;binaryLogEnabled&quot;: True or False, # (MySQL only) Whether binary log is enabled. If backup configuration is disabled, binarylog must be disabled as well.
2916      &quot;enabled&quot;: True or False, # Whether this configuration is enabled.
2917      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupConfiguration**.
2918      &quot;location&quot;: &quot;A String&quot;, # Location of the backup
2919      &quot;pointInTimeRecoveryEnabled&quot;: True or False, # (Postgres only) Whether point in time recovery is enabled.
2920      &quot;replicationLogArchivingEnabled&quot;: True or False, # Reserved for future use.
2921      &quot;startTime&quot;: &quot;A String&quot;, # Start time for the daily backup configuration in UTC timezone in the 24 hour format - **HH:MM**.
2922      &quot;transactionLogRetentionDays&quot;: 42, # The number of days of transaction logs we retain for point in time restore, from 1-7.
2923    },
2924    &quot;collation&quot;: &quot;A String&quot;, # The name of server Instance collation.
2925    &quot;crashSafeReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether database flags for crash-safe replication are enabled. This property was only applicable to First Generation instances.
2926    &quot;dataDiskSizeGb&quot;: &quot;A String&quot;, # The size of data disk, in GB. The data disk size minimum is 10GB.
2927    &quot;dataDiskType&quot;: &quot;A String&quot;, # The type of data disk: **PD_SSD** (default) or **PD_HDD**. Not used for First Generation instances.
2928    &quot;databaseFlags&quot;: [ # The database flags passed to the instance at startup.
2929      { # Database flags for Cloud SQL instances.
2930        &quot;name&quot;: &quot;A String&quot;, # The name of the flag. These flags are passed at instance startup, so include both server options and system variables. Flags are specified with underscores, not hyphens. For more information, see [Configuring Database Flags](https://cloud.google.com/sql/docs/mysql/flags) in the Cloud SQL documentation.
2931        &quot;value&quot;: &quot;A String&quot;, # The value of the flag. Booleans are set to **on** for true and **off** for false. This field must be omitted if the flag doesn&#x27;t take a value.
2932      },
2933    ],
2934    &quot;databaseReplicationEnabled&quot;: True or False, # Configuration specific to read replica instances. Indicates whether replication is enabled or not. WARNING: Changing this restarts the instance.
2935    &quot;denyMaintenancePeriods&quot;: [ # Deny maintenance periods
2936      { # Deny maintenance Periods. This specifies a date range during when all CSA rollout will be denied.
2937        &quot;endDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; end date. If the year of the end date is empty, the year of the start date also must be empty. In this case, it means the no maintenance interval recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
2938        &quot;startDate&quot;: &quot;A String&quot;, # &quot;deny maintenance period&quot; start date. If the year of the start date is empty, the year of the end date also must be empty. In this case, it means the deny maintenance period recurs every year. The date is in format yyyy-mm-dd i.e., 2020-11-01, or mm-dd, i.e., 11-01
2939        &quot;time&quot;: &quot;A String&quot;, # Time in UTC when the &quot;deny maintenance period&quot; starts on start_date and ends on end_date. The time is in format: HH:mm:SS, i.e., 00:00:00
2940      },
2941    ],
2942    &quot;insightsConfig&quot;: { # Insights configuration. This specifies when Cloud SQL Insights feature is enabled and optional configuration. # Insights configuration, for now relevant only for Postgres.
2943      &quot;queryInsightsEnabled&quot;: True or False, # Whether Query Insights feature is enabled.
2944      &quot;queryPlansPerMinute&quot;: 42, # Number of query execution plans captured by Insights per minute for all queries combined. Default is 5.
2945      &quot;queryStringLength&quot;: 42, # Maximum query length stored in bytes. Default value: 1024 bytes. Range: 256-4500 bytes. Query length more than this field value will be truncated to this value. When unset, query length will be the default value. Changing query length will restart the database.
2946      &quot;recordApplicationTags&quot;: True or False, # Whether Query Insights will record application tags from query when enabled.
2947      &quot;recordClientAddress&quot;: True or False, # Whether Query Insights will record client address when enabled.
2948    },
2949    &quot;ipConfiguration&quot;: { # IP Management configuration. # The settings for IP Management. This allows to enable or disable the instance IP and manage which external networks can connect to the instance. The IPv4 address cannot be disabled for Second Generation instances.
2950      &quot;allocatedIpRange&quot;: &quot;A String&quot;, # The name of the allocated ip range for the private ip CloudSQL instance. For example: &quot;google-managed-services-default&quot;. If set, the instance ip will be created in the allocated range. The range name must comply with [RFC 1035](https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?.`
2951      &quot;authorizedNetworks&quot;: [ # The list of external networks that are allowed to connect to the instance using the IP. In &#x27;CIDR&#x27; notation, also known as &#x27;slash&#x27; notation (for example: **157.197.200.0/24**).
2952        { # An entry for an Access Control list.
2953          &quot;expirationTime&quot;: &quot;A String&quot;, # The time when this access control entry expires in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2954          &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#aclEntry**.
2955          &quot;name&quot;: &quot;A String&quot;, # Optional. A label to identify this entry.
2956          &quot;value&quot;: &quot;A String&quot;, # The allowlisted value for the access control list.
2957        },
2958      ],
2959      &quot;ipv4Enabled&quot;: True or False, # Whether the instance is assigned a public IP address or not.
2960      &quot;privateNetwork&quot;: &quot;A String&quot;, # The resource link for the VPC network from which the Cloud SQL instance is accessible for private IP. For example, **/projects/myProject/global/networks/default**. This setting can be updated, but it cannot be removed after it is set.
2961      &quot;requireSsl&quot;: True or False, # Whether SSL connections over IP are enforced or not.
2962    },
2963    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#settings**.
2964    &quot;locationPreference&quot;: { # Preferred location. This specifies where a Cloud SQL instance is located. Note that if the preferred location is not available, the instance will be located as close as possible within the region. Only one location may be specified. # The location preference settings. This allows the instance to be located as near as possible to either an App Engine app or Compute Engine zone for better performance. App Engine co-location was only applicable to First Generation instances.
2965      &quot;followGaeApplication&quot;: &quot;A String&quot;, # The App Engine application to follow, it must be in the same region as the Cloud SQL instance. WARNING: Changing this might restart the instance.
2966      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#locationPreference**.
2967      &quot;secondaryZone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone for the secondary/failover (for example: us-central1-a, us-central1-b, etc.). Reserved for future use.
2968      &quot;zone&quot;: &quot;A String&quot;, # The preferred Compute Engine zone (for example: us-central1-a, us-central1-b, etc.). WARNING: Changing this might restart the instance.
2969    },
2970    &quot;maintenanceWindow&quot;: { # Maintenance window. This specifies when a Cloud SQL instance is restarted for system maintenance purposes. # The maintenance window for this instance. This specifies when the instance can be restarted for maintenance purposes.
2971      &quot;day&quot;: 42, # day of week (1-7), starting on Monday.
2972      &quot;hour&quot;: 42, # hour of day - 0 to 23.
2973      &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#maintenanceWindow**.
2974      &quot;updateTrack&quot;: &quot;A String&quot;, # Maintenance timing setting: **canary** (Earlier) or **stable** (Later). [Learn more](https://cloud.google.com/sql/docs/mysql/instance-settings#maintenance-timing-2ndgen).
2975    },
2976    &quot;passwordValidationPolicy&quot;: { # Database instance local user password validation policy # The local user password validation policy of the instance.
2977      &quot;complexity&quot;: &quot;A String&quot;, # The complexity of the password.
2978      &quot;disallowUsernameSubstring&quot;: True or False, # Disallow username as a part of the password.
2979      &quot;minLength&quot;: 42, # Minimum number of characters allowed.
2980      &quot;passwordChangeInterval&quot;: &quot;A String&quot;, # Minimum interval after which the password can be changed.
2981      &quot;reuseInterval&quot;: 42, # Number of previous passwords that cannot be reused.
2982    },
2983    &quot;pricingPlan&quot;: &quot;A String&quot;, # The pricing plan for this instance. This can be either **PER_USE** or **PACKAGE**. Only **PER_USE** is supported for Second Generation instances.
2984    &quot;replicationType&quot;: &quot;A String&quot;, # The type of replication this instance uses. This can be either **ASYNCHRONOUS** or **SYNCHRONOUS**. (Deprecated) This property was only applicable to First Generation instances.
2985    &quot;settingsVersion&quot;: &quot;A String&quot;, # The version of instance settings. This is a required field for update method to make sure concurrent updates are handled properly. During update, use the most recent settingsVersion value for this instance and do not try to update this value.
2986    &quot;sqlServerAuditConfig&quot;: { # SQL Server specific audit configuration. # SQL Server specific audit configuration.
2987      &quot;bucket&quot;: &quot;A String&quot;, # The name of the destination bucket (e.g., gs://mybucket).
2988      &quot;kind&quot;: &quot;A String&quot;, # This is always sql#sqlServerAuditConfig
2989    },
2990    &quot;storageAutoResize&quot;: True or False, # Configuration to increase storage size automatically. The default value is true.
2991    &quot;storageAutoResizeLimit&quot;: &quot;A String&quot;, # The maximum size to which storage capacity can be automatically increased. The default value is 0, which specifies that there is no limit.
2992    &quot;tier&quot;: &quot;A String&quot;, # The tier (or machine type) for this instance, for example **db-custom-1-3840**. WARNING: Changing this restarts the instance.
2993    &quot;userLabels&quot;: { # User-provided labels, represented as a dictionary where each label is a single key value pair.
2994      &quot;a_key&quot;: &quot;A String&quot;,
2995    },
2996  },
2997  &quot;state&quot;: &quot;A String&quot;, # The current serving state of the Cloud SQL instance.
2998  &quot;suspensionReason&quot;: [ # If the instance state is SUSPENDED, the reason for the suspension.
2999    &quot;A String&quot;,
3000  ],
3001}
3002
3003  x__xgafv: string, V1 error format.
3004    Allowed values
3005      1 - v1 error format
3006      2 - v2 error format
3007
3008Returns:
3009  An object of the form:
3010
3011    { # An Operation resource. For successful operations that return an Operation resource, only the fields relevant to the operation are populated in the resource.
3012  &quot;backupContext&quot;: { # Backup context. # The context for backup operation, if applicable.
3013    &quot;backupId&quot;: &quot;A String&quot;, # The identifier of the backup.
3014    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#backupContext**.
3015  },
3016  &quot;endTime&quot;: &quot;A String&quot;, # The time this operation finished in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
3017  &quot;error&quot;: { # Database instance operation errors list wrapper. # If errors occurred during processing of this operation, this field will be populated.
3018    &quot;errors&quot;: [ # The list of errors encountered while processing this operation.
3019      { # Database instance operation error.
3020        &quot;code&quot;: &quot;A String&quot;, # Identifies the specific error that occurred.
3021        &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationError**.
3022        &quot;message&quot;: &quot;A String&quot;, # Additional information about the error encountered.
3023      },
3024    ],
3025    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operationErrors**.
3026  },
3027  &quot;exportContext&quot;: { # Database instance export context. # The context for export operation, if applicable.
3028    &quot;csvExportOptions&quot;: { # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
3029      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
3030      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
3031      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
3032      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
3033      &quot;selectQuery&quot;: &quot;A String&quot;, # The select query used to extract the data.
3034    },
3035    &quot;databases&quot;: [ # Databases to be exported. **MySQL instances:** If **fileType** is **SQL** and no database is specified, all databases are exported, except for the **mysql** system database. If **fileType** is **CSV**, you can specify one database, either by using this property or by using the **csvExportOptions.selectQuery** property, which takes precedence over this property. **PostgreSQL instances:** You must specify one database to be exported. If **fileType** is **CSV**, this database must match the one specified in the **csvExportOptions.selectQuery** property. **SQL Server instances:** You must specify one database to be exported, and the **fileType** must be **BAK**.
3036      &quot;A String&quot;,
3037    ],
3038    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri.
3039    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#exportContext**.
3040    &quot;offload&quot;: True or False, # Option for export offload.
3041    &quot;sqlExportOptions&quot;: { # Options for exporting data as SQL statements.
3042      &quot;mysqlExportOptions&quot;: { # Options for exporting from MySQL.
3043        &quot;masterData&quot;: 42, # Option to include SQL statement required to set up replication. If set to **1**, the dump file includes a CHANGE MASTER TO statement with the binary log coordinates, and --set-gtid-purged is set to ON. If set to **2**, the CHANGE MASTER TO statement is written as a SQL comment and has no effect. If set to any value other than **1**, --set-gtid-purged is set to OFF.
3044      },
3045      &quot;schemaOnly&quot;: True or False, # Export only schemas.
3046      &quot;tables&quot;: [ # Tables to export, or that were exported, from the specified database. If you specify tables, specify one and only one database. For PostgreSQL instances, you can specify only one table.
3047        &quot;A String&quot;,
3048      ],
3049    },
3050    &quot;uri&quot;: &quot;A String&quot;, # The path to the file in Google Cloud Storage where the export will be stored. The URI is in the form **gs://bucketName/fileName**. If the file already exists, the request succeeds, but the operation fails. If **fileType** is **SQL** and the filename ends with .gz, the contents are compressed.
3051  },
3052  &quot;importContext&quot;: { # Database instance import context. # The context for import operation, if applicable.
3053    &quot;bakImportOptions&quot;: { # Import parameters specific to SQL Server .BAK files
3054      &quot;encryptionOptions&quot;: {
3055        &quot;certPath&quot;: &quot;A String&quot;, # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
3056        &quot;pvkPassword&quot;: &quot;A String&quot;, # Password that encrypts the private key
3057        &quot;pvkPath&quot;: &quot;A String&quot;, # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs://bucketName/fileName**. The instance must have write permissions to the bucket and read access to the file.
3058      },
3059    },
3060    &quot;csvImportOptions&quot;: { # Options for importing data as CSV.
3061      &quot;columns&quot;: [ # The columns to which CSV data is imported. If not specified, all columns of the database table are loaded with CSV data.
3062        &quot;A String&quot;,
3063      ],
3064      &quot;escapeCharacter&quot;: &quot;A String&quot;, # Specifies the character that should appear before a data character that needs to be escaped.
3065      &quot;fieldsTerminatedBy&quot;: &quot;A String&quot;, # Specifies the character that separates columns within each row (line) of the file.
3066      &quot;linesTerminatedBy&quot;: &quot;A String&quot;, # This is used to separate lines. If a line does not contain all fields, the rest of the columns are set to their default values.
3067      &quot;quoteCharacter&quot;: &quot;A String&quot;, # Specifies the quoting character to be used when a data value is quoted.
3068      &quot;table&quot;: &quot;A String&quot;, # The table to which CSV data is imported.
3069    },
3070    &quot;database&quot;: &quot;A String&quot;, # The target database for the import. If **fileType** is **SQL**, this field is required only if the import file does not specify a database, and is overridden by any database specification in the import file. If **fileType** is **CSV**, one database must be specified.
3071    &quot;fileType&quot;: &quot;A String&quot;, # The file type for the specified uri. **SQL**: The file contains SQL statements. **CSV**: The file contains CSV data.
3072    &quot;importUser&quot;: &quot;A String&quot;, # The PostgreSQL user for this import operation. PostgreSQL instances only.
3073    &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#importContext**.
3074    &quot;uri&quot;: &quot;A String&quot;, # Path to the import file in Cloud Storage, in the form **gs://bucketName/fileName**. Compressed gzip files (.gz) are supported when **fileType** is **SQL**. The instance must have write permissions to the bucket and read access to the file.
3075  },
3076  &quot;insertTime&quot;: &quot;A String&quot;, # The time this operation was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
3077  &quot;kind&quot;: &quot;A String&quot;, # This is always **sql#operation**.
3078  &quot;name&quot;: &quot;A String&quot;, # An identifier that uniquely identifies the operation. You can use this identifier to retrieve the Operations resource that has information about the operation.
3079  &quot;operationType&quot;: &quot;A String&quot;, # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **DELETE_DATABASE**
3080  &quot;selfLink&quot;: &quot;A String&quot;, # The URI of this resource.
3081  &quot;startTime&quot;: &quot;A String&quot;, # The time this operation actually started in UTC timezone in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
3082  &quot;status&quot;: &quot;A String&quot;, # The status of an operation.
3083  &quot;targetId&quot;: &quot;A String&quot;, # Name of the database instance related to this operation.
3084  &quot;targetLink&quot;: &quot;A String&quot;,
3085  &quot;targetProject&quot;: &quot;A String&quot;, # The project ID of the target instance related to this operation.
3086  &quot;user&quot;: &quot;A String&quot;, # The email address of the user who initiated this operation.
3087}</pre>
3088</div>
3089
3090</body></html>