Skip to content

Instantly share code, notes, and snippets.

View crowdfundhq's full-sized avatar

CrowdfundHQ crowdfundhq

View GitHub Profile
@crowdfundhq
crowdfundhq / api_usage.html
Last active October 26, 2016 12:48
An example of how to use the CrowdfundHQ API from within your site
<script>
// Enable 'Sessions enabled' in Manage Site > Configuration > Settings > API
// Then use this script in Manage Site > Design > Pages or Scripts to fetch users
document.addEventListener('DOMContentLoaded', function(){
// Define variables
var url = '/api/v1/user/list', result, list, user;
// Do ajax call using hq.js
hq.ajax(url, {
success: function(json) {