Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F7889205
auth_data.hpp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
auth_data.hpp
View Options
/******************************************************************************
* THIS FILE IS GENERATED - ANY EDITS WILL BE OVERWRITTEN
*/
#pragma once
#include
"types.hpp"
namespace
Kazv
::
Api
{
/// Used by clients to submit authentication information to the interactive-authentication API
struct
AuthenticationData
{
/// The login type that the client is attempting to complete.
std
::
string
type
;
/// The value of the session key given by the homeserver.
std
::
optional
<
std
::
string
>
session
;
/// Keys dependent on the login type
immer
::
map
<
std
::
string
,
JsonWrap
>
authInfo
;
};
}
namespace
nlohmann
{
using
namespace
Kazv
;
using
namespace
Kazv
::
Api
;
template
<>
struct
adl_serializer
<
AuthenticationData
>
{
static
void
to_json
(
json
&
jo
,
const
AuthenticationData
&
pod
)
{
if
(
!
jo
.
is_object
())
{
jo
=
json
::
object
();
}
addPropertyMapToJson
(
jo
,
pod
.
authInfo
);
jo
[
"type"
s
]
=
pod
.
type
;
addToJsonIfNeeded
(
jo
,
"session"
s
,
pod
.
session
);
}
static
void
from_json
(
const
json
&
jo
,
AuthenticationData
&
result
)
{
if
(
jo
.
contains
(
"type"
s
))
{
result
.
type
=
jo
.
at
(
"type"
s
);
}
if
(
jo
.
contains
(
"session"
s
))
{
result
.
session
=
jo
.
at
(
"session"
s
);
}
result
.
authInfo
=
jo
;
}
};
}
namespace
Kazv
::
Api
{
}
// namespace Kazv::Api
File Metadata
Details
Attached
Mime Type
text/x-c++
Expires
Thu, Oct 2, 2:24 AM (10 h, 59 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
478920
Default Alt Text
auth_data.hpp (1 KB)
Attached To
Mode
rL libkazv
Attached
Detach File
Event Timeline
Log In to Comment