code: def make_datastore_api(client):
      
      parse_result = six.moves.urllib_parse.urlparse(client._base_url)
      host = parse_result.netloc
      if parse_result.scheme == "https":
          channel = make_secure_channel(client._credentials, DEFAULT_USER_AGENT, host)
      else:
          channel = insecure_channel(host)
  
      return datastore_client.DatastoreClient(
          channel=channel,
          client_info=client_info.ClientInfo(
              client_library_version=__version__, gapic_version=__version__
          ),
      )
docs: Create an instance of the GAPIC Datastore API.
  
      :type client: :class:`~google.cloud.datastore.client.Client`
      :param client: The client that holds configuration details.
  
      :rtype: :class:`.datastore.v1.datastore_client.DatastoreClient`
      :returns: A datastore API instance with the proper credentials.