Skip to main content

Introduction

New API (V3) is available since netDecor V4.26, and should be used in all new integrations. Since V3 does not support all features available in V2, use older API when is't necessary.

caution

Mixing two API versions is possible only on a namespace level. In example, you can use project namespace form V3 along with Shop from V2. However, using both v3.project and Project form V2 in one implementation, may lead to undefined behavior and cause application ustability. If you have questions regarding this topic use netDecors's bugtracker to ask our team directly.

There are few differences between V2 and V3 APIs. In V3, arguments are passed as JavaScript objects, while V2 used JSON-formated strings. With this change it's possible to pass function pointers and binary arrays to API methods.

V3 API is available under v3 namespace of global NetDecor object, after application is fully initialized (RunNetPlusApp was called and onAPIInitialised event was successfuly executed). Example API location:

NetDecor.v3.project.getCurrentProject()