From 00f97636a22b28de26ffaafd674e1014374210e0 Mon Sep 17 00:00:00 2001 From: Travis Ralston Date: Sun, 26 May 2019 22:08:04 -0600 Subject: [PATCH 1/2] Add missing reason property to m.call.hangup Fixes https://github.com/matrix-org/matrix-doc/issues/1689 --- .../client_server/newsfragments/2031.clarification | 1 + event-schemas/schema/m.call.hangup | 10 +++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 changelogs/client_server/newsfragments/2031.clarification diff --git a/changelogs/client_server/newsfragments/2031.clarification b/changelogs/client_server/newsfragments/2031.clarification new file mode 100644 index 000000000..9bed3bcc0 --- /dev/null +++ b/changelogs/client_server/newsfragments/2031.clarification @@ -0,0 +1 @@ +Add missing ``reason`` to ``m.call.hangup``. diff --git a/event-schemas/schema/m.call.hangup b/event-schemas/schema/m.call.hangup index 9d45d179a..0328e03a3 100644 --- a/event-schemas/schema/m.call.hangup +++ b/event-schemas/schema/m.call.hangup @@ -1,6 +1,6 @@ { "type": "object", - "description": "Sent by either party to signal their termination of the call. This can be sent either once the call has has been established or before to abort the call.", + "description": "Sent by either party to signal their termination of the call. This can be sent either once the call has has been established or before to abort the call. The ``reason`` for the hangup is expected to be provided when there was an error in the call negotiation, such as ``ice_failed`` for when ICE negotiation fails or ``invite_timeout`` for when the other party did not answer in time.", "allOf": [{ "$ref": "core-event-schema/room_event.yaml" }], @@ -15,6 +15,14 @@ "version": { "type": "integer", "description": "The version of the VoIP specification this message adheres to. This specification is version 0." + }, + "reason": { + "type": "string", + "description": "Optional error reason for the hangup. This should not be provided when the user naturally ends or rejects the call.", + "enum": [ + "ice_failed", + "invite_timeout" + ] } }, "required": ["call_id", "version"] From 229893589a30f21560cf55fac00d0112fa041413 Mon Sep 17 00:00:00 2001 From: Travis Ralston Date: Mon, 27 May 2019 21:18:04 -0600 Subject: [PATCH 2/2] Move wording for reason definitions --- event-schemas/schema/m.call.hangup | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/event-schemas/schema/m.call.hangup b/event-schemas/schema/m.call.hangup index 0328e03a3..c0478f5a7 100644 --- a/event-schemas/schema/m.call.hangup +++ b/event-schemas/schema/m.call.hangup @@ -1,6 +1,6 @@ { "type": "object", - "description": "Sent by either party to signal their termination of the call. This can be sent either once the call has has been established or before to abort the call. The ``reason`` for the hangup is expected to be provided when there was an error in the call negotiation, such as ``ice_failed`` for when ICE negotiation fails or ``invite_timeout`` for when the other party did not answer in time.", + "description": "Sent by either party to signal their termination of the call. This can be sent either once the call has has been established or before to abort the call.", "allOf": [{ "$ref": "core-event-schema/room_event.yaml" }], @@ -18,7 +18,7 @@ }, "reason": { "type": "string", - "description": "Optional error reason for the hangup. This should not be provided when the user naturally ends or rejects the call.", + "description": "Optional error reason for the hangup. This should not be provided when the user naturally ends or rejects the call. When there was an error in the call negotiation, this should be ``ice_failed`` for when ICE negotiation fails or ``invite_timeout`` for when the other party did not answer in time.", "enum": [ "ice_failed", "invite_timeout"