Skip to content

Commit fab5ef6

Browse files
committed
Update Calls simulcast API definition after feedback on 2025-02-27
1 parent 72d94d4 commit fab5ef6

File tree

1 file changed

+41
-33
lines changed

1 file changed

+41
-33
lines changed

public/calls/static/calls-api-2024-05-21.yaml

Lines changed: 41 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
openapi: 3.0.0
22
info:
33
title: Cloudflare Calls API
4-
version: "1.1"
4+
version: "1.0"
55
externalDocs:
66
description: Find out more about Cloudflare Calls
77
url: https://developers.cloudflare.com/calls/
@@ -135,33 +135,16 @@ paths:
135135
sessionId: 2a45361d5fd7cc14eface0587c276c94
136136
trackName: generated-audio
137137
kind: "audio"
138-
simulcast_track:
139-
description: Share a track with simulcast configuration
138+
remote_track_with_simulcast:
139+
description: Pull a remote track with simulcast preferences
140140
value:
141-
sessionDescription:
142-
sdp: |
143-
v=0
144-
o=- 0 0 IN IP4 127.0.0.1
145-
s=-
146-
c=IN IP4 127.0.0.1
147-
t=0 0
148-
m=audio 4000 RTP/AVP 111
149-
a=rtpmap:111 OPUS/48000/2
150-
m=video 4002 RTP/AVP 96
151-
a=rtpmap:96 VP8/90000
152-
a=simulcast:send f;h;q
153-
a=rid:f send
154-
a=rid:h send
155-
a=rid:q send
156-
...
157-
type: offer
158141
tracks:
159-
- location: local
142+
- location: remote
143+
sessionId: 2a45361d5fd7cc14eface0587c276c94
160144
trackName: simulcast-video-track
161-
mid: "1"
162145
simulcast:
163146
preferredRid: "h"
164-
preferredRidNotAvailable: "leastbandwidth"
147+
fallbackStrategy: "leastBandwidth"
165148
security:
166149
- secret: []
167150
parameters:
@@ -229,6 +212,31 @@ paths:
229212
a=rtpmap:96 VP8/90000
230213
...
231214
type: offer
215+
remote_tracks_with_simulcast:
216+
value:
217+
requiresImmediateRenegotiation: true
218+
tracks:
219+
- sessionId: 2a45361d5fd7cc14eface0587c276c94
220+
trackName: simulcast-video-track
221+
mid: "5"
222+
simulcast:
223+
preferredRid: "h"
224+
fallbackStrategy: "leastBandwidth"
225+
sessionDescription:
226+
sdp: |
227+
v=0
228+
o=- 0 0 IN IP4 127.0.0.1
229+
s=-
230+
c=IN IP4 127.0.0.1
231+
t=0 0
232+
m=video 4002 RTP/AVP 96
233+
a=rtpmap:96 VP8/90000
234+
a=simulcast:recv f;h;q
235+
a=rid:f recv
236+
a=rid:h recv
237+
a=rid:q recv
238+
...
239+
type: offer
232240
/apps/{appId}/sessions/{sessionId}/renegotiate:
233241
put:
234242
tags:
@@ -351,8 +359,8 @@ paths:
351359
requiresImmediateRenegotiation: false
352360
tracks:
353361
- mid: "7"
354-
/apps/{appId}/sessions/{sessionId}/tracks/change:
355-
post:
362+
/apps/{appId}/sessions/{sessionId}/tracks/update:
363+
put:
356364
tags:
357365
- Change tracks
358366
summary: Change tracks by reusing existing transceivers
@@ -382,7 +390,7 @@ paths:
382390
mid: "8"
383391
simulcast:
384392
preferredRid: "h"
385-
preferredRidNotAvailable: "leastbandwidth"
393+
fallbackStrategy: "leastBandwidth"
386394
security:
387395
- secret: []
388396
parameters:
@@ -409,7 +417,7 @@ paths:
409417
content:
410418
application/json:
411419
schema:
412-
$ref: "#/components/schemas/ChangeTracksResponse"
420+
$ref: "#/components/schemas/UpdateTracksResponse"
413421
examples:
414422
success:
415423
value:
@@ -510,14 +518,14 @@ components:
510518
preferredRid:
511519
type: string
512520
description: Preferred RID (Resolution ID) for simulcast streams
513-
preferredRidNotAvailable:
521+
fallbackStrategy:
514522
type: string
515523
enum:
516-
- leastbandwidth
524+
- auto
525+
- leastBandwidth
517526
- none
518-
- error
519-
default: leastbandwidth
520-
description: Fallback strategy when preferred RID is not available anymore from the remote peer
527+
default: auto
528+
description: General fallback strategy when any constraint (like preferredRid, minWidth, maxBandwidth, etc.) cannot be met. 'auto' will select the best quality possible within constraints.
521529
CloseTrackObject:
522530
type: object
523531
properties:
@@ -660,7 +668,7 @@ components:
660668
description: Map of track IDs to track objects for changing tracks
661669
sessionDescription:
662670
$ref: "#/components/schemas/SessionDescription"
663-
ChangeTracksResponse:
671+
UpdateTracksResponse:
664672
type: object
665673
properties:
666674
errorCode:

0 commit comments

Comments
 (0)