Able to connect to a client
parent
c61a67d46e
commit
01a9751d08
@ -0,0 +1,30 @@
|
||||
package main
|
||||
|
||||
type Type int
|
||||
type Request_Type int
|
||||
type Response_Type int
|
||||
|
||||
type Data struct {
|
||||
Type *Type `json:"TYPE",omitempty` // TYPE
|
||||
Request *Request_Type `json:"REQUEST,omitempty"` // REQUEST TYPE
|
||||
Response *Response_Type `json:"RESPONSE,omitempty"` // RESPONSE TYPE
|
||||
Hostname *string `json:"HOSTNAME,omitempty"` // HOSTNAME
|
||||
Data *map[string]any `json:"DATA,omitempty"` // DATA
|
||||
}
|
||||
|
||||
const ( // TYPE
|
||||
REQUEST Type = 1
|
||||
RESPONSE Type = 2
|
||||
)
|
||||
|
||||
const ( // REQUEST TYPES
|
||||
NEW_SERVER_CLIENT Request_Type = 1
|
||||
NEW_DESKTOP_CLIENT Request_Type = 2
|
||||
DATA Request_Type = 3
|
||||
)
|
||||
|
||||
const ( // RESPONSE TYPES
|
||||
OK Response_Type = 1
|
||||
CREATED Response_Type = 2
|
||||
NOT_OK Response_Type = 3
|
||||
)
|
||||
Loading…
Reference in New Issue