aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/registration_tokens.cpp
diff options
context:
space:
mode:
authorAlexey Rusakov <Kitsune-Ral@users.sf.net>2022-05-31 18:24:53 +0200
committerAlexey Rusakov <Kitsune-Ral@users.sf.net>2022-05-31 18:25:37 +0200
commit42811660094c88a4a1bfa8bd8ace5f4b148c246a (patch)
tree36c7c05f16f3643eaabec75d3e231c1e6bf2a61d /lib/csapi/registration_tokens.cpp
parentfed831820965ad5654317d5e7df18c23fa75de20 (diff)
downloadlibquotient-42811660094c88a4a1bfa8bd8ace5f4b148c246a.tar.gz
libquotient-42811660094c88a4a1bfa8bd8ace5f4b148c246a.zip
Regenerate API files (FTBFS; see the next commit)
Diffstat (limited to 'lib/csapi/registration_tokens.cpp')
-rw-r--r--lib/csapi/registration_tokens.cpp33
1 files changed, 33 insertions, 0 deletions
diff --git a/lib/csapi/registration_tokens.cpp b/lib/csapi/registration_tokens.cpp
new file mode 100644
index 00000000..9c1f0587
--- /dev/null
+++ b/lib/csapi/registration_tokens.cpp
@@ -0,0 +1,33 @@
+/******************************************************************************
+ * THIS FILE IS GENERATED - ANY EDITS WILL BE OVERWRITTEN
+ */
+
+#include "registration_tokens.h"
+
+using namespace Quotient;
+
+auto queryToRegistrationTokenValidity(const QString& token)
+{
+ QUrlQuery _q;
+ addParam<>(_q, QStringLiteral("token"), token);
+ return _q;
+}
+
+QUrl RegistrationTokenValidityJob::makeRequestUrl(QUrl baseUrl,
+ const QString& token)
+{
+ return BaseJob::makeRequestUrl(
+ std::move(baseUrl),
+ makePath("/_matrix/client/v1",
+ "/register/m.login.registration_token/validity"),
+ queryToRegistrationTokenValidity(token));
+}
+
+RegistrationTokenValidityJob::RegistrationTokenValidityJob(const QString& token)
+ : BaseJob(HttpVerb::Get, QStringLiteral("RegistrationTokenValidityJob"),
+ makePath("/_matrix/client/v1",
+ "/register/m.login.registration_token/validity"),
+ queryToRegistrationTokenValidity(token), {}, false)
+{
+ addExpectedKey("valid");
+}