Skip to content

Latest commit

 

History

History
3798 lines (2525 loc) · 68.7 KB

File metadata and controls

3798 lines (2525 loc) · 68.7 KB

freehackquest-libclient-web-js

Automatically generated by fhq-server.

  • Version: v0.2.47
  • Date: 2022-01-01 07:29:32

Include script dist/freehackquest-libclient-web-js.js Example connect:

fhq.bind('server', function(data) { console.log('server', data)})
fhq.bind('notify', function(data) { console.log('notify', data)})
fhq.bind('chat', function(data) { console.log('chat', data)})
fhq.bind('connected', function(data) { console.log('connected', data)})
fhq.bind('reconnecting', function(data) { console.log('reconnecting', data)})
fhq.bind('disconnected', function(data) { console.log('disconnected', data)})
fhq.bind('broken', function(data) { console.log('broken', data)})
fhq.bind('userdata', function(data) { console.log('userdata', data)})
fhq.bind('connected', function(data) { console.log('connected', data)})
// connect
fhq.init({'baseUrl': 'ws://localhost:1234/'})
// disconnect
fhq.deinit()
addhint - Method add hint to quest

addhint

Method add hint to quest

Access: unauthorized - no, user - no, admin - yes

Input params

  • questid - integer, required; quest id
  • hint - string, required; hint text

example call method

