NAME

Google::Ai::Generativelanguage::V1alpha::File - Compiled Protocol Buffers messages for google/ai/generativelanguage/v1alpha/file.proto

SYNOPSIS

use Google::Ai::Generativelanguage::V1alpha::File;

my $msg = Google::Ai::Generativelanguage::V1alpha::File::File->new({
    video_metadata => $video_metadata,
    name => $name,
    display_name => $display_name,
    mime_type => $mime_type,
});

# Read or update a field
my $val = $msg->video_metadata();

# Binary wire-format roundtrip
my $bytes   = $msg->serialize();
my $decoded = Google::Ai::Generativelanguage::V1alpha::File::File->parse($bytes);

# Canonical ProtoJSON
my $json = $msg->to_json();

DESCRIPTION

Auto-generated Protobuf message classes compiled from google/ai/generativelanguage/v1alpha/file.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().

MESSAGES

Google::Ai::Generativelanguage::V1alpha::File::File

A file uploaded to the API. Next ID: 15

Inherits from Protobuf::Message.

Accessors

  • $msg->video_metadata() / $msg->video_metadata($value)

    Type: Message (Google::Ai::Generativelanguage::V1alpha::File::VideoMetadata)

    Output only. Metadata for a video.

  • $msg->name() / $msg->name($value)

    Type: String

    Immutable. Identifier. The `File` resource name. The ID (name excluding the "files/" prefix) can contain up to 40 characters that are lowercase alphanumeric or dashes (-). The ID cannot start or end with a dash. If the name is empty on create, a unique name will be generated. Example: `files/123-456`

  • $msg->display_name() / $msg->display_name($value)

    Type: String

    Optional. The human-readable display name for the `File`. The display name must be no more than 512 characters in length, including spaces. Example: "Welcome Image"

  • $msg->mime_type() / $msg->mime_type($value)

    Type: String

    Output only. MIME type of the file.

  • $msg->size_bytes() / $msg->size_bytes($value)

    Type: Int64

    Output only. Size of the file in bytes.

  • $msg->create_time() / $msg->create_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. The timestamp of when the `File` was created.

  • $msg->update_time() / $msg->update_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. The timestamp of when the `File` was last updated.

  • $msg->expiration_time() / $msg->expiration_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. The timestamp of when the `File` will be deleted. Only set if the `File` is scheduled to expire.

  • $msg->sha256_hash() / $msg->sha256_hash($value)

    Type: Bytes

    Output only. SHA-256 hash of the uploaded bytes.

  • $msg->uri() / $msg->uri($value)

    Type: String

    Output only. The uri of the `File`.

  • $msg->state() / $msg->state($value)

    Type: Enum (Google::Ai::Generativelanguage::V1alpha::File::State)

    Output only. Processing state of the File.

  • $msg->error() / $msg->error($value)

    Type: Message (Google::Rpc::Status::Status)

    Output only. Error status if File processing failed.

Enum: File::State

  • STATE_UNSPECIFIED => 0

  • PROCESSING => 1

  • ACTIVE => 2

  • FAILED => 10

Google::Ai::Generativelanguage::V1alpha::File::VideoMetadata

Metadata for a video `File`.

Inherits from Protobuf::Message.

Accessors

SEE ALSO

Protobuf, Protobuf::Message, Google::Ai::Generativelanguage::V1alpha::File::Types, https://protobuf.dev/

LICENSE AND COPYRIGHT

Copyright (C) 2026 Google LLC

This program is released under the Apache 2.0 license.