new commandref format
This commit is contained in:
parent
49e08e0bf3
commit
32459345cc
@ -403,15 +403,9 @@ sub Matrix_Rename($$) {
|
||||
my ($new,$old) = @_;
|
||||
$data{MATRIX}{"$new"} = $data{MATRIX}{"$old"};
|
||||
$data{MATRIX}{"$old"} = undef;
|
||||
|
||||
$hash->{helper}->{passwdobj}->getRename($newname,$oldname);
|
||||
|
||||
my $nhash = $defs{$new};
|
||||
|
||||
#my $token = Matrix_readToken( $nhash, $old );
|
||||
#Matrix_storeToken( $nhash, $token );
|
||||
|
||||
# remove old token with old name
|
||||
my $index_old = "Matrix_" . $old . "_token";
|
||||
#setKeyValue($index_old, undef);
|
||||
}
|
||||
|
||||
sub Matrix_Get {
|
||||
@ -503,13 +497,13 @@ sub Matrix_Attr {
|
||||
=item summary Provides a Matrix-Chatbot.
|
||||
=item summary_DE Stellt einen Matrix-Chatbot bereit.
|
||||
=begin html
|
||||
<a name="Matrix"></a>
|
||||
<a id="Matrix"></a>
|
||||
<h3>Matrix</h3>
|
||||
<ul>
|
||||
<i>Matrix</i> implements a client to Matrix-Synapse-Servers. It is in a very early development state.
|
||||
<br><br>
|
||||
<a name="Matrixdefine"></a>
|
||||
<b>Define</b>
|
||||
<a id="Matrix-define"></a>
|
||||
<h4>Define</h4>
|
||||
<ul>
|
||||
<code>define <name> <server> <user></code>
|
||||
<br><br>
|
||||
@ -521,8 +515,8 @@ sub Matrix_Attr {
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
<a name="Matrixset"></a>
|
||||
<b>Set</b><br>
|
||||
<a id="Matrix-set"></a>
|
||||
<h4>Set</h4>
|
||||
<ul>
|
||||
<code>set <name> <option> <value></code>
|
||||
<br><br>
|
||||
@ -530,30 +524,39 @@ sub Matrix_Attr {
|
||||
<br><br>
|
||||
Options:
|
||||
<ul>
|
||||
<li><i>password</i><br>
|
||||
<a id="Matrix-set-password"></a>
|
||||
<li><i>password</i><br>
|
||||
Set the password to login</li>
|
||||
<a id="Matrix-set-register"></a>
|
||||
<li><i>register</i><br>
|
||||
without function, do not use this</li>
|
||||
<a id="Matrix-set-login"></a>
|
||||
<li><i>login</i><br>
|
||||
Login to the Matrix-Server and sync endless if poll is set to "1"</li>
|
||||
<a id="Matrix-set-refresh"></a>
|
||||
<li><i>refresh</i><br>
|
||||
If logged in or in state "soft-logout" refresh gets a new access_token and syncs endless if poll is set to "1"</li>
|
||||
<a id="Matrix-set-filter"></a>
|
||||
<li><i>filter</i><br>
|
||||
A Filter must be set for syncing in long poll. This filter is in the moment experimentell and must be set manual to get the coresponding filter_id</li>
|
||||
<a id="Matrix-set-poll"></a>
|
||||
<li><i>poll</i><br>
|
||||
Defaults to "0": Set poll to "1" for starting the sync-loop</li>
|
||||
<a id="Matrix-set-poll.fullstate"></a>
|
||||
<li><i>poll.fullstate</i><br>
|
||||
Defaults to "0": Set poll.fullstate to "1" for getting in the next sync a full state of all rooms</li>
|
||||
<a id="Matrix-set-question.start"></a>
|
||||
<li><i>question.start</i><br>
|
||||
Start a question in the room from reading room. The first answer to the question is logged and ends the question.</li>
|
||||
<a id="Matrix-set-question.end"></a>
|
||||
<li><i>question.end</i><br>
|
||||
Stop a question also it is not answered.</li>
|
||||
</ul>
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
<a name="Matrixget"></a>
|
||||
<b>Get</b><br>
|
||||
<a id="Matrix-get"></a>
|
||||
<h4>Get</h4>
|
||||
<ul>
|
||||
<code>get <name> <option></code>
|
||||
<br><br>
|
||||
@ -561,8 +564,8 @@ sub Matrix_Attr {
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
<a name="Matrixattr"></a>
|
||||
<b>Attributes</b>
|
||||
<a id="Matrix-attr"></a>
|
||||
<h4>Attributes</h4>
|
||||
<ul>
|
||||
<code>attr <name> <attribute> <value></code>
|
||||
<br><br>
|
||||
@ -570,31 +573,37 @@ sub Matrix_Attr {
|
||||
<br><br>
|
||||
Attributes:
|
||||
<ul>
|
||||
<a id="Matrix-attr-MatrixMessage"></a>
|
||||
<li><i>MatrixMessage</i> <room-id><br>
|
||||
Set the room-id to wich messagesare sent.
|
||||
</li>
|
||||
<a id="Matrix-attr-MatrixQuestion_[0..9]"></a>
|
||||
<li><i>MatrixQuestion_[0..9]</i> <room-id><br>
|
||||
Prepared questions.
|
||||
</li>
|
||||
<a id="Matrix-attr-MatrixRoom"></a>
|
||||
<li><i>MatrixRoom</i> <room-id 1> <room-id 2> ...<br>
|
||||
Set the room-id's from wich are messages received.
|
||||
</li>
|
||||
<a id="Matrix-attr-MatrixSender"></a>
|
||||
<li><i>MatrixSender</i> <code><user 1> <user 2> ...</code><br>
|
||||
Set the user's from wich are messages received.<br><br>
|
||||
Example: <code>attr matrix MatrixSender @name:matrix.server @second.name:matrix.server</code><br>
|
||||
</li>
|
||||
</ul>
|
||||
</ul>
|
||||
<a id="Matrix-readings"></a>
|
||||
<h4>Readings</h4>
|
||||
</ul>
|
||||
=end html
|
||||
=begin html_DE
|
||||
<a name="Matrix"></a>
|
||||
<a id="Matrix"></a>
|
||||
<h3>Matrix</h3>
|
||||
<ul>
|
||||
<i>Matrix</i> stellt einen Client für Matrix-Synapse-Server bereit. It is in a very early development state.
|
||||
<br><br>
|
||||
<a name="Matrixdefine"></a>
|
||||
<b>Define</b>
|
||||
<a id="Matrix-define"></a>
|
||||
<h4>Define</h4>
|
||||
<ul>
|
||||
<code>define <name> <server> <user></code>
|
||||
<br><br>
|
||||
@ -605,8 +614,8 @@ sub Matrix_Attr {
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
<a name="Matrixset"></a>
|
||||
<b>Set</b><br>
|
||||
<a name="Matrix-set"></a>
|
||||
<h4>Set</h4>
|
||||
<ul>
|
||||
<code>set <name> <option> <wert></code>
|
||||
<br><br>
|
||||
@ -614,32 +623,41 @@ sub Matrix_Attr {
|
||||
<br><br>
|
||||
Options:
|
||||
<ul>
|
||||
<li><i>password</i><br>
|
||||
<a id="Matrix-set-password"></a>
|
||||
<li><i>password</i><br>
|
||||
Setzt das Passwort zum Login</li>
|
||||
<a id="Matrix-set-register"></a>
|
||||
<li><i>register</i><br>
|
||||
noch ohne Funktion!</li>
|
||||
<a id="Matrix-set-login"></a>
|
||||
<li><i>login</i><br>
|
||||
Login beim Matrix-Server und horche andauernd auf Nachrichten wenn poll auf "1" gesetzt ist</li>
|
||||
<a id="Matrix-set-refresh"></a>
|
||||
<li><i>refresh</i><br>
|
||||
Wenn eingeloggt oder im Zustand "soft-logout" erhält man mit refresh einen neuen access_token. Wenn poll auf "1" gesetzt ist läuft dann wieder der Empfang andauernd.</li>
|
||||
<a id="Matrix-set-filter"></a>
|
||||
<li><i>filter</i><br>
|
||||
Ein Filter muss gesetzt sein um "Longpoll"-Anfragen an den Server schicken zu können. Der Filter muss hier einmalg gesetzt werden um vom Server eine Filter-ID zu erhalten.</li>
|
||||
<a id="Matrix-set-poll"></a>
|
||||
<li><i>poll</i><br>
|
||||
Zunächst "0": Auf "1" startet die Empfangsschleife.</li>
|
||||
<a id="Matrix-set-poll.fullstate"></a>
|
||||
<li><i>poll.fullstate</i><br>
|
||||
Standard ist "0": Wenn poll.fullstate auf "1" gesetzt wird, werden beider nächsten Synchronisation alle Raumeigenschaften neu eingelesen.</li>
|
||||
<a id="Matrix-set-question.start"></a>
|
||||
<li><i>question.start</i><br>
|
||||
Frage in dem Raum des Attributs "MatrixMessage" stellen. Die erste Antwort steht im Reading "answer" und beendet die Frage.<br>
|
||||
Als Wert wird entweder die Nummer einer vorbereiteten Frage übergeben oder eine komplette Frage in der Form<br>
|
||||
<code>Frage:Antwort 1:Antwort 2:....:Antwort n</code></li>
|
||||
<a id="Matrix-set-question.end"></a>
|
||||
<li><i>question.end</i><br>
|
||||
Die gestartete Frage ohne Antwort beenden. Entweder wird ohne Parameter die aktuelle Frage beendet oder mit einer Nachrichten-ID eine "verwaiste" Frage.</li>
|
||||
</ul>
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
<a name="Matrixget"></a>
|
||||
<b>Get</b><br>
|
||||
<a id="Matrix-get"></a>
|
||||
<h4>Get</h4>
|
||||
<ul>
|
||||
<code>get <name> <option></code>
|
||||
<br><br>
|
||||
@ -647,8 +665,8 @@ sub Matrix_Attr {
|
||||
</ul>
|
||||
<br>
|
||||
|
||||
<a name="Matrixattr"></a>
|
||||
<b>Attributes</b>
|
||||
<a id="Matrix-attr"></a>
|
||||
<h4>Attributes</h4>
|
||||
<ul>
|
||||
<code>attr <name> <attribute> <value></code>
|
||||
<br><br>
|
||||
@ -656,22 +674,28 @@ sub Matrix_Attr {
|
||||
<br><br>
|
||||
Attributes:
|
||||
<ul>
|
||||
<a id="Matrix-attr-MatrixMessage"></a>
|
||||
<li><i>MatrixMessage</i> <room-id><br>
|
||||
Setzt die Raum-ID in die alle Nachrichten gesendet werden. Zur Zeit ist nur ein Raum möglich.
|
||||
</li>
|
||||
<li><i>MatrixQuestion_[0..9].</i> <room-id><br>
|
||||
<a id="Matrix-attr-MatrixQuestion_[0..9]"></a>
|
||||
<li><i>MatrixQuestion_[0..9]</i> <room-id><br>
|
||||
Vorbereitete Fragen, die mit set mt question.start 0..9 gestartet werden können.<br>
|
||||
Format der Fragen: <code>Frage:Antwort 1:Antwort 2:....:Antwort n</code>
|
||||
</li>
|
||||
<a id="Matrix-attr-MatrixRoom"></a>
|
||||
<li><i>MatrixRoom</i> <room-id 1> <room-id 2> ...<br>
|
||||
Alle Raum-ID's aus denen Nachrichten empfangen werden.
|
||||
</li>
|
||||
<a id="Matrix-attr-MatrixSender"></a>
|
||||
<li><i>MatrixSender</i> <code><user 1> <user 2> ...</code><br>
|
||||
Alle Personen von denen Nachrichten empfangen werden.<br>
|
||||
Beispiel: <code>attr matrix MatrixSender @name:matrix.server @second.name:matrix.server</code><br>
|
||||
</li>
|
||||
</ul>
|
||||
</ul>
|
||||
<a id="Matrix-readings"></a>
|
||||
<h4>Readings</h4>
|
||||
</ul>
|
||||
=end html_DE
|
||||
=cut
|
||||
|
Loading…
Reference in New Issue
Block a user