An incoming message sent from the Krist server to a websocket client.

Hierarchy

Properties

error?: string

If ok is false, the error code from the Krist API.

id: number

The message ID that this is in response to. You typically do not need to do anything with this, the library will handle message replies automatically.

message?: string

If ok is false, a human-readable error message from the Krist API.

ok: boolean

Whether the request succeeded.

parameter?: string

If ok is false, the parameter that caused the error (if available).

responding_to_type: "work"

The type of message that the server is responding to.

type: "response"

The type of incoming message.

work: number

The current Krist work (difficulty).

Generated using TypeDoc