Skip to content

Shared

ModelsExpand Collapse
type Action struct{…}
ID int64optional

A unique numeric ID that can be used to identify and reference an action.

CompletedAt Timeoptional

A time value given in ISO8601 combined date and time format that represents when the action was completed.

formatdate-time
Region Regionoptional
Available bool

This is a boolean value that represents whether new Droplets can be created in this region.

Features []string

This attribute is set to an array which contains features available in this region

Name string

The display name of the region. This will be a full name that is used in the control panel and other interfaces.

Sizes []string

This attribute is set to an array which contains the identifying slugs for the sizes available in this region. sizes:read is required to view.

Slug string

A human-readable string that is used as a unique identifier for each region.

RegionSlug stringoptional

A human-readable string that is used as a unique identifier for each region.

ResourceID int64optional

A unique identifier for the resource that the action is associated with.

ResourceType stringoptional

The type of resource that the action is associated with.

StartedAt Timeoptional

A time value given in ISO8601 combined date and time format that represents when the action was initiated.

formatdate-time
Status ActionStatusoptional

The current status of the action. This can be "in-progress", "completed", or "errored".

Accepts one of the following:
const ActionStatusInProgress ActionStatus = "in-progress"
const ActionStatusCompleted ActionStatus = "completed"
const ActionStatusErrored ActionStatus = "errored"
Type stringoptional

This is the type of action that the object represents. For example, this could be "transfer" to represent the state of an image transfer action.

type APIMeta struct{…}

Meta information about the data set

Page int64optional

The current page

formatint64
Pages int64optional

Total number of pages

formatint64
Total int64optional

Total amount of items over all pages

formatint64
type ChatCompletionChunk struct{…}

Represents a streamed chunk of a chat completion response returned by the model, based on the provided input.

ID string

A unique identifier for the chat completion. Each chunk has the same ID.

Choices []ChatCompletionChunkChoice

A list of chat completion choices. Can contain more than one elements if n is greater than 1. Can also be empty for the last chunk if you set stream_options: {"include_usage": true}.

Delta ChatCompletionChunkChoicesDelta

A chat completion delta generated by streamed model responses.

Content stringoptional

The contents of the chunk message.

ReasoningContent stringoptional

The reasoning content generated by the model.

Refusal stringoptional

The refusal message generated by the model.

Role ChatCompletionChunkChoicesDeltaRoleoptional

The role of the author of this message.

Accepts one of the following:
const ChatCompletionChunkChoicesDeltaRoleDeveloper ChatCompletionChunkChoicesDeltaRole = "developer"
const ChatCompletionChunkChoicesDeltaRoleUser ChatCompletionChunkChoicesDeltaRole = "user"
const ChatCompletionChunkChoicesDeltaRoleAssistant ChatCompletionChunkChoicesDeltaRole = "assistant"
ToolCalls []ChatCompletionChunkChoicesDeltaToolCalloptional
Index int64
ID stringoptional

The ID of the tool call.

Function ChatCompletionChunkChoicesDeltaToolCallsFunctionoptional

A chunk of a function that the model called.

Arguments stringoptional

The arguments to call the function with, as generated by the model in JSON format. Note that the model does not always generate valid JSON, and may hallucinate parameters not defined by your function schema. Validate the arguments in your code before calling your function.

Name stringoptional

The name of the function to call.

Type ChatCompletionChunkChoicesDeltaToolCallsTypeoptional

The type of the tool. Currently, only function is supported.

Accepts one of the following:
const ChatCompletionChunkChoicesDeltaToolCallsTypeFunction ChatCompletionChunkChoicesDeltaToolCallsType = "function"
FinishReason ChatCompletionChunkChoicesFinishReason

The reason the model stopped generating tokens. This will be stop if the model hit a natural stop point or a provided stop sequence, or length if the maximum number of tokens specified in the request was reached, tool_calls if the model called a tool.

Accepts one of the following:
const ChatCompletionChunkChoicesFinishReasonStop ChatCompletionChunkChoicesFinishReason = "stop"
const ChatCompletionChunkChoicesFinishReasonLength ChatCompletionChunkChoicesFinishReason = "length"
const ChatCompletionChunkChoicesFinishReasonToolCalls ChatCompletionChunkChoicesFinishReason = "tool_calls"
const ChatCompletionChunkChoicesFinishReasonContentFilter ChatCompletionChunkChoicesFinishReason = "content_filter"
Index int64

The index of the choice in the list of choices.

Logprobs ChatCompletionChunkChoicesLogprobsoptional

Log probability information for the choice.

A list of message content tokens with log probability information.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

TopLogprobs []ChatCompletionTokenLogprobTopLogprob

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

A list of message refusal tokens with log probability information.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

TopLogprobs []ChatCompletionTokenLogprobTopLogprob

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

Created int64

The Unix timestamp (in seconds) of when the chat completion was created. Each chunk has the same timestamp.

Model string

The model to generate the completion.

Object ChatCompletionChunkObject

The object type, which is always chat.completion.chunk.

Accepts one of the following:
const ChatCompletionChunkObjectChatCompletionChunk ChatCompletionChunkObject = "chat.completion.chunk"
Usage CompletionUsageoptional

An optional field that will only be present when you set stream_options: {"include_usage": true} in your request. When present, it contains a null value except for the last chunk which contains the token usage statistics for the entire request.

NOTE: If the stream is interrupted or cancelled, you may not receive the final usage chunk which contains the total token usage for the request.

CacheCreatedInputTokens int64

Number of prompt tokens written to cache.

CacheCreation CompletionUsageCacheCreation

Breakdown of prompt tokens written to cache.

Ephemeral1hInputTokens int64

Number of prompt tokens written to 1h cache.

Ephemeral5mInputTokens int64

Number of prompt tokens written to 5m cache.

CacheReadInputTokens int64

Number of prompt tokens read from cache.

CompletionTokens int64

Number of tokens in the generated completion.

PromptTokens int64

Number of tokens in the prompt.

TotalTokens int64

Total number of tokens used in the request (prompt + completion).

type ChatCompletionTokenLogprob struct{…}
Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

TopLogprobs []ChatCompletionTokenLogprobTopLogprob

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

type CompletionUsage struct{…}

Usage statistics for the completion request.

CacheCreatedInputTokens int64

Number of prompt tokens written to cache.

CacheCreation CompletionUsageCacheCreation

Breakdown of prompt tokens written to cache.

Ephemeral1hInputTokens int64

Number of prompt tokens written to 1h cache.

Ephemeral5mInputTokens int64

Number of prompt tokens written to 5m cache.

CacheReadInputTokens int64

Number of prompt tokens read from cache.

CompletionTokens int64

Number of tokens in the generated completion.

PromptTokens int64

Number of tokens in the prompt.

TotalTokens int64

Total number of tokens used in the request (prompt + completion).

type CreateResponseResponse struct{…}

Represents a text-to-text response returned by the model, based on the provided input. VLLM models only.

ID string

A unique identifier for the response.

Created int64

