Creates a new note.

Scopes

You will need authorization for the https://www.googleapis.com/auth/cloud-platform scope to make a valid call.

If unset, the scope for this method defaults to https://www.googleapis.com/auth/cloud-platform. You can set the scope for this method like this: containeranalysis1 --scope <scope> projects notes-create ...

Required Scalar Argument

  • <parent> (string)
    • Required. The name of the project in the form of projects/[PROJECT_ID], under which the note is to be created.

Required Request Value

The request value is a data-structure with various fields. Each field may be a simple scalar or another data-structure. In the latter case it is advised to set the field-cursor to the data-structure's field to specify values more concisely.

For example, a structure like this:

Note:
  attestation:
    hint:
      human-readable-name: string
  build:
    builder-version: string
  compliance:
    cis-benchmark:
      profile-level: integer
      severity: string
    description: string
    rationale: string
    remediation: string
    scan-instructions: string
    title: string
  create-time: string
  deployment:
    resource-uri: [string]
  discovery:
    analysis-kind: string
  dsse-attestation:
    hint:
      human-readable-name: string
  expiration-time: string
  image:
    fingerprint:
      v1-name: string
      v2-blob: [string]
      v2-name: string
    resource-url: string
  kind: string
  long-description: string
  name: string
  package:
    name: string
  related-note-names: [string]
  short-description: string
  update-time: string
  upgrade:
    package: string
    version:
      epoch: integer
      full-name: string
      inclusive: boolean
      kind: string
      name: string
      revision: string
    windows-update:
      description: string
      identity:
        revision: integer
        update-id: string
      kb-article-ids: [string]
      last-published-timestamp: string
      support-url: string
      title: string
  vulnerability:
    cvss-score: number
    cvss-v3:
      attack-complexity: string
      attack-vector: string
      availability-impact: string
      base-score: number
      confidentiality-impact: string
      exploitability-score: number
      impact-score: number
      integrity-impact: string
      privileges-required: string
      scope: string
      user-interaction: string
    severity: string
    source-update-time: string

