General introspection helpers for Ash applications.
Use Ash.Info.mermaid_overview(otp_app) to generate a mermaid chart of the application's domains and resources.
This offers a high level view, but will not include information from extensions. Use resource_report/2
for a detailed report of a resource.
Use Ash.Info.mermaid_overview(otp_app, type: :entity_relationship) to get a simplified entity relationship diagram.
Use Ash.Info.domains_and_resources(otp_app) to get a map where the keys are the domains, and the value is the list
of resources for that domain.
Summary
Functions
Returns a list of all defined extensions in the application.
Returns a map where the keys are the domains, and the value is the list of resources for that domain.
Returns a list of extensions in use by all the domains and resources in the given application.
Generate an %Ash.Info.Manifest{} describing the application's public Ash
surface — reachable resources, named types, and action entrypoints.
Generate a mermaid chart of the application's domains and resources.
Functions
@spec defined_extensions(app :: Application.app()) :: [module()]
Returns a list of all defined extensions in the application.
Speed
This function will load all modules in the application, which can be slow. Do not call this function in time sensitive code paths, It is intended for mix tasks, introspection, and debugging purposes.
@spec domains(atom()) :: [Ash.Domain.t()]
@spec domains_and_resources(atom()) :: %{ required(Ash.Domain.t()) => [Ash.Resource.t()] }
Returns a map where the keys are the domains, and the value is the list of resources for that domain.
@spec extensions_in_use(app :: Application.app()) :: [module()]
Returns a list of extensions in use by all the domains and resources in the given application.
@spec manifest(keyword()) :: {:ok, Ash.Info.Manifest.t()} | {:error, term()}
Generate an %Ash.Info.Manifest{} describing the application's public Ash
surface — reachable resources, named types, and action entrypoints.
Delegates to Ash.Info.Manifest.generate/1. See that module's docs for the
full list of options (action filtering, overrides, private-field visibility).
Generate a mermaid chart of the application's domains and resources.
This offers a high level view, but will not include information from extensions.