> For the complete documentation index, see [llms.txt](https://docs.i3d.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.i3d.net/game-hosting/features/platform-events.md).

# Platform Events

{% hint style="info" %}
This is an experimental feature and currently only available upon request. Details and mechanisms for this feature can change at any moment.
{% endhint %}

It is possible to receive events from within our platform, allowing you to get more insight into which actions it performing. You could log these for your own purposes.

At the time of writing this is an experimental feature that we are testing with a few clients. There is no publicly available endpoint that allows to you automatically sign up to our event stream. But you can request access to it via the usual support channels.

## RabbitMQ

After you have requested access to the event stream, it can be accessed through a [RabbitMQ](https://www.rabbitmq.com/) connection, using the AMQP protocol. There are [libraries](https://www.rabbitmq.com/devtools.html) available for many programming languages. Statistical panels and mechanisms like Logstash also have easy means to connect to a RMQ event or message stream.

## Event structure

All events are provided via the stream as JSON objects with at least the following properties:

* level
* service
* group
* code
* message
* @timestamp
* parameters

### Example Structure

```
{
  "userId" : 174085,
  "level" : "info",
  "service" : "ha-application-instance-manager",
  "group" : "AIM",
  "code" : "AIMDestroy",
  "message" : "Application instance delete.",
  "@timestamp" : "2020-02-05T19:16:23.128Z",
  "parameters" : {
    "applicationName" : "test",
    "applicationId" : 282888204204416978,
    "deploymentEnvironmentName" : "depenv-testI3D-31-39e57d3b-0dc5-4615-a46a-7cf93ad7b7e8",
    "fleetName" : "fleet--39e57d3b-0dc5-4615-a46a-7cf93ad7b7e8",
    "installId" : 13281,
    "regionName" : "i3d-us-east-1-39e57d3b-0dc5-4615-a46a-7cf93ad7b7e8",
    "dcLocationId" : 1,
    "dcLocationName" : "Ashburn - VA",
    "applicationBuildName" : "appbuild-testI3D-31-39e57d3b-0dc5-4615-a46a-7cf93ad7b7e8",
    "applicationBuildId" : 8029997744897942721,
    "regionId" : 9126781268035892791,
    "applicationInstanceId" : 8762708736248342380,
    "deploymentEnvironmentId" : 4276611139388342629,
    "fleetId" : 8817355271013717608,
    "hostId" : 93005,
    "status" : 0
  },
  "label" : [ ],
  "stracktrace" : ""
}
```

## Event Groups and Types

There are several event groups and event types. The ones described below are not exhaustive - existing ones can change and more will be added:

### Application Instance Management

**Group**: `AIM`

| Event Name  | Description                                                                |
| ----------- | -------------------------------------------------------------------------- |
| AIMCreate   | A \[platform generated] command to create a new Application Instance       |
| AIMDeployed | An Application Instance has been deployed (installed, but not yet running) |
| AIMStarted  | An Application Instance has \[been] started                                |
| AIMStopped  | An Application Instance has \[been] stopped                                |
| AIMDestroy  | An Application Instance has been destroyed                                 |

### VM Management

**Group**: `VMM`

| Event Name  | Description             |
| ----------- | ----------------------- |
| VmCreated   | A VM has been created   |
| VmDestroyed | A VM has been destroyed |
| VmStarted   | A VM has been started   |
| VmStopped   | A VM has been stopped   |

### Arcus

**Group**: `Arcus`

| Event Name | Description                                                    |
| ---------- | -------------------------------------------------------------- |
| ArcusError | Errors encountered by Arcus (our instance management protocol) |

## TTL

Events pushed through this system have a TTL of 2 hours. If you do not consume messages within 2 hours after being published, they will be purged.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.i3d.net/game-hosting/features/platform-events.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
