TeamTalk 5 C-API DLL: TeamTalkSrv.h File Reference

TeamTalk 5 C-API DLL Version 5.18A

Loading...
Searching...
No Matches
Macros | Typedefs | Functions
TeamTalkSrv.h File Reference
`#include "TeamTalk.h"`

Go to the source code of this file.

## Macros

#define | TEAMTALK_SERVER_VERSION "5.18.0.5162"
| Ensure the header and DLL are exactly the same version. To get the version of the loaded DLL call TT_GetVersion(). A remote client's version can be seen in the szVersion member of the User-struct.

## Typedefs

typedef VOID | TTSInstance
| A server instance.
typedef void | UserLoginCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpUser, IN OUT UserAccount *lpUserAccount)
| Callback when a user is requesting to log on to the server.
typedef void | UserChangeNicknameCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpUser, IN const TTCHAR *szNewNickname)
| Callback when a user is requesting to change nickname.
typedef void | UserChangeStatusCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpUser, IN INT32 nNewStatusMode, IN const TTCHAR *szNewStatusMsg)
| Callback when a user is requesting to change status.
typedef void | UserCreateUserAccountCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpUser, IN const UserAccount *lpUserAccount)
| Callback when a user is requesting to create a new user account.
typedef void | UserDeleteUserAccountCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpUser, IN const TTCHAR *szUsername)
| Callback when a user is requesting to delete a user account.
typedef void | UserAddServerBanCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpBanner, IN const User *lpBanee)
| Callback when a user is requesting to ban a user.
typedef void | UserAddServerBanIPAddressCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpBanner, IN const TTCHAR *szIPAddress)
| Callback when a user is requesting to ban an IP-address.
typedef void | UserDeleteServerBanCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, OUT ClientErrorMsg *lpClientErrorMsg, IN const User *lpUser, IN const TTCHAR *szIPAddress)
| Callback when a user is requesting to remove a ban.
typedef void | UserConnectedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when a new user is connecting to the server.
typedef void | UserLoggedInCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when a user has logged in.
typedef void | UserLoggedOutCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when a user has logged out.
typedef void | UserDisconnectedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when user has disconnected.
typedef void | UserTimedoutCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when a user's connection has timed out.
typedef void | UserKickedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpKicker, IN const User *lpKickee, IN const Channel *lpChannel)
| Callback when a user has been kicked.
typedef void | UserBannedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpBanner, IN const User *lpBanee, IN const Channel *lpChannel)
| Callback when a user has been banned.
typedef void | UserUnbannedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUnbanner, IN const TTCHAR *szIPAddress)
| Callback when a ban is removed.
typedef void | UserUpdatedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when a user's properties are being updated.
typedef void | UserJoinedChannelCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser, IN const Channel *lpChannel)
| Callback when a user has joined a channel.
typedef void | UserLeftChannelCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser, IN const Channel *lpChannel)
| Callback when a user has left a channel.
typedef void | UserMovedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpMover, IN const User *lpMovee)
| Callback when a user has been moved.
typedef void | UserTextMessageCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser, IN const TextMessage *lpTextMessage)
| Callback when a user is sending a text message.
typedef void | ChannelCreatedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const Channel *lpChannel, IN const User *lpUser)
| Callback when a new channel has been created.
typedef void | ChannelUpdatedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const Channel *lpChannel, IN const User *lpUser)
| Callback when a channel has been updated.
typedef void | ChannelRemovedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const Channel *lpChannel, IN const User *lpUser)
| Callback when channel has been removed.
typedef void | FileUploadedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const RemoteFile *lpRemoteFile, IN const User *lpUser)
| Callback when a new file has been uploaded to a channel.
typedef void | FileDownloadedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const RemoteFile *lpRemoteFile, IN const User *lpUser)
| Callback when a user has downloaded a file.
typedef void | FileDeletedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const RemoteFile *lpRemoteFile, IN const User *lpUser)
| Callback when a user has deleted a file.
typedef void | ServerUpdatedCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const ServerProperties *lpServerProperties, IN const User *lpUser)
| Callback when a user has updated the server properties.
typedef void | SaveServerConfigCallback(IN TTSInstance *lpTTSInstance, IN VOID *lpUserData, IN const User *lpUser)
| Callback when a user has reguested to save the server configuration.

## Functions

