Overview: What are we talking about?
This functionality is offered by Gingr, but requires the help of a 3rd party web developer hired by your business. Our support and development teams are not able to provide guidance for implementing the following instructions. For your convenience, Gingr does have an API. Requests are performed with HTTP over TLS (HTTPS) and returns a JSON object as a result. All endpoints are read only.
This article includes:
Helpful Hints: Before you begin.
- All requests must present an authorization key. The parameter name is key. If no API key is presented, a JSON object with a status of error is returned. API Keys are per-user and inherit that user's permissions. You can locate a user's API key from the Edit User page.
- In order to use an API key, the user must possess the Can Access API user permission from Left-hand Navigation: Reports and More Icon » Groups.
How to: Use Gingr's API Keys.
API Keys are found in Left-hand Navigation: Reports & More » Users » Edit User » API Keys.
HTTP POST https://{your_app}.gingrapp.com/api/v1/reservations
- retrieve a list of reservations within a given date range, or all currently checked in reservations
- required parameters
- key: 'user_specific_api_key',
- optional parameters
- location_id: 1 -- either the ID of a location in Gingr, or null - if null, all reservations from all locations are returned
- start_date: '2015-06-04T00:00:00+00:00',
- end_date: '2015-06-05T00:00:00+00:00' Important Note: the maximum range is 30 days
- OR checked_in: true (ignores start/end date)
HTTP GET https://{your_app}.gingrapp.com/api/v1/reservation_widget_data
- retrieve a summary of reservations for a given date, including # of check ins, outs and overnights.
- This is the API that powers the widget in the top-center of your Gingr Dashboard.
- required parameters
- key: 'user_specific_api_key',
- timestamp: a unix timestamp representing a date
HTTP GET https://{your_app}.gingrapp.com/api/v1/reservations_by_animal
- retrieve a list of reservations for a given animal
- required parameters
- key: - user's API Key
- id: 23 - an animal's ID
- optional parameters
- restrict_to: choose "pending_requests", "currently_checked_in", "future", "past", "wait_listed"
- params: an array of
- fromDate - ISO 8601 date format
- toDate - ISO 8601 date format
- reservationTypeIds - an array of reservation type IDs
- animalIds - an array of animal IDs
- cancelledOnly - boolean
- confirmedOnly - boolean
- completedOnly - boolean
- limit - number, only return these number of records
HTTP GET https://{your_app}.gingrapp.com/api/v1/reservations_by_owner
- retrieve a list of reservations for a given owner
- required parameters
- key: - user's API Key
- id: 23 - an owner's ID
- optional parameters
- restrict_to: choose "pending_requests", "currently_checked_in", "future", "past", "wait_listed"
- params: an array of
- fromDate - ISO 8601 date format
- toDate - ISO 8601 date format
- reservationTypeIds - an array of reservation type IDs
- animalIds - an array of animal IDs
- cancelledOnly - boolean
- confirmedOnly - boolean
- completedOnly - boolean
- limit - number, only return these number of records
- retrieve a list of reservation types
- required parameters
- key: 'user_specific_api_key',
- Optional Parameters
- id (reservation type id)
- active_only true/false
- retrieve a list of allowable additional services for a given reservation type
- Required Parameters
- key (same as other calls)
- type_id (reservation type id, integer)
- Optional parameters
- location_id (location id, integer, probably 1)
- authorize that an owner account exists and a provided password matches what we have on file
- Required Parameters
- email (customer email address)
- password (customers password in gingr)
- key (same as other calls)
- retrieve a list of recently uploaded report card files
- required fields
- key (same as other calls)
- optional fields
- number days - integer - (today - X days)
- limit - integer
- location_id
- customers that were created or modified within the given date range
- required parameters
- key: 'user_specific_api_key'
- start_date: '2015-06-04T00:00:00+00:00',
- end_date: '2015-06-05T00:00:00+00:00'
- optional parameters
- location_id -- if set, filters down to owners of the specified home location
- reservations that were cancelled within a given date range
- required parameters
- key: 'user_specific_api_key'
- start_date: '2015-06-04T00:00:00+00:00',
- end_date: '2015-06-05T00:00:00+00:00'
- optional parameters
- location_id -- if set, filters down to owners of the specified home location
- returns the form's data structure for a type of record
- required parameters
- form -- either "owner_form" or "animal_form"
- Retrieve information about a specific owner record
- required parameters
- key
- id - A gingr owner id
- retrieve a list of locations for this app
- required parameters
- key
- retrieve a list of species for this app
- required parameters
- key
HTTP GET https://{your_app}.gingrapp.com/api/v1/get_breeds
- retrieve a list of breeds for this app
- required parameters
- key
HTTP GET https://{your_app}.gingrapp.com/api/v1/get_vets
- retrieve a list of vets for this app
- required parameters
- key
HTTP GET https://{your_app}.gingrapp.com/api/v1/get_temperaments
- retrieve a list of temperaments for this app
- required parameters
- key
- retrieve a list of immunizations for a given species
- required parameters
- key
- species_id
- retrieve a list of immunization records for a given animal
- required parameters
- key
- animal_id
- retrieve a list of all retail items for sale
- required parameters
- key
- retrieve an estimated cost for a future reservation
- required parameters
- key
- id (for a reservation)
- retrieve a list of transactions
- required parameters
- key
- from_date -- ISO 8601 date
- to_date -- ISO 8601 date
- retrieve a transaction
- required parameters
- key
- id -- POS Transaction ID
- retrieve a list of timeclock records
- required parameters
- key
- start_date -- ISO 8601 date
- end_date -- ISO 8601 date
- location_id -- integer
- optional parameters
- include_deleted -- boolean
- include_clocked_in -- boolean
- user_ids -- array of user IDs
- retrieve a list of owners
- required parameters
- key
- optional parameters
- params: a key-value array of where clauses for the query
- Example cURL call that returns owners with a Zip code of 80302
curl "https://{your-subdomain-here}.gingrapp.com/api/v1/owners" \
-H 'Content-Type: application/x-www-form-urlencoded; charset=utf-8' \
--data-urlencode "key={your-key-here}" \
--data-urlencode "params[zip]=80302"
- retrieve a list of animals
- required parameters
- key
- optional parameters
- params: a key-value array of where clauses for the query
- Example cURL call that returns animals with a birthday in November (using MySQL functions)
curl "https://{your-subdomain-here}.gingrapp.com/api/v1/animals" \
-H 'Content-Type: application/x-www-form-urlencoded; charset=utf-8' \
--data-urlencode "params[month(from_unixtime(birthday))]=11" \
--data-urlencode "key={your-key-here}"
- retrieve a single subscription by its ID
- required parameters
- key
- id -- ID of a subscription
HTTP GET https://{your_app}.gingrapp.com/api/v1/get_subscriptions
- retrieve a list of subscriptions
- required parameters
- key
- optional parameters
- include_deleted -- true/false, whether canceled/deleted subscriptions should be returned in the response
- bill_day_of_month -- retrieve subscriptions set to renew on a specific day of the month
- owner_id -- an owner id, if set the response will be limited to subscriptions of that owner
- limit -- how many results to return in this response
- offset -- can be used in conjunction with limit to paginate the response
- location_id -- if set, response will be limited to a specific location
- package_id -- the ID of a particular package
HTTP GET https://{your_app}.gingrapp.com/api/v1/custom_field_search
- retrieve custom field information for an owner/animal
- parameters:
- key: your api key
- form_id: id of the form you wish to search (owner_form = 1 animal_form = 2)
- field_name: technical name of field you wish to search
- search: the search term you are looking for on that field_name and form_id
results:
{
"success": true,
"error": false,
"data": [{
"system_id": "1694",
"first_name": "Alexandra",
"last_name": "Smith",
"home_phone": "(555) 555-5555",
"cell_phone": "(343) 444-4444",
"emergency_contact_name": "Melissa Salminen",
"emergency_contact_phone": "(222) 222-2222",
"notes": "<b>Authorized Persons<\/b> Melissa Salminen<br>",
"home_location": "1",
"password": "adsfadsfasdfasfadsf",
"stripe_default_card": null,
"payment_processor_id": "1",
"allow_online_login": "1",
"opt_out_email": "0",
"opt_out_sms": "0",
"opt_out_marketing_email": "0",
"opt_out_marketing_sms": "1",
"opt_out_photo_sharing": "0",
"opt_out_reminder_email": "0",
"opt_out_reminder_sms": "0",
"barcode": null,
"submission_id": "10904",
.....
},
....
]
}
HTTP GET https://{your_app}.gingrapp.com/api/v1/back_of_house (AKA Digital Whiteboard)
- retrieve data used to power Gingr's digital whiteboard.
- parameters:
- key: your api key
- location_id (required)
- type_ids (required, an array of reservation_type_ids)
- mins_future (optional, if set, restricts to the next/last X minutes)
- full_day (optional, if set, mins_future field is ignored and system will include all reservations checking in/out today)
Example request
curl 'https://{subdomain}.gingrapp.com/api/v1/back_of_house?key={my_key}&location_id=1&full_day=true'
Example response
{
"success": true,
"error": false,
"data": {
"checking_in": [
{
"id": "953",
"owner_id": "94",
"animal_id": "115",
"o_last": "Holbrook",
"a_first": "Maggie",
"type_id": "1",
"type": "Daycare | Full Day ",
"check_in_stamp": null,
"check_out_stamp": null,
"start_date": "1559696400",
"end_date": "1559703600",
"run_name": null,
"area_name": null,
"belonging_count": "0",
"belonging_area": null,
"status_id": 2,
"status_string": "Checking In Soon",
"event_time": 1559696400
},
...
],
"checking_out": [
{
"id": "646",
"owner_id": "8",
"animal_id": "12",
"o_last": "Douris",
"a_first": "Sugar",
"type_id": "5",
"type": "Grooming Services",
"check_in_stamp": "1559657671",
"check_out_stamp": null,
"start_date": "1559656800",
"end_date": "1559664000",
"run_name": null,
"area_name": null,
"belonging_count": "0",
"belonging_area": null,
"status_id": 2,
"status_string": "Checking Out Soon",
"event_time": 1559664000
},
...
]
}
}
HTTP GET https://{your_app}.gingrapp.com/api/v1/quick_checkin
- checks in pet(s) for an existing reservation, if one does not exist it will create one and check it in.
- required parameters
- key
- optional parameters
- animal_id
- owner_id
- type_id -- if set, system will use this reservation type id for new reservations. if not set, it will default to your system's quick type
FAQ: Check this out!
Is there a daily API limit?
Nope, there is not!
Can we create custom queries based off the Gingr data points, or are we only allowed to use the ones in your documentation?
Only the documented API endpoints are currently available for public consumption, though we frequently add to our API!
Are the calls restricted for data for individual users?
Each API request must have an API key passed. API keys are issued per user. This key inherits all of that users permissions. Gingr has many types of permissions which can restrict data coming out of the API.
Can we generate lists of users and their contact information, most importantly email, to leverage for marketing automation?
Yes. Best route for this would be to use Gingr’s webhooks to listen for new/changed owner records.
Comments
0 comments
Article is closed for comments.