- The library is now compatible with marshmallow 4 (
marshmallow>=3.18, <5). On Python 3.9+ marshmallow 4 is used; Python 3.8 keeps marshmallow 3. As a result,to_dict()andfrom_dict()now return a plaindictinstead of anOrderedDict(insertion order is still preserved).marshmallow-dataclassis bumped to>=8.7, <8.8.
- Python 3.8 support is deprecated and will be removed in a future release. Importing the library on Python 3.8 now emits a
DeprecationWarning. Upgrade to Python 3.9+.
-
New endpoint
log_mcp_activities_bulk(): send a batch of historicalMCPActivityRequestto GitGuardian and receive ingested/duplicate counts. AddsMCPActivityBulkResponsemodel. -
Optional
timestampfield onMCPActivityRequest, used by the bulk endpoint to record historical events. Live (single-event)log_mcp_activitycallers are unaffected; the new field defaults toNone. -
New
endpoints:sendtoken scope.
-
scan_and_create_incidents: documents now accept an optionallocationfield containing an http/https URL identifying the origin of the document. -
New endpoints
send_ai_discovery()andlog_mcp_activity, with associated models. -
New
honeytokens:checktoken scope for prefix-based honeytoken lookup.
- Capture secret incident
custom_tagsdictionaries when callingretrieve_secret_incident.
- MembersParameters, TeamInvitationParameters, and TeamMembershipParameters now properly apply pagination and search queries.
- Changed the following fields to
str:visibility,kind,presence status,ignore_reason,tag.
- Missing scope leading to validation errors
- Updated
Client.scan_and_create_incidents()to match server-side API changes.
-
Added
GGClient.scan_and_create_incidents()function to scan content for secrets and automatically create incidents. -
Added
vault_type,vault_name,vault_pathandvault_path_countfields toPolicyBreak.
- Set PolicyBreak's detector_name and detector_group_name fields as optional to fix backwards compatibility with the GitGuardian API
- Added
is_vaultedfield toPolicyBreak.
- Added extra information to scan results: detector name, detector group name, and documentation URL.
- Added missing scopes to the
TokenScopeenum.
- Removed support for the deprecated SCA and IaC endpoints.
- Added support for members and teams endpoints.
- Added support for invitations endpoints.
- Added support for sources endpoints.
-
Added the
is_diffattribute toScanResult. -
Added the following attributes to
PolicyBreak:diff_kind,is_excludedandexclude_reason. -
GGClientnow provides aapi_tokens()method to retrieve API token details (see https://api.gitguardian.com/docs#tag/API-Tokens).
GGClient.content_scan()andGGClient.multi_content_scan()now accept anall_secretsparameter.
- Add missing value
infoto Severity model (#120).
GGClientnow provides aretrieve_secret_incident()method to retrieve the dashboard incident associated with a secret (see https://api.gitguardian.com/docs#tag/Secret-Incidents/operation/retrieve-incidents).
GGClientnow contains remediation messages obtained from the API/metadataendpoint.
- The project now uses pdm instead of pipenv.
GGClientno longer crashes when it receives a server response with no Content-Type header.
Yanked: release process issue.
Yanked: release process issue.
-
Add
GGClient.create_honeytoken_with_context()method. -
Export scan schemas in addition to dataclasses for sca.
- Added maximum payload size as a property of GGClient.
- Set minimum Python version to >=3.8.
-
GGClientnow obeys rate-limits and can notify callers when hitting one. -
Added the following attributes to
IaCVulnerability:url,status,ignored_until,ignore_reason,ignore_comment. -
Added the
source_foundattribute toIaCScanParametersandIaCDiffScanEntities.
- Added
extra_headersto SCA diff scans.
- Remove
potential_siblingsfrom models.
- Added the
GGClient.iac_diff_scan()method. This allows scanning two directories for IaC vulnerabilities and categorizing incidents as new, unchanged or deleted.
- Fixed a bug where py-gitguardian would sometimes increase the length of a document when preparing it to be sent to the secret scan API.
-
Added
GGClient.create_jwt()method. This is only used to interact with HasMySecretLeaked for now. -
py-gitguardian is now fully type-hinted (#49).
- All HTTP requests are now logged using Python logger. The log message includes the HTTP method, endpoint, status code and duration.
GGClient.iac_directory_scan()was not correctly sending the files to scan.
-
Added
GGClient.create_honeytoken()method. -
Added
GGClient.read_metadata()to read metadata from the server. The metadata is then used by further secret scan calls and is available in a newGGClient.secret_scan_preferencesattribute.
- The
PolicyBreakclass now includes the URL of the policy break if the dashboard already knows about it.
- Python dependencies were not correctly defined: py-gitguardian was using
marshmallow-dataclassandclickwithout depending on them. The package now explicitly depends onmarshmallow-dataclassand does not useclickanymore (#43).
Clientcan now run IaC scans (GitGuardian/ggshield#405).