diff --git a/lib/types/tunnelbroker/message-to-device-request-status-types.js b/lib/types/tunnelbroker/message-to-device-request-status-types.js --- a/lib/types/tunnelbroker/message-to-device-request-status-types.js +++ b/lib/types/tunnelbroker/message-to-device-request-status-types.js @@ -18,6 +18,7 @@ type MessageSentSuccessStatus = { +type: 'Success', +data: string }; type MessageSentErrorStatus = { +type: 'Error', +data: Failure }; type MessageSentInvalidRequestStatus = { +type: 'InvalidRequest' }; +type MessageSentUnauthenticatedStatus = { +type: 'Unauthenticated' }; type MessageSentSerializationErrorStatus = { +type: 'SerializationError', +data: string, @@ -38,6 +39,9 @@ data: failureValidator, }), tShape({ type: tString('InvalidRequest') }), + tShape({ + type: tString('Unauthenticated'), + }), tShape({ type: tString('SerializationError'), data: t.String, diff --git a/shared/tunnelbroker_messages/src/messages/message_to_device_request_status.rs b/shared/tunnelbroker_messages/src/messages/message_to_device_request_status.rs --- a/shared/tunnelbroker_messages/src/messages/message_to_device_request_status.rs +++ b/shared/tunnelbroker_messages/src/messages/message_to_device_request_status.rs @@ -9,6 +9,8 @@ pub error: String, } +// NOTE: Keep this in sync with +// lib/types/tunnelbroker/message-to-device-request-status-types.js #[derive(Serialize, Deserialize, PartialEq, Debug)] #[serde(tag = "type", content = "data")] pub enum MessageSentStatus { @@ -29,6 +31,8 @@ SerializationError(String), } +// NOTE: Keep this in sync with +// lib/types/tunnelbroker/message-to-device-request-status-types.js #[derive(Serialize, Deserialize, PartialEq, Debug)] #[serde(tag = "type", rename_all = "camelCase")] pub struct MessageToDeviceRequestStatus {