TEAMTALKDLL_API TTBOOL | TTS_SetEncryptionContext (IN TTSInstance *lpTTSInstance, IN const TTCHAR *szCertificateFile, IN const TTCHAR *szPrivateKeyFile)
| Set certificate and private key for encrypted server.
TEAMTALKDLL_API TTBOOL | TTS_SetEncryptionContextEx (IN TTSInstance *lpTTSInstance, const EncryptionContext *lpEncryptionContext)
| Set up encryption context for encrypted server.
TEAMTALKDLL_API TTSInstance * | TTS_InitTeamTalk ()
| Create new TeamTalk server instance.
TEAMTALKDLL_API TTBOOL | TTS_CloseTeamTalk (IN TTSInstance *lpTTSInstance)
| Close TeamTalk server instance.
TEAMTALKDLL_API TTBOOL | TTS_RunEventLoop (IN TTSInstance *lpTTSInstance, IN INT32 *pnWaitMs)
| Run the server's event loop.
TEAMTALKDLL_API INT32 | TTS_SetChannelFilesRoot (IN TTSInstance *lpTTSInstance, IN const TTCHAR *szFilesRoot, IN INT64 nMaxDiskUsage, IN INT64 nDefaultChannelQuota)
| The root folder of where users should upload files to.
TEAMTALKDLL_API INT32 | TTS_UpdateServer (IN TTSInstance *lpTTSInstance, IN const ServerProperties *lpServerProperties)
| Set server properties.
TEAMTALKDLL_API INT32 | TTS_MakeChannel (IN TTSInstance *lpTTSInstance, IN const Channel *lpChannel)
| Make new channel.
TEAMTALKDLL_API INT32 | TTS_UpdateChannel (IN TTSInstance *lpTTSInstance, IN const Channel *lpChannel)
| Update an existing channel.
TEAMTALKDLL_API INT32 | TTS_RemoveChannel (IN TTSInstance *lpTTSInstance, IN INT32 nChannelID)
| Remove a channel.
TEAMTALKDLL_API INT32 | TTS_AddFileToChannel (IN TTSInstance *lpTTSInstance, IN const TTCHAR *szLocalFilePath, IN const RemoteFile *lpRemoteFile)
| Add a file to an existing channel.
TEAMTALKDLL_API INT32 | TTS_RemoveFileFromChannel (IN TTSInstance *lpTTSInstance, IN const RemoteFile *lpRemoteFile)
| Remove a file from a channel.
TEAMTALKDLL_API INT32 | TTS_MoveUser (IN TTSInstance *lpTTSInstance, IN INT32 nUserID, IN const Channel *lpChannel)
| Move a user from one channel to another.
TEAMTALKDLL_API INT32 | TTS_SendTextMessage (IN TTSInstance *lpTTSInstance, const TextMessage *lpTextMessage)
| Send text message from server to clients.
TEAMTALKDLL_API TTBOOL | TTS_StartServer (IN TTSInstance *lpTTSInstance, IN const TTCHAR *szBindIPAddr, IN UINT16 nTcpPort, IN UINT16 nUdpPort, IN TTBOOL bEncrypted)
| Start server on specified IP-address and ports.
TEAMTALKDLL_API TTBOOL | TTS_StartServerSysID (IN TTSInstance *lpTTSInstance, IN const TTCHAR *szBindIPAddr, IN UINT16 nTcpPort, IN UINT16 nUdpPort, IN TTBOOL bEncrypted, IN const TTCHAR *szSystemID)
| Same as TTS_StartServer() but with the option of specifying a system-ID.
TEAMTALKDLL_API TTBOOL | TTS_StopServer (IN TTSInstance *lpTTSInstance)
| Stop server and drop all users.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserLoginCallback (IN TTSInstance *lpTTSInstance, IN UserLoginCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is requesting to log on to the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserChangeNicknameCallback (IN TTSInstance *lpTTSInstance, IN UserChangeNicknameCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback to when user is changing nickname.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserChangeStatusCallback (IN TTSInstance *lpTTSInstance, IN UserChangeStatusCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback to when user is changing status.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserCreateUserAccountCallback (IN TTSInstance *lpTTSInstance, IN UserCreateUserAccountCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is requesting to create a new user account on the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserDeleteUserAccountCallback (IN TTSInstance *lpTTSInstance, IN UserDeleteUserAccountCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is requesting to delete a user account on the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserAddServerBanCallback (IN TTSInstance *lpTTSInstance, IN UserAddServerBanCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is requesting to add a server ban requested by a user.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserAddServerBanIPAddressCallback (IN TTSInstance *lpTTSInstance, IN UserAddServerBanIPAddressCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is requesting to add a server IP-address ban requested by a user.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserDeleteServerBanCallback (IN TTSInstance *lpTTSInstance, IN UserDeleteServerBanCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is requesting to delete a server IP-address ban requested by a user.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserConnectedCallback (IN TTSInstance *lpTTSInstance, IN UserConnectedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user connects to the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserLoggedInCallback (IN TTSInstance *lpTTSInstance, IN UserLoggedInCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user logs on to the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserLoggedOutCallback (IN TTSInstance *lpTTSInstance, IN UserLoggedOutCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user logs out of the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserDisconnectedCallback (IN TTSInstance *lpTTSInstance, IN UserDisconnectedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user disconnects from the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserTimedoutCallback (IN TTSInstance *lpTTSInstance, IN UserTimedoutCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is dropped because of inactivity.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserKickedCallback (IN TTSInstance *lpTTSInstance, IN UserKickedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is kicked from the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserBannedCallback (IN TTSInstance *lpTTSInstance, IN UserBannedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is banned from the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserUnbannedCallback (IN TTSInstance *lpTTSInstance, IN UserUnbannedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when an IP-address is unbanned from the server.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserUpdatedCallback (IN TTSInstance *lpTTSInstance, IN UserUpdatedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when an user's properties are updated.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserJoinedChannelCallback (IN TTSInstance *lpTTSInstance, IN UserJoinedChannelCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when an user joins a channel.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserLeftChannelCallback (IN TTSInstance *lpTTSInstance, IN UserLeftChannelCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when an user leaves a channel.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserMovedCallback (IN TTSInstance *lpTTSInstance, IN UserMovedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user is moved.
TEAMTALKDLL_API TTBOOL | TTS_RegisterUserTextMessageCallback (IN TTSInstance *lpTTSInstance, IN UserTextMessageCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user send a text message.
TEAMTALKDLL_API TTBOOL | TTS_RegisterChannelCreatedCallback (IN TTSInstance *lpTTSInstance, IN ChannelCreatedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a channel is created.
TEAMTALKDLL_API TTBOOL | TTS_RegisterChannelUpdatedCallback (IN TTSInstance *lpTTSInstance, IN ChannelUpdatedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a channel is updated.
TEAMTALKDLL_API TTBOOL | TTS_RegisterChannelRemovedCallback (IN TTSInstance *lpTTSInstance, IN ChannelRemovedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a channel is removed.
TEAMTALKDLL_API TTBOOL | TTS_RegisterFileUploadedCallback (IN TTSInstance *lpTTSInstance, IN FileUploadedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a file is uploaded.
TEAMTALKDLL_API TTBOOL | TTS_RegisterFileDownloadedCallback (IN TTSInstance *lpTTSInstance, IN FileDownloadedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a file is downloaded.
TEAMTALKDLL_API TTBOOL | TTS_RegisterFileDeletedCallback (IN TTSInstance *lpTTSInstance, IN FileDeletedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a file is deleted.
TEAMTALKDLL_API TTBOOL | TTS_RegisterServerUpdatedCallback (IN TTSInstance *lpTTSInstance, IN ServerUpdatedCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a server's properties has been updated.
TEAMTALKDLL_API TTBOOL | TTS_RegisterSaveServerConfigCallback (IN TTSInstance *lpTTSInstance, IN SaveServerConfigCallback *lpCallback, IN VOID *lpUserData, IN TTBOOL bEnable)
| Register a callback when a user requests the server to save its configuration.

## Macro Definition Documentation

## ◆ TEAMTALK_SERVER_VERSION

#define TEAMTALK_SERVER_VERSION "5.18.0.5162"

Ensure the header and DLL are exactly the same version. To get the version of the loaded DLL call TT_GetVersion(). A remote client's version can be seen in the szVersion member of the User-struct.

Definition at line 21 of file TeamTalkSrv.h.

## Typedef Documentation

## ◆ TTSInstance

typedef VOID TTSInstance

A server instance.

See also
  TTS_InitTeamTalk()

Definition at line 31 of file TeamTalkSrv.h.