# Getting Started

1. Register for openioe web portal

&#x20;      <https://openioe.gnanodaya.org>

2. Install openioe from the terminal(Linux)/ cmd (Windows)

```
pip install openioe
```

3. Generate API Key

```python
from openioe.openioe_apis import *
oi=openioe_apis()
oi.UserEmail='xxxxxxxxxx'
oi.UserPassword='xxxxxxxxxxx'
ResponseJson,ResponseCode=oi.GenerateAPIKey()
APIKey=ResponseJson['API Key'])
```

3. Add IoT Device/s

```python
oi.APIKey=APIKey
oi.DeviceName='Test000'
oi.CryptoName='None'
oi.DataFormat='Value'
ResponseTest,ResponseCode=oi.CreateDevice()
print(ResponseTest)
print(ResponseCode)
```

4. Read from IoT Device

```python
oi.DeviceID=xx
oi.DevicePin=xxx
SensorData,ResposeCode=oi.ReadValue()
print(SensorData)
print(ResposeCode)
```

5. Write to IoT Device

```python
oi.Data=10
SensorData,ResposeCode=oi.WriteValue()
print(SensorData)
print(ResposeCode)
```


---

# 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://doc.openioe.in/python-library/getting-started.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.
