Unable to create new pilot - Missing attribute value

Post Reply
ssteiner
Member
Posts: 58
Joined: 05 Feb 2009 09:20

Unable to create new pilot - Missing attribute value

Post by ssteiner » 17 Apr 2019 07:46

I'm trying to create a new Pilot based on an existing one. So I extract the pilot, modify name and number, and submit the whole object back.

here's my template:

Code: Select all

{
	"objectName": "ACD2_Pilot",
	"objectId": "A9890009",
	"attributes": [
		{
			"name": "Cost_Center_Id",
			"value": [
				"255"
			]
		},
		{
			"name": "Pilot_AutABCLocalCall",
			"value": [
				"true"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureAddress",
			"value": [
				"7800"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureGuideDiffNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureGuideNumber",
			"value": [
				"75"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureGuideTimer",
			"value": [
				"1"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureRelease",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureRule",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_AutoClosureActivation",
			"value": [
				"true"
			]
		},
		{
			"name": "Pilot_Connection_Category",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_Directory_Number",
			"value": [
				"A9890009"
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureAddress",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureGuideDiffNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureGuideNumber",
			"value": [
				"74"
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureGuideTimer",
			"value": [
				"1"
			]
		},
		{
			"name": "Pilot_Entity_Nb",
			"value": [
				"199"
			]
		},
		{
			"name": "Pilot_Ext_Cat",
			"value": [
				"2"
			]
		},
		{
			"name": "Pilot_Facility_Category",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingActivation",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingAddress",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingGuideDiffNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingGuideNumber",
			"value": [
				"83"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingGuideTimer",
			"value": [
				"10"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingRule",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_HoldOnGuideNumber",
			"value": [
				"2"
			]
		},
		{
			"name": "Pilot_IdentificationGuideNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_InterGuideNumber",
			"value": [
				"2"
			]
		},
		{
			"name": "Pilot_Langage_Id",
			"value": [
				"German"
			]
		},
		{
			"name": "Pilot_Name",
			"value": [
				"Template PMGR"
			]
		},
		{
			"name": "Pilot_Numan",
			"value": [
				"A9890009"
			]
		},
		{
			"name": "Pilot_Pause_Time",
			"value": [
				"50"
			]
		},
		{
			"name": "Pilot_Prioritytransfer",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_PubRerout",
			"value": [
				"NoRerout"
			]
		},
		{
			"name": "Pilot_RacOnDissuasion",
			"value": [
				"true"
			]
		},
		{
			"name": "Pilot_RestoreRuleData",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_Rg0",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg1",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg10",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg11",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg12",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg13",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg14",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg15",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg16",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg17",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg18",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg19",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg2",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg20",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg21",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg22",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg23",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg24",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg25",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg26",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg27",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg28",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg29",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg3",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg4",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg5",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg6",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg7",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg8",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg9",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Routing_Flag",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_RuleNumber",
			"value": [
				"-1"
			]
		},
		{
			"name": "Pilot_SupTrf.Pil_Para1",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_SupTrf.Pilot_CallQueuingInSupTrf",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_SupTrf.Pilot_Superv_transf",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_TWrapUp",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_TransactionCodeDialling.BusinessCode",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_TransactionCodeDialling.TransactionCodeDiallingDigitNumber",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_TransactionCodeDialling.TransactionCodeDiallingTimer",
			"value": [
				"100"
			]
		},
		{
			"name": "Pilot_Trf_All_Allowed",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_VoiceMail",
			"value": [
				""
			]
		},
		{
			"name": "Robinet_Category",
			"value": [
				"0"
			]
		}
	],
	"objectNames": [
		"ACD2_Primary_Rule_Dir",
		"ACD2_Primary_Rule_Guide",
		"ACD2_TrunkGroup_Limitation"
	]
}
Then I submit this

POST http://srvroxe01.nxodev.intra/api/rest/ ... ACD2_Pilot HTTP/1.1

Code: Select all

{
	"attributes": [
		{
			"name": "Cost_Center_Id",
			"value": [
				"255"
			]
		},
		{
			"name": "Pilot_AutABCLocalCall",
			"value": [
				"true"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureAddress",
			"value": [
				"7800"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureGuideDiffNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureGuideNumber",
			"value": [
				"75"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureGuideTimer",
			"value": [
				"1"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureRelease",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureRule",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_AutoClosureActivation",
			"value": [
				"true"
			]
		},
		{
			"name": "Pilot_Connection_Category",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_Directory_Number",
			"value": [
				"98991234"
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureAddress",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureGuideDiffNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureGuideNumber",
			"value": [
				"74"
			]
		},
		{
			"name": "Pilot_EmerClosure.Pilot_EmerClosureGuideTimer",
			"value": [
				"1"
			]
		},
		{
			"name": "Pilot_Entity_Nb",
			"value": [
				"199"
			]
		},
		{
			"name": "Pilot_Ext_Cat",
			"value": [
				"2"
			]
		},
		{
			"name": "Pilot_Facility_Category",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingActivation",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingAddress",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingGuideDiffNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingGuideNumber",
			"value": [
				"83"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingGuideTimer",
			"value": [
				"10"
			]
		},
		{
			"name": "Pilot_GenForwarding.GenForwardingRule",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_HoldOnGuideNumber",
			"value": [
				"2"
			]
		},
		{
			"name": "Pilot_IdentificationGuideNb",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_InterGuideNumber",
			"value": [
				"2"
			]
		},
		{
			"name": "Pilot_Langage_Id",
			"value": [
				"German"
			]
		},
		{
			"name": "Pilot_Name",
			"value": [
				"PMGR testing"
			]
		},
		{
			"name": "Pilot_Numan",
			"value": [
				"A9890009"
			]
		},
		{
			"name": "Pilot_Pause_Time",
			"value": [
				"50"
			]
		},
		{
			"name": "Pilot_Prioritytransfer",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_PubRerout",
			"value": [
				"NoRerout"
			]
		},
		{
			"name": "Pilot_RacOnDissuasion",
			"value": [
				"true"
			]
		},
		{
			"name": "Pilot_RestoreRuleData",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_Rg0",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg1",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg10",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg11",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg12",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg13",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg14",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg15",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg16",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg17",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg18",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg19",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg2",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg20",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg21",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg22",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg23",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg24",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg25",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg26",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg27",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg28",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg29",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg3",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg4",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg5",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg6",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg7",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg8",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Rg9",
			"value": [
				""
			]
		},
		{
			"name": "Pilot_Routing_Flag",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_RuleNumber",
			"value": [
				"-1"
			]
		},
		{
			"name": "Pilot_SupTrf.Pil_Para1",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_SupTrf.Pilot_CallQueuingInSupTrf",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_SupTrf.Pilot_Superv_transf",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_TWrapUp",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_TransactionCodeDialling.BusinessCode",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_TransactionCodeDialling.TransactionCodeDiallingDigitNumber",
			"value": [
				"0"
			]
		},
		{
			"name": "Pilot_TransactionCodeDialling.TransactionCodeDiallingTimer",
			"value": [
				"100"
			]
		},
		{
			"name": "Pilot_Trf_All_Allowed",
			"value": [
				"false"
			]
		},
		{
			"name": "Pilot_VoiceMail",
			"value": [
				""
			]
		},
		{
			"name": "Robinet_Category",
			"value": [
				"0"
			]
		}
	]
}
The response I'm getting doesn't help at all

Code: Select all

{
	"httpStatus": "BAD_REQUEST",
	"code": 1003,
	"helpMessage": "No result corresponds to the requested parameter(s).",
	"type": "NOT_FOUND",
	"innerMessage": "Missing attribute value",
	"canRetry": true
}
Any idea what's going on here?

@edit: in an attempt to figure out where things go wrong, I tried creating just a basic pilot with three attributes

Code: Select all

{
	"attributes": [
		{
			"name": "Pilot_Directory_Number",
			"value": [
				"98991234"
			]
		},
		{
			"name": "Pilot_Name",
			"value": [
				"PMGR testing"
			]
		},
		{
			"name": "Pilot_AutoClosure.AutoClosureAddress",
			"value": [
				"7800"
			]
		}
	]
}
The result I'm getting is different but again not very useful:

Code: Select all

{
	"httpStatus": "BAD_REQUEST",
	"code": 1006,
	"helpMessage": "Request parameters are not correct. Please fix the problem and resend the request.",
	"type": "BAD_PARAMETER",
	"innerMessage": "Parsing error",
	"canRetry": true
}
And creating an even simpler object

Code: Select all

{
	"attributes": [
		{
			"name": "Pilot_Directory_Number",
			"value": [
				"98991234"
			]
		},
		{
			"name": "Pilot_Name",
			"value": [
				"PMGR testing"
			]
		}
	]
}
fails with this error

Code: Select all

{
	"httpStatus": "BAD_REQUEST",
	"code": 1003,
	"helpMessage": "No result corresponds to the requested parameter(s).",
	"type": "NOT_FOUND",
	"innerMessage": "Missing attribute value",
	"canRetry": true
}
looking at the WBM interface, I see it supplies just the Pilot_Directory_Number when creating a new pilot from scratch, so I don't understand why my basic request doesn't work.

Plassard
Member
Posts: 4
Joined: 27 Mar 2019 03:30

Re: Unable to create new pilot - Missing attribute value

Post by Plassard » 18 Apr 2019 05:54

This issue will be fixed with CRO2G-60 in O2G version 14.0.000.031

ssteiner
Member
Posts: 58
Joined: 05 Feb 2009 09:20

Re: Unable to create new pilot - Missing attribute value

Post by ssteiner » 24 Apr 2019 04:44

any ETA on this? I have a project that's supposed to go live any day now and that depends on this.

ssteiner
Member
Posts: 58
Joined: 05 Feb 2009 09:20

Re: Unable to create new pilot - Missing attribute value

Post by ssteiner » 02 May 2019 10:28

So I installed version 32 which is supposed to fix this.

But, Houston we have another problem now:

Prior to creating the Pilot, I'm extracting existing pilots using this

GET /api/rest/1.0/pbxs/143/instances/Application_Configuration/1/ACD2/1/ACD2_Pilot?filter=Pilot_Name==Template*&attributes=Pilot_Directory_Number,Pilot_Name,Pilot_RuleNumber

Works fine on 029.

On 032, same get

GET /api/rest/1.0/pbxs/143/instances/Application_Configuration/1/ACD2/1/ACD2_Pilot?filter=Pilot_Name==Template*&attributes=Pilot_Directory_Number,Pilot_Name,Pilot_RuleNumber

Which returns

{
"httpStatus": "BAD_REQUEST",
"code": 1006,
"helpMessage": "Request parameters are not correct. Please fix the problem and resend the request.",
"type": "BAD_PARAMETER",
"innerMessage": "Parsing error",
"canRetry": true
}

So, I managed to find the cause: my usage of the attributes... using just the filter is okay, but start using the attributes tag. and poof.

yblanchard
Member
Posts: 25
Joined: 03 Dec 2018 06:32

Re: Unable to create new pilot - Missing attribute value

Post by yblanchard » 14 May 2019 09:54

bloody regression brought by a previous correction on empty default attribute value, which is should be set only for a set operation, not for a get operation.
Will be fixed in next one

Post Reply

Return to “O2G”