Skip to main content

ScheduleInvokeInput

Arm a one-shot timer that invokes a function after a delay. The target function must be autonomousInvocable, because the timer fires headlessly with no player in the request.

input ScheduleInvokeInput {
appId: BigInt!
functionName: String!
selfContainerId: String!
delayMs: Int!
paramsJson: String
sessionId: String
dedupeKey: String
}

Fields

ScheduleInvokeInput.appId ● BigInt! non-null scalar

The app (tenant).

ScheduleInvokeInput.functionName ● String! non-null scalar

The function to invoke when the timer fires. Must be autonomousInvocable.

ScheduleInvokeInput.selfContainerId ● String! non-null scalar

The 'self' container the delayed invocation runs against. Must belong to the app, and match the function's bound container type when it has one.

ScheduleInvokeInput.delayMs ● Int! non-null scalar

Delay in milliseconds before the timer fires. Must be at least the app's minTimerDelayMs and at most 30 days.

ScheduleInvokeInput.paramsJson ● String scalar

JSON object of parameters passed to the delayed invocation. Defaults to '{}'.

ScheduleInvokeInput.sessionId ● String scalar

Session for the delayed invocation. Defaults to the container's own session.

ScheduleInvokeInput.dedupeKey ● String scalar

Optional app-scoped key. Re-arming the same key replaces the pending timer instead of adding another, which makes "reset the countdown" a single call.

Member Of

gameModelScheduleInvoke mutation