The Unix timestamp (in seconds) of when the response was created.

Model string

The model used to generate the response.

Object CreateResponseResponseObject

The object type, which is always response.

Accepts one of the following:
const CreateResponseResponseObjectResponse CreateResponseResponseObject = "response"
Usage CreateResponseResponseUsage

Detailed token usage statistics for the request, including input/output token counts and detailed breakdowns.

InputTokens int64

The number of input tokens.

InputTokensDetails CreateResponseResponseUsageInputTokensDetails

A detailed breakdown of the input tokens.

CachedTokens int64

The number of tokens that were retrieved from the cache. More on prompt caching.

OutputTokens int64

The number of output tokens.

OutputTokensDetails CreateResponseResponseUsageOutputTokensDetails

A detailed breakdown of the output tokens.

ReasoningTokens int64

The number of reasoning tokens.

ToolOutputTokens int64

The number of tool output tokens.

TotalTokens int64

The total number of tokens used.

Background booloptional

Whether the request was processed in the background

Choices []CreateResponseResponseChoiceoptional

A list of response choices. Can be more than one if n is greater than 1. Optional - Responses API primarily uses the output array.

FinishReason CreateResponseResponseChoicesFinishReason

The reason the model stopped generating tokens. This will be stop if the model hit a natural stop point or a provided stop sequence, length if the maximum number of tokens specified in the request was reached, or tool_calls if the model called a tool.

Accepts one of the following:
const CreateResponseResponseChoicesFinishReasonStop CreateResponseResponseChoicesFinishReason = "stop"
const CreateResponseResponseChoicesFinishReasonLength CreateResponseResponseChoicesFinishReason = "length"
const CreateResponseResponseChoicesFinishReasonToolCalls CreateResponseResponseChoicesFinishReason = "tool_calls"
const CreateResponseResponseChoicesFinishReasonContentFilter CreateResponseResponseChoicesFinishReason = "content_filter"
Index int64

The index of the choice in the list of choices.

Message CreateResponseResponseChoicesMessage

The generated message response.

Content stringoptional

The generated text content.

Role CreateResponseResponseChoicesMessageRoleoptional

The role of the message author, which is always assistant.

Accepts one of the following:
const CreateResponseResponseChoicesMessageRoleAssistant CreateResponseResponseChoicesMessageRole = "assistant"
ToolCalls []CreateResponseResponseChoicesMessageToolCalloptional

The tool calls generated by the model, such as function calls.

ID string

The ID of the tool call.

Function CreateResponseResponseChoicesMessageToolCallsFunction

The function that the model called.

Arguments string

The arguments to call the function with, as generated by the model in JSON format. Note that the model does not always generate valid JSON, and may hallucinate parameters not defined by your function schema. Validate the arguments in your code before calling your function.

Name string

The name of the function to call.

Type CreateResponseResponseChoicesMessageToolCallsType

The type of the tool. Currently, only function is supported.

Accepts one of the following:
const CreateResponseResponseChoicesMessageToolCallsTypeFunction CreateResponseResponseChoicesMessageToolCallsType = "function"
Logprobs CreateResponseResponseChoicesLogprobsoptional

Log probability information for the choice. Only present if logprobs was requested in the request.

A list of message content tokens with log probability information.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

TopLogprobs []ChatCompletionTokenLogprobTopLogprob

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

InputMessages []unknownoptional

Input messages (if applicable)

MaxOutputTokens int64optional

Maximum output tokens setting

MaxToolCalls int64optional

Maximum tool calls setting

Output []CreateResponseResponseOutputoptional

An array of content items generated by the model. This includes text content, function calls, reasoning items, and other output types. Use this field for Responses API compatibility.

Accepts one of the following:
type CreateResponseResponseOutputObject struct{…}
Arguments string

JSON string of function arguments

CallID string

The unique ID of the function tool call

Name string

The name of the function to call

Type CreateResponseResponseOutputObjectType

The type of output item

Accepts one of the following:
const CreateResponseResponseOutputObjectTypeFunctionCall CreateResponseResponseOutputObjectType = "function_call"
ID stringoptional

The unique ID of the function tool call (same as call_id)

EncryptedContent stringoptional

Encrypted content (optional)

Status stringoptional

Status of the item (optional, can be null)

type CreateResponseResponseOutputObject struct{…}
Text string

The text content

Type CreateResponseResponseOutputObjectType

The type of output item

Accepts one of the following:
const CreateResponseResponseOutputObjectTypeText CreateResponseResponseOutputObjectType = "text"
type CreateResponseResponseOutputObject struct{…}
ID string

The unique ID of the reasoning item

Content []CreateResponseResponseOutputObjectContent

Array of reasoning content parts

Text string

The reasoning text content

Type CreateResponseResponseOutputObjectContentType

The type of content

Accepts one of the following:
const CreateResponseResponseOutputObjectContentTypeReasoningText CreateResponseResponseOutputObjectContentType = "reasoning_text"
Summary []unknown

Summary of the reasoning (usually empty)

Type CreateResponseResponseOutputObjectType

The type of output item

Accepts one of the following:
const CreateResponseResponseOutputObjectTypeReasoning CreateResponseResponseOutputObjectType = "reasoning"
EncryptedContent stringoptional

Encrypted content (optional)

Status stringoptional

Status of the item (optional, can be null)

OutputMessages []unknownoptional

Output messages (if applicable)

ParallelToolCalls booloptional

Whether parallel tool calls are enabled

PreviousResponseID stringoptional

Previous response ID (for multi-turn conversations)

Prompt stringoptional

Prompt used for the response

Reasoning stringoptional

Reasoning content

ServiceTier stringoptional

Service tier used

Status stringoptional

Status of the response

Temperature float64optional

Temperature setting used for the response

Text stringoptional

Text content

ToolChoice stringoptional

Tool choice setting used for the response

Tools []CreateResponseResponseTooloptional

Tools available for the response

Type CreateResponseResponseToolsType

The type of the tool. Supported values are function (custom tools), web_search, and web_search_2025_08_26 (built-in web search).

Accepts one of the following:
const CreateResponseResponseToolsTypeFunction CreateResponseResponseToolsType = "function"
const CreateResponseResponseToolsTypeWebSearch CreateResponseResponseToolsType = "web_search"
const CreateResponseResponseToolsTypeWebSearch2025_08_26 CreateResponseResponseToolsType = "web_search_2025_08_26"
Description stringoptional

A description of what the function does, used by the model to choose when and how to call the function.

Name stringoptional

The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.

Parameters map[string, unknown]optional

The parameters the functions accepts, described as a JSON Schema object. See the guide for examples, and the JSON Schema reference for documentation about the format.

Omitting parameters defines a function with an empty parameter list.

TopLogprobs int64optional

Top logprobs setting

TopP float64optional

Top-p setting used for the response

Truncation stringoptional

Truncation setting

User stringoptional

User identifier

type CreateResponseStreamResponse struct{…}

Represents a streamed chunk of a text-to-text response returned by the model, based on the provided input. VLLM models only.

