Developed by YOVU Office Phone
source/delete-shared-contact/DeleteSharedContact.py
Netsapiens API Documentation - Delete a Contact
You can delete all shared contacts using this script. You may repurpose the script to loop through your own list of contact ids and delete them from the server.
Warning: Make sure you know what you are doing before proceeding. Backup if needed. We are not responsible for any changes you make to your system using this script.
You must add your credentails in Settings.ini
for the script to work.These details are used for Authentication
- Server Name. example: api.netsapiens.com ; Please do not include http// or https://
- API Client Id : Client Id of your app that you created in Netsapiens.
- Client Secret : Client Secret corresponding to the client id above.
- Domain : Domain Name from which you want to delete the shared contacts.
- User Name : Your login username for the server.
- Password : Your password you use to login.
If you like you can also hardcode the credentials within the py script and run the script.
After Execution of the script:
Logs can be found in : NSLog.log
Success.csv
will hold the list of shared contacts that were successfully deleted.
Fail.csv
will hold the list of shared contacts that were not deleted.
We have included a GUI version of the same script. source/delete-shared-contact/DeleteShareContactUI.py
You can modify the GUI version to meet your purpose.
source/read-all-devices-domain/ReadAllDevices.py
Netsapiens API Documentation - Devices Read
- You can use this script to fetch all devices within a domain. I have added only eight fields for download. You can alter the
class Device
to add more as per your need. - You can edit line
108 : read_all_devices('domainName')
to run the script for different domain. - You need to have atleast Reseller permission to read all devices within the domain. Please refer netsapiens documentation for fields,parameters and response.
After successfully running the script:
ListOfSubscribers.csv
will hold the details of all the devices within that domain.
Technical Details: There is a 5 second delay after every 25th delete request in case you are deleting a lot of request. But it is recommended to batchify the code if required.