API Reference#
- class cirun.Cirun(token=None)[source]#
Cirun Client to interact to cirun’s API
- add_repo_to_resources(org, repo, resources, teams=None, roles=None, users=None, users_from_json=None, policy_args=None)[source]#
Grants access to the resource for the repository
Parameters#
- org: str
GitHub Organization
- repo: str
GitHub Repository
- resources: List[str]
List of resources
- teams: List[str]
List of teams
- roles: List[str]
List of roles
- users: List[str]
List of users
- users_from_json: List[str]
List of users from a json url
- policy_args: Optional[Dict[str, Any]]
Policy arguments, this is a dictionary of key values, currently the only supported argument is
{"pull_request": True}
or{"pull_request": False}
Returns#
requests.Response
- cloud_connect(name, credentials, print_error=False)[source]#
Connect a cloud provider to cirun.
Parameters#
- name: str
Name of cloud provider
- credentials: str
Cloud Credentials
Returns#
- dict:
Response json