python-five9 icon indicating copy to clipboard operation
python-five9 copied to clipboard

createOutboundCampaign returns error

Open himea-saito opened this issue 3 years ago • 2 comments

When running class AdminWebService.createOutboundCampaign as follows:

client.configuration.createOutboundCampaign({'name': 'Test'})

I get the following error:

zeep.exceptions.Fault: "prompt for queue timeout" is required, but is "null"

I've tested with various variables, including prompt, maxQueueTime, callWrapup, dialNumberOnTimeout. Unfortunately none of these seem to be the variable that Five9 is looking for.

I'm unable to find this missing value in any documentation related to this project or Five9's documentation - at this point I'm stumped how to get around it.

himea-saito avatar Jan 27 '22 00:01 himea-saito

I just stumbled onto this comment, having recently hit the same issue myself (though I'm using Five9's API directly). Five9's documentation is poor, and the error responses from their API's aren't much better.

To get createOutboundCampaign to work correctly, I had to add actionOnQueueExpiration and maxQueueTime to the request payload:

outbound_campaign = {
	'type' : 'OUTBOUND',
	'name' : 'Test OB',
	'maxQueueTime' : {
		'seconds' : 1,
		'minutes' : 0,
		'hours' : 0,
		'days' : 0,
	},
	'actionOnQueueExpiration' : {
		'actionType' : 'DROP_CALL',
	},
}

client.service.createOutboundCampaign(outbound_campaign)

jplackey avatar Jun 01 '22 14:06 jplackey

I just stumbled onto this comment, having recently hit the same issue myself (though I'm using Five9's API directly). Five9's documentation is poor, and the error responses from their API's aren't much better.

To get createOutboundCampaign to work correctly, I had to add actionOnQueueExpiration and maxQueueTime to the request payload:

outbound_campaign = {
	'type' : 'OUTBOUND',
	'name' : 'Test OB',
	'maxQueueTime' : {
		'seconds' : 1,
		'minutes' : 0,
		'hours' : 0,
		'days' : 0,
	},
	'actionOnQueueExpiration' : {
		'actionType' : 'DROP_CALL',
	},
}

client.service.createOutboundCampaign(outbound_campaign)

This is awesome, thank you!

himea-saito avatar Jun 02 '22 05:06 himea-saito