Google

Container Analysis API

This API is a prerequisite for leveraging Artifact Analysis scanning capabilities in Artifact Registry. In addition, the Container Analysis API is an…

Developer tools#openapi#analytics#media

Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.

Overview

This API is a prerequisite for leveraging Artifact Analysis scanning capabilities in Artifact Registry. In addition, the Container Analysis API is an implementation of the Grafeas API, which enables storing, querying, and retrieval of critical metadata about all of your software artifacts.

Endpoints 16

projects.notes

  • POSTCreates new notes in batch./v1/:parent/notes:batchCreateCreates new notes in batch.
  • GETLists notes for the specified project./v1/:parent/notes?filter=string&pageSize=0&pageToken=string&returnPartialSuccess=trueLists notes for the specified project.
  • POSTCreates a new note./v1/:parent/notes?noteId=stringCreates a new note.

projects.occurrences

  • GETGets the specified occurrence./v1/:nameGets the specified occurrence.
  • DELETEDeletes the specified occurrence/v1/:nameDeletes the specified occurrence. For example, use this method to delete an occurrence when the occurrence is no longer applicable for the given resource.
  • PATCHUpdates the specified occurrence./v1/:name?updateMask=stringUpdates the specified occurrence.
  • POSTGets the access control policy for a note or an occurrence resource/v1/:resource:getIamPolicyGets the access control policy for a note or an occurrence resource. Requires containeranalysis.notes.setIamPolicy or…
  • POSTSets the access control policy on the specified note or occurrence/v1/:resource:setIamPolicySets the access control policy on the specified note or occurrence. Requires containeranalysis.notes.setIamPolicy or…
  • POSTReturns the permissions that a caller has on the specified note or occurrence/v1/:resource:testIamPermissionsReturns the permissions that a caller has on the specified note or occurrence. Requires list permission on the project (for example,…
  • POSTCreates new occurrences in batch./v1/:parent/occurrences:batchCreateCreates new occurrences in batch.
  • GETLists occurrences for the specified project./v1/:parent/occurrences?filter=string&pageSize=0&pageToken=string&returnPartialSuccess=trueLists occurrences for the specified project.
  • POSTCreates a new occurrence./v1/:parent/occurrencesCreates a new occurrence.
  • GETGets the note attached to the specified occurrence/v1/:name/notesGets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.
  • GETGets a summary of the number and severity of occurrences./v1/:parent/occurrences:vulnerabilitySummary?filter=string&returnPartialSuccess=trueGets a summary of the number and severity of occurrences.

projects.notes.occurrences

  • GETLists occurrences referencing the specified note/v1/:name/occurrences?filter=string&pageSize=0&pageToken=stringLists occurrences referencing the specified note. Provider projects can use this method to get all occurrences across consumer projects referencing the…

projects.resources

  • POSTGenerates an SBOM for the given resource./v1/:name:exportSBOMGenerates an SBOM for the given resource.

API details

Base URL
https://containeranalysis.googleapis.com
Authentication
OAuth 2.0 (authorization code flow) with 1 scope
An API key in the key query parameter
Operations
16 operations on 12 pathsPOST 8GET 6PATCH 1DELETE 1
Main resources
projects.occurrences 11projects.notes 3projects.notes.occurrences 1projects.resources 1
Response formats
application/json
Description format
Google API Discovery, API version v1

How to test the Container Analysis API in Swastik Codes

  1. Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
  2. Fork it into your workspaceChoose a workspace. You get your own copy of the Container Analysis API collection, without the publisher's secrets.
  3. Add your credentialsThis API uses OAuth 2.0 (authorization code flow) with 1 scope. Add yours in the collection's variables or an environment; the requests already reference it.
  4. Send a requestPick an endpoint, for example “Creates new notes in batch.” (POST /v1/:parent/notes:batchCreate), and press Send. Check the response, add tests and run the whole collection with the runner.

Frequently asked questions

What is the Container Analysis API?

This API is a prerequisite for leveraging Artifact Analysis scanning capabilities in Artifact Registry. In addition, the Container Analysis API is an… It is listed under Developer tools and has 16 endpoints.

Who publishes the Container Analysis API?

It is listed from Google's public API description (an OpenAPI document), not published by Google on Swastik Codes. Anyone who controls googleapis.com can claim the profile by adding a DNS TXT record.

What is the base URL of the Container Analysis API?

Requests go to https://containeranalysis.googleapis.com. Endpoint paths are added to this base URL.

How do I authenticate with the Container Analysis API?

It accepts 2 methods: OAuth 2.0 (authorization code flow) with 1 scope; an API key in the key query parameter.

How many endpoints does the Container Analysis API have?

16 operations on 12 paths (8 POST, 6 GET, 1 PATCH, 1 DELETE). The largest groups are projects.occurrences, projects.notes, projects.notes.occurrences, projects.resources.

Is forking the Container Analysis API free?

Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.

Suggest an API

Tell us which public API is missing. We check it, then add it here with its endpoints when it has an OpenAPI (Swagger) description.