REST Resource: projects.locations.repositories.files

Stay organized with collections Save and categorize content based on your preferences.

Resource: File

Files store content that is potentially associated with Packages or Versions.

JSON representation
{
  "name": string,
  "sizeBytes": string,
  "hashes": [
    {
      object (Hash)
    }
  ],
  "createTime": string,
  "updateTime": string,
  "owner": string
}
Fields
name

string

The name of the file, for example: "projects/p1/locations/us-central1/repositories/repo1/files/a%2Fb%2Fc.txt". If the file ID part contains slashes, they are escaped.

sizeBytes

string (int64 format)

The size of the File in bytes.

hashes[]

object (Hash)

The hashes of the file content.

createTime

string (Timestamp format)

Output only. The time when the File was created.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

updateTime

string (Timestamp format)

Output only. The time when the File was last updated.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

owner

string

The name of the Package or Version that owns this file, if any.

Hash

A hash of file content.

JSON representation
{
  "type": enum (HashType),
  "value": string
}
Fields
type

enum (HashType)

The algorithm used to compute the hash value.

value

string (bytes format)

The hash value.

A base64-encoded string.

HashType

The algorithm used to compute the hash.

Enums
HASH_TYPE_UNSPECIFIED Unspecified.
SHA256 SHA256 hash.
MD5 MD5 hash.

Methods

get

Gets a file.

list

Lists files.