def share(self, query, share_to):
images = self._container_query(query, quiet=True)<EOL>if len(images) == <NUM_LIT:0>:<EOL><INDENT>bot.error('<STR_LIT>' %query)<EOL>sys.exit(<NUM_LIT:0>)<EOL><DEDENT>image = images[<NUM_LIT:0>]<EOL>def callback(request_id, response, exception):<EOL><INDENT>if exception:<EOL><INDENT>print(exception)<EOL><DEDENT>else:<EOL><INDENT>share_id = response.get('<STR_LIT:id>')<EOL>bot.info('<STR_LIT>' %(share_to, share_id))<EOL><DEDENT><DEDENT>batch = self._service.new_batch_http_request(callback=callback)<EOL>user_permission = {<EOL>'<STR_LIT:type>': '<STR_LIT:user>',<EOL>'<STR_LIT>': '<STR_LIT>',<EOL>'<STR_LIT>': share_to<EOL>}<EOL>batch.add(self._service.permissions().create(<EOL>fileId=image['<STR_LIT:id>'],<EOL>body=user_permission,<EOL>fields='<STR_LIT:id>',<EOL>))<EOL>batch.execute()<EOL>return image<EOL>
share will use the client to get an image based on a query, and then
       the link with an email or endpoint (share_to) of choice.