Skip to content

Latest commit

 

History

History
237 lines (185 loc) · 9.46 KB

File metadata and controls

237 lines (185 loc) · 9.46 KB

IO.Swagger.Api.InteractiveMessageApi

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

GetMessage

InteractiveMessage GetMessage (Guid? uuid, bool? details = null, string accept = null, bool? pretty = null)

Get a message

Get detailed information about a message. Required permissions: - interactive-message.one

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class GetMessageExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyHeader
            Configuration.Default.AddApiKey("X-WebAPI-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-WebAPI-Key", "Bearer");
            // Configure API key authorization: ApiKeyQuery
            Configuration.Default.AddApiKey("key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("key", "Bearer");

            var apiInstance = new InteractiveMessageApi();
            var uuid = new Guid?(); // Guid? | The uuid of the sent message
            var details = true;  // bool? | Add to include additional details, omit or false otherwise (optional) 
            var accept = accept_example;  // string | Override the 'Accept' request header (useful for debugging your requests) (optional) 
            var pretty = true;  // bool? | Add to make the Web-API pretty print the response (useful for debugging your requests) (optional) 

            try
            {
                // Get a message
                InteractiveMessage result = apiInstance.GetMessage(uuid, details, accept, pretty);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling InteractiveMessageApi.GetMessage: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
uuid Guid? 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]

Return type

InteractiveMessage

Authorization

ApiKeyHeader, ApiKeyQuery

HTTP request headers

  • 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]

ListMessages

List ListMessages (bool? details = null, string accept = null, bool? pretty = null)

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

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class ListMessagesExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyHeader
            Configuration.Default.AddApiKey("X-WebAPI-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-WebAPI-Key", "Bearer");
            // Configure API key authorization: ApiKeyQuery
            Configuration.Default.AddApiKey("key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("key", "Bearer");

            var apiInstance = new InteractiveMessageApi();
            var details = true;  // bool? | Add to include additional details, omit or false otherwise (optional) 
            var accept = accept_example;  // string | Override the 'Accept' request header (useful for debugging your requests) (optional) 
            var pretty = true;  // bool? | Add to make the Web-API pretty print the response (useful for debugging your requests) (optional) 

            try
            {
                // List messages
                List<InteractiveMessage> result = apiInstance.ListMessages(details, accept, pretty);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling InteractiveMessageApi.ListMessages: " + e.Message );
            }
        }
    }
}

Parameters

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]

Return type

List

Authorization

ApiKeyHeader, ApiKeyQuery

HTTP request headers

  • 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]

SendMessage

InteractiveMessage SendMessage (InteractiveMessage body = null, bool? details = null, string accept = null, bool? pretty = null)

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

Example

using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class SendMessageExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyHeader
            Configuration.Default.AddApiKey("X-WebAPI-Key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("X-WebAPI-Key", "Bearer");
            // Configure API key authorization: ApiKeyQuery
            Configuration.Default.AddApiKey("key", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("key", "Bearer");

            var apiInstance = new InteractiveMessageApi();
            var body = new InteractiveMessage(); // InteractiveMessage |  (optional) 
            var details = true;  // bool? | Add to include additional details, omit or false otherwise (optional) 
            var accept = accept_example;  // string | Override the 'Accept' request header (useful for debugging your requests) (optional) 
            var pretty = true;  // bool? | Add to make the Web-API pretty print the response (useful for debugging your requests) (optional) 

            try
            {
                // Send a message
                InteractiveMessage result = apiInstance.SendMessage(body, details, accept, pretty);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling InteractiveMessageApi.SendMessage: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
body 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]

Return type

InteractiveMessage

Authorization

ApiKeyHeader, ApiKeyQuery

HTTP request headers

  • 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]