Skip to content

Read a FunctionCall

GET
/apis/nodus.dev/v1/namespaces/{namespace}/functioncalls/{name}
curl --request GET \
--url https://example.com/apis/nodus.dev/v1/namespaces/example/functioncalls/example
namespace
required
string

The project.

name
required
string

The object’s name.

OK

Media type application/json

FunctionCall is one invocation of a Function. .remote() and .spawn() create one; .map() creates one per input in batches of up to 1,000. Calls are kept 7 days after they end.

object
apiVersion
string
kind
string
metadata
object
annotations
object
key
additional properties
string
creationTimestamp
string
deletionGracePeriodSeconds
integer format: int64
deletionTimestamp
string
finalizers
Array<string>
nullable
generateName
string
generation
integer format: int64
labels
object
key
additional properties
string
managedFields
Array<object>
nullable
object
apiVersion
string
fieldsType
string
fieldsV1
object
key
additional properties
manager
string
operation
string
subresource
string
time
string
name
string
namespace
string
ownerReferences
Array<object>
nullable
object
apiVersion
required
string
blockOwnerDeletion
boolean
controller
boolean
kind
required
string
name
required
string
uid
required
string
resourceVersion
string
selfLink
string
uid
string
spec
required

FunctionCallSpec describes a call. Everything but state is immutable.

object
function
required

Function names a Function in the project.

string
input
required

Payload is an argument or a result: inline bytes of at most 64 KiB, or a content-addressed blob.

object
blob

Blob is the sha256: reference of a payload above 64 KiB, uploaded through /blobs/v1.

string
encoding

Encoding is Pickle (cloudpickle, the SDK) or JSON.

string
inline

Inline is the payload, base64 on the wire, at most 64 KiB. Exactly one of inline and blob.

string format: base64
sha256

SHA256 is the hex digest of the payload, set on results.

string
mapId

MapID groups the calls of one .map(); the server adds the label nodus.dev/map.

string
mapIndex

MapIndex is the call’s position in its .map().

integer format: int32
session

Session is the caller’s session id; claims take turns between sessions so no caller starves.

string
state

State is Running (the default) or the cancel state.

string
timeout

Timeout is the limit of this call, at most the Function’s (default the Function’s).

string
status

FunctionCallStatus is what Nodus observed about a call.

object
completionTime

CompletionTime is when the call ended.

string
conditions

Conditions are Funded and Scheduled.

Array<object>
nullable
object
lastTransitionTime
required
string
message
required
string
observedGeneration
integer format: int64
reason
required
string
status
required
string
type
required
string
costUSD

CostUSD is the worker time attributed to the call, whole seconds at the Function’s per-call rate.

string
error

RemoteError is an exception the function raised.

object
message
required

Message is the exception message, scrubbed.

string
traceback

Traceback is the formatted traceback, scrubbed.

string
type
required

Type is the exception’s qualified name; the SDK re-raises it when importable.

string
message

Message explains the phase in a sentence.

string
phase

Phase is Queued, Running, Recovering, Succeeded, Failed or one of the two cancel phases.

string
reason

Reason is RemoteError, DeadlineExceeded, RecoveryLimitExceeded, FunctionDeleted or the cancel reason.

string
recoveries

Recoveries counts the re-dispatches after a worker loss.

integer format: int32
result

Payload is an argument or a result: inline bytes of at most 64 KiB, or a content-addressed blob.

object
blob

Blob is the sha256: reference of a payload above 64 KiB, uploaded through /blobs/v1.

string
encoding

Encoding is Pickle (cloudpickle, the SDK) or JSON.

string
inline

Inline is the payload, base64 on the wire, at most 64 KiB. Exactly one of inline and blob.

string format: base64
sha256

SHA256 is the hex digest of the payload, set on results.

string
retries

Retries counts the exception retries used.

integer format: int32
startTime

StartTime is when a worker last started the call.

string
worker

FunctionCallWorker names the worker attempt a call is bound to.

object
attempt
required

Attempt is the worker attempt id.

string
epoch
required

Epoch is the attempt’s epoch; a result from another epoch is fenced.

integer format: int64
Example generated
{
"apiVersion": "example",
"kind": "example",
"metadata": {
"annotations": {
"additionalProperty": "example"
},
"creationTimestamp": "example",
"deletionGracePeriodSeconds": 1,
"deletionTimestamp": "example",
"finalizers": [
"example"
],
"generateName": "example",
"generation": 1,
"labels": {
"additionalProperty": "example"
},
"managedFields": [
{
"apiVersion": "example",
"fieldsType": "example",
"fieldsV1": {
"additionalProperty": "example"
},
"manager": "example",
"operation": "example",
"subresource": "example",
"time": "example"
}
],
"name": "example",
"namespace": "example",
"ownerReferences": [
{
"apiVersion": "example",
"blockOwnerDeletion": true,
"controller": true,
"kind": "example",
"name": "example",
"uid": "example"
}
],
"resourceVersion": "example",
"selfLink": "example",
"uid": "example"
},
"spec": {
"function": "example",
"input": {
"blob": "example",
"encoding": "example",
"inline": "example",
"sha256": "example"
},
"mapId": "example",
"mapIndex": 1,
"session": "example",
"state": "example",
"timeout": "example"
},
"status": {
"completionTime": "example",
"conditions": [
{
"lastTransitionTime": "example",
"message": "example",
"observedGeneration": 1,
"reason": "example",
"status": "example",
"type": "example"
}
],
"costUSD": "example",
"error": {
"message": "example",
"traceback": "example",
"type": "example"
},
"message": "example",
"phase": "example",
"reason": "example",
"recoveries": 1,
"result": {
"blob": "example",
"encoding": "example",
"inline": "example",
"sha256": "example"
},
"retries": 1,
"startTime": "example",
"worker": {
"attempt": "example",
"epoch": 1
}
}
}

An error: a metav1.Status whose reason is a registered code.

Media type application/json

Status is the error body of every API response: a Kubernetes metav1.Status (so kubectl and client-go understand it) plus three top-level extensions that those clients ignore (ADR-028).

object
apiVersion
string
code
integer format: int32
details
object
causes
Array<object>
nullable
object
field
string
message
string
reason
string
group
string
kind
string
name
string
retryAfterSeconds
integer format: int32
uid
string
docs

Docs is the URL of the code’s docs page.

string
fix

Fix says what to do next, for example a CLI command or the field to change.

string
kind
string
message
string
metadata
object
continue
string
remainingItemCount
integer format: int64
resourceVersion
string
selfLink
string
shardInfo
object
selector
required
string
reason
string
requestId

RequestID identifies the request in logs and support tickets.

string
status
string
Example generated
{
"apiVersion": "example",
"code": 1,
"details": {
"causes": [
{
"field": "example",
"message": "example",
"reason": "example"
}
],
"group": "example",
"kind": "example",
"name": "example",
"retryAfterSeconds": 1,
"uid": "example"
},
"docs": "example",
"fix": "example",
"kind": "example",
"message": "example",
"metadata": {
"continue": "example",
"remainingItemCount": 1,
"resourceVersion": "example",
"selfLink": "example",
"shardInfo": {
"selector": "example"
}
},
"reason": "example",
"requestId": "example",
"status": "example"
}