Skip to main content

notes

Creates, updates, deletes, gets or lists a notes resource.

Overview​

Namenotes
TypeResource
Idgoogle.containeranalysis.notes

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringOutput only. The name of the note in the form of projects/[PROVIDER_ID]/notes/[NOTE_ID].
aiSkillAnalysisobjectA note describing an AI skill analysis. (id: AISkillAnalysisNote)
attestationobjectA note describing an attestation role. (id: AttestationNote)
buildobjectA note describing build provenance for a verifiable build. (id: BuildNote)
complianceobjectA note describing a compliance check. (id: ComplianceNote)
createTimestring (google-datetime)Output only. The time this note was created. This field can be used as a filter in list requests.
deploymentobjectA note describing something that can be deployed. (id: DeploymentNote)
discoveryobjectA note describing the initial analysis of a resource. (id: DiscoveryNote)
dsseAttestationobjectA note describing a dsse attestation note. (id: DSSEAttestationNote)
expirationTimestring (google-datetime)Time of expiration for this note. Empty if note does not expire.
imageobjectA note describing a base image. (id: ImageNote)
kindstringOutput only. The type of analysis. This field can be used as a filter in list requests. (NOTE_KIND_UNSPECIFIED, VULNERABILITY, BUILD, IMAGE, PACKAGE, DEPLOYMENT, DISCOVERY, ATTESTATION, UPGRADE, COMPLIANCE, DSSE_ATTESTATION, VULNERABILITY_ASSESSMENT, SBOM_REFERENCE, SECRET, AI_SKILL_ANALYSIS)
longDescriptionstringA detailed description of this note.
packageobjectA note describing a package hosted by various package managers. (id: PackageNote)
relatedNoteNamesarrayOther notes related to this note.
relatedUrlarrayURLs associated with this note.
sbomReferenceobjectA note describing an SBOM reference. (id: SBOMReferenceNote)
secretobjectA note describing a secret. (id: SecretNote)
shortDescriptionstringA one sentence description of this note.
updateTimestring (google-datetime)Output only. The time this note was last updated. This field can be used as a filter in list requests.
upgradeobjectA note describing available package upgrades. (id: UpgradeNote)
vulnerabilityobjectA note describing a package vulnerability. (id: VulnerabilityNote)
vulnerabilityAssessmentobjectA note describing a vulnerability assessment. (id: VulnerabilityAssessmentNote)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
projects_locations_notes_getselectprojectsId, locationsId, notesIdGets the specified note.
projects_locations_notes_listselectprojectsId, locationsIdfilter, pageSize, pageToken, returnPartialSuccessLists notes for the specified project.
projects_notes_getselectprojectsId, notesIdGets the specified note.
projects_notes_listselectprojectsIdfilter, pageSize, pageToken, returnPartialSuccessLists notes for the specified project.
projects_locations_notes_batch_createinsertprojectsId, locationsIdCreates new notes in batch.
projects_locations_notes_createinsertprojectsId, locationsIdnoteIdCreates a new note.
projects_notes_batch_createinsertprojectsIdCreates new notes in batch.
projects_notes_createinsertprojectsIdnoteIdCreates a new note.
projects_locations_notes_patchupdateprojectsId, locationsId, notesIdupdateMaskUpdates the specified note.
projects_notes_patchupdateprojectsId, notesIdupdateMaskUpdates the specified note.
projects_locations_notes_deletedeleteprojectsId, locationsId, notesIdDeletes the specified note.
projects_notes_deletedeleteprojectsId, notesIdDeletes the specified note.

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
locationsIdstring
notesIdstring
projectsIdstring
filterstring
noteIdstring
pageSizeinteger (int32)
pageTokenstring
returnPartialSuccessboolean
updateMaskstring (google-fieldmask)

SELECT examples​

Gets the specified note.

SELECT
name,
aiSkillAnalysis,
attestation,
build,
compliance,
createTime,
deployment,
discovery,
dsseAttestation,
expirationTime,
image,
kind,
longDescription,
package,
relatedNoteNames,
relatedUrl,
sbomReference,
secret,
shortDescription,
updateTime,
upgrade,
vulnerability,
vulnerabilityAssessment
FROM google.containeranalysis.notes
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND notesId = '{{ notesId }}' -- required
;

INSERT examples​

Creates new notes in batch.

INSERT INTO google.containeranalysis.notes (
data__notes,
projectsId,
locationsId
)
SELECT
'{{ notes }}',
'{{ projectsId }}',
'{{ locationsId }}'
RETURNING
notes
;

UPDATE examples​

Updates the specified note.

UPDATE google.containeranalysis.notes
SET
data__aiSkillAnalysis = '{{ aiSkillAnalysis }}',
data__attestation = '{{ attestation }}',
data__build = '{{ build }}',
data__compliance = '{{ compliance }}',
data__createTime = '{{ createTime }}',
data__deployment = '{{ deployment }}',
data__discovery = '{{ discovery }}',
data__dsseAttestation = '{{ dsseAttestation }}',
data__expirationTime = '{{ expirationTime }}',
data__image = '{{ image }}',
data__kind = '{{ kind }}',
data__longDescription = '{{ longDescription }}',
data__name = '{{ name }}',
data__package = '{{ package }}',
data__relatedNoteNames = '{{ relatedNoteNames }}',
data__relatedUrl = '{{ relatedUrl }}',
data__sbomReference = '{{ sbomReference }}',
data__secret = '{{ secret }}',
data__shortDescription = '{{ shortDescription }}',
data__updateTime = '{{ updateTime }}',
data__upgrade = '{{ upgrade }}',
data__vulnerability = '{{ vulnerability }}',
data__vulnerabilityAssessment = '{{ vulnerabilityAssessment }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND notesId = '{{ notesId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
aiSkillAnalysis,
attestation,
build,
compliance,
createTime,
deployment,
discovery,
dsseAttestation,
expirationTime,
image,
kind,
longDescription,
package,
relatedNoteNames,
relatedUrl,
sbomReference,
secret,
shortDescription,
updateTime,
upgrade,
vulnerability,
vulnerabilityAssessment;

DELETE examples​

Deletes the specified note.

DELETE FROM google.containeranalysis.notes
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND notesId = '{{ notesId }}' --required
;