TickAtlas
Beginner ~10 min

Google Sheets Integration

Pull live indicator data directly into Google Sheets with a custom function. No coding experience required beyond copy-paste.

Step 1: Open Apps Script

In your Google Sheet, go to Extensions > Apps Script. Delete any existing code and paste the function below.

Step 2: Add the Custom Function

javascript
function TICKATLAS(symbol, indicator, timeframe) {
  var API_KEY = PropertiesService.getScriptProperties().getProperty("CLAW_API_KEY");
  var url = "https://tickatlas.com/v1/indicator"
    + "?symbol=" + symbol
    + "&indicator=" + indicator
    + "&timeframe=" + timeframe;

  var options = {
    "method": "get",
    "headers": { "X-API-Key": API_KEY },
    "muteHttpExceptions": true
  };

  var response = UrlFetchApp.fetch(url, options);
  var data = JSON.parse(response.getContentText());
  return data.value;
}

// Usage in cell: =TICKATLAS("EURUSD", "RSI_14", "H1")

Step 3: Store Your API Key

In the Apps Script editor, go to Project Settings > Script Properties and add a property named CLAW_API_KEY with your API key as the value.

Step 4: Use in Cells

Cell FormulaResult
=TICKATLAS("EURUSD","RSI_14","H1")58.43
=TICKATLAS("XAUUSD","ATR_14","D1")28.50
=TICKATLAS("GBPUSD","MACD_main","H4")0.00123

Tips for a Reliable Sheet

  • Custom functions cache by their arguments, so Sheets may not re-run on every edit. Add a time-driven trigger or a hidden timestamp argument when you need values to refresh on a schedule rather than only on recalculation.
  • Mind your rate limit: a sheet with a hundred TICKATLAS() calls fires a hundred requests on every full recalculation. Pull a batch with /v1/multi into a single cell and reference it from the others to stay well within your plan.
  • Handle errors gracefully — check that data.value exists before returning it, so a failed call surfaces a clear message in the cell instead of a cryptic #ERROR! that is hard to debug.
  • Keep your key in Script Properties, never in a cell. Anyone with view access to the spreadsheet can read cell contents, but script properties stay private to the project.

Related