AshTypescript.Rpc.Codegen.TypeGenerators.ResultTypes
(ash_typescript v0.17.3)
Copy Markdown
View Source
Generates TypeScript result types for RPC actions.
Result types define the shape of data returned from RPC actions, including:
- Field selection types (which fields can be selected)
- Inferred result types (what the result looks like given a field selection)
- Pagination wrapper types (for paginated results)
- Metadata integration (for actions that return metadata)
Summary
Functions
Generates the TypeScript result type for an RPC action.
Functions
Generates the TypeScript result type for an RPC action.
The generated type includes:
- A Fields type (what fields can be selected)
- An InferResult type (what the result will be given a field selection)
- Optional metadata types (if metadata is enabled)
- Optional pagination types (if the action supports pagination)
Parameters
resource- The Ash resourceaction- The Ash actionrpc_action- The RPC action configurationrpc_action_name- The snake_case name of the RPC action
Returns
A string containing the TypeScript type definitions for this action's result.