Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
86b02cf
Add IntegrationConnector and IntegrationConnectorType modules with co…
mateuscardosodeveloper May 6, 2025
8ee63cd
Add IntegrationConnector documentation and update Resources index
mateuscardosodeveloper May 6, 2025
060331a
Add tests for Connectors class methods in test_integration_connector.py
mateuscardosodeveloper May 6, 2025
df94233
Remove unused import of Any from IntegrationConnector module
mateuscardosodeveloper May 6, 2025
822b720
Add Notifications module and integrate it into Resources and AccountD…
mateuscardosodeveloper May 8, 2025
a5d2495
Add tests for Notifications class methods in test_notifications.py
mateuscardosodeveloper May 8, 2025
c4cf7af
Add detailed documentation for Notification types and update Resource…
mateuscardosodeveloper May 8, 2025
ae091e0
Add Secrets module and integrate it into Resources and AccountDeprecated
mateuscardosodeveloper May 12, 2025
2ad831f
Add tests for Secrets class methods in test_secrets.py
mateuscardosodeveloper May 12, 2025
f0b5e69
Add documentation for Secrets module and create index entries for Sec…
mateuscardosodeveloper May 12, 2025
8ca0486
Add ServiceAuthorization module and integrate it into Resources and A…
mateuscardosodeveloper May 12, 2025
df59926
Add tests for ServiceAuthorization methods including tokenList, token…
mateuscardosodeveloper May 12, 2025
fc8d45c
Add ServiceAuthorization documentation and integrate into Resources i…
mateuscardosodeveloper May 12, 2025
40dbbb4
Refactor import statement in ServiceAuthorization module to remove un…
mateuscardosodeveloper May 12, 2025
70a13ae
Merge pull request #47 from tago-io/feat/add-service-authorization-cl…
felipefdl Jul 26, 2025
e820d82
Merge pull request #46 from tago-io/feat/add-secrets-class/SDKPY-128
felipefdl Jul 26, 2025
4ef9ffa
Merge pull request #45 from tago-io/feat/add-notifications-class/SDKP…
felipefdl Jul 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
**Integration Connector Type**
==============================


.. _IDeviceParameters:

IDeviceParameters
----------------

**Attributes:**

| **name**: Optional[str]
| Name of the device parameter.

| **label**: Optional[str]
| Display label for the device parameter.

| **type**: Optional["text" or "dropdown" or "switch" or "number"]
| The type of input for the device parameter.

| **default**: Any
| Default value for the device parameter.

| **group**: Optional["default" or "main" or "advanced" or "hide"]
| Group category for the device parameter.

| **options**: Optional[List[Any]]
| List of options (Optional only for dropdown).


.. _ConnectorCreateInfo:

ConnectorCreateInfo
------------------

**Attributes:**

| **name**: Optional[str]
| The name of the connector.

| **description**: Optional[str]
| Description of the connector.

| **logo_url**: Optional[str]
| URL for the connector's logo image.

| **device_parameters**: Optional[List[:ref:`IDeviceParameters`]]
| List of device parameters for the connector.

| **networks**: Optional[List[:ref:`GenericID`]]
| List of network IDs associated with the connector.

| **payload_encoder**: Optional[str]
| Function to encode payload data.

| **payload_decoder**: Optional[str]
| Base64 decoded string for parsing payload data.

| **install_text**: Optional[str]
| Refers to the **description** in the Documentation settings.

| **install_end_text**: Optional[str]
| Refers to the **completion text** in the Documentation settings.

| **device_annotation**: Optional[str]
| Additional notes or annotations for the device.


.. _ConnectorInfo:

ConnectorInfo(:ref:`ConnectorCreateInfo`)
------------

**Attributes:**

| **id**: :ref:`GenericID`
| Unique identifier for the connector.

| **public**: bool
| Indicates if the connector is public.

| **description**: Optional[str]
| Description of the connector.

| **logo_url**: Optional[str]
| URL for the connector's logo image.

| **created_at**: datetime
| Date and time when the connector was created.

