# Hướng dẫn sử dụng Custom node trong automation

Custom node giúp cho việc viết script của bạn dễ dàng hơn. Bạn có thể đóng gói một script thành custom node và sử dụng trong 1 script khác. Thay vì việc phải kéo thả nhiều node thì bạn chỉ cần sử dụng 1 node duy nhất đó là custom node.

1. **Hướng dẫn tạo một custom node:**

Bước 1: Tạo 1 script không chứa custom node và không chứa node Run other script

Bước 2: Chọn script và click vào button Convert to node

<img src="http://education.hidemium.io/wp-content/uploads/2024/11/Picture1.png" alt="" height="283" width="624">

&#x20;

Bước 3: Khi popup hiện lên, bạn nhập tên của custom node và nhập mô tả. Lưu ý tên custom node phải nhỏ hơn 30 kí tự và khi tạo thành công thì sẽ không được sửa tên của custom node. Phần mô tả có thể có hoặc không, và phải nhỏ hơn 255 kí tự.

Bước 4: Sau khi tạo thành công thì có thể xem các custom node trong tab Custom node.  Bạn cũng có thể chỉnh sửa Mô tả của custom node.

<img src="http://education.hidemium.io/wp-content/uploads/2024/11/Picture2.png" alt="" height="277" width="624">

&#x20;

**Lưu ý khi tạo custom node: Custom node không được chứa node run other script và custom node khác. Khi 1 custom node được tạo thì sẽ không thể sửa lại tên của custom node đó.**

&#x20;

&#x20;     **2.  Update vào custom node đã có:**

Bạn cũng node thể update 1 script đã có vào custom node. Khi bạn update như vậy thì script sẽ ghi đè vào custom node đã có.

Bước 1: Chọn 1 script để update custom node -> Chọn button Convert to node.

Bước 2: Khi popup hiện ra, bạn chọn tab Update an existing node, sau đó bạn chọn một custom node mà bạn muốn update script vào. Tại đây bạn cũng có thể sửa lại mô tả của custom node.

<img src="http://education.hidemium.io/wp-content/uploads/2024/11/Picture3.png" alt="" height="372" width="531">

&#x20;

&#x20;     **3. Hướng dẫn sử dụng custom node đã tạo**

Bước 1: Tại màn tạo Script, các custom node sẽ hiển thị tại Library custom node

<img src="http://education.hidemium.io/wp-content/uploads/2024/11/Picture4.png" alt="" height="395" width="624">

&#x20;

Bước 2: khi popup hiện ra, bạn chỉ cần chọn custom node muốn sử dụng và click button Submit

Bước 3: Khi sử dụng bạn cũng có thể thay đổi giá trị của biến trong custom node.

<img src="http://education.hidemium.io/wp-content/uploads/2024/11/Picture5.png" alt="" height="521" width="623">


---

# 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.hidemium.io/hidemium-4/iv.-tu-dong-hoa-automation-and-ai/huong-dan-su-dung-custom-node-trong-automation.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.
