As the python-gitlab landing page you linked to states:
python-gitlab
enables you to [...] pass arbitrary parameters to the GitLab API. Simply follow GitLab’s docs on what parameters are available.
So you can just pass the GitLab APIs to the list call. Example:
import os
import gitlab
gl = gitlab.Gitlab(private_token=os.getenv("GITLAB_TOKEN"))
# Instance level
mrs = gl.mergerequests.list(
author_username=AUTHOR_USERNAME,
source_branch=SOURCE_BRANCH,
)
# Project level
project = gl.projects.get("your-group/your-project", lazy=True)
project_mrs = project.mergerequests.list(
author_username=AUTHOR_USERNAME,
source_branch=SOURCE_BRANCH,
)