Files
matrix-quotes-bot/node_modules/matrix-js-sdk/lib/matrixrtc/membershipData/rtc.d.ts
unfunny dfe4cc537f init
2026-09-13 00:29:11 -04:00

36 lines
1.3 KiB
TypeScript

import type { IContent } from "../../models/event.ts";
import type { RelationType } from "../../types.ts";
import { type RtcSlotApplicationContent, type Transport } from "../types.ts";
/**
* Represents the current form of MSC4143, which uses sticky events to store membership.
*/
export interface RtcMembershipData {
"slot_id": string;
"member": {
user_id: string;
device_id: string;
id: string;
};
"m.relates_to"?: {
event_id: string;
rel_type: RelationType.Reference;
};
"application": RtcSlotApplicationContent;
"transports": {
published: Transport[];
can_subscribe: string[];
};
"versions": string[];
"msc4354_sticky_key"?: string;
"sticky_key"?: string;
}
/**
* Validates that `data` matches the format expected by MSC4143.
* @param data The event content.
* @param sender The sender of the event.
* @returns true if `data` is valid RtcMembershipData
* @throws {MatrixRTCMembershipParseError} if the content is not valid
*/
export declare const checkRtcMembershipData: (data: IContent, sender: string) => data is RtcMembershipData;
export declare function computeRtcIdentityRaw(userId: string, deviceId: string, memberId: string): Promise<string>;
//# sourceMappingURL=rtc.d.ts.map