NAME
Google::Cloud::Datastore::V1beta3::DatastoreClient - Client library for Google Cloud Services
SYNOPSIS
use Google::Cloud::Datastore::V1beta3::DatastoreClient;
use Google::Auth;
my $auth = Google::Auth->default();
# 1. High-performance gRPC Transport (Default)
my $grpc_client = Google::Cloud::Datastore::V1beta3::DatastoreClient->new(
credentials => $auth,
transport => 'grpc', # Optional: 'grpc' is default
);
# 2. HTTP/REST Transport
my $rest_client = Google::Cloud::Datastore::V1beta3::DatastoreClient->new(
credentials => $auth,
transport => 'rest',
);
# Execute service methods
my $res = $grpc_client->some_method( %params );
DESCRIPTION
Google::Cloud::Datastore::V1beta3::DatastoreClient is an auto-generated client library for Google Cloud Services.
It provides a unified client interface supporting both high-performance HTTP/2 gRPC and HTTP/REST transports, with automatic Google Cloud Application Default Credentials (ADC) resolution and typed Protocol Buffers message handling.
SOURCE
Generated from the following Protocol Buffers schemas:
googleapis/google/datastore/v1beta3/datastore.protogoogleapis/google/datastore/v1beta3/entity.protogoogleapis/google/datastore/v1beta3/query.proto
CONSTRUCTOR
new
my $client = Google::Cloud::Datastore::V1beta3::DatastoreClient->new(
credentials => $auth, # Optional: Google::Auth object (defaults to ADC)
transport => 'grpc', # Optional: 'grpc' (default) or 'rest'
);
ATTRIBUTES
credentials
Returns or accepts the Google::Auth credentials object.
transport
Returns or accepts the active transport object (Google::gRPC::Client or Google::Cloud::REST::Client).
METHODS
METHODS
The following RPC methods are available in this client:
lookup
my $response = $client->lookup( project_id => $project_id, read_options => $read_options, keys => [ ... ], );Calls the RPC method
Lookupongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::LookupRequest
Returns: Google::Datastore::V1beta3::Datastore::LookupResponse
Parameters:
project_id-stringread_options- Google::Datastore::V1beta3::Datastore::ReadOptionskeys- ArrayRef of Google::Datastore::V1beta3::Entity::Key
run_query
my $response = $client->run_query( project_id => $project_id, partition_id => $partition_id, read_options => $read_options, );Calls the RPC method
RunQueryongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::RunQueryRequest
Returns: Google::Datastore::V1beta3::Datastore::RunQueryResponse
Parameters:
project_id-stringpartition_id- Google::Datastore::V1beta3::Entity::PartitionIdread_options- Google::Datastore::V1beta3::Datastore::ReadOptions
begin_transaction
my $response = $client->begin_transaction( project_id => $project_id, transaction_options => $transaction_options, );Calls the RPC method
BeginTransactionongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::BeginTransactionRequest
Returns: Google::Datastore::V1beta3::Datastore::BeginTransactionResponse
Parameters:
project_id-stringtransaction_options- Google::Datastore::V1beta3::Datastore::TransactionOptions
commit
my $response = $client->commit( project_id => $project_id, mode => $mode, mutations => [ ... ], );Calls the RPC method
Commitongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::CommitRequest
Returns: Google::Datastore::V1beta3::Datastore::CommitResponse
Parameters:
project_id-stringmutations- ArrayRef of Google::Datastore::V1beta3::Datastore::Mutation
rollback
my $response = $client->rollback( project_id => $project_id, transaction => $transaction, );Calls the RPC method
Rollbackongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::RollbackRequest
Returns: Google::Datastore::V1beta3::Datastore::RollbackResponse
Parameters:
project_id-stringtransaction-bytes
allocate_ids
my $response = $client->allocate_ids( project_id => $project_id, keys => [ ... ], );Calls the RPC method
AllocateIdsongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::AllocateIdsRequest
Returns: Google::Datastore::V1beta3::Datastore::AllocateIdsResponse
Parameters:
project_id-stringkeys- ArrayRef of Google::Datastore::V1beta3::Entity::Key
reserve_ids
my $response = $client->reserve_ids( project_id => $project_id, database_id => $database_id, keys => [ ... ], );Calls the RPC method
ReserveIdsongoogle.datastore.v1beta3.Datastore.Request: Google::Datastore::V1beta3::Datastore::ReserveIdsRequest
Returns: Google::Datastore::V1beta3::Datastore::ReserveIdsResponse
Parameters:
project_id-stringdatabase_id-stringkeys- ArrayRef of Google::Datastore::V1beta3::Entity::Key
LICENSE AND COPYRIGHT
Copyright (C) 2026 Google LLC
This program is released under the Apache 2.0 license.