ID string

A unique identifier for the response. Each chunk has the same ID.

Choices []CreateResponseStreamResponseChoice

A list of response choice chunks. Can contain more than one element if n is greater than 1. Can also be empty for the last chunk if you set stream_options: {"include_usage": true}.

Delta CreateResponseStreamResponseChoicesDelta

A chunk of the response message generated by the model.

Content stringoptional

The contents of the chunk message. Can be null for chunks with tool calls or other non-text content.

ReasoningContent stringoptional

The reasoning content generated by the model. Only present when the model generates reasoning text.

Role CreateResponseStreamResponseChoicesDeltaRoleoptional

The role of the message author. Only present in the first chunk.

Accepts one of the following:
const CreateResponseStreamResponseChoicesDeltaRoleAssistant CreateResponseStreamResponseChoicesDeltaRole = "assistant"
ToolCalls []CreateResponseStreamResponseChoicesDeltaToolCalloptional

The tool calls generated by the model, such as function calls. Only present when the model decides to call a tool.

ID string

The ID of the tool call.

Function CreateResponseStreamResponseChoicesDeltaToolCallsFunction

The function that the model called.

Arguments string

The arguments to call the function with, as generated by the model in JSON format. Note that the model does not always generate valid JSON, and may hallucinate parameters not defined by your function schema. Validate the arguments in your code before calling your function.

Name string

The name of the function to call.

Type CreateResponseStreamResponseChoicesDeltaToolCallsType

The type of the tool. Currently, only function is supported.

Accepts one of the following:
const CreateResponseStreamResponseChoicesDeltaToolCallsTypeFunction CreateResponseStreamResponseChoicesDeltaToolCallsType = "function"
Index int64

The index of the choice in the list of choices.

FinishReason CreateResponseStreamResponseChoicesFinishReasonoptional

The reason the model stopped generating tokens. This will be stop if the model hit a natural stop point or a provided stop sequence, length if the maximum number of tokens specified in the request was reached, or tool_calls if the model called a tool. Only present in the final chunk.

Accepts one of the following:
const CreateResponseStreamResponseChoicesFinishReasonStop CreateResponseStreamResponseChoicesFinishReason = "stop"
const CreateResponseStreamResponseChoicesFinishReasonLength CreateResponseStreamResponseChoicesFinishReason = "length"
const CreateResponseStreamResponseChoicesFinishReasonToolCalls CreateResponseStreamResponseChoicesFinishReason = "tool_calls"
const CreateResponseStreamResponseChoicesFinishReasonContentFilter CreateResponseStreamResponseChoicesFinishReason = "content_filter"
Logprobs CreateResponseStreamResponseChoicesLogprobsoptional

Log probability information for the choice. Only present if logprobs was requested in the request.

A list of message content tokens with log probability information.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

TopLogprobs []ChatCompletionTokenLogprobTopLogprob

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Token string

The token.

Bytes []int64

A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be null if there is no bytes representation for the token.

Logprob float64

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

Created int64

The Unix timestamp (in seconds) of when the response was created. Each chunk has the same timestamp.

Model string

The model used to generate the response.

Object CreateResponseStreamResponseObject

The object type, which is always response.chunk.

Accepts one of the following:
const CreateResponseStreamResponseObjectResponseChunk CreateResponseStreamResponseObject = "response.chunk"
Usage CompletionUsageoptional

An optional field that will only be present when you set stream_options: {"include_usage": true} in your request. When present, it contains a null value except for the last chunk which contains the token usage statistics for the entire request. NOTE: If the stream is interrupted or cancelled, you may not receive the final usage chunk which contains the total token usage for the request.

CacheCreatedInputTokens int64

Number of prompt tokens written to cache.

CacheCreation CompletionUsageCacheCreation

Breakdown of prompt tokens written to cache.

Ephemeral1hInputTokens int64

Number of prompt tokens written to 1h cache.

Ephemeral5mInputTokens int64

Number of prompt tokens written to 5m cache.

CacheReadInputTokens int64

Number of prompt tokens read from cache.

CompletionTokens int64

Number of tokens in the generated completion.

PromptTokens int64

Number of tokens in the prompt.

TotalTokens int64

Total number of tokens used in the request (prompt + completion).

type DiskInfo struct{…}
Size DiskInfoSizeoptional
Amount int64optional

The amount of space allocated to the disk.

Unit stringoptional

The unit of measure for the disk size.

Type DiskInfoTypeoptional

The type of disk. All Droplets contain a local disk. Additionally, GPU Droplets can also have a scratch disk for non-persistent data.

Accepts one of the following:
const DiskInfoTypeLocal DiskInfoType = "local"
const DiskInfoTypeScratch DiskInfoType = "scratch"
type Droplet struct{…}
ID int64

A unique identifier for each Droplet instance. This is automatically generated upon Droplet creation.

BackupIDs []int64

An array of backup IDs of any backups that have been taken of the Droplet instance. Droplet backups are enabled at the time of the instance creation.
Requires image:read scope.

CreatedAt Time

A time value given in ISO8601 combined date and time format that represents when the Droplet was created.

formatdate-time
Disk int64

The size of the Droplet's disk in gigabytes.

Features []string

An array of features enabled on this Droplet.

Image Image

The Droplet's image.
Requires image:read scope.

ID int64optional

A unique number that can be used to identify and reference a specific image.

CreatedAt Timeoptional

A time value given in ISO8601 combined date and time format that represents when the image was created.

formatdate-time
Description stringoptional

An optional free-form text field to describe an image.

Distribution ImageDistributionoptional

The name of a custom image's distribution. Currently, the valid values are Arch Linux, CentOS, CoreOS, Debian, Fedora, Fedora Atomic, FreeBSD, Gentoo, openSUSE, RancherOS, Rocky Linux, Ubuntu, and Unknown. Any other value will be accepted but ignored, and Unknown will be used in its place.

Accepts one of the following:
const ImageDistributionArchLinux ImageDistribution = "Arch Linux"
const ImageDistributionCentOs ImageDistribution = "CentOS"
const ImageDistributionCoreOs ImageDistribution = "CoreOS"
const ImageDistributionDebian ImageDistribution = "Debian"
const ImageDistributionFedora ImageDistribution = "Fedora"
const ImageDistributionFedoraAtomic ImageDistribution = "Fedora Atomic"
const ImageDistributionFreeBsd ImageDistribution = "FreeBSD"
const ImageDistributionGentoo ImageDistribution = "Gentoo"
const ImageDistributionOpenSuse ImageDistribution = "openSUSE"
const ImageDistributionRancherOs ImageDistribution = "RancherOS"
const ImageDistributionRockyLinux ImageDistribution = "Rocky Linux"
const ImageDistributionUbuntu ImageDistribution = "Ubuntu"
const ImageDistributionUnknown ImageDistribution = "Unknown"
ErrorMessage stringoptional

A string containing information about errors that may occur when importing a custom image.

MinDiskSize int64optional

The minimum disk size in GB required for a Droplet to use this image.

