Doku durchsuchen
Menü
Geändert am Auf GitHub bearbeiten

API-Referenz

Als Markdown kopieren

Diese Referenz zeigt die 1080 Operationen der HTTP-API von NeoDesk: 769 Routen der Konsole, die ein API-Token aufrufen kann, und 311 Routen der Server-API. Sie entsteht aus der OpenAPI-3.1-Beschreibung der API, derselben Datei, die der Server ausliefert; Seiten und Datei sagen also dasselbe. Die Beschreibungen der Routen stehen auf Englisch, wie in der Datei.

Die Beschreibung holen

Jede Konsole liefert die Beschreibung ihrer eigenen Version unter /api/openapi.json, ohne Anmeldung:

curl -o openapi.json http://<console-address>:3375/api/openapi.json

Setze die Adresse deiner Konsole für <console-address> ein. Die Kommandozeile gibt dieselbe Datei aus:

neodesk api-tokens spec > openapi.json

Code-Generatoren und API-Clients wie Postman, Bruno oder Insomnia importieren die Datei. Sie nennt zwei Server: die Konsole unter der Adresse, die du für {origin} angibst, und die Server-API auf Port 21114 (21121 in Docker), deren Pfade mit /api beginnen.

So liest du sie

  • Die Konsole nimmt ein API-Token als Authorization: Bearer ndt_...; siehe API-Tokens. Jede ihrer Routen nennt den Befehl von neodesk, der sie aufruft; die Befehlsreferenz hat dieselbe Route mit ihren Flags.
  • Die Server-API nimmt einen API-Schlüssel in X-API-Key oder ein Anmelde-Token; wo sie lauscht und wer sie erreicht, steht unter Die HTTP-API.
  • "Needs" nennt die Berechtigung, die eine Route verlangt, mit ihrem Kurznamen wie unter API-Tokens. Super-Admins bestehen jede Prüfung.
  • Zeiten sind RFC-3339-Text in UTC mit Millisekunden, etwa 2026-12-02T14:03:05.123Z, und eine Zeit, die nicht gesetzt ist, ist null. Felder, die auf _at enden, enthalten eine; eine Zeit, die du schickst, braucht ihre Zeitzone.
  • Geldbeträge sind ganze Zahlen der kleinsten Einheit der Währung, etwa Cent bei EUR, in Feldern, die auf _minor enden, neben dem ISO-4217-Code der Währung.
  • Fehler sind auf der Konsole {"success": false, "error": "...", "code": "..."}, auf der Server-API {"error": "..."}.
  • Eine Antwort kann auch Felder enthalten, die nicht aufgeführt sind: Die Schemas nennen die Felder, die der Server heute schreibt, und Clients sollten unbekannte Felder übergehen.

Die Routen der Konsole für den Browser, die Geräte und den RustDesk-Client stehen nicht in der Referenz, sondern unter Routen ohne Befehl. Die der Server-API stehen unter Ausgelassene Routen der Server-API.

Wie sie gepflegt wird

Die Beschreibung wird von Hand im Repository des Servers geschrieben, neodesk-server/openapi/openapi.json. Ein Test dort schlägt fehl, wenn eine Route der Konsole oder der Server-API darin fehlt oder wenn sie eine Route nennt, die es nicht mehr gibt; eine Änderung an den Routen ändert die Beschreibung also im selben Pull Request. Die Website kopiert die Datei mit node openapi-sync.ts <server-checkout> und baut diese Seiten aus der Kopie.

Die Konsole

Bereich Routen Was es ist
account 5 You: the account and permissions the token acts with
activity 3 What people did on devices: the activity agents report
api-tokens 5 API tokens for scripts, this command line and AI agents
attestation 6 The server's performance test and its badge
audit 9 The audit log and the security overview
automation 21 Alert rules, alerts, queued device commands and alert mail
backups 10 Full backups, the backup schedule and restores
billing 28 Billing: packages, contracts, sessions, reports and the clock
branding 18 The console's look: logo, colors, profiles and fonts
cdap 10 CDAP devices, their widgets and commands
cdap-studio 10 CDAP Studio flows
chat 27 The chat: support conversations with the people at the computers (chat.support), the team chat between colleagues (chat.team), canned replies and the chat's settings. The messages themselves go over the chat's WebSocket.
client-branding 2 Name, logo and links the desktop clients show
companion 13 NeoDesk Companion: releases, templates, installer files and the silent install
cross-platform 3 What each device platform supports
dashboard 6 The numbers on the dashboard and the server status
dataguard 7 Data guard policies and the events devices report
device-control 7 Screen, keyboard, mouse, clipboard and terminal of a NeoDesk agent
device-fields 14 Fields admins define for devices (customer, contract, warranty date) and their values
device-files 6 Files on a device with a NeoDesk agent
device-groups 3 Device groups (manual and by tag)
device-tokens 7 Tokens that let a new device join without approval
devices 41 Devices: list, details, notes, tags, bans, connection settings
enrollment 7 Who may join, and devices waiting for approval
fleet 26 Fleet tasks, workflows, compliance and resources
folders 6 Folders that sort devices
generator 18 The NeoDesk Companion generator: bundles and builds
guest-links 3 Guest links: a link that lets someone without an account connect to some devices for a while. Errors of these routes beyond the permission check are {"error": "..."}.
help-requests 3 Help requests: a person at a computer asks for help from the NeoDesk app, and staff take and close the request. Needs chat.support.
inventory 2 Hardware and software inventory of devices
invites 7 Invites that add a computer to this server
keys 6 The server's key, the client settings and the QR code
languages 9 The console's languages and translations
mesh 16 MeshCentral devices, groups and recordings
network 15 Network checks: targets, monitoring, ping and port tests
organizations 26 Organizations with their users, devices and settings
pairing 5 Pairing codes for NeoDesk Desktop and NeoDesk Companion
panel-access 5 Which console sections and client features each account may use
policies 16 Organization policies and device attestation
registrations 7 Devices that asked to register
remote 1 Remote sessions in progress
remote-targets 11 RDP and VNC targets
reports 15 Reports and trends
resource-control 11 USB, disks, monitors and quotas on devices
restart 6 Pending server restarts after a change
roles 10 Roles and their permissions
scaling 12 Relay servers and scaling rules
server 15 The server: health, versions, resources, services and logs
sessions 4 Console sign-ins: the browsers and devices an account is signed in on
settings 55 Server settings: mail, sign-in, addresses, enrollment, sessions
setup-guide 3 The setup guide a new install shows its first admin on the overview
sites 11 Sites with their networks and relay nodes, and pinning devices and folders to a site
address-books 6 Shared address books, their members and each member's rule
strategies 7 Strategies: settings pushed to desktop clients
support 12 Quick support: a code or link that lets someone at a computer without NeoDesk get help once, the feedback they give afterwards, and its settings.
tags 3 Device tags
tenants 12 Tenants with their devices and users
tickets 14 The helpdesk: tickets, their comments and attachments. Reading needs device.view, changing device.edit. These routes answer errors as {"error": "..."}.
toolkit 8 Small network and text tools
transfers 5 File transfers between the console and devices
updates 16 Server updates and the backups taken before them
user-groups 4 User groups
users 45 Console accounts: create, change, disable, delete
integrations 15 Webhooks and notification channels: where events go, the delivery log
mail-intake 8 Tickets by mail: the mailboxes the server reads, their test and their log
recordings 14 Session recordings kept on the server: list, download, delete, legal holds, rules and storage
maintenance 8 Maintenance windows that hold the alerts of devices while they are worked on

