# Event Module

Event module fetches event logs.

### 9.1 Get Logs

Get the emitted events of a smart contract.

{% tabs %}
{% tab title="Python" %}
Function Name

```python
get_logs
```

{% tabs %}
{% tab title="Query" %}

* Arguments

  ```python
  address (str): The address of the smart contract.
  ```
* Example Code

  ```python
  from crypto_com_developer_platform_client import Event

  logs = Event.get_logs('0x596A29345b8CAA702544B9167590c648efedB7B0')
  print(logs)
  ```

{% endtab %}

{% tab title="Response" %}

* Returns

  ```python
  A list of decoded contract events.
  ```
* Errors

  ```python
  ValueError: If the Event class is not initialized with a Client instance.
  ```
* Example Return

  ```python
  {'status': 'Success', 'data': {'logs': [{'_type': 'log', 'address': 'example-address', 'blockHash': 'example-hash', 'blockNumber': example-block-number, 'data': 'example-data', 'index': example-index, 'removed': example-boolean, 'topics': ['example-hash', 'example-hash'], 'transactionHash': 'example-hash', 'transactionIndex': example-index}, ...]}}
  ```

{% endtab %}
{% endtabs %}
{% endtab %}
{% endtabs %}


---

# 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://ai-agent-sdk-docs.crypto.com/crypto.com-developer-platform/on-chain-developer-platform-client-sdk/event-module.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.
