Ash FrameworkAF
Ash Framework3y ago
15 replies
roberts.gulans

How to create organization after user creation.

Ideally it would create organization for user after registration, but if user comes from invitation (to specific organization) than it does not create new one.

No functionality is created yet, im not sure, how to even approach this.

In user resource there isnt even actions for create. Apparently its definition happens somewhere in i suppose.

  authentication do
    api Domain.Accounts

    strategies do
      password :password do
        identity_field :email
        sign_in_tokens_enabled? true
      end
    end

    tokens do
      enabled? true
      token_resource Domain.Accounts.Token
      signing_secret Application.compile_env(:domain, DomainWeb.Endpoint)[:secret_key_base]
    end
  end


Sorry if i ask noob questions, i find docs rather confusing.
Was this page helpful?