minimum0
Name stringoptional

The display name that has been given to an image. This is what is shown in the control panel and is generally a descriptive title for the image in question.

Public booloptional

This is a boolean value that indicates whether the image in question is public or not. An image that is public is available to all accounts. A non-public image is only accessible from your account.

Regions []ImageRegionoptional

This attribute is an array of the regions that the image is available in. The regions are represented by their identifying slug values.

Accepts one of the following:
const ImageRegionAms1 ImageRegion = "ams1"
const ImageRegionAms2 ImageRegion = "ams2"
const ImageRegionAms3 ImageRegion = "ams3"
const ImageRegionBlr1 ImageRegion = "blr1"
const ImageRegionFra1 ImageRegion = "fra1"
const ImageRegionLon1 ImageRegion = "lon1"
const ImageRegionNyc1 ImageRegion = "nyc1"
const ImageRegionNyc2 ImageRegion = "nyc2"
const ImageRegionNyc3 ImageRegion = "nyc3"
const ImageRegionSfo1 ImageRegion = "sfo1"
const ImageRegionSfo2 ImageRegion = "sfo2"
const ImageRegionSfo3 ImageRegion = "sfo3"
const ImageRegionSgp1 ImageRegion = "sgp1"
const ImageRegionTor1 ImageRegion = "tor1"
const ImageRegionSyd1 ImageRegion = "syd1"
SizeGigabytes float64optional

The size of the image in gigabytes.

formatfloat
Slug stringoptional

A uniquely identifying string that is associated with each of the DigitalOcean-provided public images. These can be used to reference a public image as an alternative to the numeric id.

Status ImageStatusoptional

A status string indicating the state of a custom image. This may be NEW, available, pending, deleted, or retired.

Accepts one of the following:
const ImageStatusNew ImageStatus = "NEW"
const ImageStatusAvailable ImageStatus = "available"
const ImageStatusPending ImageStatus = "pending"
const ImageStatusDeleted ImageStatus = "deleted"
const ImageStatusRetired ImageStatus = "retired"
Tags []stringoptional

A flat array of tag names as strings to be applied to the resource. Tag names may be for either existing or new tags.

Requires tag:create scope.

Type ImageTypeoptional

Describes the kind of image. It may be one of base, snapshot, backup, custom, or admin. Respectively, this specifies whether an image is a DigitalOcean base OS image, user-generated Droplet snapshot, automatically created Droplet backup, user-provided virtual machine image, or an image used for DigitalOcean managed resources (e.g. DOKS worker nodes).

Accepts one of the following:
const ImageTypeBase ImageType = "base"
const ImageTypeSnapshot ImageType = "snapshot"
const ImageTypeBackup ImageType = "backup"
const ImageTypeCustom ImageType = "custom"
const ImageTypeAdmin ImageType = "admin"
Locked bool

A boolean value indicating whether the Droplet has been locked, preventing actions by users.

Memory int64

Memory of the Droplet in megabytes.

multipleOf8
Name string

The human-readable name set for the Droplet instance.

Networks DropletNetworks

The details of the network that are configured for the Droplet instance. This is an object that contains keys for IPv4 and IPv6. The value of each of these is an array that contains objects describing an individual IP resource allocated to the Droplet. These will define attributes like the IP address, netmask, and gateway of the specific network depending on the type of network it is.

V4 []NetworkV4optional
Gateway stringoptional

The gateway of the specified IPv4 network interface.

For private interfaces, a gateway is not provided. This is denoted by returning nil as its value.

IPAddress stringoptional

The IP address of the IPv4 network interface.

formatipv4
Netmask stringoptional

The netmask of the IPv4 network interface.

formatipv4
Type NetworkV4Typeoptional

The type of the IPv4 network interface.

Accepts one of the following:
const NetworkV4TypePublic NetworkV4Type = "public"
const NetworkV4TypePrivate NetworkV4Type = "private"
V6 []NetworkV6optional
Gateway stringoptional

The gateway of the specified IPv6 network interface.

formatipv6
IPAddress stringoptional

The IP address of the IPv6 network interface.

formatipv6
Netmask int64optional

The netmask of the IPv6 network interface.

Type NetworkV6Typeoptional

The type of the IPv6 network interface.

Note: IPv6 private networking is not currently supported.

Accepts one of the following:
const NetworkV6TypePublic NetworkV6Type = "public"
NextBackupWindow DropletNextBackupWindow

The details of the Droplet's backups feature, if backups are configured for the Droplet. This object contains keys for the start and end times of the window during which the backup will start.

End Timeoptional

A time value given in ISO8601 combined date and time format specifying the end of the Droplet's backup window.

formatdate-time
Start Timeoptional

A time value given in ISO8601 combined date and time format specifying the start of the Droplet's backup window.

formatdate-time
Region Region
Available bool

This is a boolean value that represents whether new Droplets can be created in this region.

Features []string

This attribute is set to an array which contains features available in this region

Name string

The display name of the region. This will be a full name that is used in the control panel and other interfaces.

Sizes []string

This attribute is set to an array which contains the identifying slugs for the sizes available in this region. sizes:read is required to view.

Slug string

A human-readable string that is used as a unique identifier for each region.

Size Size
Available bool

This is a boolean value that represents whether new Droplets can be created with this size.

Description string

A string describing the class of Droplets created from this size. For example: Basic, General Purpose, CPU-Optimized, Memory-Optimized, or Storage-Optimized.

Disk int64

The amount of disk space set aside for Droplets of this size. The value is represented in gigabytes.

Memory int64

The amount of RAM allocated to Droplets created of this size. The value is represented in megabytes.

multipleOf8
minimum8
PriceHourly float64

This describes the price of the Droplet size as measured hourly. The value is measured in US dollars.

formatfloat
PriceMonthly float64

This attribute describes the monthly cost of this Droplet size if the Droplet is kept for an entire month. The value is measured in US dollars.

formatfloat
Regions []string

An array containing the region slugs where this size is available for Droplet creates.

Slug string

A human-readable string that is used to uniquely identify each size.

Transfer float64

The amount of transfer bandwidth that is available for Droplets created in this size. This only counts traffic on the public interface. The value is given in terabytes.

formatfloat
Vcpus int64

The number of CPUs allocated to Droplets of this size.

DiskInfo []DiskInfooptional

An array of objects containing information about the disks available to Droplets created with this size.

Size DiskInfoSizeoptional
Amount int64optional

The amount of space allocated to the disk.

Unit stringoptional

The unit of measure for the disk size.

Type DiskInfoTypeoptional

The type of disk. All Droplets contain a local disk. Additionally, GPU Droplets can also have a scratch disk for non-persistent data.

Accepts one of the following:
const DiskInfoTypeLocal DiskInfoType = "local"
const DiskInfoTypeScratch DiskInfoType = "scratch"
GPUInfo GPUInfooptional

An object containing information about the GPU capabilities of Droplets created with this size.

Count int64optional

The number of GPUs allocated to the Droplet.

Model stringoptional

