telnety.

API Reference

Reference documentation for Telnety Tauri commands (IPC), cloud API (REST), and the JavaScript SDK.

Tauri Commands (IPC)

Telnety exposes Rust functions to the frontend via Tauri's IPC system. These are called using invoke() from the React frontend.

get_hosts

List all saved hosts

Returns: Vec<Host>

create_host

Create a new host entry

Returns: Host

update_host

Update an existing host

Returns: Host

delete_host

Delete a host by ID

Returns: ()

ssh_connect

Open an SSH connection

Returns: String (session_id)

ssh_disconnect

Close an SSH session

Returns: ()

ssh_send_data

Send data to SSH session

Returns: ()

sftp_list_dir

List remote directory

Returns: Vec<SftpEntry>

sftp_upload

Upload file to remote

Returns: ()

sftp_download

Download file from remote

Returns: Vec<u8>

vault_unlock

Unlock the credential vault

Returns: ()

vault_get_entries

List vault entries

Returns: Vec<VaultEntry>

Cloud API (REST)

The Telnety cloud server (Axum) exposes REST endpoints for authentication, sync, and team management.

POST/auth/registerCreate a new account
POST/auth/loginAuthenticate and receive JWT
POST/auth/logoutRevoke token family
GET/profileGet current user profile
GET/devicesList registered devices
POST/sync/pushPush local changes to cloud
GET/sync/pullPull remote changes
WS/sync/wsWebSocket for real-time sync

SDK

The @telnety/sdk package provides a TypeScript client for the cloud API. Install from npm and use it to build integrations, CI/CD plugins, and custom tooling.

import { TelnetyClient } from "@telnety/sdk";

const client = new TelnetyClient({
  apiKey: process.env.TELNETY_API_KEY,
});

const hosts = await client.hosts.list();