repository_name stringlengths 5 67 | func_path_in_repository stringlengths 4 234 | func_name stringlengths 0 314 | whole_func_string stringlengths 52 3.87M | language stringclasses 6
values | func_code_string stringlengths 52 3.87M | func_documentation_string stringlengths 1 47.2k | func_code_url stringlengths 85 339 |
|---|---|---|---|---|---|---|---|
sorgerlab/indra | indra/sources/isi/preprocessor.py | IsiPreprocessor.preprocess_abstract_list | def preprocess_abstract_list(self, abstract_list):
"""Preprocess abstracts in database pickle dump format for ISI reader.
For each abstract, creates a plain text file with one sentence per
line, and stores metadata to be included with each statement from
that abstract.
Paramete... | python | def preprocess_abstract_list(self, abstract_list):
"""Preprocess abstracts in database pickle dump format for ISI reader.
For each abstract, creates a plain text file with one sentence per
line, and stores metadata to be included with each statement from
that abstract.
Paramete... | Preprocess abstracts in database pickle dump format for ISI reader.
For each abstract, creates a plain text file with one sentence per
line, and stores metadata to be included with each statement from
that abstract.
Parameters
----------
abstract_list : list[dict]
... | https://github.com/sorgerlab/indra/blob/79a70415832c5702d7a820c7c9ccc8e25010124b/indra/sources/isi/preprocessor.py#L204-L234 |
sorgerlab/indra | indra/sources/geneways/api.py | process_geneways_files | def process_geneways_files(input_folder=data_folder, get_evidence=True):
"""Reads in Geneways data and returns a list of statements.
Parameters
----------
input_folder : Optional[str]
A folder in which to search for Geneways data. Looks for these
Geneways extraction data files: human_ac... | python | def process_geneways_files(input_folder=data_folder, get_evidence=True):
"""Reads in Geneways data and returns a list of statements.
Parameters
----------
input_folder : Optional[str]
A folder in which to search for Geneways data. Looks for these
Geneways extraction data files: human_ac... | Reads in Geneways data and returns a list of statements.
Parameters
----------
input_folder : Optional[str]
A folder in which to search for Geneways data. Looks for these
Geneways extraction data files: human_action.txt,
human_actionmention.txt, human_symbols.txt.
Omit this ... | https://github.com/sorgerlab/indra/blob/79a70415832c5702d7a820c7c9ccc8e25010124b/indra/sources/geneways/api.py#L24-L47 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_update | def post_update(self, post_id, tag_string=None, rating=None, source=None,
parent_id=None, has_embedded_notes=None,
is_rating_locked=None, is_note_locked=None,
is_status_locked=None):
"""Update a specific post (Requires login).
Parameters:
... | python | def post_update(self, post_id, tag_string=None, rating=None, source=None,
parent_id=None, has_embedded_notes=None,
is_rating_locked=None, is_note_locked=None,
is_status_locked=None):
"""Update a specific post (Requires login).
Parameters:
... | Update a specific post (Requires login).
Parameters:
post_id (int): The id number of the post to update.
tag_string (str): A space delimited list of tags.
rating (str): The rating for the post. Can be: safe, questionable,
or explicit.
so... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L51-L80 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_revert | def post_revert(self, post_id, version_id):
"""Function to reverts a post to a previous version (Requires login).
Parameters:
post_id (int):
version_id (int): The post version id to revert to.
"""
return self._get('posts/{0}/revert.json'.format(post_id),
... | python | def post_revert(self, post_id, version_id):
"""Function to reverts a post to a previous version (Requires login).
Parameters:
post_id (int):
version_id (int): The post version id to revert to.
"""
return self._get('posts/{0}/revert.json'.format(post_id),
... | Function to reverts a post to a previous version (Requires login).
Parameters:
post_id (int):
version_id (int): The post version id to revert to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L82-L90 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_copy_notes | def post_copy_notes(self, post_id, other_post_id):
"""Function to copy notes (requires login).
Parameters:
post_id (int):
other_post_id (int): The id of the post to copy notes to.
"""
return self._get('posts/{0}/copy_notes.json'.format(post_id),
... | python | def post_copy_notes(self, post_id, other_post_id):
"""Function to copy notes (requires login).
Parameters:
post_id (int):
other_post_id (int): The id of the post to copy notes to.
"""
return self._get('posts/{0}/copy_notes.json'.format(post_id),
... | Function to copy notes (requires login).
Parameters:
post_id (int):
other_post_id (int): The id of the post to copy notes to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L92-L100 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_mark_translated | def post_mark_translated(self, post_id, check_translation,
partially_translated):
"""Mark post as translated (Requires login) (UNTESTED).
If you set check_translation and partially_translated to 1 post will
be tagged as 'translated_request'
Parameters:
... | python | def post_mark_translated(self, post_id, check_translation,
partially_translated):
"""Mark post as translated (Requires login) (UNTESTED).
If you set check_translation and partially_translated to 1 post will
be tagged as 'translated_request'
Parameters:
... | Mark post as translated (Requires login) (UNTESTED).
If you set check_translation and partially_translated to 1 post will
be tagged as 'translated_request'
Parameters:
post_id (int):
check_translation (int): Can be 0, 1.
partially_translated (int): Can be 0,... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L102-L119 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_vote | def post_vote(self, post_id, score):
"""Action lets you vote for a post (Requires login).
Danbooru: Post votes/create.
Parameters:
post_id (int):
score (str): Can be: up, down.
"""
return self._get('posts/{0}/votes.json'.format(post_id),
... | python | def post_vote(self, post_id, score):
"""Action lets you vote for a post (Requires login).
Danbooru: Post votes/create.
Parameters:
post_id (int):
score (str): Can be: up, down.
"""
return self._get('posts/{0}/votes.json'.format(post_id),
... | Action lets you vote for a post (Requires login).
Danbooru: Post votes/create.
Parameters:
post_id (int):
score (str): Can be: up, down. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L121-L130 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_unvote | def post_unvote(self, post_id):
"""Action lets you unvote for a post (Requires login).
Parameters:
post_id (int):
"""
return self._get('posts/{0}/unvote.json'.format(post_id),
method='PUT', auth=True) | python | def post_unvote(self, post_id):
"""Action lets you unvote for a post (Requires login).
Parameters:
post_id (int):
"""
return self._get('posts/{0}/unvote.json'.format(post_id),
method='PUT', auth=True) | Action lets you unvote for a post (Requires login).
Parameters:
post_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L132-L139 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_flag_list | def post_flag_list(self, creator_id=None, creator_name=None, post_id=None,
reason_matches=None, is_resolved=None, category=None):
"""Function to flag a post (Requires login).
Parameters:
creator_id (int): The user id of the flag's creator.
creator_name (st... | python | def post_flag_list(self, creator_id=None, creator_name=None, post_id=None,
reason_matches=None, is_resolved=None, category=None):
"""Function to flag a post (Requires login).
Parameters:
creator_id (int): The user id of the flag's creator.
creator_name (st... | Function to flag a post (Requires login).
Parameters:
creator_id (int): The user id of the flag's creator.
creator_name (str): The name of the flag's creator.
post_id (int): The post id if the flag. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L141-L155 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_flag_create | def post_flag_create(self, post_id, reason):
"""Function to flag a post.
Parameters:
post_id (int): The id of the flagged post.
reason (str): The reason of the flagging.
"""
params = {'post_flag[post_id]': post_id, 'post_flag[reason]': reason}
return self... | python | def post_flag_create(self, post_id, reason):
"""Function to flag a post.
Parameters:
post_id (int): The id of the flagged post.
reason (str): The reason of the flagging.
"""
params = {'post_flag[post_id]': post_id, 'post_flag[reason]': reason}
return self... | Function to flag a post.
Parameters:
post_id (int): The id of the flagged post.
reason (str): The reason of the flagging. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L165-L173 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_appeals_list | def post_appeals_list(self, creator_id=None, creator_name=None,
post_id=None):
"""Function to return list of appeals (Requires login).
Parameters:
creator_id (int): The user id of the appeal's creator.
creator_name (str): The name of the appeal's creato... | python | def post_appeals_list(self, creator_id=None, creator_name=None,
post_id=None):
"""Function to return list of appeals (Requires login).
Parameters:
creator_id (int): The user id of the appeal's creator.
creator_name (str): The name of the appeal's creato... | Function to return list of appeals (Requires login).
Parameters:
creator_id (int): The user id of the appeal's creator.
creator_name (str): The name of the appeal's creator.
post_id (int): The post id if the appeal. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L175-L189 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_appeals_create | def post_appeals_create(self, post_id, reason):
"""Function to create appeals (Requires login).
Parameters:
post_id (int): The id of the appealed post.
reason (str) The reason of the appeal.
"""
params = {'post_appeal[post_id]': post_id,
'post_a... | python | def post_appeals_create(self, post_id, reason):
"""Function to create appeals (Requires login).
Parameters:
post_id (int): The id of the appealed post.
reason (str) The reason of the appeal.
"""
params = {'post_appeal[post_id]': post_id,
'post_a... | Function to create appeals (Requires login).
Parameters:
post_id (int): The id of the appealed post.
reason (str) The reason of the appeal. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L199-L208 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_versions_list | def post_versions_list(self, updater_name=None, updater_id=None,
post_id=None, start_id=None):
"""Get list of post versions.
Parameters:
updater_name (str):
updater_id (int):
post_id (int):
start_id (int):
"""
pa... | python | def post_versions_list(self, updater_name=None, updater_id=None,
post_id=None, start_id=None):
"""Get list of post versions.
Parameters:
updater_name (str):
updater_id (int):
post_id (int):
start_id (int):
"""
pa... | Get list of post versions.
Parameters:
updater_name (str):
updater_id (int):
post_id (int):
start_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L210-L226 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.post_versions_undo | def post_versions_undo(self, version_id):
"""Undo post version (Requires login) (UNTESTED).
Parameters:
version_id (int):
"""
return self._get('post_versions/{0}/undo.json'.format(version_id),
method='PUT', auth=True) | python | def post_versions_undo(self, version_id):
"""Undo post version (Requires login) (UNTESTED).
Parameters:
version_id (int):
"""
return self._get('post_versions/{0}/undo.json'.format(version_id),
method='PUT', auth=True) | Undo post version (Requires login) (UNTESTED).
Parameters:
version_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L236-L243 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.upload_list | def upload_list(self, uploader_id=None, uploader_name=None, source=None):
"""Search and return an uploads list (Requires login).
Parameters:
uploader_id (int): The id of the uploader.
uploader_name (str): The name of the uploader.
source (str): The source of the uplo... | python | def upload_list(self, uploader_id=None, uploader_name=None, source=None):
"""Search and return an uploads list (Requires login).
Parameters:
uploader_id (int): The id of the uploader.
uploader_name (str): The name of the uploader.
source (str): The source of the uplo... | Search and return an uploads list (Requires login).
Parameters:
uploader_id (int): The id of the uploader.
uploader_name (str): The name of the uploader.
source (str): The source of the upload (exact string match). | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L253-L266 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.upload_create | def upload_create(self, tags, rating, file_=None, source=None,
parent_id=None):
"""Function to create a new upload (Requires login).
Parameters:
tags (str):
rating (str): Can be: `s`, `q`, or `e`. Alternatively, you can
specify `ra... | python | def upload_create(self, tags, rating, file_=None, source=None,
parent_id=None):
"""Function to create a new upload (Requires login).
Parameters:
tags (str):
rating (str): Can be: `s`, `q`, or `e`. Alternatively, you can
specify `ra... | Function to create a new upload (Requires login).
Parameters:
tags (str):
rating (str): Can be: `s`, `q`, or `e`. Alternatively, you can
specify `rating:safe`, `rating:questionable`, or
`rating:explicit` in the tag string.
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L276-L303 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_list | def comment_list(self, group_by, limit=None, page=None, body_matches=None,
post_id=None, post_tags_match=None, creator_name=None,
creator_id=None, is_deleted=None):
"""Return a list of comments.
Parameters:
limit (int): How many posts you want to re... | python | def comment_list(self, group_by, limit=None, page=None, body_matches=None,
post_id=None, post_tags_match=None, creator_name=None,
creator_id=None, is_deleted=None):
"""Return a list of comments.
Parameters:
limit (int): How many posts you want to re... | Return a list of comments.
Parameters:
limit (int): How many posts you want to retrieve.
page (int): The page number.
group_by: Can be 'comment', 'post'. Comment will return recent
comments. Post will return posts that have been recently
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L305-L338 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_create | def comment_create(self, post_id, body, do_not_bump_post=None):
"""Action to lets you create a comment (Requires login).
Parameters:
post_id (int):
body (str):
do_not_bump_post (bool): Set to 1 if you do not want the post to be
bu... | python | def comment_create(self, post_id, body, do_not_bump_post=None):
"""Action to lets you create a comment (Requires login).
Parameters:
post_id (int):
body (str):
do_not_bump_post (bool): Set to 1 if you do not want the post to be
bu... | Action to lets you create a comment (Requires login).
Parameters:
post_id (int):
body (str):
do_not_bump_post (bool): Set to 1 if you do not want the post to be
bumped to the top of the comment listing. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L340-L354 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_update | def comment_update(self, comment_id, body):
"""Function to update a comment (Requires login).
Parameters:
comment_id (int):
body (str):
"""
params = {'comment[body]': body}
return self._get('comments/{0}.json'.format(comment_id), params, 'PUT',
... | python | def comment_update(self, comment_id, body):
"""Function to update a comment (Requires login).
Parameters:
comment_id (int):
body (str):
"""
params = {'comment[body]': body}
return self._get('comments/{0}.json'.format(comment_id), params, 'PUT',
... | Function to update a comment (Requires login).
Parameters:
comment_id (int):
body (str): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L356-L365 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_delete | def comment_delete(self, comment_id):
"""Remove a specific comment (Requires login).
Parameters:
comment_id (int): The id number of the comment to remove.
"""
return self._get('comments/{0}.json'.format(comment_id),
method='DELETE', auth=True) | python | def comment_delete(self, comment_id):
"""Remove a specific comment (Requires login).
Parameters:
comment_id (int): The id number of the comment to remove.
"""
return self._get('comments/{0}.json'.format(comment_id),
method='DELETE', auth=True) | Remove a specific comment (Requires login).
Parameters:
comment_id (int): The id number of the comment to remove. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L375-L382 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_undelete | def comment_undelete(self, comment_id):
"""Undelete a specific comment (Requires login) (UNTESTED).
Parameters:
comment_id (int):
"""
return self._get('comments/{0}/undelete.json'.format(comment_id),
method='POST', auth=True) | python | def comment_undelete(self, comment_id):
"""Undelete a specific comment (Requires login) (UNTESTED).
Parameters:
comment_id (int):
"""
return self._get('comments/{0}/undelete.json'.format(comment_id),
method='POST', auth=True) | Undelete a specific comment (Requires login) (UNTESTED).
Parameters:
comment_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L384-L391 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_vote | def comment_vote(self, comment_id, score):
"""Lets you vote for a comment (Requires login).
Parameters:
comment_id (int):
score (str): Can be: up, down.
"""
params = {'score': score}
return self._get('comments/{0}/votes.json'.format(comment_id), params,
... | python | def comment_vote(self, comment_id, score):
"""Lets you vote for a comment (Requires login).
Parameters:
comment_id (int):
score (str): Can be: up, down.
"""
params = {'score': score}
return self._get('comments/{0}/votes.json'.format(comment_id), params,
... | Lets you vote for a comment (Requires login).
Parameters:
comment_id (int):
score (str): Can be: up, down. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L393-L402 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.comment_unvote | def comment_unvote(self, comment_id):
"""Lets you unvote a specific comment (Requires login).
Parameters:
comment_id (int):
"""
return self._get('posts/{0}/unvote.json'.format(comment_id),
method='POST', auth=True) | python | def comment_unvote(self, comment_id):
"""Lets you unvote a specific comment (Requires login).
Parameters:
comment_id (int):
"""
return self._get('posts/{0}/unvote.json'.format(comment_id),
method='POST', auth=True) | Lets you unvote a specific comment (Requires login).
Parameters:
comment_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L404-L411 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.favorite_remove | def favorite_remove(self, post_id):
"""Remove a post from favorites (Requires login).
Parameters:
post_id (int): Where post_id is the post id.
"""
return self._get('favorites/{0}.json'.format(post_id), method='DELETE',
auth=True) | python | def favorite_remove(self, post_id):
"""Remove a post from favorites (Requires login).
Parameters:
post_id (int): Where post_id is the post id.
"""
return self._get('favorites/{0}.json'.format(post_id), method='DELETE',
auth=True) | Remove a post from favorites (Requires login).
Parameters:
post_id (int): Where post_id is the post id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L431-L438 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.dmail_list | def dmail_list(self, message_matches=None, to_name=None, to_id=None,
from_name=None, from_id=None, read=None):
"""Return list of Dmails. You can only view dmails you own
(Requires login).
Parameters:
message_matches (str): The message body contains the given terms... | python | def dmail_list(self, message_matches=None, to_name=None, to_id=None,
from_name=None, from_id=None, read=None):
"""Return list of Dmails. You can only view dmails you own
(Requires login).
Parameters:
message_matches (str): The message body contains the given terms... | Return list of Dmails. You can only view dmails you own
(Requires login).
Parameters:
message_matches (str): The message body contains the given terms.
to_name (str): The recipient's name.
to_id (int): The recipient's user id.
from_name (str): The sender'... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L440-L461 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.dmail_create | def dmail_create(self, to_name, title, body):
"""Create a dmail (Requires login)
Parameters:
to_name (str): The recipient's name.
title (str): The title of the message.
body (str): The body of the message.
"""
params = {
'dmail[to_name]': ... | python | def dmail_create(self, to_name, title, body):
"""Create a dmail (Requires login)
Parameters:
to_name (str): The recipient's name.
title (str): The title of the message.
body (str): The body of the message.
"""
params = {
'dmail[to_name]': ... | Create a dmail (Requires login)
Parameters:
to_name (str): The recipient's name.
title (str): The title of the message.
body (str): The body of the message. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L472-L485 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.dmail_delete | def dmail_delete(self, dmail_id):
"""Delete a dmail. You can only delete dmails you own (Requires login).
Parameters:
dmail_id (int): where dmail_id is the dmail id.
"""
return self._get('dmails/{0}.json'.format(dmail_id), method='DELETE',
auth=True) | python | def dmail_delete(self, dmail_id):
"""Delete a dmail. You can only delete dmails you own (Requires login).
Parameters:
dmail_id (int): where dmail_id is the dmail id.
"""
return self._get('dmails/{0}.json'.format(dmail_id), method='DELETE',
auth=True) | Delete a dmail. You can only delete dmails you own (Requires login).
Parameters:
dmail_id (int): where dmail_id is the dmail id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L487-L494 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_list | def artist_list(self, query=None, artist_id=None, creator_name=None,
creator_id=None, is_active=None, is_banned=None,
empty_only=None, order=None):
"""Get an artist of a list of artists.
Parameters:
query (str):
This field has multiple... | python | def artist_list(self, query=None, artist_id=None, creator_name=None,
creator_id=None, is_active=None, is_banned=None,
empty_only=None, order=None):
"""Get an artist of a list of artists.
Parameters:
query (str):
This field has multiple... | Get an artist of a list of artists.
Parameters:
query (str):
This field has multiple uses depending on what the query starts
with:
'http:desired_url':
Search for artist with this URL.
'name:desired_url':
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L496-L537 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_create | def artist_create(self, name, other_names_comma=None, group_name=None,
url_string=None, body=None):
"""Function to create an artist (Requires login) (UNTESTED).
Parameters:
name (str):
other_names_comma (str): List of alternative names for this
... | python | def artist_create(self, name, other_names_comma=None, group_name=None,
url_string=None, body=None):
"""Function to create an artist (Requires login) (UNTESTED).
Parameters:
name (str):
other_names_comma (str): List of alternative names for this
... | Function to create an artist (Requires login) (UNTESTED).
Parameters:
name (str):
other_names_comma (str): List of alternative names for this
artist, comma delimited.
group_name (str): The name of the group this artist belongs to.
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L547-L568 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_update | def artist_update(self, artist_id, name=None, other_names_comma=None,
group_name=None, url_string=None, body=None):
"""Function to update artists (Requires login) (UNTESTED).
Parameters:
artist_id (str):
name (str): Artist name.
other_names_comm... | python | def artist_update(self, artist_id, name=None, other_names_comma=None,
group_name=None, url_string=None, body=None):
"""Function to update artists (Requires login) (UNTESTED).
Parameters:
artist_id (str):
name (str): Artist name.
other_names_comm... | Function to update artists (Requires login) (UNTESTED).
Parameters:
artist_id (str):
name (str): Artist name.
other_names_comma (str): List of alternative names for this
artist, comma delimited.
group_name (str): The name of t... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L570-L593 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_delete | def artist_delete(self, artist_id):
"""Action to lets you delete an artist (Requires login) (UNTESTED)
(Only Builder+).
Parameters:
artist_id (int): Where artist_id is the artist id.
"""
return self._get('artists/{0}.json'.format(artist_id), method='DELETE',
... | python | def artist_delete(self, artist_id):
"""Action to lets you delete an artist (Requires login) (UNTESTED)
(Only Builder+).
Parameters:
artist_id (int): Where artist_id is the artist id.
"""
return self._get('artists/{0}.json'.format(artist_id), method='DELETE',
... | Action to lets you delete an artist (Requires login) (UNTESTED)
(Only Builder+).
Parameters:
artist_id (int): Where artist_id is the artist id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L595-L603 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_undelete | def artist_undelete(self, artist_id):
"""Lets you undelete artist (Requires login) (UNTESTED) (Only Builder+).
Parameters:
artist_id (int):
"""
return self._get('artists/{0}/undelete.json'.format(artist_id),
method='POST', auth=True) | python | def artist_undelete(self, artist_id):
"""Lets you undelete artist (Requires login) (UNTESTED) (Only Builder+).
Parameters:
artist_id (int):
"""
return self._get('artists/{0}/undelete.json'.format(artist_id),
method='POST', auth=True) | Lets you undelete artist (Requires login) (UNTESTED) (Only Builder+).
Parameters:
artist_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L605-L612 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_revert | def artist_revert(self, artist_id, version_id):
"""Revert an artist (Requires login) (UNTESTED).
Parameters:
artist_id (int): The artist id.
version_id (int): The artist version id to revert to.
"""
params = {'version_id': version_id}
return self._get('ar... | python | def artist_revert(self, artist_id, version_id):
"""Revert an artist (Requires login) (UNTESTED).
Parameters:
artist_id (int): The artist id.
version_id (int): The artist version id to revert to.
"""
params = {'version_id': version_id}
return self._get('ar... | Revert an artist (Requires login) (UNTESTED).
Parameters:
artist_id (int): The artist id.
version_id (int): The artist version id to revert to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L619-L628 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_versions | def artist_versions(self, name=None, updater_name=None, updater_id=None,
artist_id=None, is_active=None, is_banned=None,
order=None):
"""Get list of artist versions (Requires login).
Parameters:
name (str):
updater_name (str):
... | python | def artist_versions(self, name=None, updater_name=None, updater_id=None,
artist_id=None, is_active=None, is_banned=None,
order=None):
"""Get list of artist versions (Requires login).
Parameters:
name (str):
updater_name (str):
... | Get list of artist versions (Requires login).
Parameters:
name (str):
updater_name (str):
updater_id (int):
artist_id (int):
is_active (bool): Can be: True, False.
is_banned (bool): Can be: True, False.
order (str): Can be: nam... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L630-L653 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_commentary_list | def artist_commentary_list(self, text_matches=None, post_id=None,
post_tags_match=None, original_present=None,
translated_present=None):
"""list artist commentary.
Parameters:
text_matches (str):
post_id (int):
... | python | def artist_commentary_list(self, text_matches=None, post_id=None,
post_tags_match=None, original_present=None,
translated_present=None):
"""list artist commentary.
Parameters:
text_matches (str):
post_id (int):
... | list artist commentary.
Parameters:
text_matches (str):
post_id (int):
post_tags_match (str): The commentary's post's tags match the
giventerms. Meta-tags not supported.
original_present (str): Can be: yes, no.
trans... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L655-L675 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_commentary_create_update | def artist_commentary_create_update(self, post_id, original_title,
original_description, translated_title,
translated_description):
"""Create or update artist commentary (Requires login) (UNTESTED).
Parameters:
... | python | def artist_commentary_create_update(self, post_id, original_title,
original_description, translated_title,
translated_description):
"""Create or update artist commentary (Requires login) (UNTESTED).
Parameters:
... | Create or update artist commentary (Requires login) (UNTESTED).
Parameters:
post_id (int): Post id.
original_title (str): Original title.
original_description (str): Original description.
translated_title (str): Translated title.
translated_descriptio... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L677-L697 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_commentary_revert | def artist_commentary_revert(self, id_, version_id):
"""Revert artist commentary (Requires login) (UNTESTED).
Parameters:
id_ (int): The artist commentary id.
version_id (int): The artist commentary version id to
revert to.
"""
param... | python | def artist_commentary_revert(self, id_, version_id):
"""Revert artist commentary (Requires login) (UNTESTED).
Parameters:
id_ (int): The artist commentary id.
version_id (int): The artist commentary version id to
revert to.
"""
param... | Revert artist commentary (Requires login) (UNTESTED).
Parameters:
id_ (int): The artist commentary id.
version_id (int): The artist commentary version id to
revert to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L699-L709 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.artist_commentary_versions | def artist_commentary_versions(self, post_id, updater_id):
"""Return list of artist commentary versions.
Parameters:
updater_id (int):
post_id (int):
"""
params = {'search[updater_id]': updater_id, 'search[post_id]': post_id}
return self._get('artist_comm... | python | def artist_commentary_versions(self, post_id, updater_id):
"""Return list of artist commentary versions.
Parameters:
updater_id (int):
post_id (int):
"""
params = {'search[updater_id]': updater_id, 'search[post_id]': post_id}
return self._get('artist_comm... | Return list of artist commentary versions.
Parameters:
updater_id (int):
post_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L711-L719 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.note_list | def note_list(self, body_matches=None, post_id=None, post_tags_match=None,
creator_name=None, creator_id=None, is_active=None):
"""Return list of notes.
Parameters:
body_matches (str): The note's body matches the given terms.
post_id (int): A specific post.
... | python | def note_list(self, body_matches=None, post_id=None, post_tags_match=None,
creator_name=None, creator_id=None, is_active=None):
"""Return list of notes.
Parameters:
body_matches (str): The note's body matches the given terms.
post_id (int): A specific post.
... | Return list of notes.
Parameters:
body_matches (str): The note's body matches the given terms.
post_id (int): A specific post.
post_tags_match (str): The note's post's tags match the given terms.
creator_name (str): The creator's name. Exact match.
cr... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L721-L741 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.note_create | def note_create(self, post_id, coor_x, coor_y, width, height, body):
"""Function to create a note (Requires login) (UNTESTED).
Parameters:
post_id (int):
coor_x (int): The x coordinates of the note in pixels,
with respect to the top-left corner of the i... | python | def note_create(self, post_id, coor_x, coor_y, width, height, body):
"""Function to create a note (Requires login) (UNTESTED).
Parameters:
post_id (int):
coor_x (int): The x coordinates of the note in pixels,
with respect to the top-left corner of the i... | Function to create a note (Requires login) (UNTESTED).
Parameters:
post_id (int):
coor_x (int): The x coordinates of the note in pixels,
with respect to the top-left corner of the image.
coor_y (int): The y coordinates of the note in pixels,
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L751-L772 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.note_update | def note_update(self, note_id, coor_x=None, coor_y=None, width=None,
height=None, body=None):
"""Function to update a note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
coor_x (int): The x coordinates of the note in pix... | python | def note_update(self, note_id, coor_x=None, coor_y=None, width=None,
height=None, body=None):
"""Function to update a note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
coor_x (int): The x coordinates of the note in pix... | Function to update a note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
coor_x (int): The x coordinates of the note in pixels,
with respect to the top-left corner of the image.
coor_y (int): The y coordinates ... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L774-L796 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.note_delete | def note_delete(self, note_id):
"""delete a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
"""
return self._get('notes/{0}.json'.format(note_id), method='DELETE',
auth=True) | python | def note_delete(self, note_id):
"""delete a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
"""
return self._get('notes/{0}.json'.format(note_id), method='DELETE',
auth=True) | delete a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L798-L805 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.note_revert | def note_revert(self, note_id, version_id):
"""Function to revert a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
version_id (int): The note version id to revert to.
"""
return self._get('notes/{0}/revert.json... | python | def note_revert(self, note_id, version_id):
"""Function to revert a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
version_id (int): The note version id to revert to.
"""
return self._get('notes/{0}/revert.json... | Function to revert a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): Where note_id is the note id.
version_id (int): The note version id to revert to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L807-L815 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.note_versions | def note_versions(self, updater_id=None, post_id=None, note_id=None):
"""Get list of note versions.
Parameters:
updater_id (int):
post_id (int):
note_id (int):
"""
params = {
'search[updater_id]': updater_id,
'search[post_id]':... | python | def note_versions(self, updater_id=None, post_id=None, note_id=None):
"""Get list of note versions.
Parameters:
updater_id (int):
post_id (int):
note_id (int):
"""
params = {
'search[updater_id]': updater_id,
'search[post_id]':... | Get list of note versions.
Parameters:
updater_id (int):
post_id (int):
note_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L817-L830 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.user_list | def user_list(self, name=None, name_matches=None, min_level=None,
max_level=None, level=None, user_id=None, order=None):
"""Function to get a list of users or a specific user.
Levels:
Users have a number attribute called level representing their role.
The curre... | python | def user_list(self, name=None, name_matches=None, min_level=None,
max_level=None, level=None, user_id=None, order=None):
"""Function to get a list of users or a specific user.
Levels:
Users have a number attribute called level representing their role.
The curre... | Function to get a list of users or a specific user.
Levels:
Users have a number attribute called level representing their role.
The current levels are:
Member 20, Gold 30, Platinum 31, Builder 32, Contributor 33,
Janitor 35, Moderator 40 and Admin 50.
P... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L832-L862 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_list | def pool_list(self, name_matches=None, pool_ids=None, category=None,
description_matches=None, creator_name=None, creator_id=None,
is_deleted=None, is_active=None, order=None):
"""Get a list of pools.
Parameters:
name_matches (str):
pool_ids (... | python | def pool_list(self, name_matches=None, pool_ids=None, category=None,
description_matches=None, creator_name=None, creator_id=None,
is_deleted=None, is_active=None, order=None):
"""Get a list of pools.
Parameters:
name_matches (str):
pool_ids (... | Get a list of pools.
Parameters:
name_matches (str):
pool_ids (str): Can search for multiple ID's at once, separated by
commas.
description_matches (str):
creator_name (str):
creator_id (int):
is_active (bool): C... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L872-L900 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_create | def pool_create(self, name, description, category):
"""Function to create a pool (Requires login) (UNTESTED).
Parameters:
name (str): Pool name.
description (str): Pool description.
category (str): Can be: series, collection.
"""
params = {
... | python | def pool_create(self, name, description, category):
"""Function to create a pool (Requires login) (UNTESTED).
Parameters:
name (str): Pool name.
description (str): Pool description.
category (str): Can be: series, collection.
"""
params = {
... | Function to create a pool (Requires login) (UNTESTED).
Parameters:
name (str): Pool name.
description (str): Pool description.
category (str): Can be: series, collection. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L910-L923 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_update | def pool_update(self, pool_id, name=None, description=None, post_ids=None,
is_active=None, category=None):
"""Update a pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): Where pool_id is the pool id.
name (str):
description (str):
... | python | def pool_update(self, pool_id, name=None, description=None, post_ids=None,
is_active=None, category=None):
"""Update a pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): Where pool_id is the pool id.
name (str):
description (str):
... | Update a pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): Where pool_id is the pool id.
name (str):
description (str):
post_ids (str): List of space delimited post ids.
is_active (int): Can be: 1, 0.
category (str): Can be: ser... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L925-L945 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_delete | def pool_delete(self, pool_id):
"""Delete a pool (Requires login) (UNTESTED) (Moderator+).
Parameters:
pool_id (int): Where pool_id is the pool id.
"""
return self._get('pools/{0}.json'.format(pool_id), method='DELETE',
auth=True) | python | def pool_delete(self, pool_id):
"""Delete a pool (Requires login) (UNTESTED) (Moderator+).
Parameters:
pool_id (int): Where pool_id is the pool id.
"""
return self._get('pools/{0}.json'.format(pool_id), method='DELETE',
auth=True) | Delete a pool (Requires login) (UNTESTED) (Moderator+).
Parameters:
pool_id (int): Where pool_id is the pool id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L947-L954 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_undelete | def pool_undelete(self, pool_id):
"""Undelete a specific poool (Requires login) (UNTESTED) (Moderator+).
Parameters:
pool_id (int): Where pool_id is the pool id.
"""
return self._get('pools/{0}/undelete.json'.format(pool_id),
method='POST', auth=True... | python | def pool_undelete(self, pool_id):
"""Undelete a specific poool (Requires login) (UNTESTED) (Moderator+).
Parameters:
pool_id (int): Where pool_id is the pool id.
"""
return self._get('pools/{0}/undelete.json'.format(pool_id),
method='POST', auth=True... | Undelete a specific poool (Requires login) (UNTESTED) (Moderator+).
Parameters:
pool_id (int): Where pool_id is the pool id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L956-L963 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_revert | def pool_revert(self, pool_id, version_id):
"""Function to revert a specific pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): Where pool_id is the pool id.
version_id (int):
"""
return self._get('pools/{0}/revert.json'.format(pool_id),
... | python | def pool_revert(self, pool_id, version_id):
"""Function to revert a specific pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): Where pool_id is the pool id.
version_id (int):
"""
return self._get('pools/{0}/revert.json'.format(pool_id),
... | Function to revert a specific pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): Where pool_id is the pool id.
version_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L965-L973 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.pool_versions | def pool_versions(self, updater_id=None, updater_name=None, pool_id=None):
"""Get list of pool versions.
Parameters:
updater_id (int):
updater_name (str):
pool_id (int):
"""
params = {
'search[updater_id]': updater_id,
'search[... | python | def pool_versions(self, updater_id=None, updater_name=None, pool_id=None):
"""Get list of pool versions.
Parameters:
updater_id (int):
updater_name (str):
pool_id (int):
"""
params = {
'search[updater_id]': updater_id,
'search[... | Get list of pool versions.
Parameters:
updater_id (int):
updater_name (str):
pool_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L975-L988 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.tag_list | def tag_list(self, name_matches=None, name=None, category=None,
hide_empty=None, has_wiki=None, has_artist=None, order=None):
"""Get a list of tags.
Parameters:
name_matches (str): Can be: part or full name.
name (str): Allows searching for multiple tags with ex... | python | def tag_list(self, name_matches=None, name=None, category=None,
hide_empty=None, has_wiki=None, has_artist=None, order=None):
"""Get a list of tags.
Parameters:
name_matches (str): Can be: part or full name.
name (str): Allows searching for multiple tags with ex... | Get a list of tags.
Parameters:
name_matches (str): Can be: part or full name.
name (str): Allows searching for multiple tags with exact given
names, separated by commas. e.g.
search[name]=touhou,original,k-on! would return the
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L990-L1017 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.tag_update | def tag_update(self, tag_id, category):
"""Lets you update a tag (Requires login) (UNTESTED).
Parameters:
tag_id (int):
category (str): Can be: 0, 1, 3, 4 (general, artist, copyright,
character respectively).
"""
param = {'tag[category... | python | def tag_update(self, tag_id, category):
"""Lets you update a tag (Requires login) (UNTESTED).
Parameters:
tag_id (int):
category (str): Can be: 0, 1, 3, 4 (general, artist, copyright,
character respectively).
"""
param = {'tag[category... | Lets you update a tag (Requires login) (UNTESTED).
Parameters:
tag_id (int):
category (str): Can be: 0, 1, 3, 4 (general, artist, copyright,
character respectively). | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1027-L1037 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.tag_aliases | def tag_aliases(self, name_matches=None, antecedent_name=None,
tag_id=None):
"""Get tags aliases.
Parameters:
name_matches (str): Match antecedent or consequent name.
antecedent_name (str): Match antecedent name (exact match).
tag_id (int): The ta... | python | def tag_aliases(self, name_matches=None, antecedent_name=None,
tag_id=None):
"""Get tags aliases.
Parameters:
name_matches (str): Match antecedent or consequent name.
antecedent_name (str): Match antecedent name (exact match).
tag_id (int): The ta... | Get tags aliases.
Parameters:
name_matches (str): Match antecedent or consequent name.
antecedent_name (str): Match antecedent name (exact match).
tag_id (int): The tag alias id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1039-L1053 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.tag_implications | def tag_implications(self, name_matches=None, antecedent_name=None,
tag_id=None):
"""Get tags implications.
Parameters:
name_matches (str): Match antecedent or consequent name.
antecedent_name (str): Match antecedent name (exact match).
tag_i... | python | def tag_implications(self, name_matches=None, antecedent_name=None,
tag_id=None):
"""Get tags implications.
Parameters:
name_matches (str): Match antecedent or consequent name.
antecedent_name (str): Match antecedent name (exact match).
tag_i... | Get tags implications.
Parameters:
name_matches (str): Match antecedent or consequent name.
antecedent_name (str): Match antecedent name (exact match).
tag_id (int): Tag implication id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1055-L1069 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.tag_related | def tag_related(self, query, category=None):
"""Get related tags.
Parameters:
query (str): The tag to find the related tags for.
category (str): If specified, show only tags of a specific
category. Can be: General 0, Artist 1, Copyright
... | python | def tag_related(self, query, category=None):
"""Get related tags.
Parameters:
query (str): The tag to find the related tags for.
category (str): If specified, show only tags of a specific
category. Can be: General 0, Artist 1, Copyright
... | Get related tags.
Parameters:
query (str): The tag to find the related tags for.
category (str): If specified, show only tags of a specific
category. Can be: General 0, Artist 1, Copyright
3 and Character 4. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1071-L1081 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.wiki_list | def wiki_list(self, title=None, creator_id=None, body_matches=None,
other_names_match=None, creator_name=None, hide_deleted=None,
other_names_present=None, order=None):
"""Function to retrieves a list of every wiki page.
Parameters:
title (str): Page titl... | python | def wiki_list(self, title=None, creator_id=None, body_matches=None,
other_names_match=None, creator_name=None, hide_deleted=None,
other_names_present=None, order=None):
"""Function to retrieves a list of every wiki page.
Parameters:
title (str): Page titl... | Function to retrieves a list of every wiki page.
Parameters:
title (str): Page title.
creator_id (int): Creator id.
body_matches (str): Page content.
other_names_match (str): Other names.
creator_name (str): Creator name.
hide_deleted (str... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1083-L1108 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.wiki_create | def wiki_create(self, title, body, other_names=None):
"""Action to lets you create a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): Page title.
body (str): Page content.
other_names (str): Other names.
"""
params = {
'wiki... | python | def wiki_create(self, title, body, other_names=None):
"""Action to lets you create a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): Page title.
body (str): Page content.
other_names (str): Other names.
"""
params = {
'wiki... | Action to lets you create a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): Page title.
body (str): Page content.
other_names (str): Other names. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1118-L1131 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.wiki_update | def wiki_update(self, page_id, title=None, body=None,
other_names=None, is_locked=None, is_deleted=None):
"""Action to lets you update a wiki page (Requires login) (UNTESTED).
Parameters:
page_id (int): Whre page_id is the wiki page id.
title (str): Page titl... | python | def wiki_update(self, page_id, title=None, body=None,
other_names=None, is_locked=None, is_deleted=None):
"""Action to lets you update a wiki page (Requires login) (UNTESTED).
Parameters:
page_id (int): Whre page_id is the wiki page id.
title (str): Page titl... | Action to lets you update a wiki page (Requires login) (UNTESTED).
Parameters:
page_id (int): Whre page_id is the wiki page id.
title (str): Page title.
body (str): Page content.
other_names (str): Other names.
is_locked (int): Can be: 0, 1 (Builder+)... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1133-L1151 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.wiki_delete | def wiki_delete(self, page_id):
"""Delete a specific page wiki (Requires login) (UNTESTED) (Builder+).
Parameters:
page_id (int):
"""
return self._get('wiki_pages/{0}.json'.format(page_id), auth=True,
method='DELETE') | python | def wiki_delete(self, page_id):
"""Delete a specific page wiki (Requires login) (UNTESTED) (Builder+).
Parameters:
page_id (int):
"""
return self._get('wiki_pages/{0}.json'.format(page_id), auth=True,
method='DELETE') | Delete a specific page wiki (Requires login) (UNTESTED) (Builder+).
Parameters:
page_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1153-L1160 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.wiki_revert | def wiki_revert(self, wiki_page_id, version_id):
"""Revert page to a previeous version (Requires login) (UNTESTED).
Parameters:
wiki_page_id (int): Where page_id is the wiki page id.
version_id (int):
"""
return self._get('wiki_pages/{0}/revert.json'.format(wiki_... | python | def wiki_revert(self, wiki_page_id, version_id):
"""Revert page to a previeous version (Requires login) (UNTESTED).
Parameters:
wiki_page_id (int): Where page_id is the wiki page id.
version_id (int):
"""
return self._get('wiki_pages/{0}/revert.json'.format(wiki_... | Revert page to a previeous version (Requires login) (UNTESTED).
Parameters:
wiki_page_id (int): Where page_id is the wiki page id.
version_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1162-L1170 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.wiki_versions_list | def wiki_versions_list(self, page_id, updater_id):
"""Return a list of wiki page version.
Parameters:
page_id (int):
updater_id (int):
"""
params = {
'earch[updater_id]': updater_id,
'search[wiki_page_id]': page_id
}
re... | python | def wiki_versions_list(self, page_id, updater_id):
"""Return a list of wiki page version.
Parameters:
page_id (int):
updater_id (int):
"""
params = {
'earch[updater_id]': updater_id,
'search[wiki_page_id]': page_id
}
re... | Return a list of wiki page version.
Parameters:
page_id (int):
updater_id (int): | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1172-L1183 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_topic_list | def forum_topic_list(self, title_matches=None, title=None,
category_id=None):
"""Function to get forum topics.
Parameters:
title_matches (str): Search body for the given terms.
title (str): Exact title match.
category_id (int): Can be: 0, 1, ... | python | def forum_topic_list(self, title_matches=None, title=None,
category_id=None):
"""Function to get forum topics.
Parameters:
title_matches (str): Search body for the given terms.
title (str): Exact title match.
category_id (int): Can be: 0, 1, ... | Function to get forum topics.
Parameters:
title_matches (str): Search body for the given terms.
title (str): Exact title match.
category_id (int): Can be: 0, 1, 2 (General, Tags, Bugs & Features
respectively). | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1193-L1208 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_topic_create | def forum_topic_create(self, title, body, category=None):
"""Function to create topic (Requires login) (UNTESTED).
Parameters:
title (str): topic title.
body (str): Message of the initial post.
category (str): Can be: 0, 1, 2 (General, Tags, Bugs & Features
... | python | def forum_topic_create(self, title, body, category=None):
"""Function to create topic (Requires login) (UNTESTED).
Parameters:
title (str): topic title.
body (str): Message of the initial post.
category (str): Can be: 0, 1, 2 (General, Tags, Bugs & Features
... | Function to create topic (Requires login) (UNTESTED).
Parameters:
title (str): topic title.
body (str): Message of the initial post.
category (str): Can be: 0, 1, 2 (General, Tags, Bugs & Features
respectively). | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1218-L1232 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_topic_update | def forum_topic_update(self, topic_id, title=None, category=None):
"""Update a specific topic (Login Requires) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
title (str): Topic title.
category (str): Can be: 0, 1, 2 (General, Tags, Bugs & Fea... | python | def forum_topic_update(self, topic_id, title=None, category=None):
"""Update a specific topic (Login Requires) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
title (str): Topic title.
category (str): Can be: 0, 1, 2 (General, Tags, Bugs & Fea... | Update a specific topic (Login Requires) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
title (str): Topic title.
category (str): Can be: 0, 1, 2 (General, Tags, Bugs & Features
respectively). | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1234-L1248 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_topic_delete | def forum_topic_delete(self, topic_id):
"""Delete a topic (Login Requires) (Moderator+) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
"""
return self._get('forum_topics/{0}.json'.format(topic_id),
method='DELETE', auth=True) | python | def forum_topic_delete(self, topic_id):
"""Delete a topic (Login Requires) (Moderator+) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
"""
return self._get('forum_topics/{0}.json'.format(topic_id),
method='DELETE', auth=True) | Delete a topic (Login Requires) (Moderator+) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1250-L1257 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_topic_undelete | def forum_topic_undelete(self, topic_id):
"""Un delete a topic (Login requries) (Moderator+) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
"""
return self._get('forum_topics/{0}/undelete.json'.format(topic_id),
method='POST'... | python | def forum_topic_undelete(self, topic_id):
"""Un delete a topic (Login requries) (Moderator+) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id.
"""
return self._get('forum_topics/{0}/undelete.json'.format(topic_id),
method='POST'... | Un delete a topic (Login requries) (Moderator+) (UNTESTED).
Parameters:
topic_id (int): Where topic_id is the topic id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1259-L1266 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_post_list | def forum_post_list(self, creator_id=None, creator_name=None,
topic_id=None, topic_title_matches=None,
topic_category_id=None, body_matches=None):
"""Return a list of forum posts.
Parameters:
creator_id (int):
creator_name (str):
... | python | def forum_post_list(self, creator_id=None, creator_name=None,
topic_id=None, topic_title_matches=None,
topic_category_id=None, body_matches=None):
"""Return a list of forum posts.
Parameters:
creator_id (int):
creator_name (str):
... | Return a list of forum posts.
Parameters:
creator_id (int):
creator_name (str):
topic_id (int):
topic_title_matches (str):
topic_category_id (int): Can be: 0, 1, 2 (General, Tags, Bugs &
Features respectively).
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1268-L1290 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_post_create | def forum_post_create(self, topic_id, body):
"""Create a forum post (Requires login).
Parameters:
topic_id (int):
body (str): Post content.
"""
params = {'forum_post[topic_id]': topic_id, 'forum_post[body]': body}
return self._get('forum_posts.json', para... | python | def forum_post_create(self, topic_id, body):
"""Create a forum post (Requires login).
Parameters:
topic_id (int):
body (str): Post content.
"""
params = {'forum_post[topic_id]': topic_id, 'forum_post[body]': body}
return self._get('forum_posts.json', para... | Create a forum post (Requires login).
Parameters:
topic_id (int):
body (str): Post content. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1292-L1300 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_post_update | def forum_post_update(self, topic_id, body):
"""Update a specific forum post (Requries login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum topic id.
body (str): Post content.
"""
params = {'forum_post[body]': body}
return self._get('forum_posts... | python | def forum_post_update(self, topic_id, body):
"""Update a specific forum post (Requries login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum topic id.
body (str): Post content.
"""
params = {'forum_post[body]': body}
return self._get('forum_posts... | Update a specific forum post (Requries login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum topic id.
body (str): Post content. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1302-L1311 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_post_delete | def forum_post_delete(self, post_id):
"""Delete a specific forum post (Requires login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum post id.
"""
return self._get('forum_posts/{0}.json'.format(post_id),
method='DELETE', auth=True) | python | def forum_post_delete(self, post_id):
"""Delete a specific forum post (Requires login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum post id.
"""
return self._get('forum_posts/{0}.json'.format(post_id),
method='DELETE', auth=True) | Delete a specific forum post (Requires login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum post id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1313-L1320 |
LuqueDaniel/pybooru | pybooru/api_danbooru.py | DanbooruApi_Mixin.forum_post_undelete | def forum_post_undelete(self, post_id):
"""Undelete a specific forum post (Requires login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum post id.
"""
return self._get('forum_posts/{0}/undelete.json'.format(post_id),
method='POST', auth=True... | python | def forum_post_undelete(self, post_id):
"""Undelete a specific forum post (Requires login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum post id.
"""
return self._get('forum_posts/{0}/undelete.json'.format(post_id),
method='POST', auth=True... | Undelete a specific forum post (Requires login)(Moderator+)(UNTESTED).
Parameters:
post_id (int): Forum post id. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_danbooru.py#L1322-L1329 |
LuqueDaniel/pybooru | pybooru/pybooru.py | _Pybooru.site_name | def site_name(self, site_name):
"""Function that sets and checks the site name and set url.
Parameters:
site_name (str): The site name in 'SITE_LIST', default sites.
Raises:
PybooruError: When 'site_name' isn't valid.
"""
if site_name in SITE_LIST:
... | python | def site_name(self, site_name):
"""Function that sets and checks the site name and set url.
Parameters:
site_name (str): The site name in 'SITE_LIST', default sites.
Raises:
PybooruError: When 'site_name' isn't valid.
"""
if site_name in SITE_LIST:
... | Function that sets and checks the site name and set url.
Parameters:
site_name (str): The site name in 'SITE_LIST', default sites.
Raises:
PybooruError: When 'site_name' isn't valid. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/pybooru.py#L79-L93 |
LuqueDaniel/pybooru | pybooru/pybooru.py | _Pybooru.site_url | def site_url(self, url):
"""URL setter and validator for site_url property.
Parameters:
url (str): URL of on Moebooru/Danbooru based sites.
Raises:
PybooruError: When URL scheme or URL are invalid.
"""
# Regular expression to URL validate
regex =... | python | def site_url(self, url):
"""URL setter and validator for site_url property.
Parameters:
url (str): URL of on Moebooru/Danbooru based sites.
Raises:
PybooruError: When URL scheme or URL are invalid.
"""
# Regular expression to URL validate
regex =... | URL setter and validator for site_url property.
Parameters:
url (str): URL of on Moebooru/Danbooru based sites.
Raises:
PybooruError: When URL scheme or URL are invalid. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/pybooru.py#L106-L134 |
LuqueDaniel/pybooru | pybooru/pybooru.py | _Pybooru._request | def _request(self, url, api_call, request_args, method='GET'):
"""Function to request and returning JSON data.
Parameters:
url (str): Base url call.
api_call (str): API function to be called.
request_args (dict): All requests parameters.
method (str): (De... | python | def _request(self, url, api_call, request_args, method='GET'):
"""Function to request and returning JSON data.
Parameters:
url (str): Base url call.
api_call (str): API function to be called.
request_args (dict): All requests parameters.
method (str): (De... | Function to request and returning JSON data.
Parameters:
url (str): Base url call.
api_call (str): API function to be called.
request_args (dict): All requests parameters.
method (str): (Defauld: GET) HTTP method 'GET' or 'POST'
Raises:
Pyboo... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/pybooru.py#L149-L186 |
LuqueDaniel/pybooru | pybooru/danbooru.py | Danbooru._get | def _get(self, api_call, params=None, method='GET', auth=False,
file_=None):
"""Function to preapre API call.
Parameters:
api_call (str): API function to be called.
params (str): API function parameters.
method (str): (Defauld: GET) HTTP method (GET, POS... | python | def _get(self, api_call, params=None, method='GET', auth=False,
file_=None):
"""Function to preapre API call.
Parameters:
api_call (str): API function to be called.
params (str): API function parameters.
method (str): (Defauld: GET) HTTP method (GET, POS... | Function to preapre API call.
Parameters:
api_call (str): API function to be called.
params (str): API function parameters.
method (str): (Defauld: GET) HTTP method (GET, POST, PUT or
DELETE)
file_ (file): File to upload (only uploads).... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/danbooru.py#L55-L86 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.post_create | def post_create(self, tags, file_=None, rating=None, source=None,
rating_locked=None, note_locked=None, parent_id=None,
md5=None):
"""Function to create a new post (Requires login).
There are only two mandatory fields: you need to supply the
'tags', and y... | python | def post_create(self, tags, file_=None, rating=None, source=None,
rating_locked=None, note_locked=None, parent_id=None,
md5=None):
"""Function to create a new post (Requires login).
There are only two mandatory fields: you need to supply the
'tags', and y... | Function to create a new post (Requires login).
There are only two mandatory fields: you need to supply the
'tags', and you need to supply the 'file_', either through a
multipart form or through a source URL (Requires login) (UNTESTED).
Parameters:
tags (str): A space delim... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L38-L77 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.post_update | def post_update(self, post_id, tags=None, file_=None, rating=None,
source=None, is_rating_locked=None, is_note_locked=None,
parent_id=None):
"""Update a specific post.
Only the 'post_id' parameter is required. Leave the other parameters
blank if you don't... | python | def post_update(self, post_id, tags=None, file_=None, rating=None,
source=None, is_rating_locked=None, is_note_locked=None,
parent_id=None):
"""Update a specific post.
Only the 'post_id' parameter is required. Leave the other parameters
blank if you don't... | Update a specific post.
Only the 'post_id' parameter is required. Leave the other parameters
blank if you don't want to change them (Requires login).
Parameters:
post_id (int): The id number of the post to update.
tags (str): A space delimited list of tags. Specify prev... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L79-L113 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.post_revert_tags | def post_revert_tags(self, post_id, history_id):
"""Function to reverts a post to a previous set of tags
(Requires login) (UNTESTED).
Parameters:
post_id (int): The post id number to update.
history_id (int): The id number of the tag history.
"""
params =... | python | def post_revert_tags(self, post_id, history_id):
"""Function to reverts a post to a previous set of tags
(Requires login) (UNTESTED).
Parameters:
post_id (int): The post id number to update.
history_id (int): The id number of the tag history.
"""
params =... | Function to reverts a post to a previous set of tags
(Requires login) (UNTESTED).
Parameters:
post_id (int): The post id number to update.
history_id (int): The id number of the tag history. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L126-L135 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.post_vote | def post_vote(self, post_id, score):
"""Action lets you vote for a post (Requires login).
Parameters:
post_id (int): The post id.
score (int):
* 0: No voted or Remove vote.
* 1: Good.
* 2: Great.
* 3: Favorite, add ... | python | def post_vote(self, post_id, score):
"""Action lets you vote for a post (Requires login).
Parameters:
post_id (int): The post id.
score (int):
* 0: No voted or Remove vote.
* 1: Good.
* 2: Great.
* 3: Favorite, add ... | Action lets you vote for a post (Requires login).
Parameters:
post_id (int): The post id.
score (int):
* 0: No voted or Remove vote.
* 1: Good.
* 2: Great.
* 3: Favorite, add post to favorites.
Raises:
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L137-L155 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.tag_update | def tag_update(self, name=None, tag_type=None, is_ambiguous=None):
"""Action to lets you update tag (Requires login) (UNTESTED).
Parameters:
name (str): The name of the tag to update.
tag_type (int):
* General: 0.
* artist: 1.
* co... | python | def tag_update(self, name=None, tag_type=None, is_ambiguous=None):
"""Action to lets you update tag (Requires login) (UNTESTED).
Parameters:
name (str): The name of the tag to update.
tag_type (int):
* General: 0.
* artist: 1.
* co... | Action to lets you update tag (Requires login) (UNTESTED).
Parameters:
name (str): The name of the tag to update.
tag_type (int):
* General: 0.
* artist: 1.
* copyright: 3.
* character: 4.
is_ambiguous (int): Wh... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L172-L190 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.artist_create | def artist_create(self, name, urls=None, alias=None, group=None):
"""Function to create an artist (Requires login) (UNTESTED).
Parameters:
name (str): The artist's name.
urls (str): A list of URLs associated with the artist, whitespace
delimited.
... | python | def artist_create(self, name, urls=None, alias=None, group=None):
"""Function to create an artist (Requires login) (UNTESTED).
Parameters:
name (str): The artist's name.
urls (str): A list of URLs associated with the artist, whitespace
delimited.
... | Function to create an artist (Requires login) (UNTESTED).
Parameters:
name (str): The artist's name.
urls (str): A list of URLs associated with the artist, whitespace
delimited.
alias (str): The artist that this artist is an alias for. Simply
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L212-L230 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.artist_update | def artist_update(self, artist_id, name=None, urls=None, alias=None,
group=None):
"""Function to update artists (Requires Login) (UNTESTED).
Only the artist_id parameter is required. The other parameters are
optional.
Parameters:
artist_id (int): The i... | python | def artist_update(self, artist_id, name=None, urls=None, alias=None,
group=None):
"""Function to update artists (Requires Login) (UNTESTED).
Only the artist_id parameter is required. The other parameters are
optional.
Parameters:
artist_id (int): The i... | Function to update artists (Requires Login) (UNTESTED).
Only the artist_id parameter is required. The other parameters are
optional.
Parameters:
artist_id (int): The id of thr artist to update (Type: INT).
name (str): The artist's name.
urls (str): A list of... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L232-L256 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.comment_create | def comment_create(self, post_id, comment_body, anonymous=None):
"""Action to lets you create a comment (Requires login).
Parameters:
post_id (int): The post id number to which you are responding.
comment_body (str): The body of the comment.
anonymous (int): Set to 1... | python | def comment_create(self, post_id, comment_body, anonymous=None):
"""Action to lets you create a comment (Requires login).
Parameters:
post_id (int): The post id number to which you are responding.
comment_body (str): The body of the comment.
anonymous (int): Set to 1... | Action to lets you create a comment (Requires login).
Parameters:
post_id (int): The post id number to which you are responding.
comment_body (str): The body of the comment.
anonymous (int): Set to 1 if you want to post this comment
anonymously. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L274-L288 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.wiki_create | def wiki_create(self, title, body):
"""Action to lets you create a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page.
body (str): The body of the wiki page.
"""
params = {'wiki_page[title]': title, 'wiki_page[body]': body}... | python | def wiki_create(self, title, body):
"""Action to lets you create a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page.
body (str): The body of the wiki page.
"""
params = {'wiki_page[title]': title, 'wiki_page[body]': body}... | Action to lets you create a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page.
body (str): The body of the wiki page. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L309-L317 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.wiki_update | def wiki_update(self, title, new_title=None, page_body=None):
"""Action to lets you update a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page to update.
new_title (str): The new title of the wiki page.
page_body (str): The ne... | python | def wiki_update(self, title, new_title=None, page_body=None):
"""Action to lets you update a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page to update.
new_title (str): The new title of the wiki page.
page_body (str): The ne... | Action to lets you update a wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page to update.
new_title (str): The new title of the wiki page.
page_body (str): The new body of the wiki page. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L319-L332 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.wiki_revert | def wiki_revert(self, title, version):
"""Function to revert a specific wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page to update.
version (int): The version to revert to.
"""
params = {'title': title, 'version': version... | python | def wiki_revert(self, title, version):
"""Function to revert a specific wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page to update.
version (int): The version to revert to.
"""
params = {'title': title, 'version': version... | Function to revert a specific wiki page (Requires login) (UNTESTED).
Parameters:
title (str): The title of the wiki page to update.
version (int): The version to revert to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L370-L378 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.note_revert | def note_revert(self, note_id, version):
"""Function to revert a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): The note id to update.
version (int): The version to revert to.
"""
params = {'id': note_id, 'version': version}
return ... | python | def note_revert(self, note_id, version):
"""Function to revert a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): The note id to update.
version (int): The version to revert to.
"""
params = {'id': note_id, 'version': version}
return ... | Function to revert a specific note (Requires login) (UNTESTED).
Parameters:
note_id (int): The note id to update.
version (int): The version to revert to. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L415-L423 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.note_create_update | def note_create_update(self, post_id=None, coor_x=None, coor_y=None,
width=None, height=None, is_active=None, body=None,
note_id=None):
"""Function to create or update note (Requires login) (UNTESTED).
Parameters:
post_id (int): The post... | python | def note_create_update(self, post_id=None, coor_x=None, coor_y=None,
width=None, height=None, is_active=None, body=None,
note_id=None):
"""Function to create or update note (Requires login) (UNTESTED).
Parameters:
post_id (int): The post... | Function to create or update note (Requires login) (UNTESTED).
Parameters:
post_id (int): The post id number this note belongs to.
coor_x (int): The X coordinate of the note.
coor_y (int): The Y coordinate of the note.
width (int): The width of the note.
... | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L425-L452 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.pool_update | def pool_update(self, pool_id, name=None, is_public=None,
description=None):
"""Function to update a pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): The pool id number.
name (str): The name.
is_public (int): 1 or 0, whether or not the... | python | def pool_update(self, pool_id, name=None, is_public=None,
description=None):
"""Function to update a pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): The pool id number.
name (str): The name.
is_public (int): 1 or 0, whether or not the... | Function to update a pool (Requires login) (UNTESTED).
Parameters:
pool_id (int): The pool id number.
name (str): The name.
is_public (int): 1 or 0, whether or not the pool is public.
description (str): A description of the pool. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L498-L514 |
LuqueDaniel/pybooru | pybooru/api_moebooru.py | MoebooruApi_Mixin.pool_create | def pool_create(self, name, description, is_public):
"""Function to create a pool (Require login) (UNTESTED).
Parameters:
name (str): The name.
description (str): A description of the pool.
is_public (int): 1 or 0, whether or not the pool is public.
"""
... | python | def pool_create(self, name, description, is_public):
"""Function to create a pool (Require login) (UNTESTED).
Parameters:
name (str): The name.
description (str): A description of the pool.
is_public (int): 1 or 0, whether or not the pool is public.
"""
... | Function to create a pool (Require login) (UNTESTED).
Parameters:
name (str): The name.
description (str): A description of the pool.
is_public (int): 1 or 0, whether or not the pool is public. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/api_moebooru.py#L516-L526 |
LuqueDaniel/pybooru | pybooru/moebooru.py | Moebooru.site_name | def site_name(self, site_name):
"""Sets api_version and hash_string.
Parameters:
site_name (str): The site name in 'SITE_LIST', default sites.
Raises:
PybooruError: When 'site_name' isn't valid.
"""
# Set base class property site_name
_Pybooru.si... | python | def site_name(self, site_name):
"""Sets api_version and hash_string.
Parameters:
site_name (str): The site name in 'SITE_LIST', default sites.
Raises:
PybooruError: When 'site_name' isn't valid.
"""
# Set base class property site_name
_Pybooru.si... | Sets api_version and hash_string.
Parameters:
site_name (str): The site name in 'SITE_LIST', default sites.
Raises:
PybooruError: When 'site_name' isn't valid. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/moebooru.py#L74-L88 |
LuqueDaniel/pybooru | pybooru/moebooru.py | Moebooru._build_url | def _build_url(self, api_call):
"""Build request url.
Parameters:
api_call (str): Base API Call.
Returns:
Complete url (str).
"""
if self.api_version in ('1.13.0', '1.13.0+update.1', '1.13.0+update.2'):
if '/' not in api_call:
... | python | def _build_url(self, api_call):
"""Build request url.
Parameters:
api_call (str): Base API Call.
Returns:
Complete url (str).
"""
if self.api_version in ('1.13.0', '1.13.0+update.1', '1.13.0+update.2'):
if '/' not in api_call:
... | Build request url.
Parameters:
api_call (str): Base API Call.
Returns:
Complete url (str). | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/moebooru.py#L90-L102 |
LuqueDaniel/pybooru | pybooru/moebooru.py | Moebooru._build_hash_string | def _build_hash_string(self):
"""Function for build password hash string.
Raises:
PybooruError: When isn't provide hash string.
PybooruError: When aren't provide username or password.
PybooruError: When Pybooru can't add password to hash strring.
"""
... | python | def _build_hash_string(self):
"""Function for build password hash string.
Raises:
PybooruError: When isn't provide hash string.
PybooruError: When aren't provide username or password.
PybooruError: When Pybooru can't add password to hash strring.
"""
... | Function for build password hash string.
Raises:
PybooruError: When isn't provide hash string.
PybooruError: When aren't provide username or password.
PybooruError: When Pybooru can't add password to hash strring. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/moebooru.py#L104-L131 |
LuqueDaniel/pybooru | pybooru/moebooru.py | Moebooru._get | def _get(self, api_call, params, method='GET', file_=None):
"""Function to preapre API call.
Parameters:
api_call (str): API function to be called.
params (dict): API function parameters.
method (str): (Defauld: GET) HTTP method 'GET' or 'POST'
file_ (fil... | python | def _get(self, api_call, params, method='GET', file_=None):
"""Function to preapre API call.
Parameters:
api_call (str): API function to be called.
params (dict): API function parameters.
method (str): (Defauld: GET) HTTP method 'GET' or 'POST'
file_ (fil... | Function to preapre API call.
Parameters:
api_call (str): API function to be called.
params (dict): API function parameters.
method (str): (Defauld: GET) HTTP method 'GET' or 'POST'
file_ (file): File to upload. | https://github.com/LuqueDaniel/pybooru/blob/60cd5254684d293b308f0b11b8f4ac2dce101479/pybooru/moebooru.py#L133-L156 |
bjodah/pyodesys | pyodesys/symbolic.py | _is_autonomous | def _is_autonomous(indep, exprs):
""" Whether the expressions for the dependent variables are autonomous.
Note that the system may still behave as an autonomous system on the interface
of :meth:`integrate` due to use of pre-/post-processors.
"""
if indep is None:
return True
for expr in... | python | def _is_autonomous(indep, exprs):
""" Whether the expressions for the dependent variables are autonomous.
Note that the system may still behave as an autonomous system on the interface
of :meth:`integrate` due to use of pre-/post-processors.
"""
if indep is None:
return True
for expr in... | Whether the expressions for the dependent variables are autonomous.
Note that the system may still behave as an autonomous system on the interface
of :meth:`integrate` due to use of pre-/post-processors. | https://github.com/bjodah/pyodesys/blob/0034a6165b550d8d9808baef58678dca5a493ab7/pyodesys/symbolic.py#L81-L96 |
bjodah/pyodesys | pyodesys/symbolic.py | symmetricsys | def symmetricsys(dep_tr=None, indep_tr=None, SuperClass=TransformedSys, **kwargs):
""" A factory function for creating symmetrically transformed systems.
Creates a new subclass which applies the same transformation for each dependent variable.
Parameters
----------
dep_tr : pair of callables (defa... | python | def symmetricsys(dep_tr=None, indep_tr=None, SuperClass=TransformedSys, **kwargs):
""" A factory function for creating symmetrically transformed systems.
Creates a new subclass which applies the same transformation for each dependent variable.
Parameters
----------
dep_tr : pair of callables (defa... | A factory function for creating symmetrically transformed systems.
Creates a new subclass which applies the same transformation for each dependent variable.
Parameters
----------
dep_tr : pair of callables (default: None)
Forward and backward transformation callbacks to be applied to the
... | https://github.com/bjodah/pyodesys/blob/0034a6165b550d8d9808baef58678dca5a493ab7/pyodesys/symbolic.py#L961-L1027 |
bjodah/pyodesys | pyodesys/symbolic.py | get_logexp | def get_logexp(a=1, b=0, a2=None, b2=None, backend=None):
""" Utility function for use with :func:symmetricsys.
Creates a pair of callbacks for logarithmic transformation
(including scaling and shifting): ``u = ln(a*x + b)``.
Parameters
----------
a : number
Scaling (forward).
b : ... | python | def get_logexp(a=1, b=0, a2=None, b2=None, backend=None):
""" Utility function for use with :func:symmetricsys.
Creates a pair of callbacks for logarithmic transformation
(including scaling and shifting): ``u = ln(a*x + b)``.
Parameters
----------
a : number
Scaling (forward).
b : ... | Utility function for use with :func:symmetricsys.
Creates a pair of callbacks for logarithmic transformation
(including scaling and shifting): ``u = ln(a*x + b)``.
Parameters
----------
a : number
Scaling (forward).
b : number
Shift (forward).
a2 : number
Scaling (b... | https://github.com/bjodah/pyodesys/blob/0034a6165b550d8d9808baef58678dca5a493ab7/pyodesys/symbolic.py#L1361-L1390 |
bjodah/pyodesys | pyodesys/symbolic.py | SymbolicSys.from_callback | def from_callback(cls, rhs, ny=None, nparams=None, first_step_factory=None,
roots_cb=None, indep_name=None, **kwargs):
""" Create an instance from a callback.
Parameters
----------
rhs : callbable
Signature ``rhs(x, y[:], p[:], backend=math) -> f[:]``.
... | python | def from_callback(cls, rhs, ny=None, nparams=None, first_step_factory=None,
roots_cb=None, indep_name=None, **kwargs):
""" Create an instance from a callback.
Parameters
----------
rhs : callbable
Signature ``rhs(x, y[:], p[:], backend=math) -> f[:]``.
... | Create an instance from a callback.
Parameters
----------
rhs : callbable
Signature ``rhs(x, y[:], p[:], backend=math) -> f[:]``.
ny : int
Length of ``y`` in ``rhs``.
nparams : int
Length of ``p`` in ``rhs``.
first_step_factory : calla... | https://github.com/bjodah/pyodesys/blob/0034a6165b550d8d9808baef58678dca5a493ab7/pyodesys/symbolic.py#L385-L463 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.