fhq.addhint({
    "questid": 0,
    "hint": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
answerlist - Return user answers list

answerlist

Return user answers list

Access: unauthorized - no, user - no, admin - yes

Input params

  • page - integer, required; Number of page
  • onpage - integer, required; How much rows on page
  • questid - integer, optional; Filter for questid
  • userid - integer, optional; Filter for userid

example call method

fhq.answerlist({
    "page": 0,
    "onpage": 10,
    "questid": 0,
    "userid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chat_latest_messages - Method will be send chat message and it sent to another users

chat_latest_messages

Method will be send chat message and it sent to another users

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.chat_latest_messages({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chat_send_message - Method will be send chat message and it sent to another users

chat_send_message

Method will be send chat message and it sent to another users

Access: unauthorized - no, user - yes, admin - yes

Input params

  • type - string, required; Type
  • message - string, required; Message

example call method

fhq.chat_send_message({
    "type": "",
    "message": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_add_to_black_list - Add user to black list

chats_add_to_black_list

Add user to black list

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_add_to_black_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_add_to_chat - Add user to some chat

chats_add_to_chat

Add user to some chat

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_add_to_chat({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_change_owner - Change owner of the chat

chats_change_owner

Change owner of the chat

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_change_owner({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_create_group_chat - Create group chat

chats_create_group_chat

Create group chat

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_create_group_chat({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_delete_from_black_list - Delete user from black list

chats_delete_from_black_list

Delete user from black list

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_delete_from_black_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_delete_from_chat - Delete user from chat

chats_delete_from_chat

Delete user from chat

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_delete_from_chat({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_dialogs_list - Show list of dialogs

chats_dialogs_list

Show list of dialogs

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.chats_dialogs_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_message_delete - Delete message from chat

chats_message_delete

Delete message from chat

Access: unauthorized - no, user - yes, admin - yes

Input params

  • message_id - integer, required; Message id for remove

example call method

fhq.chats_message_delete({
    "message_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_message_edit - Edit message

chats_message_edit

Edit message

Access: unauthorized - no, user - yes, admin - yes

Input params

  • message_id - integer, required; Message id
  • message_new - string, required; New message

example call method

fhq.chats_message_edit({
    "message_id": 0,
    "message_new": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_message_read - Get all messages in chat

chats_message_read

Get all messages in chat

Access: unauthorized - no, user - yes, admin - yes

Input params

  • chat - string, required; Chat for reading messages

example call method

fhq.chats_message_read({
    "chat": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
chats_message_send - Method will be send chat message and it sent to another users

chats_message_send

Method will be send chat message and it sent to another users

Access: unauthorized - no, user - yes, admin - yes

Input params

  • chat - string, required; Chat for sending a message
  • message - string, required; Message

example call method

fhq.chats_message_send({
    "chat": "",
    "message": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_add_record - Adds a new article with the specified name, content, and id.

classbook_add_record

Adds a new article with the specified name, content, and id.

Access: unauthorized - no, user - no, admin - yes

Input params

  • parentid - integer, required; pareintid for classbook article
  • name - string, required; name of article
  • content - string, required; content of article
  • uuid - string, optional; uuid of article
  • ordered - integer, optional; order of article

example call method

fhq.classbook_add_record({
    "parentid": 0,
    "name": "",
    "content": "",
    "uuid": "",
    "ordered": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_delete_record - Delete a article with a given classbookid

classbook_delete_record

Delete a article with a given classbookid

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbookid - integer, required; id for classbook article

example call method

fhq.classbook_delete_record({
    "classbookid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_export - Export classbook's articles to html or markdown, optionally in zip archive.

classbook_export

Export classbook's articles to html or markdown, optionally in zip archive.

Access: unauthorized - no, user - yes, admin - yes

Input params

  • output - string, required; The output file format
  • lang - string, required; The output file format
  • zip - boolean, optional; Zipping the output

example call method

fhq.classbook_export({
    "output": "",
    "lang": "",
    "zip": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_info - Return name and content, langs, path classbook article with a given id

classbook_info

Return name and content, langs, path classbook article with a given id

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • classbookid - integer, required; id for the classbook article
  • lang - string, optional; Set lang for the article

example call method

fhq.classbook_info({
    "classbookid": 0,
    "lang": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_list - Return list of classbook articles

classbook_list

Return list of classbook articles

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • parentid - integer, required; parentid for classbook articles
  • lang - string, optional; lang for classbook articles
  • search - string, optional; Search string for classbook articles

example call method

fhq.classbook_list({
    "parentid": 0,
    "lang": "",
    "search": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_localization_add_record - Add a new article localization for the English version

classbook_localization_add_record

Add a new article localization for the English version

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbookid - integer, required; Classbookid for article localization
  • lang - string, required; Language
  • name - string, required; Article name
  • content - string, required; The content of the article

example call method

fhq.classbook_localization_add_record({
    "classbookid": 0,
    "lang": "",
    "name": "",
    "content": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_localization_delete_record - Delete an article localization

classbook_localization_delete_record

Delete an article localization

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbook_localizationid - integer, required; Localization id

example call method

fhq.classbook_localization_delete_record({
    "classbook_localizationid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_localization_info - Find and display localization for an article by classbookid

classbook_localization_info

Find and display localization for an article by classbookid

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbook_localizationid - integer, required; Localization id

example call method

fhq.classbook_localization_info({
    "classbook_localizationid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_localization_update_record - Update table with localization by classbookid

classbook_localization_update_record

Update table with localization by classbookid

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbook_localizationid - integer, required; Localization id
  • name - string, required; Article name
  • content - string, required; The content of the article

example call method

fhq.classbook_localization_update_record({
    "classbook_localizationid": 0,
    "name": "",
    "content": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_propasal_approve - Approve updating requests

classbook_propasal_approve

Approve updating requests

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbook_proposal_id - integer, required; Proposal id

example call method

fhq.classbook_propasal_approve({
    "classbook_proposal_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_propasal_prepare_merge_record - Prepare to merge updating requests

classbook_propasal_prepare_merge_record

Prepare to merge updating requests

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbook_proposal_id - integer, required; Proposal id

example call method

fhq.classbook_propasal_prepare_merge_record({
    "classbook_proposal_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_propasal_update - Approve updating requests

classbook_propasal_update

Approve updating requests

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbook_proposal_id - integer, required; Proposal id
  • content - string, required; new content

example call method

fhq.classbook_propasal_update({
    "classbook_proposal_id": 0,
    "content": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_proposal_add_record - Propose an update of article

classbook_proposal_add_record

Propose an update of article

Access: unauthorized - no, user - yes, admin - yes

Input params

  • classbookid - integer, required; Classbookid for an article
  • lang - string, required; Language
  • name - string, required; Article name
  • content - string, required; The content of the article

example call method

fhq.classbook_proposal_add_record({
    "classbookid": 0,
    "lang": "",
    "name": "",
    "content": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_proposal_delete_record - Delete a proposal of updating an article

classbook_proposal_delete_record

Delete a proposal of updating an article

Access: unauthorized - no, user - yes, admin - yes

Input params

  • classbook_proposal_id - integer, required; Proposal id

example call method

fhq.classbook_proposal_delete_record({
    "classbook_proposal_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_proposal_info - Find and display all proposal data by id

classbook_proposal_info

Find and display all proposal data by id

Access: unauthorized - no, user - yes, admin - yes

Input params

  • classbook_proposal_id - integer, required; Proposal id

example call method

fhq.classbook_proposal_info({
    "classbook_proposal_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_proposal_list - Display list of proposals by classbookid

classbook_proposal_list

Display list of proposals by classbookid

Access: unauthorized - no, user - yes, admin - yes

Input params

  • classbookid - integer, required; Classbookid for an article
  • lang - string, optional; Language

example call method

fhq.classbook_proposal_list({
    "classbookid": 0,
    "lang": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
classbook_update_record - Update a article with a given classbookid

classbook_update_record

Update a article with a given classbookid

Access: unauthorized - no, user - no, admin - yes

Input params

  • classbookid - integer, required; id for classbook article
  • name - string, optional; name for classbook article
  • content - string, optional; content for classbook article
  • ordered - integer, optional; ordered for classbook article
  • parentid - integer, optional; parentid for classbook article

example call method

fhq.classbook_update_record({
    "classbookid": 0,
    "name": "",
    "content": "",
    "ordered": 0,
    "parentid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
createpublicevent - Create the public event

createpublicevent

Create the public event

Access: unauthorized - no, user - no, admin - yes

Input params

  • type - string, required; Type of event
  • message - string, required; Message

example call method

fhq.createpublicevent({
    "type": "",
    "message": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
createquest - Method will be create new quest

createquest

Method will be create new quest

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the quest
  • gameid - integer, required; Which game included this quest
  • name - string, required; Name of the quest
  • text - string, required; Description of the quest
  • score - integer, required; How much append to user score after solve quest by them
  • author - string, required; Author of the quest
  • subject - string, required; Subject must be one from types
  • answer - string, required; Answer for the quest
  • answer_format - string, required; Answer format for the quest
  • state - string, required; State of the quest
  • description_state - string, required; You can add some descriptions for quest state
  • copyright - string, optional; You can add some copyright information

example call method

fhq.createquest({
    "uuid": "",
    "gameid": 0,
    "name": "",
    "text": "",
    "score": 0,
    "author": "",
    "subject": "",
    "answer": "",
    "answer_format": "",
    "state": "",
    "description_state": "",
    "copyright": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
deletehint - Method for delete hint from quest

deletehint

Method for delete hint from quest

Access: unauthorized - no, user - no, admin - yes

Input params

  • hintid - integer, required; hint id

example call method

fhq.deletehint({
    "hintid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
deletepublicevent - Delete public event

deletepublicevent

Delete public event

Access: unauthorized - no, user - no, admin - yes

Input params

  • eventid - integer, required; Event ID

example call method

fhq.deletepublicevent({
    "eventid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
feedback_add - Create the feedback

feedback_add

Create the feedback

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • from - string, required; From user
  • text - string, required; Text of feedback
  • type - string, required; Type of feedback

example call method

fhq.feedback_add({
    "from": "",
    "text": "",
    "type": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_create - Create the game

game_create

Create the game

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game
  • name - string, required; Name of the Game
  • description - string, required; Description of the Game
  • state - string, required; State of the game
  • form - string, required; Form of the game
  • type - string, required; Type of the game
  • date_start - string, required; Date start
  • date_stop - string, required; Date stop
  • date_restart - string, required; Date restart
  • organizators - string, required; Organizators

example call method

fhq.game_create({
    "uuid": "",
    "name": "",
    "description": "",
    "state": "",
    "form": "",
    "type": "",
    "date_start": "",
    "date_stop": "",
    "date_restart": "",
    "organizators": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_delete - Remove game and all quests

game_delete

Remove game and all quests

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game
  • admin_password - string, required; Admin Password

example call method

fhq.game_delete({
    "uuid": "",
    "admin_password": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_export - Export the game

game_export

Export the game

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game

example call method

fhq.game_export({
    "uuid": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_import - Import game

game_import

Import game

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game

example call method

fhq.game_import({
    "uuid": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_info - Return game info

game_info

Return game info

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game

example call method

fhq.game_info({
    "uuid": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_update - Update game info

game_update

Update game info

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game
  • name - string, optional; Name of the Game
  • description - string, optional; Description of the Game
  • state - string, optional; State of the game
  • form - string, optional; Form of the game
  • type - string, optional; Type of the game
  • date_start - string, optional; Date start
  • date_stop - string, optional; Date stop
  • date_restart - string, optional; Date restart
  • organizators - string, optional; Organizators

example call method

fhq.game_update({
    "uuid": "",
    "name": "",
    "description": "",
    "state": "",
    "form": "",
    "type": "",
    "date_start": "",
    "date_stop": "",
    "date_restart": "",
    "organizators": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
game_update_logo - Update game logo

game_update_logo

Update game logo

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game
  • image_png_base64 - string, required; Image PNG in Base64

example call method

fhq.game_update_logo({
    "uuid": "",
    "image_png_base64": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
games.info - Return info about game by uuid

games.info

Return info about game by uuid

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • uuid - string, required; Global Identificator of the Game

example call method

fhq.games_info({
    "uuid": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
games_list - Method returned list of games

games_list

Method returned list of games

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.games_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
getmap - Returned coordinate list

getmap

Returned coordinate list

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.getmap({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
getpublicevent - Return public event info by id

getpublicevent

Return public event info by id

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • eventid - integer, required; Event id

example call method

fhq.getpublicevent({
    "eventid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
hints - Return list of hints

hints

Return list of hints

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • questid - integer, required; Quest id

example call method

fhq.hints({
    "questid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
leaks.add - Method adds a leak

leaks.add

Method adds a leak

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; UUID of the leak
  • game_uuid - string, required; UUID of the game
  • name - string, required; Visible part of the content
  • content - string, required; Content of the leak
  • score - integer, required; Price of the leak

example call method

fhq.leaks_add({
    "uuid": "",
    "game_uuid": "",
    "name": "",
    "content": "",
    "score": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
leaks.buy - Method buys a leak

leaks.buy

Method buys a leak

Access: unauthorized - no, user - yes, admin - no

Input params

  • id - integer, required; Leak id

example call method

fhq.leaks_buy({
    "id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
leaks.delete - Method deletes a leak

leaks.delete

Method deletes a leak

Access: unauthorized - no, user - no, admin - yes

Input params

  • id - integer, required; Leak id

example call method

fhq.leaks_delete({
    "id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
leaks.list - Method returns list of leaks

leaks.list

Method returns list of leaks

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • page - integer, required; Number of page
  • onpage - integer, required; How much rows in one page

example call method

fhq.leaks_list({
    "page": 0,
    "onpage": 10
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
leaks.update - Method updates a leak

leaks.update

Method updates a leak

Access: unauthorized - no, user - no, admin - yes

Input params

  • id - integer, required; Leak id
  • name - string, optional; Visible part of the content
  • content - string, optional; Content of the leak
  • score - integer, optional; Price of the leak

example call method

fhq.leaks_update({
    "id": 0,
    "name": "",
    "content": "",
    "score": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
login - Method for login

login

Method for login

Access: unauthorized - yes, user - no, admin - no

Input params

  • email - string, required; E-mail
  • password - string, required; Password

example call method

fhq.login({
    "email": "",
    "password": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_containers - Any actions with the container. Actions: create, start, stop and delete container

lxd_containers

Any actions with the container. Actions: create, start, stop and delete container

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; Container name
  • action - string, required; Actions: create, start, stop and delete container

example call method

fhq.lxd_containers({
    "name": "",
    "action": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_exec - Exec command in the container with name.

lxd_exec

Exec command in the container with name.

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; Container name
  • command - string, required; Name of execution command

example call method

fhq.lxd_exec({
    "name": "",
    "command": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_file - Pull, push, delete file inside the container.

lxd_file

Pull, push, delete file inside the container.

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; Container name
  • action - string, required; Action with files: pull, push or delete
  • path - string, required; Path to file inside the container

example call method

fhq.lxd_file({
    "name": "",
    "action": "",
    "path": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_import_container - Import container from json configuration.

lxd_import_container

Import container from json configuration.

Access: unauthorized - no, user - no, admin - yes

Input params

  • config - string, required; Container's configuration in json dumped string.

example call method

fhq.lxd_import_container({
    "config": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_import_service_from_zip - Import Service from zip.

lxd_import_service_from_zip

Import Service from zip.

Access: unauthorized - no, user - no, admin - yes

Input params

  • zip_file - string, required; Service's configuration in Base64 zip archive.

example call method

fhq.lxd_import_service_from_zip({
    "zip_file": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_info - Get information about the orhestra, containers.

lxd_info

Get information about the orhestra, containers.

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; Container name
  • get - string, optional; Requested information

example call method

fhq.lxd_info({
    "name": "",
    "get": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_list - Get information about all containers.

lxd_list

Get information about all containers.

Access: unauthorized - no, user - no, admin - yes

Input params

example call method

fhq.lxd_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_open_port - Opens the container port.

lxd_open_port

Opens the container port.

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; Container name
  • port - integer, required; Number container port
  • protocol - string, required; Protocol

example call method

fhq.lxd_open_port({
    "name": "",
    "port": 0,
    "protocol": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
lxd_start_service - Start service.

lxd_start_service

Start service.

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; Service's name.

example call method

fhq.lxd_start_service({
    "name": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
mail_info - This method Will be return info of mail

mail_info

This method Will be return info of mail

Access: unauthorized - no, user - no, admin - yes

Input params

example call method

fhq.mail_info({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
mail_send - Mail Send

mail_send

Mail Send

Access: unauthorized - no, user - no, admin - yes

Input params

  • to - string, required; E-mail of the recipient
  • subject - string, required; Subject of the message
  • body - string, required; Body of the message

example call method

fhq.mail_send({
    "to": "",
    "subject": "",
    "body": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
mails_list - Mails list

mails_list

Mails list

Access: unauthorized - no, user - no, admin - yes

Input params

  • filter_email - string, optional; Filter by email
  • filter_subject - string, optional; Filter by subject
  • filter_message - string, optional; Filter by message
  • onpage - integer, optional; On page
  • page - integer, optional; page

example call method

fhq.mails_list({
    "filter_email": "",
    "filter_subject": "",
    "filter_message": "",
    "onpage": 10,
    "page": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
public_info - Method return public information about server

public_info

Method return public information about server

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.public_info({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
publiceventslist - Return list of public events

publiceventslist

Return list of public events

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • page - integer, required; Number of page
  • onpage - integer, required; How much rows in one page
  • type - string, optional; Filter by type events
  • search - string, optional; Filter by message event

example call method

fhq.publiceventslist({
    "page": 0,
    "onpage": 10,
    "type": "",
    "search": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quest - Update the quest info

quest

Update the quest info

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • questid - integer, required; Quest ID

example call method

fhq.quest({
    "questid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quest_delete - Method for delete quest

quest_delete

Method for delete quest

Access: unauthorized - no, user - no, admin - yes

Input params

  • questid - integer, required; Quest ID

example call method

fhq.quest_delete({
    "questid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quest_pass - Quest pass

quest_pass

Quest pass

Access: unauthorized - no, user - yes, admin - yes

Input params

  • questid - integer, required; Quest ID
  • answer - string, required; Answer

example call method

fhq.quest_pass({
    "questid": 0,
    "answer": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quest_proposal - Add quest proposal

quest_proposal

Add quest proposal

Access: unauthorized - no, user - yes, admin - yes

Input params

  • gameid - integer, required; Which game included this quest
  • name - string, required; Name of the quest
  • text - string, required; Description of the quest
  • score - integer, required; How much append to user score after solve quest by them
  • author - string, required; Author of the quest
  • subject - string, required; Subject must be one from types (look types)
  • answer - string, required; Answer for the quest
  • answer_format - string, required; Answer format for the quest

example call method

fhq.quest_proposal({
    "gameid": 0,
    "name": "",
    "text": "",
    "score": 0,
    "author": "",
    "subject": "",
    "answer": "",
    "answer_format": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quest_statistics - Mehtod will be return quest public statistics

quest_statistics

Mehtod will be return quest public statistics

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • questid - integer, required; Quest ID

example call method

fhq.quest_statistics({
    "questid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quest_update - Update the quest info

quest_update

Update the quest info

Access: unauthorized - no, user - no, admin - yes

Input params

  • questid - integer, required; Quest ID
  • name - string, optional; Name of the quest
  • gameid - integer, optional; Which game included this quest
  • text - string, optional; Description of the quest
  • score - integer, optional; How much append to user score after solve quest by them
  • subject - string, optional; Subject must be one from types
  • author - string, optional; Author of the quest
  • answer - string, optional; Answer for the quest
  • answer_format - string, optional; Answer format for the quest
  • state - string, optional; State of the quest
  • description_state - string, optional; You can update some descriptions for quest state
  • copyright - string, optional; You can update copyright

example call method

fhq.quest_update({
    "questid": 0,
    "name": "",
    "gameid": 0,
    "text": "",
    "score": 0,
    "subject": "",
    "author": "",
    "answer": "",
    "answer_format": "",
    "state": "",
    "description_state": "",
    "copyright": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests - Method will be returned quest list

quests

Method will be returned quest list

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • subject - string, optional; Filter by subject
  • gameid - integer, optional; Filter by local gameid
  • filter - string, optional; Filter by some text

example call method

fhq.quests({
    "subject": "",
    "gameid": 0,
    "filter": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_files.delete - Delete file from quest

quests_files.delete

Delete file from quest

Access: unauthorized - no, user - no, admin - yes

Input params

  • quest_uuid - string, required; Quest UUID
  • file_id - integer, required; File ID

example call method

fhq.quests_files_delete({
    "quest_uuid": "",
    "file_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_files.upload - Update the quest

quests_files.upload

Update the quest

Access: unauthorized - no, user - no, admin - yes

Input params

  • quest_uuid - string, required; Quest UUID
  • file_base64 - string, required; Byte-array encoded in base64
  • file_name - string, required; File name

example call method

fhq.quests_files_upload({
    "quest_uuid": "",
    "file_base64": "",
    "file_name": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_proposal_list - Quests proposal list

quests_proposal_list

Quests proposal list

Access: unauthorized - no, user - no, admin - yes

Input params

  • page_size - integer, optional; Pgae size
  • page_index - integer, optional; Page index

example call method

fhq.quests_proposal_list({
    "page_size": 0,
    "page_index": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_subjects - Method returned list of quests by subjects

quests_subjects

Method returned list of quests by subjects

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.quests_subjects({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_user_answer_list - Return user answers list

quests_user_answer_list

Return user answers list

Access: unauthorized - no, user - yes, admin - yes

Input params

  • questid - integer, required; Filter for questid

example call method

fhq.quests_user_answer_list({
    "questid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_writeups_delete - This method will be remove writeup

quests_writeups_delete

This method will be remove writeup

Access: unauthorized - no, user - no, admin - yes

Input params

  • writeupid - integer, required; WriteUp ID

example call method

fhq.quests_writeups_delete({
    "writeupid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_writeups_list - This method will be returned list of writeups by questid

quests_writeups_list

This method will be returned list of writeups by questid

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • questid - integer, required; Quest ID

example call method

fhq.quests_writeups_list({
    "questid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_writeups_proposal - This method will be add writeup from authorized user

quests_writeups_proposal

This method will be add writeup from authorized user

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.quests_writeups_proposal({
    "questid": 0,
    "writeup_link": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
quests_writeups_update - This method will be update writeup approve now

quests_writeups_update

This method will be update writeup approve now

Access: unauthorized - no, user - no, admin - yes

Input params

  • writeupid - integer, required; WriteUp ID
  • approve - string, required; Approve value 1 or 0

example call method

fhq.quests_writeups_update({
    "writeupid": 0,
    "approve": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
registration - Method for registration

registration

Method for registration

Access: unauthorized - yes, user - no, admin - no

Input params

  • email - string, required; E-mail
  • university - string, required; University

example call method

fhq.registration({
    "email": "",
    "university": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
scoreboard - Method return scoreboard

scoreboard

Method return scoreboard

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • page - integer, required; Number of page
  • onpage - integer, required; How much rows in one page

example call method

fhq.scoreboard({
    "page": 0,
    "onpage": 10
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
server_api - This method Will be return list of all handlers

server_api

This method Will be return list of all handlers

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.server_api({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
server_info - Return server private information

server_info

Return server private information

Access: unauthorized - no, user - no, admin - yes

Input params

example call method

fhq.server_info({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
server_settings - Return server settings

server_settings

Return server settings

Access: unauthorized - no, user - no, admin - yes

Input params

example call method

fhq.server_settings({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
server_settings_update - Update server settings

server_settings_update

Update server settings

Access: unauthorized - no, user - no, admin - yes

Input params

  • name - string, required; name of setting
  • value - string, required; value of setting

example call method

fhq.server_settings_update({
    "name": "",
    "value": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
token - Method for login by token

token

Method for login by token

Access: unauthorized - yes, user - no, admin - no

Input params

  • token - string, required; Authorization token

example call method

fhq.token({
    "token": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
updateuserlocation - This method will be try update user location by lastip

updateuserlocation

This method will be try update user location by lastip

Access: unauthorized - no, user - no, admin - yes

Input params

  • userid - integer, required; User ID

example call method

fhq.updateuserlocation({
    "userid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_add - Method for add new useful link

useful_links_add

Method for add new useful link

Access: unauthorized - no, user - no, admin - yes

Input params

  • url - string, required; URL
  • description - string, required; Description
  • author - string, required; Author

example call method

fhq.useful_links_add({
    "url": "",
    "description": "",
    "author": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_clicked - Useful Links removed from favorite

useful_links_clicked

Useful Links removed from favorite

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link

example call method

fhq.useful_links_clicked({
    "useful_link_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_comment_add - Useful Links add comment

useful_links_comment_add

Useful Links add comment

Access: unauthorized - no, user - yes, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link
  • comment - string, required; Comment

example call method

fhq.useful_links_comment_add({
    "useful_link_id": 0,
    "comment": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_comment_delete - Useful Links remove comment

useful_links_comment_delete

Useful Links remove comment

Access: unauthorized - no, user - yes, admin - yes

Input params

  • useful_link_comment_id - integer, required; Comment Id for useful link

example call method

fhq.useful_links_comment_delete({
    "useful_link_comment_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_comment_list - Useful Links list of comments

useful_links_comment_list

Useful Links list of comments

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link

example call method

fhq.useful_links_comment_list({
    "useful_link_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_delete - Method for delete link by admin

useful_links_delete

Method for delete link by admin

Access: unauthorized - no, user - no, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link

example call method

fhq.useful_links_delete({
    "useful_link_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_list - Method will be return list of useful links

useful_links_list

Method will be return list of useful links

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • filter - string, optional; Filter by word
  • filter_by_tag - string, optional; Filter by tag
  • page_index - integer, optional; Page Index
  • page_size - integer, optional; Page Size (default 10)

example call method

fhq.useful_links_list({
    "filter": "",
    "filter_by_tag": "",
    "page_index": 0,
    "page_size": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_retrieve - Method for retrieve useful link

useful_links_retrieve

Method for retrieve useful link

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link

example call method

fhq.useful_links_retrieve({
    "useful_link_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_tag_add - Useful Links add tag

useful_links_tag_add

Useful Links add tag

Access: unauthorized - no, user - no, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link
  • tag - string, required; Tag Value

example call method

fhq.useful_links_tag_add({
    "useful_link_id": 0,
    "tag": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_tag_delete - Useful Links remove tag

useful_links_tag_delete

Useful Links remove tag

Access: unauthorized - no, user - no, admin - yes

Input params

  • useful_link_id - integer, required; Useful Link Id
  • tag - string, required; Tag Value

example call method

fhq.useful_links_tag_delete({
    "useful_link_id": 0,
    "tag": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_tag_list - Useful Links - List of tags

useful_links_tag_list

Useful Links - List of tags

Access: unauthorized - yes, user - yes, admin - yes

Input params

example call method

fhq.useful_links_tag_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_update - Method for update useful link

useful_links_update

Method for update useful link

Access: unauthorized - no, user - no, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link
  • url - string, required; URL
  • description - string, required; Description
  • author - string, required; Author

example call method

fhq.useful_links_update({
    "useful_link_id": 0,
    "url": "",
    "description": "",
    "author": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_user_favorite - Useful Links add to favorite

useful_links_user_favorite

Useful Links add to favorite

Access: unauthorized - no, user - yes, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link

example call method

fhq.useful_links_user_favorite({
    "useful_link_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_user_favorite_list - Useful Links list of favorite

useful_links_user_favorite_list

Useful Links list of favorite

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.useful_links_user_favorite_list({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_user_propose - Useful Links propose link by user

useful_links_user_propose

Useful Links propose link by user

Access: unauthorized - no, user - yes, admin - yes

Input params

  • url - string, required; Url
  • description - string, required; Description
  • tags - string, required; tags

example call method

fhq.useful_links_user_propose({
    "url": "",
    "description": "",
    "tags": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_user_propose_approve - Useful Links Approve propose link by admin

useful_links_user_propose_approve

Useful Links Approve propose link by admin

Access: unauthorized - no, user - no, admin - yes

Input params

  • useful_links_propose_id - integer, required; Id of propose for useful_links

example call method

fhq.useful_links_user_propose_approve({
    "useful_links_propose_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
useful_links_user_unfavorite - Useful Links removed from favorite

useful_links_user_unfavorite

Useful Links removed from favorite

Access: unauthorized - no, user - yes, admin - yes

Input params

  • useful_link_id - integer, required; Id of useful link

example call method

fhq.useful_links_user_unfavorite({
    "useful_link_id": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
user - Return user info

user

Return user info

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • userid - integer, optional; Id of user

example call method

fhq.user({
    "userid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
user_change_password - This method for change user password

user_change_password

This method for change user password

Access: unauthorized - no, user - yes, admin - yes

Input params

  • password_old - string, required; Old password
  • password_new - string, required; New password

example call method

fhq.user_change_password({
    "password_old": "",
    "password_new": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
user_reset_password - Method for reset password

user_reset_password

Method for reset password

Access: unauthorized - yes, user - no, admin - no

Input params

  • email - string, required; E-mail

example call method

fhq.user_reset_password({
    "email": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
user_skills - Return user skills info

user_skills

Return user skills info

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • userid - integer, required; Id of user

example call method

fhq.user_skills({
    "userid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
user_update - Update user info

user_update

Update user info

Access: unauthorized - no, user - yes, admin - yes

Input params

  • userid - integer, required; Id of user
  • nick - string, optional; Nick of user
  • university - string, optional; University of user
  • about - string, optional; About of user
  • country - string, optional; Country of user

example call method

fhq.user_update({
    "userid": 0,
    "nick": "",
    "university": "",
    "about": "",
    "country": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users - Method return list of users

users

Method return list of users

Access: unauthorized - no, user - no, admin - yes

Input params

  • filter_text - string, optional; Filter by user email or nick
  • filter_role - string, optional; Filter by user role
  • onpage - integer, optional; On Page
  • page - integer, optional; Number of page

example call method

fhq.users({
    "filter_text": "",
    "filter_role": "",
    "onpage": 10,
    "page": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_add - Method for add new user

users_add

Method for add new user

Access: unauthorized - no, user - no, admin - yes

Input params

  • uuid - string, required; User's Global Unique Identifier
  • email - string, required; User's E-mail
  • nick - string, required; User's nick
  • password - string, required; Password
  • role - string, required; User's role
  • university - string, optional; University

example call method

fhq.users_add({
    "uuid": "",
    "email": "",
    "nick": "",
    "password": "",
    "role": "",
    "university": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_change_email - Method for email changing

users_change_email

Method for email changing

Access: unauthorized - no, user - yes, admin - yes

Input params

  • email - string, required; New E-mail
  • password - string, required; Password

example call method

fhq.users_change_email({
    "email": "",
    "password": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_change_email_verification - Method for email changing verification

users_change_email_verification

Method for email changing verification

Access: unauthorized - no, user - yes, admin - yes

Input params

  • code - string, required; Verification code

example call method

fhq.users_change_email_verification({
    "code": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_delete - Method for deleting a user

users_delete

Method for deleting a user

Access: unauthorized - no, user - no, admin - yes

Input params

  • userid - integer, required; User's id
  • password - string, required; Admin's password

example call method

fhq.users_delete({
    "userid": 0,
    "password": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_info - Return user info

users_info

Return user info

Access: unauthorized - yes, user - yes, admin - yes

Input params

  • uuid - integer, required; Global unique identify of user

example call method

fhq.users_info({
    "uuid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_registration - Method for registration

users_registration

Method for registration

Access: unauthorized - yes, user - no, admin - no

Input params

  • email - string, required; E-mail

example call method

fhq.users_registration({
    "email": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_registration_verification - Method for registration verification

users_registration_verification

Method for registration verification

Access: unauthorized - yes, user - no, admin - no

Input params

  • code - string, required; Verification code

example call method

fhq.users_registration_verification({
    "code": ""
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_tokens - List of active user tokens

users_tokens

List of active user tokens

Access: unauthorized - no, user - yes, admin - yes

Input params

example call method

fhq.users_tokens({

}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});
users_tokens_delete - Delete user tokens

users_tokens_delete

Delete user tokens

Access: unauthorized - no, user - yes, admin - yes

Input params

  • tokenid - integer, required; Token ID

example call method

fhq.users_tokens_delete({
    "tokenid": 0
}).done(function(r) {
    console.log('Success: ', r);
}).fail(function(err) {
    console.error('Error:', err);
});