List Users

List Users

GET https://api.ocamba.com/v1/hood/users
Returns a list of Users

Rate limits:

  • Burst: 10/s
  • Steady: 150/m

Query parameters

parameters

Response schemas

curl -X GET \
 "https://api.ocamba.com/v1/hood/users" \
  -H "Authorization: Bearer {TOKEN}"
const url = 'https://api.ocamba.com/v1/hood/users';
const options = {
  method: 'GET',
  headers: {
    Authorization: `Bearer {TOKEN}`
  }
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
$ch = curl_init("https://api.ocamba.com/v1/hood/users");
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
curl_setopt($ch, CURLOPT_HTTPHEADER, [
  "Authorization: Bearer {TOKEN}"
]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);

Responses

200 OK

{
  "total": 20,
  "items": [
    {
      "client_id": "16959755123015102980",
      "first_session_date": "2023-09-29",
      "tag_id": "1704",
      "app_type": "web",
      "app_name": "dev.ocamba.info",
      "country_code": "RS",
      "region": "7581800",
      "city": "792078",
      "asn": "203512",
      "os_id": "4",
      "os_version": "10",
      "browser_id": "12",
      "browser_version": "117",
      "user_lang": "en",
      "timezone": "Europe/Belgrade",
      "last_session_time": "2023-09-29 08:18:35",
      "total_sessions": "1",
      "total_pageviews": "1",
      "total_goals": "0",
      "traffic_source_type": "Direct",
      "last_clicked": "1970-01-01 00:00:00",
      "push_status_str": "unknown",
      "push_wokenup": "0",
      "push_clicks": "0",
      "remote_user_id": "b8373f16-0a4b-4176-9074-f395dec19857",
      "ad_served": "0",
      "ad_impressions": "0",
      "ad_spam_impressions": "0",
      "ad_clicks": "0",
      "ad_spam_clicks": "0",
      "ad_conversions": "0",
      "income": "0",
      "cost": "0",
      "conversion_score": "25"
    }
  ]
}

400 Bad Request

{
  "code": 400,
  "title": "Bad request.",
  "message": "The request body is not valid.",
  "trace_id": "99a84211-f73d-4ff8-acdf-eb3e06bb9d62"
}

500 Internal Server Error

{
  "code": 500,
  "title": "Internal server error.",
  "trace_id": "99a84211-f73d-4ff8-acdf-eb3e06bb9d62"
}
Responses

Tip

Sortable fields are client_id, first_session_date, tag_name, app_name, app_type, country_code, region_name, city_name, isp, conn_type_name, browser_name, device_name, user_lang, last_session_time, total_pageviews, total_goals, push_subscription_time, push_unsubscription_time, push_last_touched, push_last_clicked, ad_last_served, ad_last_clicked, ad_last_impression, last_clicked, push_wokenup, push_clicks, ad_served, ad_impressions, ad_spam_impressions, ad_clicks, ad_spam_clicks, ad_conversions, income, cost, conversion_score.

Filterable fields are client_id, first_session_date, tag_id, app_type, country_code, region, city, asn, conn_type, os_id, os_version, browser_id, browser_version, device_id, user_lang, timezone, last_session_time, total_sessions, total_pageviews, total_goals, comment, utm_source, utm_medium, utm_campaign, utm_term, utm_content, push_subscription_time, push_last_clicked, ad_last_served, ad_last_clicked, ad_last_impression, last_clicked, push_unsubscription_time, push_last_touched, push_credentials, push_status, push_wokenup, push_clicks, retargeting, remote_user_id, ad_served, ad_impressions, ad_spam_impressions, ad_clicks, ad_spam_clicks, ad_conversions, income, cost, extra, is_woken_up, click_id, mobile_phone_number, sms_subscription_time, sms_status, email, email_subscription_time, email_status, conversion_score, lists.

If you don’t send first_session_date it will filter by today’s date.

If you want to filter users as clickers/non clickers, you should send values 0 or 1 on clicker parameter. Example: &clicker=1

Any PI data will be hidden by default. For now that are the SMS and Email fields of the object. If you want to read real data for these fields, add the filter “read_gdpr_fields=true” to you query. The response will have revealed these fields, if you have the necessary privilegues for this action.

Warning
This route is deprecated and will be removed in a future release. Please use the corresponding profiles-based route instead, which provides more consistent structure and aligns with the current data model.