[api] move some functions in the action models