Documentation ¶
Overview ¶
Package firebasedatabase provides access to the Firebase Realtime Database Management API.
For product documentation, see: https://firebase.google.com/docs/reference/rest/database/database-management/rest/
Creating a client ¶
Usage example:
import "google.golang.org/api/firebasedatabase/v1beta" ... ctx := context.Background() firebasedatabaseService, err := firebasedatabase.NewService(ctx)
In this example, Google Application Default Credentials are used for authentication.
For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
Other authentication options ¶
By default, all available scopes (see "Constants") are used to authenticate. To restrict scopes, use option.WithScopes:
firebasedatabaseService, err := firebasedatabase.NewService(ctx, option.WithScopes(firebasedatabase.FirebaseReadonlyScope))
To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
firebasedatabaseService, err := firebasedatabase.NewService(ctx, option.WithAPIKey("AIza..."))
To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
config := &oauth2.Config{...} // ... token, err := config.Exchange(ctx, ...) firebasedatabaseService, err := firebasedatabase.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
See https://godoc.org/google.golang.org/api/option/ for details on options.
Index ¶
- Constants
- type DatabaseInstance
- type DisableDatabaseInstanceRequest
- type ListDatabaseInstancesResponse
- type ProjectsLocationsInstancesCreateCall
- func (c *ProjectsLocationsInstancesCreateCall) Context(ctx context.Context) *ProjectsLocationsInstancesCreateCall
- func (c *ProjectsLocationsInstancesCreateCall) DatabaseId(databaseId string) *ProjectsLocationsInstancesCreateCall
- func (c *ProjectsLocationsInstancesCreateCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
- func (c *ProjectsLocationsInstancesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesCreateCall
- func (c *ProjectsLocationsInstancesCreateCall) Header() http.Header
- func (c *ProjectsLocationsInstancesCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsInstancesCreateCall
- type ProjectsLocationsInstancesDeleteCall
- func (c *ProjectsLocationsInstancesDeleteCall) Context(ctx context.Context) *ProjectsLocationsInstancesDeleteCall
- func (c *ProjectsLocationsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
- func (c *ProjectsLocationsInstancesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDeleteCall
- func (c *ProjectsLocationsInstancesDeleteCall) Header() http.Header
- type ProjectsLocationsInstancesDisableCall
- func (c *ProjectsLocationsInstancesDisableCall) Context(ctx context.Context) *ProjectsLocationsInstancesDisableCall
- func (c *ProjectsLocationsInstancesDisableCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
- func (c *ProjectsLocationsInstancesDisableCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDisableCall
- func (c *ProjectsLocationsInstancesDisableCall) Header() http.Header
- type ProjectsLocationsInstancesGetCall
- func (c *ProjectsLocationsInstancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetCall
- func (c *ProjectsLocationsInstancesGetCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
- func (c *ProjectsLocationsInstancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetCall
- func (c *ProjectsLocationsInstancesGetCall) Header() http.Header
- func (c *ProjectsLocationsInstancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetCall
- type ProjectsLocationsInstancesListCall
- func (c *ProjectsLocationsInstancesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesListCall
- func (c *ProjectsLocationsInstancesListCall) Do(opts ...googleapi.CallOption) (*ListDatabaseInstancesResponse, error)
- func (c *ProjectsLocationsInstancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesListCall
- func (c *ProjectsLocationsInstancesListCall) Header() http.Header
- func (c *ProjectsLocationsInstancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesListCall
- func (c *ProjectsLocationsInstancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesListCall
- func (c *ProjectsLocationsInstancesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesListCall
- func (c *ProjectsLocationsInstancesListCall) Pages(ctx context.Context, f func(*ListDatabaseInstancesResponse) error) error
- type ProjectsLocationsInstancesReenableCall
- func (c *ProjectsLocationsInstancesReenableCall) Context(ctx context.Context) *ProjectsLocationsInstancesReenableCall
- func (c *ProjectsLocationsInstancesReenableCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
- func (c *ProjectsLocationsInstancesReenableCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesReenableCall
- func (c *ProjectsLocationsInstancesReenableCall) Header() http.Header
- type ProjectsLocationsInstancesService
- func (r *ProjectsLocationsInstancesService) Create(parent string, databaseinstance *DatabaseInstance) *ProjectsLocationsInstancesCreateCall
- func (r *ProjectsLocationsInstancesService) Delete(name string) *ProjectsLocationsInstancesDeleteCall
- func (r *ProjectsLocationsInstancesService) Disable(name string, disabledatabaseinstancerequest *DisableDatabaseInstanceRequest) *ProjectsLocationsInstancesDisableCall
- func (r *ProjectsLocationsInstancesService) Get(nameid string) *ProjectsLocationsInstancesGetCall
- func (r *ProjectsLocationsInstancesService) List(parent string) *ProjectsLocationsInstancesListCall
- func (r *ProjectsLocationsInstancesService) Reenable(name string, reenabledatabaseinstancerequest *ReenableDatabaseInstanceRequest) *ProjectsLocationsInstancesReenableCall
- type ProjectsLocationsService
- type ProjectsService
- type ReenableDatabaseInstanceRequest
- type Service
Constants ¶
const ( // View and manage your data across Google Cloud Platform services CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" // View your data across Google Cloud Platform services CloudPlatformReadOnlyScope = "https://www.googleapis.com/auth/cloud-platform.read-only" // View and administer all your Firebase data and settings FirebaseScope = "https://www.googleapis.com/auth/firebase" // View all your Firebase data and settings FirebaseReadonlyScope = "https://www.googleapis.com/auth/firebase.readonly" )
OAuth2 scopes used by this API.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DatabaseInstance ¶
type DatabaseInstance struct { // DatabaseUrl: Immutable. The globally unique hostname of the database. DatabaseUrl string `json:"databaseUrl,omitempty"` // Name: The fully qualified resource name of the database instance, in // the form: // `projects/{project-number}/locations/{location-id}/instances/{database // -id}`. Currently the only supported location is 'us-central1'. Name string `json:"name,omitempty"` // Project: The resource name of the project this instance belongs to. // For example: `projects/{project-number}`. Project string `json:"project,omitempty"` // State: The database's lifecycle state. Read-only. // // Possible values: // "LIFECYCLE_STATE_UNSPECIFIED" - Unspecified state, likely the // result of an error on the backend. This is only used for // distinguishing unset values. // "ACTIVE" - The normal and active state. // "DISABLED" - The database is in a disabled state. It can be // re-enabled later. // "DELETED" - The database is in a deleted state. State string `json:"state,omitempty"` // Type: The database instance type. On creation only USER_DATABASE is // allowed, which is also the default when omitted. // // Possible values: // "DATABASE_INSTANCE_TYPE_UNSPECIFIED" - Unknown state, likely the // result of an error on the backend. This is only used for // distinguishing unset values. // "DEFAULT_DATABASE" - The default database that is provisioned when // a project is created. // "USER_DATABASE" - A database that the user created. Type string `json:"type,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "DatabaseUrl") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "DatabaseUrl") to include // in API requests with the JSON null value. By default, fields with // empty values are omitted from API requests. However, any field with // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
DatabaseInstance: Representation of a Realtime Database instance. Details on interacting with contents of a DatabaseInstance can be found at: https://firebase.google.com/docs/database/rest/start.
func (*DatabaseInstance) MarshalJSON ¶
func (s *DatabaseInstance) MarshalJSON() ([]byte, error)
type DisableDatabaseInstanceRequest ¶
type DisableDatabaseInstanceRequest struct { }
DisableDatabaseInstanceRequest: The request sent to the DisableDatabaseInstance method.
type ListDatabaseInstancesResponse ¶
type ListDatabaseInstancesResponse struct { // Instances: List of each DatabaseInstance that is in the parent // Firebase project. Instances []*DatabaseInstance `json:"instances,omitempty"` // NextPageToken: If the result list is too large to fit in a single // response, then a token is returned. If the string is empty, then this // response is the last page of results. This token can be used in a // subsequent call to `ListDatabaseInstances` to find the next group of // database instances. Page tokens are short-lived and should not be // persisted. NextPageToken string `json:"nextPageToken,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` // ForceSendFields is a list of field names (e.g. "Instances") to // unconditionally include in API requests. By default, fields with // empty values are omitted from API requests. However, any non-pointer, // non-interface field appearing in ForceSendFields will be sent to the // server regardless of whether the field is empty or not. This may be // used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` // NullFields is a list of field names (e.g. "Instances") to include in // API requests with the JSON null value. By default, fields with empty // values are omitted from API requests. However, any field with an // empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` }
ListDatabaseInstancesResponse: The response from the ListDatabaseInstances method.
func (*ListDatabaseInstancesResponse) MarshalJSON ¶
func (s *ListDatabaseInstancesResponse) MarshalJSON() ([]byte, error)
type ProjectsLocationsInstancesCreateCall ¶
type ProjectsLocationsInstancesCreateCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesCreateCall) Context ¶
func (c *ProjectsLocationsInstancesCreateCall) Context(ctx context.Context) *ProjectsLocationsInstancesCreateCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesCreateCall) DatabaseId ¶
func (c *ProjectsLocationsInstancesCreateCall) DatabaseId(databaseId string) *ProjectsLocationsInstancesCreateCall
DatabaseId sets the optional parameter "databaseId": The globally unique identifier of the database instance.
func (*ProjectsLocationsInstancesCreateCall) Do ¶
func (c *ProjectsLocationsInstancesCreateCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
Do executes the "firebasedatabase.projects.locations.instances.create" call. Exactly one of *DatabaseInstance or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *DatabaseInstance.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesCreateCall) Fields ¶
func (c *ProjectsLocationsInstancesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesCreateCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesCreateCall) Header ¶
func (c *ProjectsLocationsInstancesCreateCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesCreateCall) ValidateOnly ¶
func (c *ProjectsLocationsInstancesCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsInstancesCreateCall
ValidateOnly sets the optional parameter "validateOnly": When set to true, the request will be validated but not submitted.
type ProjectsLocationsInstancesDeleteCall ¶
type ProjectsLocationsInstancesDeleteCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesDeleteCall) Context ¶
func (c *ProjectsLocationsInstancesDeleteCall) Context(ctx context.Context) *ProjectsLocationsInstancesDeleteCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesDeleteCall) Do ¶
func (c *ProjectsLocationsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
Do executes the "firebasedatabase.projects.locations.instances.delete" call. Exactly one of *DatabaseInstance or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *DatabaseInstance.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesDeleteCall) Fields ¶
func (c *ProjectsLocationsInstancesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDeleteCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesDeleteCall) Header ¶
func (c *ProjectsLocationsInstancesDeleteCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
type ProjectsLocationsInstancesDisableCall ¶
type ProjectsLocationsInstancesDisableCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesDisableCall) Context ¶
func (c *ProjectsLocationsInstancesDisableCall) Context(ctx context.Context) *ProjectsLocationsInstancesDisableCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesDisableCall) Do ¶
func (c *ProjectsLocationsInstancesDisableCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
Do executes the "firebasedatabase.projects.locations.instances.disable" call. Exactly one of *DatabaseInstance or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *DatabaseInstance.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesDisableCall) Fields ¶
func (c *ProjectsLocationsInstancesDisableCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesDisableCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesDisableCall) Header ¶
func (c *ProjectsLocationsInstancesDisableCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
type ProjectsLocationsInstancesGetCall ¶
type ProjectsLocationsInstancesGetCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesGetCall) Context ¶
func (c *ProjectsLocationsInstancesGetCall) Context(ctx context.Context) *ProjectsLocationsInstancesGetCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesGetCall) Do ¶
func (c *ProjectsLocationsInstancesGetCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
Do executes the "firebasedatabase.projects.locations.instances.get" call. Exactly one of *DatabaseInstance or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *DatabaseInstance.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesGetCall) Fields ¶
func (c *ProjectsLocationsInstancesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesGetCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesGetCall) Header ¶
func (c *ProjectsLocationsInstancesGetCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesGetCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstancesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesGetCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
type ProjectsLocationsInstancesListCall ¶
type ProjectsLocationsInstancesListCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesListCall) Context ¶
func (c *ProjectsLocationsInstancesListCall) Context(ctx context.Context) *ProjectsLocationsInstancesListCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesListCall) Do ¶
func (c *ProjectsLocationsInstancesListCall) Do(opts ...googleapi.CallOption) (*ListDatabaseInstancesResponse, error)
Do executes the "firebasedatabase.projects.locations.instances.list" call. Exactly one of *ListDatabaseInstancesResponse or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *ListDatabaseInstancesResponse.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesListCall) Fields ¶
func (c *ProjectsLocationsInstancesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesListCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesListCall) Header ¶
func (c *ProjectsLocationsInstancesListCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
func (*ProjectsLocationsInstancesListCall) IfNoneMatch ¶
func (c *ProjectsLocationsInstancesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsInstancesListCall
IfNoneMatch sets the optional parameter which makes the operation fail if the object's ETag matches the given value. This is useful for getting updates only after the object has changed since the last request. Use googleapi.IsNotModified to check whether the response error from Do is the result of In-None-Match.
func (*ProjectsLocationsInstancesListCall) PageSize ¶
func (c *ProjectsLocationsInstancesListCall) PageSize(pageSize int64) *ProjectsLocationsInstancesListCall
PageSize sets the optional parameter "pageSize": The maximum number of database instances to return in the response. The server may return fewer than this at its discretion. If no value is specified (or too large a value is specified), then the server will impose its own limit.
func (*ProjectsLocationsInstancesListCall) PageToken ¶
func (c *ProjectsLocationsInstancesListCall) PageToken(pageToken string) *ProjectsLocationsInstancesListCall
PageToken sets the optional parameter "pageToken": Token returned from a previous call to `ListDatabaseInstances` indicating where in the set of database instances to resume listing.
func (*ProjectsLocationsInstancesListCall) Pages ¶
func (c *ProjectsLocationsInstancesListCall) Pages(ctx context.Context, f func(*ListDatabaseInstancesResponse) error) error
Pages invokes f for each page of results. A non-nil error returned from f will halt the iteration. The provided context supersedes any context provided to the Context method.
type ProjectsLocationsInstancesReenableCall ¶
type ProjectsLocationsInstancesReenableCall struct {
// contains filtered or unexported fields
}
func (*ProjectsLocationsInstancesReenableCall) Context ¶
func (c *ProjectsLocationsInstancesReenableCall) Context(ctx context.Context) *ProjectsLocationsInstancesReenableCall
Context sets the context to be used in this call's Do method. Any pending HTTP request will be aborted if the provided context is canceled.
func (*ProjectsLocationsInstancesReenableCall) Do ¶
func (c *ProjectsLocationsInstancesReenableCall) Do(opts ...googleapi.CallOption) (*DatabaseInstance, error)
Do executes the "firebasedatabase.projects.locations.instances.reenable" call. Exactly one of *DatabaseInstance or error will be non-nil. Any non-2xx status code is an error. Response headers are in either *DatabaseInstance.ServerResponse.Header or (if a response was returned at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check whether the returned error was because http.StatusNotModified was returned.
func (*ProjectsLocationsInstancesReenableCall) Fields ¶
func (c *ProjectsLocationsInstancesReenableCall) Fields(s ...googleapi.Field) *ProjectsLocationsInstancesReenableCall
Fields allows partial responses to be retrieved. See https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more information.
func (*ProjectsLocationsInstancesReenableCall) Header ¶
func (c *ProjectsLocationsInstancesReenableCall) Header() http.Header
Header returns an http.Header that can be modified by the caller to add HTTP headers to the request.
type ProjectsLocationsInstancesService ¶
type ProjectsLocationsInstancesService struct {
// contains filtered or unexported fields
}
func NewProjectsLocationsInstancesService ¶
func NewProjectsLocationsInstancesService(s *Service) *ProjectsLocationsInstancesService
func (*ProjectsLocationsInstancesService) Create ¶
func (r *ProjectsLocationsInstancesService) Create(parent string, databaseinstance *DatabaseInstance) *ProjectsLocationsInstancesCreateCall
Create: Requests that a new DatabaseInstance be created. The state of a successfully created DatabaseInstance is ACTIVE. Only available for projects on the Blaze plan. Projects can be upgraded using the Cloud Billing API https://cloud.google.com/billing/reference/rest/v1/projects/updateBillingInfo. Note that it might take a few minutes for billing enablement state to propagate to Firebase systems.
func (*ProjectsLocationsInstancesService) Delete ¶
func (r *ProjectsLocationsInstancesService) Delete(name string) *ProjectsLocationsInstancesDeleteCall
Delete: Marks a DatabaseInstance to be deleted. The DatabaseInstance will be purged within 30 days. The default database cannot be deleted. IDs for deleted database instances may never be recovered or re-used. The Database may only be deleted if it is already in a DISABLED state.
func (*ProjectsLocationsInstancesService) Disable ¶
func (r *ProjectsLocationsInstancesService) Disable(name string, disabledatabaseinstancerequest *DisableDatabaseInstanceRequest) *ProjectsLocationsInstancesDisableCall
Disable: Disables a DatabaseInstance. The database can be re-enabled later using ReenableDatabaseInstance. When a database is disabled, all reads and writes are denied, including view access in the Firebase console.
func (*ProjectsLocationsInstancesService) Get ¶
func (r *ProjectsLocationsInstancesService) Get(nameid string) *ProjectsLocationsInstancesGetCall
Get: Gets the DatabaseInstance identified by the specified resource name.
func (*ProjectsLocationsInstancesService) List ¶
func (r *ProjectsLocationsInstancesService) List(parent string) *ProjectsLocationsInstancesListCall
List: Lists each DatabaseInstance associated with the specified parent project. The list items are returned in no particular order, but will be a consistent view of the database instances when additional requests are made with a `pageToken`. The resulting list contains instances in any STATE. The list results may be stale by a few seconds. Use GetDatabaseInstance for consistent reads.
func (*ProjectsLocationsInstancesService) Reenable ¶
func (r *ProjectsLocationsInstancesService) Reenable(name string, reenabledatabaseinstancerequest *ReenableDatabaseInstanceRequest) *ProjectsLocationsInstancesReenableCall
Reenable: Enables a DatabaseInstance. The database must have been disabled previously using DisableDatabaseInstance. The state of a successfully reenabled DatabaseInstance is ACTIVE.
type ProjectsLocationsService ¶
type ProjectsLocationsService struct { Instances *ProjectsLocationsInstancesService // contains filtered or unexported fields }
func NewProjectsLocationsService ¶
func NewProjectsLocationsService(s *Service) *ProjectsLocationsService
type ProjectsService ¶
type ProjectsService struct { Locations *ProjectsLocationsService // contains filtered or unexported fields }
func NewProjectsService ¶
func NewProjectsService(s *Service) *ProjectsService
type ReenableDatabaseInstanceRequest ¶
type ReenableDatabaseInstanceRequest struct { }
ReenableDatabaseInstanceRequest: The request sent to the ReenableDatabaseInstance method.
type Service ¶
type Service struct { BasePath string // API endpoint base URL UserAgent string // optional additional User-Agent fragment Projects *ProjectsService // contains filtered or unexported fields }
func New
deprecated
New creates a new Service. It uses the provided http.Client for requests.
Deprecated: please use NewService instead. To provide a custom HTTP client, use option.WithHTTPClient. If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
func NewService ¶
NewService creates a new Service.