GoliathDevelopersGet an API key
Reference/Teamgenerated from the gateway manifest

getMemberActivity

WHAT ONE PERSON DID in a time window.

POST/api/v1/callREADreadruns as the key's owner
View as Markdown

WHAT ONE PERSON DID in a time window ("what did I do today", "how was my week", "what did Sam get done yesterday") in ONE call: their own texts (sent/delivered/failed), calls (outbound, inbound, connected, conversations, talkSeconds), emailsSent, notesWritten, tasksCreated, appointmentsBooked, tasksCompleted and dealStageMoves. Counts only, live. Use it instead of combining countOutboundTexts, getTeamCallStats and timeline reads. WINDOW: startDate (inclusive) and endDate (exclusive) as ISO datetimes WITH an offset, resolved in the USER's timezone (getMyProfile.resolvedTimezone): "today" is local midnight to now or to the next midnight. At most 93 calendar days; wider is REFUSED. WHO: omit userId for the key owner; naming a teammate needs VIEW_ALL_PHONES (org admins hold it) and is REFUSED otherwise. WHAT IS THEIRS: only work the person did themselves; an AI employee, a workflow or an outreach tool working on their behalf is never counted, nor is a bulk action or import, and notes, tasks and appointments count when made by hand in the app (texts and calls follow countOutboundTexts and getTeamCallStats). emailsSent is outbound mail from their connected mailbox. tasksCompleted is tasks they are on that were completed in the window (who ticked it is not recorded). dealStageMoves is moves they made by hand. For the records themselves, read the timeline or lists afterwards.

curl https://server.goliathdata.com/api/v1/call \
  -H "Authorization: Bearer $GOLIATH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "operationId": "getMemberActivity",
    "variables": {
      "startDate": "2026-01-01T00:00:00.000Z",
      "endDate": "2026-01-01T00:00:00.000Z"
    }
  }'
import { GoliathClient } from '@goliath-data/sdk'

const goliath = new GoliathClient({
  apiKey: process.env.GOLIATH_API_KEY!,
  baseUrl: 'https://server.goliathdata.com',
})

const result = await goliath.team.getMemberActivity({
  startDate: '2026-01-01T00:00:00.000Z',
  endDate: '2026-01-01T00:00:00.000Z'
})
const res = await fetch('https://server.goliathdata.com/api/v1/call', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.GOLIATH_API_KEY}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    operationId: 'getMemberActivity',
    variables: {
      startDate: '2026-01-01T00:00:00.000Z',
      endDate: '2026-01-01T00:00:00.000Z'
    }
  }),
})
const { data, errors } = await res.json()

Variables

The example sends only what the schema requires. Some operations also need one of several optional variables (one filter or another, say); the description above says which.

startDateDateTime!required
endDateDateTime!required
userIdID

Response

What comes back under data: a list shows as one entry, and a value as its type.

response shape
{
  "data": {
    "teamAnalyticsQuery": {
      "memberActivity": {
        "startDate": "2026-01-01T00:00:00.000Z",
        "endDate": "2026-01-01T00:00:00.000Z",
        "userId": "<ID>",
        "name": "…",
        "texts": {
          "sent": 0,
          "delivered": 0,
          "failed": 0
        },
        "calls": {
          "outboundCalls": 0,
          "inboundCalls": 0,
          "connectedCalls": 0,
          "conversationCalls": 0,
          "talkSeconds": 0
        },
        "emailsSent": 0,
        "notesWritten": 0,
        "tasksCreated": 0,
        "appointmentsBooked": 0,
        "tasksCompleted": 0,
        "dealStageMoves": 0
      }
    }
  }
}

Errors

Behaviour

A read. It rejects an Idempotency-Key header with 400 bad_request.