| **updated_at**: datetime
| Date and time when the connector was last updated.

| **device_parameters**: Optional[List[:ref:`IDeviceParameters`]]
| List of device parameters for the connector.

| **networks**: Optional[List[:ref:`GenericID`]]
| List of network IDs associated with the connector.

| **install_text**: Optional[str]
| Refers to the **description** in the Documentation settings.

| **install_end_text**: Optional[str]
| Refers to the **completion text** in the Documentation settings.

| **device_annotation**: Optional[str]
| Additional notes or annotations for the device.


.. _ConnectorQuery:

ConnectorQuery(:ref:`Query`)
-------------

**Attributes:**

| **fields**: Optional[List["name" or "id" or "description" or "logo_url" or "install_text" or "install_end_text" or "device_annotation" or "payload_decoder" or "networks"]]
| List of fields to include in query results.

| **filters**: Optional[:ref:`ConnectorInfo`]
| Filter criteria for the connector query.
149 changes: 149 additions & 0 deletions docs/source/Resources/IntegrationConnector/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,149 @@
**Integration Connector**
==========

Manage connectors in your application.

========
list
========

Lists all connectors from the application with pagination support.

See: `Connector Overview <https://help.tago.io/portal/en/kb/articles/466-connector-overview>`_

**Parameters:**

| *Optional* **queryObj**: :ref:`ConnectorQuery`
| Query parameters to filter the results.

**Returns:**

| list[:ref:`ConnectorInfo`]

.. code-block:: python

from tagoio_sdk import Resources

resources = Resources()
result = resources.integration.connectors.list({
"page": 1,
"fields": ["id", "name"],
"amount": 10,
"orderBy": ["name", "asc"]
})
print(result) # [{'id': 'connector-id-123', 'name': 'My Connector'}, ...]


========
info
========

Retrieves detailed information about a specific connector.

See: `Connector Overview <https://help.tago.io/portal/en/kb/articles/466-connector-overview>`_

**Parameters:**

| **connectorID**: GenericID: str
| Connector ID

| *Optional* **fields**: List[str]
| List of fields to retrieve

**Returns:**

| :ref:`ConnectorInfo`

.. code-block:: python

from tagoio_sdk import Resources

resources = Resources()
result = resources.integration.connectors.info("connector-id-123", ["id", "name"])
print(result) # {'id': 'connector-id-123', 'name': 'My Connector', 'profile': 'profile-id-123'}


========
create
========

Creates a new connector in the application.

See: `Creating a connector <https://help.tago.io/portal/en/kb/articles/466-connector-overview#Creating_a_connector>`_

**Parameters:**

| **connectorObj**: :ref:`ConnectorCreateInfo`
| Object with connector properties

**Returns:**

| dict[str, GenericID]

.. code-block:: python

from tagoio_sdk import Resources

resources = Resources()
result = resources.integration.connectors.create({
"name": "My Connector",
"type": "custom",
"networks": ["network-id-123"],
"enabled": True
})
print(result["connector"]) # 'connector-id-123'


========
edit
========

Modifies an existing connector's properties.

See: `Connector Overview <https://help.tago.io/portal/en/kb/articles/466-connector-overview>`_

**Parameters:**

| **connectorID**: GenericID: str
| Connector ID

| **connectorObj**: Dict
| Object with properties to update

**Returns:**

| str

.. code-block:: python

from tagoio_sdk import Resources

resources = Resources()
result = resources.integration.connectors.edit("connector-id-123", {"name": "Updated Connector"})
print(result) # Connector Successfully Updated


========
delete
========

Deletes a connector from the application.

See: `Connector Overview <https://help.tago.io/portal/en/kb/articles/466-connector-overview>`_

**Parameters:**

| **connectorID**: str
| Connector ID

**Returns:**

| str

.. code-block:: python

from tagoio_sdk import Resources

resources = Resources()
result = resources.integration.connectors.delete("connector-id-123")
print(result) # Connector Successfully Deleted
Loading