Goki API
Search…
Endpoints
Let Goki query or update your system
You can add some endpoints to your integration which Goki will use to interact with you. This helps us to get some information from you or trigger events on your system.
url and token are provided by you during endpoint registration.

Available endpoints

1) getSpaces

Goki uses this endpoint to get the list of your spaces (rooms/beds). Staff can use the Goki Dashboard (which uses this endpoint) to map their Goki spaces/locks to your rooms/beds. Goki also uses background jobs to regularly check the mapping and make sure nothing is broken.
Request Sample
Response Sample
Response Data
1
// Method: Your registered method (GET or POST)
2
URL: `${url}?token=${token}`
Copied!
1
// Your response format should be an array of rooms/beds like below
2
3
[
4
{
5
"id": "7123487134",
6
"type": "Room",
7
"name": "101",
8
"isPrivate": false,
9
"isActive": true
10
},
11
{
12
"id": "7123487134",
13
"type": "Bed",
14
"name": "101 A",
15
"isPrivate": false,
16
"isActive": true
17
},
18
...
19
]
Copied!
Property
Type
Required
Description
id
string
Y
ID of the room or bed in your system (PMS)
type
string
Y
Can be only Room, Bed, Dorm. (Make sure you have used uppercase - these names are shown in the Goki dashboard to help staff map their rooms and beds)
name
string
Y
Room name in your system
isPrivate
boolean
Y
Mark it as false if the room is shared. (In case you have a shared room which also can be booked as a private room, mark it false too)
isActive
boolean
Y
If the room is out of service permanently and should not be used by staff, mark it as false. (This is for PMSes which still have a room but it is not used and cannot delete from their system otherwise you normally set this to active=true )

2) getCheckeInStatus

Goki uses this endpoint to check the status of a reservation on your system during the check-in process.
Request Sample
Response Sample
Response Data
1
// Method: Your registered method (GET or POST)
2
URL: `${url}?token=${token}&reservationId=${Reservation ID on your system}`
Copied!
1
{
2
"owing": 111.11,
3
"owingCurrency": "AUD",
4
"roomReady": true
5
}
Copied!
Property
Type
Required
Description
owing
number
Y
The owing amount which user should still pay and cannot check-in unless it is settled
owingCurrency
string
Y
The currency of the owing amount
roomReady
boolean
Y
In case the room is not clean and we should stop users from checking in. If the room is dirty we show a message at the end of the check-in process to the user to sit and we inform them as soon as we get a reservation update from PMS with state=started.

3) checkIn

In self-check-in automation, Goki uses this endpoint to let your system know, you can check the reservation in. We also submit the collected check-in information when calling the endpoint. It is optional for you to store it or ignore it.
This endpoint method MUST be POST.
Request Sample
Request Body
Response Sample
Response Data
1
// Method: Your registered method (POST)
2
URL: `${url}?token=${token}`
3
Body: { reservationId, mainCustomer, companions }
Copied!
1
{
2
"reservationId": "00308227-05ba-48d3-a42d-2e8d13313984", // ID of reservation on your side
3
"mainCustomer": {
4
"firstName": "Bob",
5
"lastName": "Smith",
6
"email": "[email protected]",
7
"address": "1 Bringa Avenue",
8
"mobile": "0401408439",
9
"gender": "male",
10
"nationality": "Australia",
11
"dob": "1986-12-13",
12
"hometown": {
13
"city": "Sydney",
14
"country": "Australia",
15
},
16
"passport": {
17
"number": "563422",
18
"expiry": "2026-01-02",
19
"image": {
20
"publicId": "refhncvdkfns",
21
"gokiSecureUrl": "https://dashboard.goki.travel/secured?property=ce95acc-d3e2-459e-9b65-fda25c7acd&id=a9f0b29f-d279-4d1a-8ca5-9c034fd1b271&type=1"
22
}
23
},
24
"driversLicense": {
25
"number": "942945",
26
"expiry": "2027-12-21",
27
"image": {
28
"publicId": "dkwhfewiuhapewo",
29
"gokiSecureUrl": "https://dashboard.goki.travel/secured?property=ce95acc-d3e2-459e-9b65-fda25c7acd&id=a9f0b29f-d279-4d1a-8ca5-9c034fd1b271&type=2"
30
}
31
},
32
"idCard": {
33
"number": "481233",
34
"expiry": "2028-12-11",
35
"image": {
36
"publicId": "odwifheuowfhwewwefw",
37
"gokiSecureUrl": "https://dashboard.goki.travel/secured?property=ce95acc-d3e2-459e-9b65-fda25c7acd&id=a9f0b29f-d279-4d1a-8ca5-9c034fd1b271&type=3"
38
}
39
},
40
"visa" {
41
"image": {
42
"publicId": "cn2nxarbomkoxpy2vmmk",
43
"gokiSecureUrl": "https://dashboard.goki.travel/secured?property=ce95acc-d3e2-459e-9b65-fda25c7acd&id=a9f0b29f-d279-4d1a-8ca5-9c034fd1b271&type=4"
44
}
45
}
46
},
47
"companions": [
48
{
49
"firstName": "Jon",
50
"lastName": "Snow",
51
"email": "[email protected]",
52
"hometown": {
53
"city": "Sydney",
54
"country": "Australia"
55
},
56
"passport": {
57
"number": "563422",
58
"expiry": "2026-01-02"
59
},
60
"driversLicense": {
61
"number": "942945",
62
"expiry": "2027-12-21"
63
},
64
"idCard": {
65
"number": "481233",
66
"expiry": "2028-12-11"
67
}
68
},
69
...
70
]
71
}
Copied!
1
// Your response should be as follows (you should provide a reason when success is false)
2
{
3
"success": false,
4
"reason": "roomIsNotReady" // reason is mandatory if success is false
5
}
Copied!
Property
Type
Required
Description
success
boolean
Y
Set it to true if you can check the guest in successfully.
reason
string
N
If success if false and you cannot check guest in, you MUST provide a reason. Reason can be one of these:
    roomIsNotReady: Room is not ready yet
    hasOwing: Reservation had owing which must be paid before check-in
    alreadyCheckedIn: Reservation was already checked-in

Data Structure

APIs

Last modified 1mo ago