All URIs are relative to https://localhost/api/v5
Method | HTTP request | Description |
---|---|---|
getMessage | GET /interactive-message/{uuid} | Get a message |
listMessages | GET /interactive-message | List messages |
sendMessage | POST /interactive-message | Send a message |
\Swagger\Client\Model\InteractiveMessage getMessage($uuid, $details, $accept, $pretty)
Get a message
Get detailed information about a message. Required permissions: - interactive-message.one
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: ApiKeyHeader
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-WebAPI-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-WebAPI-Key', 'Bearer');
// Configure API key authorization: ApiKeyQuery
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('key', 'Bearer');
$apiInstance = new Swagger\Client\Api\InteractiveMessageApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$uuid = "uuid_example"; // string | The uuid of the sent message
$details = true; // bool | Add to include additional details, omit or false otherwise
$accept = "accept_example"; // string | Override the 'Accept' request header (useful for debugging your requests)
$pretty = true; // bool | Add to make the Web-API pretty print the response (useful for debugging your requests)
try {
$result = $apiInstance->getMessage($uuid, $details, $accept, $pretty);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling InteractiveMessageApi->getMessage: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
uuid | string | The uuid of the sent message | |
details | bool | Add to include additional details, omit or false otherwise | [optional] |
accept | string | Override the 'Accept' request header (useful for debugging your requests) | [optional] |
pretty | bool | Add to make the Web-API pretty print the response (useful for debugging your requests) | [optional] |
\Swagger\Client\Model\InteractiveMessage
- Content-Type: application/json, application/xml
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Swagger\Client\Model\InteractiveMessage[] listMessages($details, $accept, $pretty)
List messages
Get a list of all the messages that were sent through the message endpoint since the server started. Required permissions: - interactive-message.list
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: ApiKeyHeader
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-WebAPI-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-WebAPI-Key', 'Bearer');
// Configure API key authorization: ApiKeyQuery
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('key', 'Bearer');
$apiInstance = new Swagger\Client\Api\InteractiveMessageApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$details = true; // bool | Add to include additional details, omit or false otherwise
$accept = "accept_example"; // string | Override the 'Accept' request header (useful for debugging your requests)
$pretty = true; // bool | Add to make the Web-API pretty print the response (useful for debugging your requests)
try {
$result = $apiInstance->listMessages($details, $accept, $pretty);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling InteractiveMessageApi->listMessages: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
details | bool | Add to include additional details, omit or false otherwise | [optional] |
accept | string | Override the 'Accept' request header (useful for debugging your requests) | [optional] |
pretty | bool | Add to make the Web-API pretty print the response (useful for debugging your requests) | [optional] |
\Swagger\Client\Model\InteractiveMessage[]
- Content-Type: application/json, application/xml
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Swagger\Client\Model\InteractiveMessage sendMessage($body, $details, $accept, $pretty)
Send a message
Send an interactive message to a player. Make sure to have an event hook for "custom_message" to receive the response. Required permissions: - interactive-message.create
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: ApiKeyHeader
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-WebAPI-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-WebAPI-Key', 'Bearer');
// Configure API key authorization: ApiKeyQuery
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('key', 'Bearer');
$apiInstance = new Swagger\Client\Api\InteractiveMessageApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$body = new \Swagger\Client\Model\InteractiveMessage(); // \Swagger\Client\Model\InteractiveMessage |
$details = true; // bool | Add to include additional details, omit or false otherwise
$accept = "accept_example"; // string | Override the 'Accept' request header (useful for debugging your requests)
$pretty = true; // bool | Add to make the Web-API pretty print the response (useful for debugging your requests)
try {
$result = $apiInstance->sendMessage($body, $details, $accept, $pretty);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling InteractiveMessageApi->sendMessage: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
body | \Swagger\Client\Model\InteractiveMessage | [optional] | |
details | bool | Add to include additional details, omit or false otherwise | [optional] |
accept | string | Override the 'Accept' request header (useful for debugging your requests) | [optional] |
pretty | bool | Add to make the Web-API pretty print the response (useful for debugging your requests) | [optional] |
\Swagger\Client\Model\InteractiveMessage
- Content-Type: application/json, application/xml
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]