# Technical Integration

## Step 1: Access Credentials

Get your Username, Password, and CustomerPackageId from your CSM.

You will receive access to three RabbitMQ virtual hosts:

* `/fixtures` – pre-event metadata
* `/Inplay_Tips` – real-time tips (added/removed)
* `/Prematch_Tips` – tips for future games (fixtures) (added/removed)

***

## Step 2: Queue Provisioning

For each vhost, LSports provisions a queue per customer.

**Queue name (all vhosts):** `_{CustomerPackageId}_`

**Encoding:** UTF-8 JSON

**Transport:** AMQP 0-9-1 over TLS (port 5671)

***

## Step 3: Establish Connections

**Host:** `engage.lsports.eu` **Port:** 5671 (AMQP 0-9-1 over TLS)

Open three AMQP connections (one per vhost) and consume from the same queue name on each vhost:

* `/fixtures` → `_{CustomerPackageId}_`
* `/Inplay_Tips` → `_{CustomerPackageId}_`
* `/Prematch_Tips` → `_{CustomerPackageId}_`

Integration examples in C#, Python, and Java appear under Code Samples below.

***

## Step 4: Data Mapping

### Fixtures

Subscribe to `/fixtures` and persist by `body.fixtureId`.

* Delta updates only (messages are sent only on change).
* Use add or update: unknown fixture ⇒ add; known fixture ⇒ update changed fields.

### Inplay\_Tips

Subscribe to `/Inplay_Tips` and correlate by `body.fixtureId` against your fixtures store.

* Two message kinds: Added (1) and Removed (2).
* For Added, you get full tip objects; for Removed, you get IDs to remove.

### Prematch\_Tips

Subscribe to `/Prematch_Tips` and correlate by `body.fixtureId` against your fixtures store.

* Two message kinds: Added (1) and Removed (2).
* For Added, you get full tip objects; for Removed, you get IDs to remove.


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.lsports.eu/u/engage/tips-feed/technical-integration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