can be set completely with the following arguments which are assumed to be executed in the given order. Note how the cursor position is adjusted to the respective structures, allowing simple field names to be used most of the time.

  • -r .attestation.hint human-readable-name=et

    • Required. The human readable name of this attestation authority, for example "qa".
  • ...build builder-version=magna

    • Required. Immutable. Version of the builder which produced this build.
  • ..compliance.cis-benchmark profile-level=90

    • No description provided.
  • severity=ipsum

    • No description provided.
  • .. description=voluptua.

    • A description about this compliance check.
  • rationale=at
    • A rationale for the existence of this compliance check.
  • remediation=sanctus
    • A description of remediation steps if the compliance check fails.
  • scan-instructions=sed
    • Serialized scan instructions with a predefined format.
  • title=amet.

    • The title that identifies this compliance check.
  • .. create-time=takimata

    • Output only. The time this note was created. This field can be used as a filter in list requests.
  • deployment resource-uri=amet.

    • Required. Resource URI for the artifact being deployed.
    • Each invocation of this argument appends the given value to the array.
  • ..discovery analysis-kind=duo

    • Required. Immutable. The kind of analysis that is handled by this discovery.
  • ..dsse-attestation.hint human-readable-name=ipsum

    • Required. The human readable name of this attestation authority, for example "cloudbuild-prod".
  • ... expiration-time=gubergren

    • Time of expiration for this note. Empty if note does not expire.
  • image.fingerprint v1-name=lorem
    • Required. The layer ID of the final layer in the Docker image's v1 representation.
  • v2-blob=gubergren
    • Required. The ordered list of v2 blobs that represent a given image.
    • Each invocation of this argument appends the given value to the array.
  • v2-name=eos

    • Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept.
  • .. resource-url=dolor

    • Required. Immutable. The resource_url for the resource representing the basis of associated occurrence images.
  • .. kind=ea

    • Output only. The type of analysis. This field can be used as a filter in list requests.
  • long-description=ipsum
    • A detailed description of this note.
  • name=invidunt
    • Output only. The name of the note in the form of projects/[PROVIDER_ID]/notes/[NOTE_ID].
  • package name=amet

    • Required. Immutable. The name of the package.
  • .. related-note-names=duo

    • Other notes related to this note.
    • Each invocation of this argument appends the given value to the array.
  • short-description=ipsum
    • A one sentence description of this note.
  • update-time=sed
    • Output only. The time this note was last updated. This field can be used as a filter in list requests.
  • upgrade package=ut
    • Required for non-Windows OS. The package this Upgrade is for.
  • version epoch=89
    • Used to correct mistakes in the version numbering scheme.
  • full-name=rebum.
    • Human readable version string. This string is of the form :- and is only set when kind is NORMAL.
  • inclusive=true
    • Whether this version is specifying part of an inclusive range. Grafeas does not have the capability to specify version ranges; instead we have fields that specify start version and end versions. At times this is insufficient - we also need to specify whether the version is included in the range or is excluded from the range. This boolean is expected to be set to true when the version is included in a range.
  • kind=ipsum
    • Required. Distinguishes between sentinel MIN/MAX versions and normal versions.
  • name=ipsum
    • Required only when version kind is NORMAL. The main part of the version name.
  • revision=est

    • The iteration of the package build from the above version.
  • ..windows-update description=gubergren

    • The localized description of the update.
  • identity revision=84
    • The revision number of the update.
  • update-id=dolor

    • The revision independent identifier of the update.
  • .. kb-article-ids=lorem

    • The Microsoft Knowledge Base article IDs that are associated with the update.
    • Each invocation of this argument appends the given value to the array.
  • last-published-timestamp=eos
    • The last published timestamp of the update.
  • support-url=labore
    • The hyperlink to the support information for the update.
  • title=sed

    • The localized title of the update.
  • ...vulnerability cvss-score=0.24638057468506236

    • The CVSS score of this vulnerability. CVSS score is on a scale of 0 - 10 where 0 indicates low severity and 10 indicates high severity.
  • cvss-v3 attack-complexity=sed
    • No description provided.
  • attack-vector=no
    • Base Metrics Represents the intrinsic characteristics of a vulnerability that are constant over time and across user environments.
  • availability-impact=stet
    • No description provided.
  • base-score=0.6905413711203235
    • The base score is a function of the base metric scores.
  • confidentiality-impact=et
    • No description provided.
  • exploitability-score=0.45715758654038996
    • No description provided.
  • impact-score=0.2648561880289837
    • No description provided.
  • integrity-impact=vero
    • No description provided.
  • privileges-required=erat
    • No description provided.
  • scope=sed
    • No description provided.
  • user-interaction=duo

    • No description provided.
  • .. severity=dolore

    • The note provider assigned severity of this vulnerability.
  • source-update-time=et
    • The time this information was last changed at the source. This is an upstream timestamp from the underlying information source - e.g. Ubuntu security tracker.

About Cursors

The cursor position is key to comfortably set complex nested structures. The following rules apply:

  • The cursor position is always set relative to the current one, unless the field name starts with the . character. Fields can be nested such as in -r f.s.o .
  • The cursor position is set relative to the top-level structure if it starts with ., e.g. -r .s.s
  • You can also set nested fields without setting the cursor explicitly. For example, to set a value relative to the current cursor position, you would specify -r struct.sub_struct=bar.
  • You can move the cursor one level up by using ... Each additional . moves it up one additional level. E.g. ... would go three levels up.

Optional Output Flags

The method's return value a JSON encoded structure, which will be written to standard output by default.

  • -o out
    • out specifies the destination to which to write the server's result to. It will be a JSON-encoded structure. The destination may be - to indicate standard output, or a filepath that is to contain the received bytes. If unset, it defaults to standard output.

Optional Method Properties

You may set the following properties to further configure the call. Please note that -p is followed by one or more key-value-pairs, and is called like this -p k1=v1 k2=v2 even though the listing below repeats the -p for completeness.

  • -p note-id=string
    • Required. The ID to use for this note.

Optional General Properties

The following properties can configure any call, and are not specific to this method.

  • -p $-xgafv=string

    • V1 error format.
  • -p access-token=string

    • OAuth access token.
  • -p alt=string

    • Data format for response.
  • -p callback=string

    • JSONP
  • -p fields=string

    • Selector specifying which fields to include in a partial response.
  • -p key=string

    • API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
  • -p oauth-token=string

    • OAuth 2.0 token for the current user.
  • -p pretty-print=boolean

    • Returns response with indentations and line breaks.
  • -p quota-user=string

    • Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
  • -p upload-type=string

    • Legacy upload protocol for media (e.g. "media", "multipart").
  • -p upload-protocol=string

    • Upload protocol for media (e.g. "raw", "multipart").