Scorum
Public Member Functions | List of all members
scorum::app::login_api Class Reference

The login_api class implements the bottom layer of the RPC API. More...

#include <api.hpp>

Public Member Functions

 login_api (const api_context &ctx)
 
virtual ~login_api ()
 
bool login (const std::string &user, const std::string &password)
 Authenticate to the RPC server. More...
 
fc::api_ptr get_api_by_name (const std::string &api_name) const
 
scorum_version_info get_version ()
 
void on_api_startup ()
 internal method, not exposed via JSON RPC More...
 

Detailed Description

The login_api class implements the bottom layer of the RPC API.

All other APIs must be requested from this API.

Definition at line 201 of file api.hpp.

Constructor & Destructor Documentation

◆ login_api()

scorum::app::login_api::login_api ( const api_context ctx)

Definition at line 50 of file api.cpp.

◆ ~login_api()

scorum::app::login_api::~login_api ( )
virtual

Definition at line 55 of file api.cpp.

Member Function Documentation

◆ get_api_by_name()

fc::api_ptr scorum::app::login_api::get_api_by_name ( const std::string &  api_name) const

Definition at line 102 of file api.cpp.

◆ get_version()

scorum_version_info scorum::app::login_api::get_version ( )

Definition at line 122 of file api.cpp.

◆ login()

bool scorum::app::login_api::login ( const std::string &  user,
const std::string &  password 
)

Authenticate to the RPC server.

Parameters
userUsername to login with
passwordPassword to login with
Returns
True if logged in successfully; false otherwise
Note
This must be called prior to requesting other APIs. Other APIs may not be accessible until the client has sucessfully authenticated.

Definition at line 63 of file api.cpp.

◆ on_api_startup()

void scorum::app::login_api::on_api_startup ( )

internal method, not exposed via JSON RPC

Definition at line 59 of file api.cpp.


The documentation for this class was generated from the following files: