Generates TypeScript code for interacting with Ash resources via Rpc.
Summary
Functions
Formats an endpoint configuration for TypeScript code generation.
Generates a namespace re-export file for the given namespace and actions.
Generates RPC-specific TypeScript content for the multi-file architecture.
Generates per-action schemas for all RPC actions using the given formatter.
The marker comment used to separate generated code from custom code in namespace files. Content below this marker is preserved when regenerating namespace files.
Functions
Formats an endpoint configuration for TypeScript code generation.
Delegates to AshTypescript.Helpers.format_ts_value/1.
Generates a namespace re-export file for the given namespace and actions.
Used by the Orchestrator to generate namespace files with proper import paths.
Generates RPC-specific TypeScript content for the multi-file architecture.
Contains hook types, helper functions, typed queries, and RPC functions.
Types are imported from ash_types.ts via export type * from re-export
and a local import type for types actually referenced in the body.
Parameters
resources_and_actions- List of{resource, action, rpc_action}tuplesopts- Hook configuration options (endpoint overrides, lifecycle hooks)codegen_opts- Additional codegen options::import_paths-%{types: path}for import resolution:otp_app- The OTP application name:all_resources- All resources for typed query generation:shared_type_names- List of type names exported by ash_types.ts (for local import)
Generates per-action schemas for all RPC actions using the given formatter.
Returns a list of schema strings (one per action that has arguments).
These are meant to be passed to SharedSchemaGenerator as :additional_schemas.
The marker comment used to separate generated code from custom code in namespace files. Content below this marker is preserved when regenerating namespace files.