Skip to content

Privacy / GDPR

/api/v1/$FLOCK/user/hosted/privacy/

The hosted privacy call provides all the data needed to build a privacy page.

http GET https://api.sheepcrm.com/api/v1/$FLOCK/user/hosted/privacy/
HTTP/1.1 200 OK
{
"address_lines": [
"1 Pretend Street",
"Pretendsville",
"Utah"
],
"consent_list": [
{
"channels": [
"email"
],
"cid": "c000",
"context": "What's On Newsletter",
"purpose": "Live Programme Newsletter"
},
{
"channels": [
"email",
"phone",
"post"
],
"cid": "c001",
"context": "Bothering phonecalls and letters",
"purpose": "To bother you"
}
],
"email": "fake@example.com",
"flock": "example",
"flockNamePublic": "My Community Trust",
"flockNamePublicShort": "MCT",
"how_to_contact_us_intro": "...",
"how_we_collect": [
"you send us an email",
"you sign up as a member",
"you make a donation",
"you volunteer",
"you sign up to a mailing list online"
],
"how_we_collect_intro": "We collect personal information directly from you when:",
"name_in_logo": false,
"other_questions_contact": "...",
"palette": {},
"phone": "01234 567 890",
"privacy_intro": "...",
"website": "https://www.sheepcrm.com/",
"what_we_collect": ["..."],
"what_we_collect_intro": "We collect the following information:",
"why_we_collect": ["..."],
"why_we_collect_intro": "We use your personal data for the following purposes:"
}

/api/v1/$FLOCK/user/consent/

POST a public fresh consent submission (person + consent data). Sheep will find or create the contact and add the consent records.

Payload fields for finding or creating a person:

FieldRequiredDescription
titleNoPerson’s title
first_nameNoPerson’s first name
last_nameNoPerson’s last name
date_of_birthNoPerson’s date of birth
emailYesPerson’s email address
postal_codeNoPerson’s postal code

Consent fields:

Consents to set are each represented by a separate composite field e.g. consent__c001__post. The field name has three parts separated by double underscores __:

  1. consent (always)
  2. The consent ID (e.g. c001)
  3. The consent channel (e.g. email, sms, post)

The value should be set to True. Do not include consents which have not been granted, and do not try withdrawing consent with a False value.

http POST https://api.sheepcrm.com/api/v1/$FLOCK/user/consent/ first_name=Jim last_name=Lovell email=jim@nasa.gov consent__c001__post=True
HTTP/1.1 201 CREATED
{
"consent_added": [
{
"channel": "post",
"context": "I provide consent for Example to process my data to send me electronic newsletters.",
"context_url": "Unknown",
"date": "2020-02-25T07:31:44.068904",
"purpose": "newsletter",
"reference": "/example/person/5e44020149c3a85acee1ff9b/",
"source": "Sheep App",
"source_reference": "fresh consent form"
}
],
"errors": {},
"updates": {
"email": [
"jim@nasa.gov"
],
"first_name": "Jim",
"last_name": "Lovell"
}
}

/api/v1/$FLOCK/user/{uid}/consent/

User authentication required. Get or update consents associated with the user account.

/$FLOCK/user/{uid}/consent/{consent_uid}/withdraw/

User authentication required. PUT to withdraw a consent.