# External Libraries

In a lot of cases, you may require some functionality in your code which can be easily solved by importing an existing library or a script. Writing custom logic for everything can be time-consuming and may not always be helpful. Hence, with IoTIFY, you can import any NPM package or a custom script you can find online to help you write your code easily.

To import any library or a custom script, go to the Library tab and here you can add up to 5 libraries and scripts in total.

![](https://1549501356-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LhKFvCh4dnxgthNTIuu%2Fuploads%2F4pq6LSlL5t6MbmzHsU9s%2FIFY_Test_Library.png?alt=media\&token=aeca42a2-138c-48c9-835b-fc915e7331c3)

**Import As**: Name of the module object that will be used as a kind of namespace when referring to the imported library.

**Type**: Select whether you are importing an NPM package or a custom script.

**NPM Package or Public node script**: The name of a valid NPM package or an URL to the custom script. When a valid package name or URL is given the icon beside the input turns into a tick mark. This means that it is a valid package and can be imported into the test.

To delete any of the packages, you can click on the cross icon at the right end of the library.

{% hint style="warning" %}
You can only import up to a total of 5 additional packages into the tests. &#x20;

Many commonly used libraries are already inbuilt into IoTIFY, which you do not need to separately import. We will look into all the inbuilt libraries shortly.
{% endhint %}
