I have tried sending "CreateElement" by Json but the response is 500 Internal Error.
Does DataMiner support Json format of this method?
The response is as belows.
{
"Message": "型 'System.String' のオブジェクトを型 'System.Int32[]' のオブジェクトに変換できません",
"StackTrace": " 場所 System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeInternal(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject)\r\n 場所 System.Web.Script.Serialization.ObjectConverter.ConvertObjectToTypeMain(Object o, Type type, JavaScriptSerializer serializer, Boolean throwOnError, Object& convertedObject)\r\n 場所 System.Web.Script.Services.WebServiceMethodData.StrongTypeParameters(IDictionary`2 rawParams)\r\n 場所 System.Web.Script.Services.WebServiceMethodData.CallMethodFromRawParams(Object target, IDictionary`2 parameters)\r\n 場所 System.Web.Script.Services.RestHandler.InvokeMethod(HttpContext context, WebServiceMethodData methodData, IDictionary`2 rawParams)\r\n 場所 System.Web.Script.Services.RestHandler.ExecuteWebServiceCall(HttpContext context, WebServiceMethodData methodData)",
"ExceptionType": "System.InvalidOperationException"
}
The following is the request I send to DataMiner.
{
"connection":"10df979a-6bbd-412b-9182-66a38f0ec4eb",
"dmaID":"24202",
"viewIDs":"154",
"configuration":{
"Name":"APItest",
"Description":"",
"ProtocolName":"Microsoft Platform",
"protocolVersion":"5.0.0.2",
"Type":"Information Platform",
"AlarmTemplate":"",
"TrendTemplate":"",
"ForceAgent":"",
"IPAddress":"192.168.0.1",
"IPAddressMask":"255.255.255.0",
"CreateDVEs":"",
"EnableSnmpAgent":"",
"EnableTelnet":"",
"IsHidden":"",
"IsReadOnly":"",
"IsReplication":"",
"KeepOnline":"",
"SnmpReadCommunityString":"",
"SnmpWriteCommunityString":"",
"TimeoutTime":"1500",
"SlowPoll":"",
"State":"Stopped",
"Ports": {
"DMAElementBasePortInfo":{
"ElementTimeoutTime":"",
"TimeoutTime":"",
"Retries":""
}
}
}
}
Hello Tomoya,
Please, also consider using the IDP solution to help you to create/manage elements on your system.
Thank you. I understand that.