Die Server-API

Bereich Routen Was es ist
devices 38 Devices on the server API: their records, live status, bans, IDs, tags, access policy, connection mode and telemetry, and the device lists RustDesk clients and RustDesk Pro scripts read.
sign-in 3 Signing in to the server API with a console account, and the account the token signs in as.
single sign-on 6 The LDAP and OpenID Connect settings of the server and their tests.
accounts 9 Console accounts as the server API keeps them: create, change, delete, two-factor sign-in and organizations.
API keys 3 The API keys of the server API, sent as X-API-Key.
roles 6 The roles, their built-in permissions, the stored overrides and the console sections access rules can name.
user groups 3 User groups of console accounts.
device groups and folders 15 Device groups, folders and the devices an account was given one by one.
settings 2 Single settings in the server API's settings table, read and written by key.
health 3 Whether the server answers, and its runtime figures for monitoring.
keys 5 The server's public key, which clients need to trust it.
organizations 30 Organizations on the server API: their users and members, invitations, devices, settings, shared address book, saved connect passwords and policies, and the sign-in of an organization's users.
branding 3 The branding NeoDesk Desktop and RustDesk clients get from the server.
billing 20 Billing packages, contracts, billed sessions and work reports on the server API.
strategies 6 The server's copy of the strategies it hands to RustDesk clients, and whom they are given to.
fleet 24 Fleet management on the server API: resources of organizations, tasks that run on devices, workflows and compliance scans. The console's Fleet page passes its calls on to these routes.
resource control 7 What devices may use: USB storage, optical drives, monitors, disks and usage limits, per device and as the server's default. The console's Resource control page passes its calls on to these routes.
guest links 5 Guest links on the server API: making, listing and revoking them, and the routes the guest page asks with the link's token.
help requests 5 Help requests on the server API. Its errors come as {"error": "..."} with the content type text/plain.
chat 9 The chat store of the server API: messages, read marks, contacts and groups, which the console's chat reads and writes. Each route needs chat.support or chat.team. Errors come as {"error": "..."} with the content type text/plain.
enrollment 7 The enrollment queue of the server API: devices that wait for approval, the decisions, and the enrollment mode.
enrollment tokens 7 Tokens a device joins the server with, for one computer or for a rollout to many.
pairing codes 3 Short one-time codes a person types into NeoDesk Desktop or NeoDesk Companion to configure it for this server.
cdap 15 The CDAP gateway: devices that connect over the Connected Device Access Protocol, their widgets, alerts and commands, delegations, and the WebSockets of their terminal, desktop, media and files.
meshcentral 18 MeshCentral support: devices that run a MeshAgent, their groups, relays for desktop, terminal, files and ports, power actions, commands, share links and recordings.
remote targets 12 RDP and VNC endpoints the server reaches through guacd: the targets, their saved sign-in, trusted certificates and the session tunnel.
blocklist 3 Addresses, networks and device IDs the server refuses.
audit 5 The server's audit log, and the connection, file transfer and alarm records RustDesk clients send.
events 1 The live stream of server events over a WebSocket.
connection 2 How devices connect: peer to peer first or always through the relay, and who may start a connection.
time sync 4 The server's clock check against NTP, which billing relies on.
desktop agents 3 The management channel of NeoDesk desktop clients: which are connected, and messages to them.
client api 29 The API the RustDesk and NeoDesk desktop clients call: sign-in, the signed-in account, the address book, groups and peer keys. Its answers have the shapes the clients expect.

Weiteres

Durchsucht Seiten, Abschnitte, Befehle und Einstellungen.