Skip to content

Feature request: Support docstring #33

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2xyo opened this issue Mar 17, 2020 · 0 comments
Open

Feature request: Support docstring #33

2xyo opened this issue Mar 17, 2020 · 0 comments

Comments

@2xyo
Copy link

2xyo commented Mar 17, 2020

It would be great to be able to add comments for methods and class and have the ability to get the documentation from __doc__ method attribut. Something like this:

class UserResource(Resource):
    """
    My doc... 
    """
    actions = {
        "search": {"method": "GET", "url": "users/search","doc":"Search users"},
        "retrieve": {"method": "GET", "url": "users/{}", "doc": "Search a user X. X should be a username"},
    }

instagram_api.add_resource(resource_name="users", resource_class=UserResource)

help(instagram_api.users)
help(instagram_api.users.search)
help(instagram_api.users.retrieve)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant