beem.comment module¶
-
class
beem.comment.Comment(authorperm, full=False, lazy=False, steem_instance=None)¶ Bases:
beem.blockchainobject.BlockchainObjectRead data about a Comment/Post in the chain
Parameters: - authorperm (str) – perm link to post/comment
- steem_instance (steem) – Steem() instance to use when accesing a RPC
-
body¶
-
category¶
-
delete(account=None, identifier=None)¶ Delete an existing post/comment :param str identifier: Identifier for the post to upvote Takes
the form@author/permlinkParameters: account (str) – Voter to use for voting. (Optional) If
voteris not defines, thedefault_accountwill be taken or a ValueError will be raised
-
downvote(weight=-100, voter=None)¶ Downvote the post :param float weight: (optional) Weight for posting (-100.0 - +100.0) defaults to -100.0 :param str voter: (optional) Voting account
-
edit(body, meta=None, replace=False)¶ Edit an existing post :param str body: Body of the reply :param json meta: JSON meta object that can be attached to the
post. (optional)Parameters: replace (bool) – Instead of calculating a diff, replace the post entirely (defaults to False)
-
get_reblogged_by(identifier=None)¶
-
get_votes()¶
-
id¶
-
is_comment()¶ Retuns True if post is a comment
-
is_main_post()¶ Retuns True if main post, and False if this is a comment (reply).
-
json()¶
-
json_metadata¶
-
parent_permlink¶
-
permlink¶
-
refresh()¶
-
reply(body, title='', author='', meta=None)¶ Reply to an existing post :param str body: Body of the reply :param str title: Title of the reply post :param str author: Author of reply (optional) if not provided
default_userwill be used, if present, else aValueErrorwill be raised.Parameters: meta (json) – JSON meta object that can be attached to the post. (optional)
-
resteem(identifier=None, account=None)¶ Resteem a post :param str identifier: post identifier (@<account>/<permlink>) :param str account: (optional) the account to allow access
to (defaults todefault_account)
-
title¶
-
type_id= 8¶
-
upvote(weight=100, voter=None)¶ Upvote the post :param float weight: (optional) Weight for posting (-100.0 - +100.0) defaults to +100.0 :param str voter: (optional) Voting account
-
vote(weight, account=None, identifier=None, **kwargs)¶ Vote for a post :param str identifier: Identifier for the post to upvote Takes
the form@author/permlinkParameters: - weight (float) – Voting weight. Range: -100.0 - +100.0. May not be 0.0
- account (str) – Voter to use for voting. (Optional)
If
voteris not defines, thedefault_accountwill be taken or a ValueError will be raised