The model of the GPU.

Vram GPUInfoVramoptional
Amount int64optional

The amount of VRAM allocated to the GPU.

Unit stringoptional

The unit of measure for the VRAM.

SizeSlug string

The unique slug identifier for the size of this Droplet.

SnapshotIDs []int64

An array of snapshot IDs of any snapshots created from the Droplet instance.
Requires image:read scope.

Status DropletStatus

A status string indicating the state of the Droplet instance. This may be "new", "active", "off", or "archive".

Accepts one of the following:
const DropletStatusNew DropletStatus = "new"
const DropletStatusActive DropletStatus = "active"
const DropletStatusOff DropletStatus = "off"
const DropletStatusArchive DropletStatus = "archive"
Tags []string

An array of Tags the Droplet has been tagged with.
Requires tag:read scope.

Vcpus int64

The number of virtual CPUs.

VolumeIDs []string

A flat array including the unique identifier for each Block Storage volume attached to the Droplet.
Requires block_storage:read scope.

DiskInfo []DiskInfooptional

An array of objects containing information about the disks available to the Droplet.

Size DiskInfoSizeoptional
Amount int64optional

The amount of space allocated to the disk.

Unit stringoptional

The unit of measure for the disk size.

Type DiskInfoTypeoptional

The type of disk. All Droplets contain a local disk. Additionally, GPU Droplets can also have a scratch disk for non-persistent data.

Accepts one of the following:
const DiskInfoTypeLocal DiskInfoType = "local"
const DiskInfoTypeScratch DiskInfoType = "scratch"
GPUInfo GPUInfooptional

An object containing information about the GPU capabilities of Droplets created with this size.

Count int64optional

The number of GPUs allocated to the Droplet.

Model stringoptional

The model of the GPU.

Vram GPUInfoVramoptional
Amount int64optional

The amount of VRAM allocated to the GPU.

Unit stringoptional

The unit of measure for the VRAM.

DeprecatedKernel Kerneloptional

Note: All Droplets created after March 2017 use internal kernels by default. These Droplets will have this attribute set to null.

The current kernel for Droplets with externally managed kernels. This will initially be set to the kernel of the base image when the Droplet is created.

ID int64optional

A unique number used to identify and reference a specific kernel.

Name stringoptional

The display name of the kernel. This is shown in the web UI and is generally a descriptive title for the kernel in question.

Version stringoptional

A standard kernel version string representing the version, patch, and release information.

VpcUuid stringoptional

A string specifying the UUID of the VPC to which the Droplet is assigned.
Requires vpc:read scope.

type DropletNextBackupWindow struct{…}
End Timeoptional

A time value given in ISO8601 combined date and time format specifying the end of the Droplet's backup window.

formatdate-time
Start Timeoptional

A time value given in ISO8601 combined date and time format specifying the start of the Droplet's backup window.

formatdate-time
type FirewallRuleTarget struct{…}
Addresses []stringoptional

An array of strings containing the IPv4 addresses, IPv6 addresses, IPv4 CIDRs, and/or IPv6 CIDRs to which the firewall will allow traffic.

DropletIDs []int64optional

An array containing the IDs of the Droplets to which the firewall will allow traffic.

KubernetesIDs []stringoptional

An array containing the IDs of the Kubernetes clusters to which the firewall will allow traffic.

LoadBalancerUids []stringoptional

An array containing the IDs of the load balancers to which the firewall will allow traffic.

Tags []stringoptional

A flat array of tag names as strings to be applied to the resource. Tag names must exist in order to be referenced in a request.

Requires tag:create and tag:read scopes.

type GarbageCollection struct{…}
BlobsDeleted int64optional

The number of blobs deleted as a result of this garbage collection.

CreatedAt Timeoptional

The time the garbage collection was created.

formatdate-time
FreedBytes int64optional

The number of bytes freed as a result of this garbage collection.

RegistryName stringoptional

The name of the container registry.

Status GarbageCollectionStatusoptional

The current status of this garbage collection.

Accepts one of the following:
const GarbageCollectionStatusRequested GarbageCollectionStatus = "requested"
const GarbageCollectionStatusWaitingForWriteJwTsToExpire GarbageCollectionStatus = "waiting for write JWTs to expire"
const GarbageCollectionStatusScanningManifests GarbageCollectionStatus = "scanning manifests"
const GarbageCollectionStatusDeletingUnreferencedBlobs GarbageCollectionStatus = "deleting unreferenced blobs"
const GarbageCollectionStatusCancelling GarbageCollectionStatus = "cancelling"
const GarbageCollectionStatusFailed GarbageCollectionStatus = "failed"
const GarbageCollectionStatusSucceeded GarbageCollectionStatus = "succeeded"
const GarbageCollectionStatusCancelled GarbageCollectionStatus = "cancelled"
UpdatedAt Timeoptional

The time the garbage collection was last updated.

formatdate-time
Uuid stringoptional

A string specifying the UUID of the garbage collection.

type GPUInfo struct{…}

An object containing information about the GPU capabilities of Droplets created with this size.

Count int64optional

The number of GPUs allocated to the Droplet.

Model stringoptional

The model of the GPU.

Vram GPUInfoVramoptional
Amount int64optional

The amount of VRAM allocated to the GPU.

Unit stringoptional

The unit of measure for the VRAM.

type Image struct{…}
ID int64optional

A unique number that can be used to identify and reference a specific image.

CreatedAt Timeoptional

A time value given in ISO8601 combined date and time format that represents when the image was created.

formatdate-time
Description stringoptional

An optional free-form text field to describe an image.

Distribution ImageDistributionoptional

The name of a custom image's distribution. Currently, the valid values are Arch Linux, CentOS, CoreOS, Debian, Fedora, Fedora Atomic, FreeBSD, Gentoo, openSUSE, RancherOS, Rocky Linux, Ubuntu, and Unknown. Any other value will be accepted but ignored, and Unknown will be used in its place.

Accepts one of the following:
const ImageDistributionArchLinux ImageDistribution = "Arch Linux"
const ImageDistributionCentOs ImageDistribution = "CentOS"
const ImageDistributionCoreOs ImageDistribution = "CoreOS"
const ImageDistributionDebian ImageDistribution = "Debian"
const ImageDistributionFedora ImageDistribution = "Fedora"
const ImageDistributionFedoraAtomic ImageDistribution = "Fedora Atomic"
const ImageDistributionFreeBsd ImageDistribution = "FreeBSD"
const ImageDistributionGentoo ImageDistribution = "Gentoo"
const ImageDistributionOpenSuse ImageDistribution = "openSUSE"
const ImageDistributionRancherOs ImageDistribution = "RancherOS"
const ImageDistributionRockyLinux ImageDistribution = "Rocky Linux"
const ImageDistributionUbuntu ImageDistribution = "Ubuntu"
const ImageDistributionUnknown ImageDistribution = "Unknown"
ErrorMessage stringoptional

A string containing information about errors that may occur when importing a custom image.

MinDiskSize int64optional

