Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sdk/communication/Azure.Communication.JobRouter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ Now, we register a worker to receive work from that queue, with a label of `Some
Response<RouterWorker> worker = await routerClient.CreateWorkerAsync(
new CreateWorkerOptions(workerId: "worker-1", totalCapacity: 1)
{
QueueIds = { [queue.Value.Id] = new RouterQueueAssignment() },
QueueAssignments = { [queue.Value.Id] = new RouterQueueAssignment() },
Labels = { ["Some-Skill"] = new LabelValue(11) },
ChannelConfigurations = { ["my-channel"] = new ChannelConfiguration(1) },
AvailableForOffers = true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public CreateJobOptions(string jobId, string channelId, string queueId) { }
public string JobId { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Labels { get { throw null; } }
public Azure.Communication.JobRouter.JobMatchingMode MatchingMode { get { throw null; } set { } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.Models.RouterJobNote> Notes { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterJobNote> Notes { get { throw null; } }
public int? Priority { get { throw null; } set { } }
public string QueueId { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterWorkerSelector> RequestedWorkerSelectors { get { throw null; } }
Expand All @@ -101,7 +101,7 @@ public CreateJobWithClassificationPolicyOptions(string jobId, string channelId,
public string JobId { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Labels { get { throw null; } }
public Azure.Communication.JobRouter.JobMatchingMode MatchingMode { get { throw null; } set { } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.Models.RouterJobNote> Notes { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterJobNote> Notes { get { throw null; } }
public int? Priority { get { throw null; } set { } }
public string QueueId { get { throw null; } set { } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterWorkerSelector> RequestedWorkerSelectors { get { throw null; } }
Expand All @@ -122,7 +122,7 @@ public CreateWorkerOptions(string workerId, int totalCapacity) { }
public bool AvailableForOffers { get { throw null; } set { } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.ChannelConfiguration> ChannelConfigurations { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Labels { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.RouterQueueAssignment> QueueIds { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.RouterQueueAssignment> QueueAssignments { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Tags { get { throw null; } }
public int TotalCapacity { get { throw null; } }
public string WorkerId { get { throw null; } }
Expand Down Expand Up @@ -385,23 +385,15 @@ public enum ServiceVersion
public static bool operator !=(Azure.Communication.JobRouter.LabelOperator left, Azure.Communication.JobRouter.LabelOperator right) { throw null; }
public override string ToString() { throw null; }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public readonly partial struct LabelValue : System.IEquatable<Azure.Communication.JobRouter.LabelValue>
public partial class LabelValue : System.IEquatable<Azure.Communication.JobRouter.LabelValue>
{
private readonly object _dummy;
private readonly int _dummyPrimitive;
public LabelValue(bool value) { throw null; }
public LabelValue(char value) { throw null; }
public LabelValue(decimal value) { throw null; }
public LabelValue(double value) { throw null; }
public LabelValue(short value) { throw null; }
public LabelValue(int value) { throw null; }
public LabelValue(long value) { throw null; }
public LabelValue(float value) { throw null; }
public LabelValue(string value) { throw null; }
public LabelValue(ushort value) { throw null; }
public LabelValue(uint value) { throw null; }
public LabelValue(ulong value) { throw null; }
public LabelValue(bool value) { }
public LabelValue(decimal value) { }
public LabelValue(double value) { }
public LabelValue(int value) { }
public LabelValue(long value) { }
public LabelValue(float value) { }
public LabelValue(string value) { }
public object Value { get { throw null; } }
public bool Equals(Azure.Communication.JobRouter.LabelValue other) { throw null; }
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
Expand Down Expand Up @@ -472,6 +464,12 @@ public partial class RoundRobinMode : Azure.Communication.JobRouter.Distribution
{
public RoundRobinMode() { }
}
public partial class RouterJobNote
{
public RouterJobNote() { }
public System.DateTimeOffset? AddedAt { get { throw null; } set { } }
public string Message { get { throw null; } set { } }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public readonly partial struct RouterJobStatusSelector : System.IEquatable<Azure.Communication.JobRouter.RouterJobStatusSelector>
{
Expand Down Expand Up @@ -580,15 +578,8 @@ public RuleEngineWorkerSelectorAttachment(Azure.Communication.JobRouter.RouterRu
}
public partial class ScheduleAndSuspendMode
{
public ScheduleAndSuspendMode() { }
public System.DateTimeOffset? ScheduleAt { get { throw null; } set { } }
}
public partial class ScoringRuleOptions
{
internal ScoringRuleOptions() { }
public bool? AllowScoringBatchOfWorkers { get { throw null; } set { } }
public int? BatchSize { get { throw null; } set { } }
public bool? DescendingOrder { get { throw null; } set { } }
public ScheduleAndSuspendMode(System.DateTimeOffset scheduleAt) { }
public System.DateTimeOffset ScheduleAt { get { throw null; } }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public readonly partial struct ScoringRuleParameterSelector : System.IEquatable<Azure.Communication.JobRouter.ScoringRuleParameterSelector>
Expand Down Expand Up @@ -668,7 +659,7 @@ public UpdateJobOptions(string jobId) { }
public string JobId { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Labels { get { throw null; } }
public Azure.Communication.JobRouter.JobMatchingMode MatchingMode { get { throw null; } set { } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.Models.RouterJobNote> Notes { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterJobNote> Notes { get { throw null; } }
public int? Priority { get { throw null; } set { } }
public string QueueId { get { throw null; } set { } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterWorkerSelector> RequestedWorkerSelectors { get { throw null; } }
Expand All @@ -689,7 +680,7 @@ public UpdateWorkerOptions(string workerId) { }
public bool? AvailableForOffers { get { throw null; } set { } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.ChannelConfiguration?> ChannelConfigurations { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Labels { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.RouterQueueAssignment?> QueueIds { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.RouterQueueAssignment?> QueueAssignments { get { throw null; } }
public System.Collections.Generic.IDictionary<string, Azure.Communication.JobRouter.LabelValue> Tags { get { throw null; } }
public int? TotalCapacity { get { throw null; } set { } }
public string WorkerId { get { throw null; } }
Expand Down Expand Up @@ -802,7 +793,7 @@ internal RouterJob() { }
public string Id { get { throw null; } }
public System.Collections.Generic.Dictionary<string, Azure.Communication.JobRouter.LabelValue> Labels { get { throw null; } }
public Azure.Communication.JobRouter.JobMatchingMode MatchingMode { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.Models.RouterJobNote> Notes { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterJobNote> Notes { get { throw null; } }
public int? Priority { get { throw null; } }
public string QueueId { get { throw null; } }
public System.Collections.Generic.List<Azure.Communication.JobRouter.RouterWorkerSelector> RequestedWorkerSelectors { get { throw null; } }
Expand All @@ -825,12 +816,6 @@ internal RouterJobItem() { }
public Azure.ETag ETag { get { throw null; } }
public Azure.Communication.JobRouter.Models.RouterJob Job { get { throw null; } }
}
public partial class RouterJobNote
{
public RouterJobNote() { }
public System.DateTimeOffset? AddedAt { get { throw null; } set { } }
public string Message { get { throw null; } set { } }
}
public partial class RouterJobOffer
{
internal RouterJobOffer() { }
Expand Down Expand Up @@ -947,6 +932,13 @@ internal RouterWorkerItem() { }
public static bool operator !=(Azure.Communication.JobRouter.Models.RouterWorkerSelectorStatus left, Azure.Communication.JobRouter.Models.RouterWorkerSelectorStatus right) { throw null; }
public override string ToString() { throw null; }
}
public partial class ScoringRuleOptions
{
internal ScoringRuleOptions() { }
public bool? AllowScoringBatchOfWorkers { get { throw null; } set { } }
public int? BatchSize { get { throw null; } set { } }
public bool? DescendingOrder { get { throw null; } set { } }
}
public partial class UnassignJobResult
{
internal UnassignJobResult() { }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ Response<RouterWorker> worker = routerClient.CreateWorker(
{
AvailableForOffers = true, // if a worker is not registered, no offer will be issued
ChannelConfigurations = { ["general"] = new ChannelConfiguration(100), },
QueueIds = { [jobQueue.Value.Id] = new RouterQueueAssignment(), },
QueueAssignments = { [jobQueue.Value.Id] = new RouterQueueAssignment(), },
});

// now that we have a registered worker, we can expect offer to be sent to the worker
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ Response<RouterWorker> worker = await routerClient.CreateWorkerAsync(
{
AvailableForOffers = true, // if a worker is not registered, no offer will be issued
ChannelConfigurations = { ["general"] = new ChannelConfiguration(100), },
QueueIds = { [jobQueue.Value.Id] = new RouterQueueAssignment(), },
QueueAssignments = { [jobQueue.Value.Id] = new RouterQueueAssignment(), },
});

// now that we have a registered worker, we can expect offer to be sent to the worker
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ string routerWorkerId = "my-router-worker";
Response<RouterWorker> worker = routerClient.CreateWorker(
new CreateWorkerOptions(workerId: routerWorkerId, totalCapacity: 100)
{
QueueIds =
QueueAssignments =
{
["worker-q-1"] = new RouterQueueAssignment(),
["worker-q-2"] = new RouterQueueAssignment()
Expand Down Expand Up @@ -75,7 +75,7 @@ Console.WriteLine($"Worker associated with queues: {queriedWorker.Value.QueueAss
Response<RouterWorker> updateWorker = routerClient.UpdateWorker(
new UpdateWorkerOptions(routerWorkerId)
{
QueueIds = { ["worker-q-3"] = new RouterQueueAssignment() },
QueueAssignments = { ["worker-q-3"] = new RouterQueueAssignment() },
ChannelConfigurations = { ["WebChatEscalated"] = new ChannelConfiguration(50), },
Labels =
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Response<RouterWorker> worker = await routerClient.CreateWorkerAsync(
workerId: routerWorkerId,
totalCapacity: 100)
{
QueueIds =
QueueAssignments =
{
["worker-q-1"] = new RouterQueueAssignment(),
["worker-q-2"] = new RouterQueueAssignment()
Expand Down Expand Up @@ -77,7 +77,7 @@ Console.WriteLine($"Worker associated with queues: {queriedWorker.Value.QueueAss
Response<RouterWorker> updateWorker = await routerClient.UpdateWorkerAsync(
new UpdateWorkerOptions(routerWorkerId)
{
QueueIds = { ["worker-q-3"] = new RouterQueueAssignment() },
QueueAssignments = { ["worker-q-3"] = new RouterQueueAssignment() },
ChannelConfigurations = { ["WebChatEscalated"] = new ChannelConfiguration(50), },
Labels =
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Register a worker associated with the queue that was just created. We will assig
Response<RouterWorker> worker = routerClient.CreateWorker(
new CreateWorkerOptions(workerId: "worker-1", totalCapacity: 1)
{
QueueIds = { [queue.Value.Id] = new RouterQueueAssignment() },
QueueAssignments = { [queue.Value.Id] = new RouterQueueAssignment() },
Labels = { ["Some-Skill"] = new LabelValue(11) },
ChannelConfigurations = { ["my-channel"] = new ChannelConfiguration(1) },
AvailableForOffers = true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Register a worker associated with the queue that was just created. We will assig
Response<RouterWorker> worker = await routerClient.CreateWorkerAsync(
new CreateWorkerOptions(workerId: "worker-1", totalCapacity: 1)
{
QueueIds = { [queue.Value.Id] = new RouterQueueAssignment() },
QueueAssignments = { [queue.Value.Id] = new RouterQueueAssignment() },
Labels = { ["Some-Skill"] = new LabelValue(11) },
ChannelConfigurations = { ["my-channel"] = new ChannelConfiguration(1) },
AvailableForOffers = true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ Response<RouterWorker> worker1 = await routerClient.CreateWorkerAsync(
["Geo"] = new LabelValue("NA"),
["Skill_English_Lvl"] = new LabelValue(7),
}, // attaching labels associated with worker
QueueIds = { [queueId] = new RouterQueueAssignment() }
QueueAssignments = { [queueId] = new RouterQueueAssignment() }
});

string workerId2 = "worker-id-2";
Expand All @@ -111,7 +111,7 @@ Response<RouterWorker> worker2 = await routerClient.CreateWorkerAsync(
AvailableForOffers = true, // registering worker at the time of creation
ChannelConfigurations = { ["general"] = new ChannelConfiguration(10), },
Labels = { ["Skill_English_Lvl"] = new LabelValue(7) }, // attaching labels associated with worker
QueueIds = { [queueId] = new RouterQueueAssignment() }
QueueAssignments = { [queueId] = new RouterQueueAssignment() }
});


Expand Down Expand Up @@ -230,7 +230,7 @@ Response<RouterWorker> worker1 = await routerClient.CreateWorkerAsync(
["Geo"] = new LabelValue("NA"),
["Skill_English_Lvl"] = new LabelValue(7)
}, // attaching labels associated with worker
QueueIds = { [queueId] = new RouterQueueAssignment() }
QueueAssignments = { [queueId] = new RouterQueueAssignment() }
});

string workerId2 = "worker-id-2";
Expand All @@ -245,7 +245,7 @@ Response<RouterWorker> worker2 = await routerClient.CreateWorkerAsync(
["Geo"] = new LabelValue("NA"),
["Skill_English_Lvl"] = new LabelValue(7)
}, // attaching labels associated with worker
QueueIds = { [queueId] = new RouterQueueAssignment() }
QueueAssignments = { [queueId] = new RouterQueueAssignment() }
});


Expand Down Expand Up @@ -373,7 +373,7 @@ Response<RouterWorker> worker1 = await routerClient.CreateWorkerAsync(
["Dept"] = new LabelValue("O365"),
["Skill_English_Lvl"] = new LabelValue(10),
}, // attaching labels associated with worker
QueueIds = { [queueId] = new RouterQueueAssignment() }
QueueAssignments = { [queueId] = new RouterQueueAssignment() }
});

string workerId2 = "worker-id-2";
Expand All @@ -391,7 +391,7 @@ Response<RouterWorker> worker2 = await routerClient.CreateWorkerAsync(
["Dept"] = new LabelValue("Xbox"),
["Skill_English_Lvl"] = new LabelValue(10),
}, // attaching labels associated with worker
QueueIds = { [queueId] = new RouterQueueAssignment() }
QueueAssignments = { [queueId] = new RouterQueueAssignment() }
});


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ Response<RouterWorker> worker1 = await routerClient.CreateWorkerAsync(
AvailableForOffers = true,
ChannelConfigurations = { [channelId] = new ChannelConfiguration(10), },
Labels = { ["HandleEscalation"] = new LabelValue(true), ["IT_Support"] = new LabelValue(true) },
QueueIds = { [jobQueueId] = new RouterQueueAssignment(), }
QueueAssignments = { [jobQueueId] = new RouterQueueAssignment(), }
});

// Worker 2 cannot handle escalation
Expand All @@ -62,7 +62,7 @@ Response<RouterWorker> worker2 = await routerClient.CreateWorkerAsync(
AvailableForOffers = true,
ChannelConfigurations = { [channelId] = new ChannelConfiguration(10), },
Labels = { ["IT_Support"] = new LabelValue(true), },
QueueIds = { [jobQueueId] = new RouterQueueAssignment(), },
QueueAssignments = { [jobQueueId] = new RouterQueueAssignment(), },
});

// Create job
Expand Down Expand Up @@ -271,7 +271,7 @@ string workerId1 = "worker-Id-1";
Response<RouterWorker> worker1 = await routerClient.CreateWorkerAsync(
options: new CreateWorkerOptions(workerId: workerId1, totalCapacity: 100)
{
QueueIds = { [queueId] = new RouterQueueAssignment(), },
QueueAssignments = { [queueId] = new RouterQueueAssignment(), },
Labels =
{
["HighPrioritySupport"] = new LabelValue(true),
Expand All @@ -290,7 +290,7 @@ string workerId2 = "worker-Id-2";
Response<RouterWorker> worker2 = await routerClient.CreateWorkerAsync(
options: new CreateWorkerOptions(workerId: workerId2, totalCapacity: 100)
{
QueueIds = { [queueId] = new RouterQueueAssignment(), },
QueueAssignments = { [queueId] = new RouterQueueAssignment(), },
Labels =
{
["HighPrioritySupport"] = new LabelValue(true),
Expand All @@ -312,7 +312,7 @@ Dictionary<string, LabelValue> worker3Labels = new Dictionary<string, LabelValue
Response<RouterWorker> worker3 = await routerClient.CreateWorkerAsync(
options: new CreateWorkerOptions(workerId: workerId3, totalCapacity: 100)
{
QueueIds = { [queueId] = new RouterQueueAssignment(), },
QueueAssignments = { [queueId] = new RouterQueueAssignment(), },
Labels =
{
["HighPrioritySupport"] = new LabelValue(false),
Expand Down
Loading