Globals

Method

generateToJSONFromRow

generateToJSONFromRow()

Wherever a row object is returned, it is assigned a "toJSON" function. This function will create that function in a consistent format.

Abstract types

BasicCallback

BasicCallback(err, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

apiResponse

object

The full API response.

BasicResponse

array

Property

Parameter

0

object

The full API response.

ClientConfig

object

Properties

Parameter

projectId

Optional

string

The project ID from the Google Developer's Console, e.g. 'grape-spaceship-123'. We will also check the environment variable GCLOUD_PROJECT for your project ID. If your app is running in an environment which supports Application Default Credentials, your project ID will be detected automatically.

keyFilename

Optional

string

Full path to the a .json, .pem, or .p12 key downloaded from the Google Developers Console. If you provide a path to a JSON file, the projectId option above is not necessary. NOTE: .pem and .p12 require you to specify the email option as well.

email

Optional

string

Account email address. Required when using a .pem or .p12 keyFilename.

credentials

Optional

object

Credentials object.

Values in credentials have the following properties:

Parameter

client_email

Optional

string

private_key

Optional

string

autoRetry

Optional

boolean

Automatically retry requests if the response is related to rate limits or certain intermittent server errors. We will exponentially backoff subsequent requests by default.

maxRetries

Optional

number

Maximum number of automatic retries attempted before returning the error.

promise

Optional

Constructor

Custom promise module to use instead of native Promises.

CloseDatabaseCallback

CloseDatabaseCallback(err)

Parameter

err

Error

Request error, if any.

Value may be null.

CreateDatabaseCallback

CreateDatabaseCallback(err, database, operation, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

database

Database

The new Database.

operation

Operation

An Operation object that can be used to check the status of the request.

apiResponse

object

The full API response.

CreateDatabaseRequest

object

Config for the new database.

Property

Parameter

poolOptions

Optional

SessionPoolOptions

CreateDatabaseResponse

array

Properties

Parameter

0

Database

The new Database.

1

Operation

An Operation object that can be used to check the status of the request.

2

object

The full API response.

CreateInstanceCallback

CreateInstanceCallback(err, instance, operation, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

instance

Instance

The new Instance.

operation

Operation

An Operation object that can be used to check the status of the request.

apiResponse

object

The full API response.

CreateInstanceRequest

object

Config for the new instance.

Properties

Parameter

config

string

The name of the instance's configuration.

nodes

number

The number of nodes allocated to this instance.

CreateInstanceResponse

array

Properties

Parameter

0

Instance

The new Instance.

1

Operation

An Operation object that can be used to check the status of the request.

2

object

The full API response.

CreateSessionCallback

CreateSessionCallback(err, session, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

session

Session

The newly created session.

apiResponse

object

The full API response.

CreateSessionResponse

array

Properties

Parameter

0

Session

The newly created session.

2

object

The full API response.

CreateTableCallback

CreateTableCallback(err, table, operation, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

table

Table

The new Table.

operation

Operation

An Operation object that can be used to check the status of the request.

apiResponse

object

The full API response.

CreateTableResponse

array

Properties

Parameter

0

Table

The new Table.

1

Operation

An Operation object that can be used to check the status of the request.

2

object

The full API response.

DatabaseExistsCallback

DatabaseExistsCallback(err, exists)

Parameter

err

Error

Request error, if any.

Value may be null.

exists

boolean

Whether the Database exists.

DatabaseExistsResponse

array

Property

Parameter

0

boolean

Whether the Database exists.

DatabaseRunRequest

object

Transaction options.

Properties

Parameter

exactStaleness

Optional

number

Executes all reads at the timestamp that is exactStaleness old.

readTimestamp

Optional

date

Execute all reads at the given timestamp.

strong

Optional

boolean

Read at the timestamp where all previously committed transactions are visible.

DeleteInstanceCallback

DeleteInstanceCallback(err, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

apiResponse

object

The full API response.

DeleteInstanceResponse

array

Property

Parameter

0

object

The full API response.

GetDatabaseCallback

GetDatabaseCallback(err, database, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

database

Database

The Database.

apiResponse

object

The full API response.

GetDatabaseMetadataCallback

GetDatabaseMetadataCallback(err, metadata, apiResponse)

Parameter

err

Error

Request error, if any.

Value may be null.

meta