Simple Python client for SonarQube Web API
Project description
simple-sonarqube-api
Sonarqube api python module
Usage
Build module
python -m venv .venv
Linux/macOS
source .venv/bin/activate
Windows (PowerShell)
# .\.venv\Scripts\Activate.ps1
build
python -m pip install -U pip
pip install -e .
Example
Install module
$ pip install simple-sonarqube-api
Code example
from simple_sonarqube_api.client import SonarQubeClient
client = SonarQubeClient(
base_url="https://sonar.midominio",
token="squ_xxxxxxxxx"
)
assert client.is_authenticated()
issues = list(client.iter_issues(types="VULNERABILITY", resolved=False))
evidence = client.get_issue_code_evidence(issues[0]["key"], context_lines=3)
print(evidence["snippet"])
Check bandit
$ bandit -r src/simple_sonarqube_api
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file simple_sonarqube_api-0.1.5.tar.gz.
File metadata
- Download URL: simple_sonarqube_api-0.1.5.tar.gz
- Upload date:
- Size: 23.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45109182ccc8c1fa43418aa227511f79178d2733ab92ec85a37bea1736801a22
|
|
| MD5 |
763241eba1a589dc71514e4ce5c2c6b7
|
|
| BLAKE2b-256 |
8b9b7470ab5c584a51c9d91ffa3c9e66780a8848b73ea9521365fbfd6464c59e
|
Provenance
The following attestation bundles were made for simple_sonarqube_api-0.1.5.tar.gz:
Publisher:
publish.yml on Mikehenrytech/simple-sonarqube-api
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
simple_sonarqube_api-0.1.5.tar.gz -
Subject digest:
45109182ccc8c1fa43418aa227511f79178d2733ab92ec85a37bea1736801a22 - Sigstore transparency entry: 828802108
- Sigstore integration time:
-
Permalink:
Mikehenrytech/simple-sonarqube-api@7e2e30aa06da593508d0d3d1a6d368171bb8a60d -
Branch / Tag:
refs/tags/v0.1.5 - Owner: https://github.com/Mikehenrytech
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@7e2e30aa06da593508d0d3d1a6d368171bb8a60d -
Trigger Event:
push
-
Statement type:
File details
Details for the file simple_sonarqube_api-0.1.5-py3-none-any.whl.
File metadata
- Download URL: simple_sonarqube_api-0.1.5-py3-none-any.whl
- Upload date:
- Size: 24.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eeb60f2e46c6d7b0a0c3ff9a297da62522d3a694276b4a34639b0ed008a5e52f
|
|
| MD5 |
61eb4489601cc0c96d4dfe961a9ae6b7
|
|
| BLAKE2b-256 |
f16229eac0567e0940a241f8ec92c81cba9346cc3bacfb4cd886f7ea11edf04c
|
Provenance
The following attestation bundles were made for simple_sonarqube_api-0.1.5-py3-none-any.whl:
Publisher:
publish.yml on Mikehenrytech/simple-sonarqube-api
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
simple_sonarqube_api-0.1.5-py3-none-any.whl -
Subject digest:
eeb60f2e46c6d7b0a0c3ff9a297da62522d3a694276b4a34639b0ed008a5e52f - Sigstore transparency entry: 828802122
- Sigstore integration time:
-
Permalink:
Mikehenrytech/simple-sonarqube-api@7e2e30aa06da593508d0d3d1a6d368171bb8a60d -
Branch / Tag:
refs/tags/v0.1.5 - Owner: https://github.com/Mikehenrytech
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@7e2e30aa06da593508d0d3d1a6d368171bb8a60d -
Trigger Event:
push
-
Statement type: