Skip to content

computers.pauseComputer

POST
/v1/computers/{computerId}/pause
curl --request POST \
--url https://example.com/v1/computers/example/pause \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "commandKey": "example" }'

Accepts a command to pause a Computer and returns its execution receipt. The provider keeps its files. E2B also keeps its memory and running programs.

computerId
required
string
>= 1 characters <= 128 characters
Media typeapplication/json
object
commandKey
required
string
>= 1 characters <= 128 characters

Example generated

{
"commandKey": "example"
}

Success

Media typeapplication/json
object
executionId
required
string
>= 1 characters <= 128 characters
commandKey
required
string
>= 1 characters <= 128 characters
sequence
required
integer
<= 9007199254740991

Example generated

{
"executionId": "example",
"commandKey": "example",
"sequence": 1
}

ComputerInvalid | OrganizationRequired

Media typeapplication/json
Any of:
object
_tag
required
string
Allowed values: ComputerInvalid
message
required
string

Example

{
"_tag": "ComputerInvalid"
}

AuthenticationRequired

Media typeapplication/json
object
_tag
required
string
Allowed values: AuthenticationRequired

Example

{
"_tag": "AuthenticationRequired"
}

@nmnmcc/ability/Authorizer/Forbidden | ExecutionForbidden | MembershipRequired | ForbiddenOrigin

Media typeapplication/json
Any of:
object
_tag
required
string
Allowed values: Forbidden
action
required
string
kind
required
string
field
string
reason
string

Example

{
"_tag": "Forbidden"
}

ComputerNotFound | ComputerPathNotFound | ComputerSessionNotFound | ComputerProviderNotFound | PairingInvalid | ExecutionNotFound

Media typeapplication/json
Any of:
object
_tag
required
string
Allowed values: ComputerNotFound
id
required
string

Example

{
"_tag": "ComputerNotFound"
}

@nmnmcc/ability/Authorizer/Pending | ComputerProviderInUse | ComputerConflict | ComputerUnsupported | ComputerNotReady | ExecutionConflict | ExecutionKeyConflict

Media typeapplication/json
Any of:
object
_tag
required
string
Allowed values: Pending
ticket
required
string
reason
string

Example

{
"_tag": "Pending"
}

RateLimited

Media typeapplication/json
object
_tag
required
string
Allowed values: RateLimited
retryAfterSeconds
required
integer
>= -9007199254740991 <= 9007199254740991

Example

{
"_tag": "RateLimited"
}

ComputerProviderFailed | ComputerExecutionFailed

Media typeapplication/json
Any of:
object
_tag
required
string
Allowed values: ComputerProviderFailed
message
required
string

Example

{
"_tag": "ComputerProviderFailed"
}

ComputersUnavailable | ExecutionUnavailable | AuthenticationUnavailable | RequestFailed

Media typeapplication/json
Any of:
object
_tag
required
string
Allowed values: PolicyUnavailable

Example

{
"_tag": "PolicyUnavailable"
}