Foreman Discovered host Provisioning from Non admin user not working

Hi team,

I have just created non admin user in foreman and given the below permission,
view_architectures
view_domains
view_environments
“view_discovered_hosts,
provision_discovered_hosts,
ipmi_boot_hosts, power_hosts”
view_hostgroups
“view_locations,
assign_locations”
view_media
view_operatingsystems
“view_organizations,
assign_organizations”
view_subnets
Creating the host from hammer then I am getting below error
Could not create the host:
Resource discovered_host not found by id ‘82’

and here is log

2019-09-20T09:41:23 [I|app|d6f41e12]   Parameters: {"location_id"=>2, "organization_id"=>1, "discovered_host"=>{"environment_id"=>1, "architecture_id"=>1, "domain_id"=>1, "operatingsystem_id"=>1, "medium_id"=>10, "subnet_id"=>1, "hostgroup_id"=>9, "build"=>true, "provision_method"=>"build", "pxe_loader"=>"PXELinux BIOS", "ptable_id"=>"104", "root_pass"=>"[FILTERED]"}, "apiv"=>"v2", "id"=>"82"}
2019-09-20T09:41:23 [I|app|d6f41e12] Current user set to bharat (regular)
2019-09-20T09:41:23 [I|app|d6f41e12] ActiveRecord::RecordNotFound (ActiveRecord::RecordNotFound)
2019-09-20T09:41:23 [I|app|d6f41e12]   Rendering api/v2/errors/not_found.json.rabl within api/v2/layouts/error_layout
2019-09-20T09:41:23 [I|app|d6f41e12]   Rendered api/v2/errors/not_found.json.rabl within api/v2/layouts/error_layout (1.4ms)
2019-09-20T09:41:23 [I|app|d6f41e12] Completed 404 Not Found in 89ms (Views: 3.0ms | ActiveRecord: 21.9ms)

Thanks

just wanted to know is there anything else I need to provide in the permission list.

Please use Roles we ship with Foreman, there should be couple of discovery roles and these are tested to work. Otherwise you will need to find the correct permissions one by one, depends on your hostgroup.