System
Health Check
Section titled “Health Check”GET https://api.sheepcrm.com/api/v1/health/
HTTP/1.1 200 OK{ "message": "ok"}Validate an Email Address
Section titled “Validate an Email Address”The validate_email package checks if the host has an SMTP server and the email really exists.
GET https://api.sheepcrm.com/api/v1/validate/email/?email=james@sheepcrm.com
HTTP/1.1 200 OK{ "email": "james@sheepcrm.com", "valid": true}GET https://api.sheepcrm.com/api/v1/validate/email/?email=james@example.com
HTTP/1.1 200 OK{ "email": "james@example.com", "valid": false}Group By and Count
Section titled “Group By and Count”Group any resource type by any field. All field permutations are returned (the data packet may be large).
GET https://sls-api.sheepcrm.com/api/v2/{flock}/groupby/{resource_type}/{field}/count/Authorization: Bearer $API_KEY
HTTP/1.1 200 OK{ "results": [ { "count": 2, "value": "New York" }, { "count": 1, "value": "Pretendsville" } ]}Data Lookups
Section titled “Data Lookups”Data lookups are designed to drive auto-complete form elements.
| Parameter | Description |
|---|---|
q | Search term. |
callback | Provide a callback to get the results as JSONP. |
Not all lookups require a flock param or authentication. Public datasets are timezones, connection_types and taxonomy (taxonomy requires a subtype of genera or families).
Authenticated lookups
Section titled “Authenticated lookups”GET https://sls-api.sheepcrm.com/api/v2/$FLOCK/lookup/{data_type}/Authorization: Bearer $API_KEYGET https://sls-api.sheepcrm.com/api/v2/$FLOCK/lookup/{data_type}/?q=abcAuthorization: Bearer $API_KEYGET https://api.sheepcrm.com/api/v1/$FLOCK/lookup/{data_type}/{field}/Authorization: Bearer $API_KEYGET https://api.sheepcrm.com/api/v1/$FLOCK/lookup/{data_type}/{field}/?q=abcAuthorization: Bearer $API_KEYPublic lookups
Section titled “Public lookups”GET https://api.sheepcrm.com/api/v1/lookup/{data_type}/GET https://api.sheepcrm.com/api/v1/lookup/{data_type}/?q=abcGET https://api.sheepcrm.com/api/v1/lookup/{data_type}/{subtype}/GET https://api.sheepcrm.com/api/v1/lookup/{data_type}/{subtype}/?q=abcExample
Section titled “Example”GET https://api.sheepcrm.com/api/v1/$FLOCK/lookup/badge/name/?q=aAuthorization: Bearer $API_KEY
HTTP/1.1 200 OK[ {"id": "Magazine", "text": "Magazine"}, {"id": "attendance", "text": "attendance"}, {"id": "self_service_useraccount", "text": "self_service_useraccount"}, {"id": "useraccount", "text": "useraccount"}]GDPR Purposes
Section titled “GDPR Purposes”| Parameter | Description |
|---|---|
channel | Optional. Filter by channel. |
GET https://sls-api.sheepcrm.com/api/v2/{flock}/system/gdpr_purposeAuthorization: Bearer $API_KEY
HTTP/1.1 200 OK{ "purposes": [ { "channel": "process, email & post", "legal": "legitimate interests", "legal_purpose": "legitimate interests: to process, manage and communicate with you about your forms.", "purpose": "to process, manage and communicate with you about your forms." }, { "channel": "process, email & post", "legal": "legitimate interests", "legal_purpose": "legitimate interests: to process, manage and communicate with you about your membership.", "purpose": "to process, manage and communicate with you about your membership." } ]}System Endpoints
Section titled “System Endpoints”The following system endpoints are available:
| Endpoint | Description |
|---|---|
/api/v1/$FLOCK/system/asset_categories/ | Asset categories |
/api/v1/$FLOCK/system/asset_subcategories/ | Asset subcategories |
/api/v1/$FLOCK/system/asset_testers/ | Asset testers |
/api/v1/$FLOCK/system/booking_types/ | Booking types |
/api/v1/$FLOCK/system/calendar_groups/ | Calendar groups |
/api/v1/$FLOCK/system/connections/ | Connections |
/api/v1/$FLOCK/system/default_checklist/ | Default checklist |
/api/v1/$FLOCK/system/flock_users/ | Flock users |
/api/v1/$FLOCK/system/import_templates/ | Import templates |
/api/v1/$FLOCK/system/index/{resource_type}/ | Index for a resource type |
/api/v1/$FLOCK/system/index/{resource_type}/{field}/ | Index for a specific field |
/api/v1/$FLOCK/system/locked_tags/ | Locked tags |
/api/v1/$FLOCK/system/purchases/ | Purchases |
/api/v1/$FLOCK/system/resource_types/ | Resource types |
/api/v1/$FLOCK/system/settings/ | Settings |
/api/v1/$FLOCK/system/settings/full/ | Full settings |
/api/v1/$FLOCK/system/settings/{field}/ | Specific setting field |
/api/v1/$FLOCK/system/settings/{field}/{view}/ | Setting field with view |
/api/v1/$FLOCK/system/tags/ | Tags |
/api/v1/$FLOCK/system/{resource_type}/ | Resource type system data |
/api/v1/$FLOCK/system/{resource_type}/refresh/ | Refresh resource type data |
/api/v1/$FLOCK/system/{resource_type}/{view}/ | Resource type system view |