The minimum disk size in GB required for a Droplet to use this image.

minimum0
Name stringoptional

The display name that has been given to an image. This is what is shown in the control panel and is generally a descriptive title for the image in question.

Public booloptional

This is a boolean value that indicates whether the image in question is public or not. An image that is public is available to all accounts. A non-public image is only accessible from your account.

Regions []ImageRegionoptional

This attribute is an array of the regions that the image is available in. The regions are represented by their identifying slug values.

Accepts one of the following:
const ImageRegionAms1 ImageRegion = "ams1"
const ImageRegionAms2 ImageRegion = "ams2"
const ImageRegionAms3 ImageRegion = "ams3"
const ImageRegionBlr1 ImageRegion = "blr1"
const ImageRegionFra1 ImageRegion = "fra1"
const ImageRegionLon1 ImageRegion = "lon1"
const ImageRegionNyc1 ImageRegion = "nyc1"
const ImageRegionNyc2 ImageRegion = "nyc2"
const ImageRegionNyc3 ImageRegion = "nyc3"
const ImageRegionSfo1 ImageRegion = "sfo1"
const ImageRegionSfo2 ImageRegion = "sfo2"
const ImageRegionSfo3 ImageRegion = "sfo3"
const ImageRegionSgp1 ImageRegion = "sgp1"
const ImageRegionTor1 ImageRegion = "tor1"
const ImageRegionSyd1 ImageRegion = "syd1"
SizeGigabytes float64optional

The size of the image in gigabytes.

formatfloat
Slug stringoptional

A uniquely identifying string that is associated with each of the DigitalOcean-provided public images. These can be used to reference a public image as an alternative to the numeric id.

Status ImageStatusoptional

A status string indicating the state of a custom image. This may be NEW, available, pending, deleted, or retired.

Accepts one of the following:
const ImageStatusNew ImageStatus = "NEW"
const ImageStatusAvailable ImageStatus = "available"
const ImageStatusPending ImageStatus = "pending"
const ImageStatusDeleted ImageStatus = "deleted"
const ImageStatusRetired ImageStatus = "retired"
Tags []stringoptional

A flat array of tag names as strings to be applied to the resource. Tag names may be for either existing or new tags.

Requires tag:create scope.

Type ImageTypeoptional

Describes the kind of image. It may be one of base, snapshot, backup, custom, or admin. Respectively, this specifies whether an image is a DigitalOcean base OS image, user-generated Droplet snapshot, automatically created Droplet backup, user-provided virtual machine image, or an image used for DigitalOcean managed resources (e.g. DOKS worker nodes).

Accepts one of the following:
const ImageTypeBase ImageType = "base"
const ImageTypeSnapshot ImageType = "snapshot"
const ImageTypeBackup ImageType = "backup"
const ImageTypeCustom ImageType = "custom"
const ImageTypeAdmin ImageType = "admin"
type ImageGenCompletedEvent struct{…}

Emitted when image generation has completed and the final image is available.

B64Json string

Base64-encoded image data, suitable for rendering as an image.

Background ImageGenCompletedEventBackground

The background setting for the generated image.

Accepts one of the following:
const ImageGenCompletedEventBackgroundTransparent ImageGenCompletedEventBackground = "transparent"
const ImageGenCompletedEventBackgroundOpaque ImageGenCompletedEventBackground = "opaque"
const ImageGenCompletedEventBackgroundAuto ImageGenCompletedEventBackground = "auto"
CreatedAt int64

The Unix timestamp when the event was created.

OutputFormat ImageGenCompletedEventOutputFormat

The output format for the generated image.

Accepts one of the following:
const ImageGenCompletedEventOutputFormatPng ImageGenCompletedEventOutputFormat = "png"
const ImageGenCompletedEventOutputFormatWebp ImageGenCompletedEventOutputFormat = "webp"
const ImageGenCompletedEventOutputFormatJpeg ImageGenCompletedEventOutputFormat = "jpeg"
Quality ImageGenCompletedEventQuality

The quality setting for the generated image.

Accepts one of the following:
const ImageGenCompletedEventQualityLow ImageGenCompletedEventQuality = "low"
const ImageGenCompletedEventQualityMedium ImageGenCompletedEventQuality = "medium"
const ImageGenCompletedEventQualityHigh ImageGenCompletedEventQuality = "high"
const ImageGenCompletedEventQualityAuto ImageGenCompletedEventQuality = "auto"
Size ImageGenCompletedEventSize

The size of the generated image.

Accepts one of the following:
const ImageGenCompletedEventSize1024x1024 ImageGenCompletedEventSize = "1024x1024"
const ImageGenCompletedEventSize1024x1536 ImageGenCompletedEventSize = "1024x1536"
const ImageGenCompletedEventSize1536x1024 ImageGenCompletedEventSize = "1536x1024"
const ImageGenCompletedEventSizeAuto ImageGenCompletedEventSize = "auto"
Type ImageGenCompletedEventType

The type of the event. Always image_generation.completed.

Accepts one of the following:
const ImageGenCompletedEventTypeImageGenerationCompleted ImageGenCompletedEventType = "image_generation.completed"
Usage ImageGenCompletedEventUsage

For gpt-image-1 only, the token usage information for the image generation.

InputTokens int64

The number of tokens (images and text) in the input prompt.

InputTokensDetails ImageGenCompletedEventUsageInputTokensDetails

The input tokens detailed information for the image generation.

ImageTokens int64

The number of image tokens in the input prompt.

TextTokens int64

The number of text tokens in the input prompt.

OutputTokens int64

The number of image tokens in the output image.

TotalTokens int64

The total number of tokens (images and text) used for the image generation.

type ImageGenPartialImageEvent struct{…}

Emitted when a partial image is available during image generation streaming.

B64Json string

Base64-encoded partial image data, suitable for rendering as an image.

Background ImageGenPartialImageEventBackground

The background setting for the requested image.

Accepts one of the following:
const ImageGenPartialImageEventBackgroundTransparent ImageGenPartialImageEventBackground = "transparent"
const ImageGenPartialImageEventBackgroundOpaque ImageGenPartialImageEventBackground = "opaque"
const ImageGenPartialImageEventBackgroundAuto ImageGenPartialImageEventBackground = "auto"
CreatedAt int64

The Unix timestamp when the event was created.

OutputFormat ImageGenPartialImageEventOutputFormat

The output format for the requested image.

Accepts one of the following:
const ImageGenPartialImageEventOutputFormatPng ImageGenPartialImageEventOutputFormat = "png"
const ImageGenPartialImageEventOutputFormatWebp ImageGenPartialImageEventOutputFormat = "webp"
const ImageGenPartialImageEventOutputFormatJpeg ImageGenPartialImageEventOutputFormat = "jpeg"
PartialImageIndex int64

0-based index for the partial image (streaming).

Quality ImageGenPartialImageEventQuality

The quality setting for the requested image.

