forked from legastero/stanza
-
Notifications
You must be signed in to change notification settings - Fork 0
/
xep0092.ts
34 lines (29 loc) · 918 Bytes
/
xep0092.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
// ====================================================================
// XEP-0092: Software Version
// --------------------------------------------------------------------
// Source: https://xmpp.org/extensions/xep-0092.html
// Version: 1.1 (2007-02-15)
// ====================================================================
import { childText, DefinitionOptions } from '../jxt';
import { NS_VERSION } from '../Namespaces';
declare module './' {
export interface IQPayload {
softwareVersion?: SoftwareVersion;
}
}
export interface SoftwareVersion {
name?: string;
version?: string;
os?: string;
}
const Protocol: DefinitionOptions = {
element: 'query',
fields: {
name: childText(null, 'name'),
os: childText(null, 'os'),
version: childText(null, 'version')
},
namespace: NS_VERSION,
path: 'iq.softwareVersion'
};
export default Protocol;