All URIs are relative to https://localhost/gamification
Method | HTTP request | Description |
---|---|---|
addActionUsingPOST | POST /model/game/{gameId}/action/{actionId} | Add action |
deleteActionUsingDELETE | DELETE /model/game/{gameId}/action/{actionId} | Delete action |
deleteGameUsingDELETE1 | DELETE /model/game/{gameId} | Delete game |
deleteLevelUsingDELETE | DELETE /model/game/{gameId}/level/{levelName} | Delete a level |
editActionUsingPUT | PUT /model/game/{domain}/action/{actionId} | Edit action |
readActionUsingGET | GET /model/game/{gameId}/action/{actionId} | Get action |
readAllActionUsingGET | GET /model/game/{gameId}/action | Get actions |
readGameStatisticsUsingGET | GET /data/game/{gameId}/statistics | Get game statistics |
readGameUsingGET1 | GET /model/game/{gameId} | Read game definition |
readGamesUsingGET1 | GET /model/game | Get games |
saveGameUsingPOST2 | POST /model/game | Save a game |
saveLevelUsingPOST | POST /model/game/{gameId}/level | Save a level |
startGameUsingPUT | PUT /model/game/{gameId}/start | Start game |
stopGameUsingPUT | PUT /model/game/{gameId}/stop | Stop a game |
addActionUsingPOST(gameId)
Add action
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
apiInstance.addActionUsingPOST(gameId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#addActionUsingPOST");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json
deleteActionUsingDELETE(gameId, actionId)
Delete action
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
String actionId = "actionId_example"; // String | actionId
try {
apiInstance.deleteActionUsingDELETE(gameId, actionId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#deleteActionUsingDELETE");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId | |
actionId | String | actionId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json
deleteGameUsingDELETE1(gameId)
Delete game
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
apiInstance.deleteGameUsingDELETE1(gameId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#deleteGameUsingDELETE1");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json
Boolean deleteLevelUsingDELETE(gameId, levelName)
Delete a level
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
String levelName = "levelName_example"; // String | levelName
try {
Boolean result = apiInstance.deleteLevelUsingDELETE(gameId, levelName);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#deleteLevelUsingDELETE");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId | |
levelName | String | levelName |
Boolean
- Content-Type: application/json
- Accept: application/json
editActionUsingPUT(gameId)
Edit action
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
apiInstance.editActionUsingPUT(gameId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#editActionUsingPUT");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json
readActionUsingGET(gameId)
Get action
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
apiInstance.readActionUsingGET(gameId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#readActionUsingGET");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json
List<String> readAllActionUsingGET(gameId)
Get actions
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
List<String> result = apiInstance.readAllActionUsingGET(gameId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#readAllActionUsingGET");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
List<String>
- Content-Type: application/json
- Accept: application/json
List<GameStatistics> readGameStatisticsUsingGET(gameId, pointConceptName, periodName, timestamp, periodIndex, page, size)
Get game statistics
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
String pointConceptName = "pointConceptName_example"; // String | pointConceptName
String periodName = "periodName_example"; // String | periodName
Long timestamp = 789L; // Long | timestamp
String periodIndex = "periodIndex_example"; // String | periodIndex
Integer page = -1; // Integer | page
Integer size = -1; // Integer | size
try {
List<GameStatistics> result = apiInstance.readGameStatisticsUsingGET(gameId, pointConceptName, periodName, timestamp, periodIndex, page, size);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#readGameStatisticsUsingGET");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId | |
pointConceptName | String | pointConceptName | [optional] |
periodName | String | periodName | [optional] |
timestamp | Long | timestamp | [optional] |
periodIndex | String | periodIndex | [optional] |
page | Integer | page | [optional] [default to -1] |
size | Integer | size | [optional] [default to -1] |
- Content-Type: application/json
- Accept: application/json
GameDTO readGameUsingGET1(gameId)
Read game definition
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
GameDTO result = apiInstance.readGameUsingGET1(gameId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#readGameUsingGET1");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
- Content-Type: application/json
- Accept: application/json
List<GameDTO> readGamesUsingGET1()
Get games
Get all the game definitions of a user
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
try {
List<GameDTO> result = apiInstance.readGamesUsingGET1();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#readGamesUsingGET1");
e.printStackTrace();
}
This endpoint does not need any parameter.
- Content-Type: application/json
- Accept: application/json
GameDTO saveGameUsingPOST2(game)
Save a game
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
GameDTO game = new GameDTO(); // GameDTO | game
try {
GameDTO result = apiInstance.saveGameUsingPOST2(game);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#saveGameUsingPOST2");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
game | GameDTO | game |
- Content-Type: application/json
- Accept: application/json
LevelDTO saveLevelUsingPOST(gameId, level)
Save a level
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
LevelDTO level = new LevelDTO(); // LevelDTO | level
try {
LevelDTO result = apiInstance.saveLevelUsingPOST(gameId, level);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#saveLevelUsingPOST");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId | |
level | LevelDTO | level |
- Content-Type: application/json
- Accept: application/json
startGameUsingPUT(gameId)
Start game
The game is able to accept action executions
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
apiInstance.startGameUsingPUT(gameId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#startGameUsingPUT");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json
stopGameUsingPUT(gameId)
Stop a game
The game will not accept action execution anymore
// Import classes:
//import it.smartcommunitylab.ApiClient;
//import it.smartcommunitylab.ApiException;
//import it.smartcommunitylab.Configuration;
//import it.smartcommunitylab.auth.*;
//import it.smartcommunitylab.basic.api.GameControllerApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basic
HttpBasicAuth basic = (HttpBasicAuth) defaultClient.getAuthentication("basic");
basic.setUsername("YOUR USERNAME");
basic.setPassword("YOUR PASSWORD");
GameControllerApi apiInstance = new GameControllerApi();
String gameId = "gameId_example"; // String | gameId
try {
apiInstance.stopGameUsingPUT(gameId);
} catch (ApiException e) {
System.err.println("Exception when calling GameControllerApi#stopGameUsingPUT");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gameId | String | gameId |
null (empty response body)
- Content-Type: application/json
- Accept: application/json