Interface: QueryDefinition<Ret, Args, Name>
An interface representing a Workflow query definition as returned from defineQuery
Remarks
Args and Ret can be used for parameter type inference in handler functions and WorkflowHandle methods.
Name can optionally be specified with a string literal type to preserve type-level knowledge of the query name.
Type Parameters
Ret
Ret
Args
Args extends any[] = []
Name
Name extends string = string
Properties
[argsBrand]
[argsBrand]:
Args
Virtual type brand to maintain a distinction between QueryDefinition types with different args. This field is not present at run-time.
[retBrand]
[retBrand]:
Ret
Virtual type brand to maintain a distinction between QueryDefinition types with different return types. This field is not present at run-time.
name
name:
Name
type
type:
"query"
typeInfo?
optionaltypeInfo?:PayloadTypeInfo
Type information used to convert Query arguments and results.