How to create Module though API
How to create Module though API.
1) I can goto Administrator--> Module Builder and the create module. (This step I want to do through API)
2) And then go-to the newly create module and add content type to it.
3) Then I can click Code reference for <Module Name created in step 1> and use API's to add/remove/update items inside the module (content type)
Now question is how do I can create module with API. I want to insert data through API which is possible with the code provided in step 3, but in-case we can't find module then system should do following
Note: I am able to insert data to module through API's and only needed a way to create module with API.
Cheers
Hello Hardeep,
Currently you can create dynamic modules only from the Sitefinity backend using the Module Builder. You can refer to the following article from our documentation on how to achieve this. Code samples are automatically generated for the dynamic module you have created and you can use it as a sample on how to work with your dynamic module programmatically - e.g. how to create a dynamic module item, to delete a dynamic module item, to get a collection of dynamic module items through filtering and etc.
Creating the dynamic module itself via the Api is not possible due to the complexity of the implementation and the fact that all the Api is internal.
Alternatively, module structure can be exported and imported from the UI which can save time.
I hope this helps.
Regards,
Ivan D. Dimitrov
Telerik