Thank you @lfischer !
Best posts made by joana_115
Latest posts made by joana_115
-
RE: Creating objects using the API
Hey @lfischer,
Thank you for your response!
I tried to create the server and associate the IPv4 address, but I can't.
This is my request:{ "version": "2.0", "method": "cmdb.object.create", "params": { "type": "C__OBJTYPE__SERVER", "title": "my little server", "description": "my little server description", "apikey": "---", "language": "en", "categories": { "C__CATG__IP": [ {"net_type": 1}, {"ipv4_assignment": 1}, {"ipv4_address": "192.168.1.13"}, {"primary_hostaddress": "192.168.1.13"} ] } }, "id": 1 }
The 1 for the "net_type" refers to the IPv4 (Internet Protocol v4) in the table isys_net_type, and the 1 for the "ipv4_assignment" refers to DHCP in the table isys_ip_assignment.
I am sorry for not being able to use your suggestion.
What am I doing wrong? -
Creating objects using the API
Hello.
I am trying to create objects using the API (JSON-RPC).
I am using the method cmdb.object.create for that.
However, I cannot send a lot of information about the objects.For example, the template to create a server is:
{
"version": "2.0",
"method": "cmdb.object.create",
"params": {
"type": "C__OBJTYPE__SERVER",
"title": "My little server",
"apikey": "xxx",
"language": "en"
},
"id": 1
}Although, I would like to send information about its IP address for example. I can do that by creating the Server using the UI. Can I also do that using the API?
Can you help me?