Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mtxclient
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
mtxclient
Commits
387b940c
Verified
Commit
387b940c
authored
2 years ago
by
Nicolas Werner
Browse files
Options
Downloads
Patches
Plain Diff
Properly document some requests
parent
a1b7b81c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#3903
failed
2 years ago
Stage: build
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
include/mtx/requests.hpp
+11
-0
11 additions, 0 deletions
include/mtx/requests.hpp
with
11 additions
and
0 deletions
include/mtx/requests.hpp
+
11
−
0
View file @
387b940c
...
...
@@ -280,13 +280,18 @@ struct PublicRooms
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
PublicRooms
&
request
);
};
//! An empty response.
///
/// Some endpoints return this on success.
struct
Empty
{
friend
inline
void
to_json
(
nlohmann
::
json
&
,
const
Empty
&
)
{}
};
//! A successfull logout.
using
Logout
=
Empty
;
//! A signed onetime key. Usually curve25519.
struct
SignedOneTimeKey
{
//! Required. The unpadded Base64-encoded 32-byte Curve25519 public key.
...
...
@@ -301,6 +306,7 @@ struct SignedOneTimeKey
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
SignedOneTimeKey
&
);
};
//! Upload a mix of device, one time and fallback keys.
struct
UploadKeys
{
//! Identity keys for the device.
...
...
@@ -328,8 +334,10 @@ struct UploadKeys
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
UploadKeys
&
);
};
//! The default timeout for a download.
constexpr
uint64_t
DEFAULT_DOWNLOAD_TIMEOUT
=
10UL
*
1000
;
// 10 seconds
//! Query the keys of devices of specific users.
struct
QueryKeys
{
//! The time (in milliseconds) to wait when downloading keys from remote servers.
...
...
@@ -348,6 +356,7 @@ struct QueryKeys
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
QueryKeys
&
);
};
//! Claim onetime keys of devices of specific users.
struct
ClaimKeys
{
//! The time (in milliseconds) to wait when downloading keys from remote servers.
...
...
@@ -358,6 +367,7 @@ struct ClaimKeys
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
ClaimKeys
&
request
);
};
//! Upload new signatures for a device or cross-signing key.
struct
KeySignaturesUpload
{
//! map from user_id to either a map of device id to DeviceKey with new signatures or the
...
...
@@ -385,6 +395,7 @@ struct DeviceSigningUpload
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
DeviceSigningUpload
&
req
);
};
//! Information about a pusher.
struct
PusherData
{
//! Required if `kind` is http. The URL to use to send notifications to.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment