This page contains some example code to use javascript within SSP
Adding Timeslots to datastore
Storing PowerShell results in datastore
Filtering on JSON array
Working with dates
Retrieving all service details through public API