Accepts one of the following:
const ImageGenPartialImageEventQualityLow ImageGenPartialImageEventQuality = "low"
const ImageGenPartialImageEventQualityMedium ImageGenPartialImageEventQuality = "medium"
const ImageGenPartialImageEventQualityHigh ImageGenPartialImageEventQuality = "high"
const ImageGenPartialImageEventQualityAuto ImageGenPartialImageEventQuality = "auto"
Size ImageGenPartialImageEventSize

The size of the requested image.

Accepts one of the following:
const ImageGenPartialImageEventSize1024x1024 ImageGenPartialImageEventSize = "1024x1024"
const ImageGenPartialImageEventSize1024x1536 ImageGenPartialImageEventSize = "1024x1536"
const ImageGenPartialImageEventSize1536x1024 ImageGenPartialImageEventSize = "1536x1024"
const ImageGenPartialImageEventSizeAuto ImageGenPartialImageEventSize = "auto"
Type ImageGenPartialImageEventType

The type of the event. Always image_generation.partial_image.

Accepts one of the following:
const ImageGenPartialImageEventTypeImageGenerationPartialImage ImageGenPartialImageEventType = "image_generation.partial_image"
type ImageGenStreamEvent interface{…}

Emitted when a partial image is available during image generation streaming.

Accepts one of the following:
type ImageGenPartialImageEvent struct{…}

Emitted when a partial image is available during image generation streaming.

B64Json string

Base64-encoded partial image data, suitable for rendering as an image.

Background ImageGenPartialImageEventBackground

The background setting for the requested image.

Accepts one of the following:
const ImageGenPartialImageEventBackgroundTransparent ImageGenPartialImageEventBackground = "transparent"
const ImageGenPartialImageEventBackgroundOpaque ImageGenPartialImageEventBackground = "opaque"
const ImageGenPartialImageEventBackgroundAuto ImageGenPartialImageEventBackground = "auto"
CreatedAt int64

The Unix timestamp when the event was created.

OutputFormat ImageGenPartialImageEventOutputFormat

The output format for the requested image.

Accepts one of the following:
const ImageGenPartialImageEventOutputFormatPng ImageGenPartialImageEventOutputFormat = "png"
const ImageGenPartialImageEventOutputFormatWebp ImageGenPartialImageEventOutputFormat = "webp"
const ImageGenPartialImageEventOutputFormatJpeg ImageGenPartialImageEventOutputFormat = "jpeg"
PartialImageIndex int64

0-based index for the partial image (streaming).

Quality ImageGenPartialImageEventQuality

The quality setting for the requested image.

Accepts one of the following:
const ImageGenPartialImageEventQualityLow ImageGenPartialImageEventQuality = "low"
const ImageGenPartialImageEventQualityMedium ImageGenPartialImageEventQuality = "medium"
const ImageGenPartialImageEventQualityHigh ImageGenPartialImageEventQuality = "high"
const ImageGenPartialImageEventQualityAuto ImageGenPartialImageEventQuality = "auto"
Size ImageGenPartialImageEventSize

The size of the requested image.

Accepts one of the following:
const ImageGenPartialImageEventSize1024x1024 ImageGenPartialImageEventSize = "1024x1024"
const ImageGenPartialImageEventSize1024x1536 ImageGenPartialImageEventSize = "1024x1536"
const ImageGenPartialImageEventSize1536x1024 ImageGenPartialImageEventSize = "1536x1024"
const ImageGenPartialImageEventSizeAuto ImageGenPartialImageEventSize = "auto"
Type ImageGenPartialImageEventType

The type of the event. Always image_generation.partial_image.

Accepts one of the following:
const ImageGenPartialImageEventTypeImageGenerationPartialImage ImageGenPartialImageEventType = "image_generation.partial_image"
type ImageGenCompletedEvent struct{…}

Emitted when image generation has completed and the final image is available.

B64Json string

Base64-encoded image data, suitable for rendering as an image.

Background ImageGenCompletedEventBackground

The background setting for the generated image.

Accepts one of the following:
const ImageGenCompletedEventBackgroundTransparent ImageGenCompletedEventBackground = "transparent"
const ImageGenCompletedEventBackgroundOpaque ImageGenCompletedEventBackground = "opaque"
const ImageGenCompletedEventBackgroundAuto ImageGenCompletedEventBackground = "auto"
CreatedAt int64

The Unix timestamp when the event was created.

OutputFormat ImageGenCompletedEventOutputFormat

The output format for the generated image.

Accepts one of the following:
const ImageGenCompletedEventOutputFormatPng ImageGenCompletedEventOutputFormat = "png"
const ImageGenCompletedEventOutputFormatWebp ImageGenCompletedEventOutputFormat = "webp"
const ImageGenCompletedEventOutputFormatJpeg ImageGenCompletedEventOutputFormat = "jpeg"
Quality ImageGenCompletedEventQuality

The quality setting for the generated image.

Accepts one of the following:
const ImageGenCompletedEventQualityLow ImageGenCompletedEventQuality = "low"
const ImageGenCompletedEventQualityMedium ImageGenCompletedEventQuality = "medium"
const ImageGenCompletedEventQualityHigh ImageGenCompletedEventQuality = "high"
const ImageGenCompletedEventQualityAuto ImageGenCompletedEventQuality = "auto"
Size ImageGenCompletedEventSize

The size of the generated image.

Accepts one of the following:
const ImageGenCompletedEventSize1024x1024 ImageGenCompletedEventSize = "1024x1024"
const ImageGenCompletedEventSize1024x1536 ImageGenCompletedEventSize = "1024x1536"
const ImageGenCompletedEventSize1536x1024 ImageGenCompletedEventSize = "1536x1024"
const ImageGenCompletedEventSizeAuto ImageGenCompletedEventSize = "auto"
Type ImageGenCompletedEventType

The type of the event. Always image_generation.completed.

Accepts one of the following:
const ImageGenCompletedEventTypeImageGenerationCompleted ImageGenCompletedEventType = "image_generation.completed"
Usage ImageGenCompletedEventUsage

For gpt-image-1 only, the token usage information for the image generation.

InputTokens int64

The number of tokens (images and text) in the input prompt.

InputTokensDetails ImageGenCompletedEventUsageInputTokensDetails

The input tokens detailed information for the image generation.

ImageTokens int64

The number of image tokens in the input prompt.

TextTokens int64

The number of text tokens in the input prompt.

OutputTokens int64

The number of image tokens in the output image.

TotalTokens int64

The total number of tokens (images and text) used for the image generation.

type Kernel struct{…}

Note: All Droplets created after March 2017 use internal kernels by default. These Droplets will have this attribute set to null.

The current kernel for Droplets with externally managed kernels. This will initially be set to the kernel of the base image when the Droplet is created.

ID int64optional

A unique number used to identify and reference a specific kernel.

Name stringoptional

The display name of the kernel. This is shown in the web UI and is generally a descriptive title for the kernel in question.

Version stringoptional

A standard kernel version string representing the version, patch, and release information.

type MetaProperties struct{…}

Information about the response itself.

Total int64optional

Number of objects returned by the request.

