Project

General

Profile

Bug #9352

Regression of API host creation bug #7989

Added by Emil Flink over 7 years ago. Updated over 7 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
API
Target version:
-
Difficulty:
Triaged:
No
Bugzilla link:
Pull request:
Fixed in Releases:
Found in Releases:

Description

After upgrading from 1.6.x to 1.7.2 I am facing the exact same issue as described in bug #7989.

Trying to create a host returns error:
"operatingsystem_id is not allowed as nested parameter for hosts. Allowed parameters are hostgroup_id, location_id, organization_id, environment_id"

If any further information is helpful please let me know.

History

#1 Updated by Emil Flink over 7 years ago

Sorry, apparently my POST request was actually incorrect but correct enough to pass in old versions of Foreman.

I sent my data as: { key: value, key2: value }

When I should have sent: {'host': { key: value, key2: value } }

Also available in: Atom PDF