Server SDK overview
The Server SDK runs on your backend. Each language package provides a classroom client and a whiteboardClient. Python uses whiteboard_client; Go uses Client() / WhiteboardClient(); Java uses client() / whiteboardClient().
Choose a language
| Language | Package | Runtime | Guide |
|---|---|---|---|
| Node.js / TypeScript | @eduskit/server-sdk | Node.js 18+ | Node.js |
| Python | eduskit | Python 3.9+, standard-library HTTP | Python |
| Java | com.eduskit:server-sdk | Java 11+, Gson | Java |
| Go | github.com/eduskit/server-sdk-go | Go 1.21+ | Go |
| PHP | eduskit/server-sdk-php | PHP 8.1+ with cURL for HTTP | PHP |
The installation examples use version 0.1.5 for all five languages. See Versions and distribution for the Node.js classroom-creation type compatibility note.
Configuration
| Field | Meaning |
|---|---|
baseUrl | The relevant server-api endpoint; the SDK appends /v1/... |
appId | Application ID used for local token signing |
appKey | HTTP x-app-key header |
appSecret | HTTP x-app-secret header and local HS256 signing secret |
timeoutMs | Node.js/PHP request timeout, 10000 milliseconds by default; other languages have native equivalents |
lang | x-lang, defaults to zh-CN |
Local classroom server-api runs at http://localhost:3112; local whiteboard server-api runs at http://localhost:3012. Supply addresses explicitly in client configuration. For public endpoints, use the address supplied by your deployment; the client endpoint https://sdk.eduskit.com is not a substitute.
Configure classroom and whiteboard applications separately. Omit the whiteboard side if unused. Accessing an unconfigured side returns SDK_CLIENT_NOT_CONFIGURED without a request.
Examples read EDU_SERVER_URL, EDU_APP_ID, EDU_APP_KEY and EDU_APP_SECRET from the backend environment or secret manager. Do not put them in frontend build variables.
Responses and errors
The usual success envelope is { code, message, data, traceId }; SDK methods return data. Request and response JSON fields use camelCase in every language. Only Python configuration keys and method names use snake_case.
Failures use EduskitError or Go's *eduskit.Error. Preserve the error code, HTTP status, traceId, path and source; see Errors and troubleshooting. A shared client's lastTraceId describes its most recent request, so it cannot reliably identify concurrent requests.
The SDK does not automatically retry HTTP calls or verify webhooks. After a timeout during classroom creation, start/end or recording start, check whether the operation completed before retrying.
Receive business events
Configure an HTTPS callback URL and subscriptions in the console to receive classroom and courseware changes. See Server webhooks, event data and signature verification. Webhook delivery retries are separate from Server SDK HTTP behavior.
Application and tenant APIs
Source builds provide 50 application-authenticated HTTP routes through client, including users, classrooms, courseware libraries, live assets, and diagnostics. See application business APIs and workflow examples. The separate tenant management client uses tenant sessions for account, application, dashboard, and billing operations. The new methods require the matching server-api deployment and a source build; public 0.1.5 packages do not include them.