type NetworkV4 struct{…}
Gateway stringoptional

The gateway of the specified IPv4 network interface.

For private interfaces, a gateway is not provided. This is denoted by returning nil as its value.

IPAddress stringoptional

The IP address of the IPv4 network interface.

formatipv4
Netmask stringoptional

The netmask of the IPv4 network interface.

formatipv4
Type NetworkV4Typeoptional

The type of the IPv4 network interface.

Accepts one of the following:
const NetworkV4TypePublic NetworkV4Type = "public"
const NetworkV4TypePrivate NetworkV4Type = "private"
type NetworkV6 struct{…}
Gateway stringoptional

The gateway of the specified IPv6 network interface.

formatipv6
IPAddress stringoptional

The IP address of the IPv6 network interface.

formatipv6
Netmask int64optional

The netmask of the IPv6 network interface.

Type NetworkV6Typeoptional

The type of the IPv6 network interface.

Note: IPv6 private networking is not currently supported.

Accepts one of the following:
const NetworkV6TypePublic NetworkV6Type = "public"
Accepts one of the following:
type Region struct{…}
Available bool

This is a boolean value that represents whether new Droplets can be created in this region.

Features []string

This attribute is set to an array which contains features available in this region

Name string

The display name of the region. This will be a full name that is used in the control panel and other interfaces.

Sizes []string

This attribute is set to an array which contains the identifying slugs for the sizes available in this region. sizes:read is required to view.

Slug string

A human-readable string that is used as a unique identifier for each region.

type Size struct{…}
Available bool

This is a boolean value that represents whether new Droplets can be created with this size.

Description string

A string describing the class of Droplets created from this size. For example: Basic, General Purpose, CPU-Optimized, Memory-Optimized, or Storage-Optimized.

Disk int64

The amount of disk space set aside for Droplets of this size. The value is represented in gigabytes.

Memory int64

The amount of RAM allocated to Droplets created of this size. The value is represented in megabytes.

multipleOf8
minimum8
PriceHourly float64

This describes the price of the Droplet size as measured hourly. The value is measured in US dollars.

formatfloat
PriceMonthly float64

This attribute describes the monthly cost of this Droplet size if the Droplet is kept for an entire month. The value is measured in US dollars.

formatfloat
Regions []string

An array containing the region slugs where this size is available for Droplet creates.

Slug string

A human-readable string that is used to uniquely identify each size.

Transfer float64

The amount of transfer bandwidth that is available for Droplets created in this size. This only counts traffic on the public interface. The value is given in terabytes.

formatfloat
Vcpus int64

The number of CPUs allocated to Droplets of this size.

DiskInfo []DiskInfooptional

An array of objects containing information about the disks available to Droplets created with this size.

Size DiskInfoSizeoptional
Amount int64optional

The amount of space allocated to the disk.

Unit stringoptional

The unit of measure for the disk size.

Type DiskInfoTypeoptional

The type of disk. All Droplets contain a local disk. Additionally, GPU Droplets can also have a scratch disk for non-persistent data.

Accepts one of the following:
const DiskInfoTypeLocal DiskInfoType = "local"
const DiskInfoTypeScratch DiskInfoType = "scratch"
GPUInfo GPUInfooptional

An object containing information about the GPU capabilities of Droplets created with this size.

Count int64optional

The number of GPUs allocated to the Droplet.

Model stringoptional

The model of the GPU.

Vram GPUInfoVramoptional
Amount int64optional

The amount of VRAM allocated to the GPU.

Unit stringoptional

The unit of measure for the VRAM.

type Snapshots struct{…}
ID string

The unique identifier for the snapshot.

CreatedAt Time

A time value given in ISO8601 combined date and time format that represents when the snapshot was created.

formatdate-time
MinDiskSize int64

The minimum size in GB required for a volume or Droplet to use this snapshot.

Name string

A human-readable name for the snapshot.

Regions []string

An array of the regions that the snapshot is available in. The regions are represented by their identifying slug values.

ResourceID string

The unique identifier for the resource that the snapshot originated from.

ResourceType SnapshotsResourceType

The type of resource that the snapshot originated from.

Accepts one of the following:
const SnapshotsResourceTypeDroplet SnapshotsResourceType = "droplet"
const SnapshotsResourceTypeVolume SnapshotsResourceType = "volume"
SizeGigabytes float64

The billable size of the snapshot in gigabytes.

formatfloat
Tags []string

An array of Tags the snapshot has been tagged with.

Requires tag:read scope.

type Subscription struct{…}
CreatedAt Timeoptional

The time at which the subscription was created.

formatdate-time
AllowStorageOverage booloptional

A boolean indicating whether the subscription tier supports additional storage above what is included in the base plan at an additional cost per GiB used.

IncludedBandwidthBytes int64optional

The amount of outbound data transfer included in the subscription tier in bytes.

IncludedRepositories int64optional

The number of repositories included in the subscription tier. 0 indicates that the subscription tier includes unlimited repositories.

IncludedStorageBytes int64optional

The amount of storage included in the subscription tier in bytes.

MonthlyPriceInCents int64optional

The monthly cost of the subscription tier in cents.

Name stringoptional

The name of the subscription tier.

Slug stringoptional

The slug identifier of the subscription tier.

StorageOveragePriceInCents int64optional

The price paid in cents per GiB for additional storage beyond what is included in the subscription plan.

UpdatedAt Timeoptional

The time at which the subscription was last updated.

formatdate-time
type SubscriptionTierBase struct{…}
AllowStorageOverage booloptional

A boolean indicating whether the subscription tier supports additional storage above what is included in the base plan at an additional cost per GiB used.

IncludedBandwidthBytes int64optional

The amount of outbound data transfer included in the subscription tier in bytes.

IncludedRepositories int64optional

The number of repositories included in the subscription tier. 0 indicates that the subscription tier includes unlimited repositories.

IncludedStorageBytes int64optional

The amount of storage included in the subscription tier in bytes.

MonthlyPriceInCents int64optional

The monthly cost of the subscription tier in cents.

Name stringoptional

The name of the subscription tier.

Slug stringoptional

The slug identifier of the subscription tier.

StorageOveragePriceInCents int64optional

The price paid in cents per GiB for additional storage beyond what is included in the subscription plan.

type VpcPeering struct{…}
ID stringoptional

A unique ID that can be used to identify and reference the VPC peering.

formatuuid
CreatedAt Timeoptional

A time value given in ISO8601 combined date and time format.

formatdate-time
Name stringoptional

The name of the VPC peering. Must be unique within the team and may only contain alphanumeric characters and dashes.

Status VpcPeeringStatusoptional

The current status of the VPC peering.

Accepts one of the following:
const VpcPeeringStatusProvisioning VpcPeeringStatus = "PROVISIONING"
const VpcPeeringStatusActive VpcPeeringStatus = "ACTIVE"
const VpcPeeringStatusDeleting VpcPeeringStatus = "DELETING"
VpcIDs []stringoptional

An array of the two peered VPCs IDs.