Gorilla Dash

arrow_back Back to Knowledge Base

Your tribes: the tribes endpoint

download Download PDF

Tribes are called tribes throughout the Gorilla Dash API. GET https://api.gorilladash.com/api/v1/tribes lists them, and GET /tribes/{id} returns one.

This is the endpoint behind a "our tribes" page: name, address, coordinates, phone numbers and opening hours, all kept current from Gorilla Dash rather than hand-edited on your site.

Listing tribes

ParameterNotes
pagePage number, from 1.
results_per_pageDefaults to just 5. Set it. Values above 1000 are clamped to 1000 rather than refused.
statusWhich tribes to include — see below.
THE DEFAULT PAGE SIZE IS FIVE
Unlike every other list endpoint, this one defaults to five results. If your tribe list is mysteriously short, that is why. Always pass results_per_page explicitly.
statusReturns
omittedLaunched tribes — Active and Opening Soon. The default, and what a public website normally wants.
launchThe same as omitting it.
activeActive tribes only.
opening soonTribes marked as opening soon.
allActive, testing and opening soon together.

Tribes come back newest first.

One tribe

GET /tribes/{id} accepts either the numeric id or the slug, so /tribes/482 and /tribes/brisbane-north both work. It takes the same status parameter, and answers 404 if the tribe exists but does not match the status you asked for.

What comes back

FieldNotes
id, slug, nameIdentity. Key your own records on id; use the slug in URLs and when routing an enquiry.
global_idYour own identifier for the tribe, if you set one.
statusActive, Testing, Opening Soon and so on.
address_1, address_2, locality, state, state_abbreviated, postal_code, countryThe address.
latitude, longitudeCoordinates, for maps.
main_telephoneThe tribe's own number.
paid_number, paid_number_e164The tracking number to show visitors arriving from paid campaigns.
organic_number, organic_number_e164The tracking number to show everyone else.
website_number_swap_enabledWhether number swapping is switched on for this tribe.
opening_hours_arrayOpening hours, day by day.
square_urlThe tribe's square image, if it has one.

Number swapping

The paid and organic numbers exist so a website can show a different phone number depending on how the visitor arrived, which is what lets Gorilla Dash attribute a phone call to a campaign.

  1. If website_number_swap_enabled is false, show main_telephone and stop.
  2. If the visitor arrived with paid campaign parameters, show paid_number.
  3. Otherwise show organic_number.
  4. If the number you chose is empty, fall back to main_telephone.

Use the _e164 variant for the tel: link and the plain one for the text a visitor reads.

Scoping and caching

An organisation key sees every tribe. A tribe key sees only itself — which is exactly what you want for a single-tribe website.

Both endpoints are cached and send an ETag. An edit to a tribe can take a few minutes to show up.

BUILDING A STORE LOCATOR?
This endpoint lists tribes; it does not sort them by distance. For "nearest to me", use POST /tribes/search instead — it geocodes an address or takes coordinates and returns the closest tribes in order.

If you are building website pages rather than a list, look at GET /wordpress/tribes/{id} as well: it returns the same tribe plus headings, introductions, social links, galleries and review scores in one call.