Developers
Our platform was built to be flexible and intuitive for developers like you. You own all the data you collect with Tradable Bits. Our API and SDK are designed to make it easy to access your fan data, tickets and campaigns at any time, on your terms Customize the front end of any of your campaigns with the help of our documentation, complete with examples. Our RESTful API helps you access, send or receive fan data from our system to your endpoints quickly and securely. Enrich your Fan CRM and Tickets Analytics with data from other CRM systems through our many integrations. Have any questions about our developers platform? Our support team is happy to help.
Tracker and Google Sheets Integration

You can easily integrate Generation of tracker urls into Google Sheets via custom Javascript function.

Step 1: Open the Spreadsheet and navigate to Tools -> Script Editor

Step 2: Add Function Definition for Tracker Integration


/**
 * Tradable Bits Tracker
 * @customfunction
 */
function createTracker(name, group, url, network, tracker_key) {
  // tracker_name, tracker_group_name and tracker_url are required
  // network and tracker_key are optional
  var tracker_name = name;
  var tracker_group_name = group;
  var tracker_url = url;
  var network = network;
  var tracker_key = tracker_key;

  if (!(tracker_name && tracker_group_name && tracker_url)) {
    return null
  }
  // TradableBits Public API Key goes here
  var api_key = 'XXXX-XXXX-XXXXX-XXXXX';
  var data = {
    'api_key': api_key,
    'tracker_name': tracker_name,
    'tracker_group_name': tracker_group_name,
    'tracker_url': tracker_url,
    'tracker_key': tracker_key,
    'network': network,
    'virtual_domain': 'tradablebits.com'
  }
  var url = 'https://tradablebits.com/api/v1/trackers/';
  var options = {
    'method': 'post',
    'payload': data
  }
  var response = JSON.parse(UrlFetchApp.fetch(url, options).getContentText())
  return 'https://' + response.virtual_domain + '/trk/' + response.tracker_key
}

function onOpen() {
  // Checkbox column location
  var checkboxColumn = "F"
  var sheet = SpreadsheetApp.getActiveSpreadsheet().getActiveSheet();
  var range = sheet.getRange(checkboxColumn + ":" + checkboxColumn);
  var values = range.getValues();

  for (var i = 0; i < values.length; i++) {
    if((values[i][0] == true))
    values[i][0] = false;
  }
  range.setValues(values);
}
    

Step 3: Open the Spreadsheet and make cell F1 a checkbox

Step 4: Enter the value in cell G1 as

=IF(F1=TRUE, createTracker(A1,B1,C1,D1,E1), G1)

Step 5: Navigate to File -> Settings -> Calculation tab -> Turn on Iterative calculation. Set Max number of iterations to 1

Step 6: Assuming that values in A1,B1,C1,D1,E1 are correct, and you put the correct API KEY, tracker shortened url will show up in cell G1 after F1 is checked