Skip to content

Commit 10f3a6b

Browse files
committed
OBR-289: Add FloatAtLeast(1) validation for max_calls_per_agent
1 parent 3ee8998 commit 10f3a6b

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

docs/resources/outbound_campaign.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ resource "genesyscloud_outbound_campaign" "campaign2" {
9696
- `dynamic_contact_queueing_settings` (Block List, Max: 1) Settings for dynamic queueing of contacts. If not set, default dynamic contact queue settings will be applied (see [below for nested schema](#nestedblock--dynamic_contact_queueing_settings))
9797
- `dynamic_line_balancing_settings` (Block List, Max: 1) Dynamic line balancing settings. (see [below for nested schema](#nestedblock--dynamic_line_balancing_settings))
9898
- `edge_group_id` (String) The EdgeGroup that will place the calls. Required for all dialing modes except preview.
99-
- `max_calls_per_agent` (Number) The maximum number of calls that can be placed per agent on this campaign. Supports decimal values (e.g., 1.5, 2.3).
99+
- `max_calls_per_agent` (Number) The maximum number of calls that can be placed per agent on this campaign. Must be >= 1. Supports decimal values (e.g., 1.5, 2.3).
100100
- `no_answer_timeout` (Number) How long to wait before dispositioning a call as 'no-answer'. Default 30 seconds. Only applicable to non-preview campaigns.
101101
- `outbound_line_count` (Number) The number of outbound lines to be concurrently dialed. Only applicable to non-preview campaigns; only required for agentless.
102102
- `preview_time_out_seconds` (Number) The number of seconds before a call will be automatically placed on a preview. A value of 0 indicates no automatic placement of calls. Only applicable to preview campaigns.

genesyscloud/outbound_campaign/resource_genesyscloud_outbound_campaign_schema.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -112,9 +112,10 @@ func ResourceOutboundCampaign() *schema.Resource {
112112
Type: schema.TypeFloat,
113113
},
114114
`max_calls_per_agent`: {
115-
Description: `The maximum number of calls that can be placed per agent on this campaign. Supports decimal values (e.g., 1.5, 2.3).`,
116-
Optional: true,
117-
Type: schema.TypeFloat,
115+
Description: `The maximum number of calls that can be placed per agent on this campaign. Must be >= 1. Supports decimal values (e.g., 1.5, 2.3).`,
116+
Optional: true,
117+
Type: schema.TypeFloat,
118+
ValidateFunc: validation.FloatAtLeast(1),
118119
},
119120
`dnc_list_ids`: {
120121
Description: `DncLists for this Campaign to check before placing a call.`,

0 commit comments

Comments
 (0)