NAME
OpenAPI::Client::OpenAI::Path::containers - Documentation for the /containers path.
OPERATIONS
GET /containers
ListContainers
$client->list_containers({
body => { ... },
});
List Containers
Lists containers.
Path/query parameters
limit(in query, optional, integer) - A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.Default: 20
order(in query, optional, string) - Sort order by thecreated_attimestamp of the objects.ascfor ascending order anddescfor descending order.Allowed values: asc, desc
Default: desc
after(in query, optional, string) - A cursor for use in pagination.afteris an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include after=obj_foo in order to fetch the next page of the list.name(in query, optional, string) - Filter results by container name.
Responses
200 - Success
Content-Type: application/json
Example:
{
"data" : [
"{\n \"id\": \"cntr_682dfebaacac8198bbfe9c2474fb6f4a085685cbe3cb5863\",\n \"object\": \"container\",\n \"created_at\": 1747844794,\n \"status\": \"running\",\n \"expires_after\": {\n \"anchor\": \"last_active_at\",\n \"minutes\": 20\n },\n \"last_active_at\": 1747844794,\n \"memory_limit\": \"1g\",\n \"name\": \"My Container\"\n}\n"
],
"first_id" : "string",
"has_more" : false,
"last_id" : "string",
"object" : "list"
}
POST /containers
CreateContainer
$client->create_container({
body => { ... },
});
Create Container
Creates a container.
Responses
200 - Success
Content-Type: application/json
Example:
{
"created_at" : 1747844794,
"expires_after" : {
"anchor" : "last_active_at",
"minutes" : 20
},
"id" : "cntr_682dfebaacac8198bbfe9c2474fb6f4a085685cbe3cb5863",
"last_active_at" : 1747844794,
"memory_limit" : "1g",
"name" : "My Container",
"object" : "container",
"status" : "running"
}
SCHEMAS
ContainerListResource
Properties:
data(array of ContainerResource, required) - A list of containers.first_id(string, required) - The ID of the first container in the list.has_more(boolean, required) - Whether there are more containers available.last_id(string, required) - The ID of the last container in the list.object(string, required) - The type of object returned, must be 'list'.Allowed values: list
ContainerResource
Properties:
created_at(integer, required) - Unix timestamp (in seconds) when the container was created.expires_after(object) - The container will expire after this time period. The anchor is the reference point for the expiration. The minutes is the number of minutes after the anchor before the container expires.id(string, required) - Unique identifier for the container.last_active_at(integer) - Unix timestamp (in seconds) when the container was last active.memory_limit(string) - The memory limit configured for the container.Allowed values: 1g, 4g, 16g, 64g
name(string, required) - Name of the container.network_policy(object) - Network access policy for the container.object(string, required) - The type of this object.status(string, required) - Status of the container (e.g., active, deleted).
CreateContainerBody
Properties:
expires_after(object) - Container expiration time in seconds relative to the 'anchor' time.file_ids(array of string) - IDs of files to copy to the container.memory_limit(string) - Optional memory limit for the container. Defaults to "1g".Allowed values: 1g, 4g, 16g, 64g
name(string, required) - Name of the container to create.network_policy(oneOf) - Network access policy for the container.skills(array of object) - An optional list of skills referenced by id or inline data.
SEE ALSO
COPYRIGHT AND LICENSE
Copyright (C) 2023-2026 by Nelson Ferraz
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.14.0 or, at your option, any later version of Perl 5 you may have available.