Skip to content

Commit 96b926e

Browse files
Merge pull request #259199 from williamzhao87/patch-1
Update router-quickstart-javascript.md
2 parents 6b12907 + 3e24f96 commit 96b926e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

articles/communication-services/quickstarts/router/includes/router-quickstart-javascript.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ let worker = await client.path("/routing/workers/{workerId}", "worker-1").patch(
138138
capacity: 1,
139139
queues: [queue.body.id],
140140
labels: { "Some-Skill": 11 },
141-
channels: [ { channelId: "voice", capacityCostPerJob: 1 } ],
141+
channels: [{ channelId: "voice", capacityCostPerJob: 1 }],
142142
availableForOffers: true
143143
},
144144
contentType: "application/merge-patch+json"
@@ -181,7 +181,7 @@ console.log(`Worker ${worker.body.id} has completed job ${accept.body.jobId}`);
181181
Once the worker is ready to take on new jobs, the worker should close the job. Optionally, the worker can provide a disposition code to indicate the outcome of the job.
182182

183183
```javascript
184-
await client.path("/routing/jobs/{jobId}/assignments/{assignmentId}:complete", accept.body.jobId, accept.assignmentId).post({
184+
await client.path("/routing/jobs/{jobId}/assignments/{assignmentId}:close", accept.body.jobId, accept.body.assignmentId).post({
185185
body: { dispositionCode: "Resolved" }
186186
});
187187
console.log(`Worker ${worker.body.id} has closed job ${accept.body.jobId}`);

0 commit comments

Comments
 (0)