Bulk
Bulk Documentation
Contacts [BULK DELETE]
Contacts [BULK DELETE]
Request
Endpoint
DELETE /api/v2/contacts/bulk
Content-Type: application/vnd.api+json
Body
{
"data": [
{
"data": {
"type": "contacts",
"id": "edf429cd-7687-48bf-86a4-ea1836a76859"
}
},
{
"data": {
"type": "contacts",
"id": "270072f8-69f4-4d01-8e75-fd9f940a20ed"
}
}
]
}
Response
Headers
Content-Type: application/vnd.api+json; charset=utf-8
200 OK
Body
[
{
"data": {
"id": "270072f8-69f4-4d01-8e75-fd9f940a20ed",
"type": "contacts",
"attributes": {
"avatar": "https://mpdx.org/images/avatar.png",
"church_name": null,
"created_at": "2022-01-12T17:18:31Z",
"deceased": false,
"direct_deposit": false,
"envelope_greeting": "Efrain Lebsack",
"greeting": "",
"last_activity": null,
"last_appointment": null,
"last_donation": null,
"last_letter": null,
"last_phone_call": null,
"last_pre_call": null,
"last_thank": null,
"late_at": "2022-01-08",
"likely_to_give": null,
"locale": "en",
"magazine": false,
"missionary_pages_banner": false,
"name": "Lebsack, Efrain",
"next_ask": null,
"no_appeals": null,
"no_gift_aid": null,
"notes": "Test Note.",
"notes_saved_at": "2022-01-12T17:18:31Z",
"pledge_amount": "100.0",
"pledge_currency": "USD",
"pledge_currency_symbol": "$",
"pledge_frequency": "1",
"pledge_received": false,
"pledge_start_date": "2021-12-08",
"preferred_contact_method": null,
"relationship_code": null,
"send_newsletter": null,
"source": "MPDX",
"square_avatar": "https://mpdx.org/images/avatar.png",
"starred_at": null,
"status": "Partner - Financial",
"status_valid": null,
"suggested_changes": {
},
"tag_list": [
],
"timezone": null,
"uncompleted_tasks_count": 0,
"updated_at": "2022-01-12T17:18:31Z",
"updated_in_db_at": "2022-01-12T17:18:31Z",
"website": "http://hagenes.co/eliseo_bergnaum"
},
"relationships": {
"account_list": {
"data": {
"id": "52c9982c-7fcb-49b1-953d-42b434877c75",
"type": "account_lists"
}
},
"user": {
"data": null
},
"addresses": {
"data": [
]
},
"appeal_contacts": {
"data": [
]
},
"appeals": {
"data": [
]
},
"contact_referrals_by_me": {
"data": [
]
},
"contact_referrals_to_me": {
"data": [
]
},
"contacts_referred_by_me": {
"data": [
]
},
"contacts_that_referred_me": {
"data": [
]
},
"donor_accounts": {
"data": [
]
},
"excluded_appeal_contacts": {
"data": [
]
},
"last_six_donations": {
"data": [
]
},
"people": {
"data": [
]
},
"pledges": {
"data": [
]
},
"tasks": {
"data": [
]
},
"primary_person": {
"data": null
},
"primary_or_first_person": {
"data": {
"type": "people"
}
},
"spouse": {
"data": null
}
}
}
},
{
"data": {
"id": "edf429cd-7687-48bf-86a4-ea1836a76859",
"type": "contacts",
"attributes": {
"avatar": "https://mpdx.org/images/avatar.png",
"church_name": null,
"created_at": "2022-01-12T17:18:31Z",
"deceased": false,
"direct_deposit": false,
"envelope_greeting": "Jani D'Amore",
"greeting": "",
"last_activity": null,
"last_appointment": null,
"last_donation": null,
"last_letter": null,
"last_phone_call": null,
"last_pre_call": null,
"last_thank": null,
"late_at": "2022-01-08",
"likely_to_give": null,
"locale": "en",
"magazine": false,
"missionary_pages_banner": false,
"name": "D'Amore, Jani",
"next_ask": null,
"no_appeals": null,
"no_gift_aid": null,
"notes": "Test Note.",
"notes_saved_at": "2022-01-12T17:18:31Z",
"pledge_amount": "100.0",
"pledge_currency": "USD",
"pledge_currency_symbol": "$",
"pledge_frequency": "1",
"pledge_received": false,
"pledge_start_date": "2021-12-08",
"preferred_contact_method": null,
"relationship_code": null,
"send_newsletter": null,
"source": "MPDX",
"square_avatar": "https://mpdx.org/images/avatar.png",
"starred_at": null,
"status": "Partner - Financial",
"status_valid": null,
"suggested_changes": {
},
"tag_list": [
],
"timezone": null,
"uncompleted_tasks_count": 0,
"updated_at": "2022-01-12T17:18:31Z",
"updated_in_db_at": "2022-01-12T17:18:31Z",
"website": "http://price.com/jae_paucek"
},
"relationships": {
"account_list": {
"data": {
"id": "52c9982c-7fcb-49b1-953d-42b434877c75",
"type": "account_lists"
}
},
"user": {
"data": null
},
"addresses": {
"data": [
]
},
"appeal_contacts": {
"data": [
]
},
"appeals": {
"data": [
]
},
"contact_referrals_by_me": {
"data": [
]
},
"contact_referrals_to_me": {
"data": [
]
},
"contacts_referred_by_me": {
"data": [
]
},
"contacts_that_referred_me": {
"data": [
]
},
"donor_accounts": {
"data": [
]
},
"excluded_appeal_contacts": {
"data": [
]
},
"last_six_donations": {
"data": [
]
},
"people": {
"data": [
]
},
"pledges": {
"data": [
]
},
"tasks": {
"data": [
]
},
"primary_person": {
"data": null
},
"primary_or_first_person": {
"data": {
"type": "people"
}
},
"spouse": {
"data": null
}
}
}
}
]
Fields
data
Type
[Contact]
Description An array of Contacts that have just been deleted
Contacts [BULK POST]
an individual element of the
data
array
{
"data": {
"type": "contacts",
"id": "1d6393dd-f3f4-49d3-9fd8-7e758b056b1f",
"attributes": {
"name": "Steve Rogers",
"more_attributes": "...etc"
}
}
}
For this bulk create endpoint, you are required to send an array of items within the data
object.
Each member of the array must contain a client generated
id
to be used for the Contact being created.Each member of the array must contain a
type
that has the value of'contacts'
.Each member of the array must have an
attributes
hash of values to be used for the Contact being created.
Request
Endpoint
POST /api/v2/contacts/bulk
Content-Type: application/vnd.api+json
Body
{
"data": [
{
"data": {
"type": "contacts",
"id": "d9508f9a-3d42-4170-a98c-d262d34ed938",
"attributes": {
"locale": "en",
"name": "Carter, Orval",
"notes": "Test Note.",
"pledge_amount": 100,
"pledge_frequency": 1,
"pledge_start_date": "2021-12-08 17:18:31 UTC",
"status": "Partner - Financial",
"website": "http://thompson-conn.com/blaine",
"updated_in_db_at": "2022-01-12 17:18:31 UTC"
},
"relationships": {
"account_list": {
"data": {
"id": "e19f18da-6674-4df6-80a3-bdad292b942c",
"type": "account_lists"
}
}
}
}
}
]
}
Response
Headers
Content-Type: application/vnd.api+json; charset=utf-8
200 OK
Body
[
{
"data": {
"id": "d9508f9a-3d42-4170-a98c-d262d34ed938",
"type": "contacts",
"attributes": {
"avatar": "https://mpdx.org/images/avatar.png",
"church_name": null,
"created_at": "2022-01-12T17:18:31Z",
"deceased": false,
"direct_deposit": false,
"envelope_greeting": "Orval Carter",
"greeting": "",
"last_activity": null,
"last_appointment": null,
"last_donation": null,
"last_letter": null,
"last_phone_call": null,
"last_pre_call": null,
"last_thank": null,
"late_at": "2022-01-08",
"likely_to_give": null,
"locale": "en",
"magazine": false,
"missionary_pages_banner": false,
"name": "Carter, Orval",
"next_ask": null,
"no_appeals": null,
"no_gift_aid": null,
"notes": "Test Note.",
"notes_saved_at": "2022-01-12T17:18:31Z",
"pledge_amount": "100.0",
"pledge_currency": "USD",
"pledge_currency_symbol": "$",
"pledge_frequency": "1",
"pledge_received": false,
"pledge_start_date": "2021-12-08",
"preferred_contact_method": null,
"relationship_code": null,
"send_newsletter": null,
"source": "MPDX",
"square_avatar": "https://mpdx.org/images/avatar.png",
"starred_at": null,
"status": "Partner - Financial",
"status_valid": null,
"suggested_changes": {
},
"tag_list": [
],
"timezone": null,
"uncompleted_tasks_count": 0,
"updated_at": "2022-01-12T17:18:31Z",
"updated_in_db_at": "2022-01-12T17:18:31Z",
"website": "http://thompson-conn.com/blaine"
},
"relationships": {
"account_list": {
"data": {
"id": "e19f18da-6674-4df6-80a3-bdad292b942c",
"type": "account_lists"
}
},
"user": {
"data": null
},
"addresses": {
"data": [
]
},
"appeal_contacts": {
"data": [
]
},
"appeals": {
"data": [
]
},
"contact_referrals_by_me": {
"data": [
]
},
"contact_referrals_to_me": {
"data": [
]
},
"contacts_referred_by_me": {
"data": [
]
},
"contacts_that_referred_me": {
"data": [
]
},
"donor_accounts": {
"data": [
]
},
"excluded_appeal_contacts": {
"data": [
]
},
"last_six_donations": {
"data": [
]
},
"people": {
"data": [
]
},
"pledges": {
"data": [
]
},
"tasks": {
"data": [
]
},
"primary_person": {
"data": null
},
"primary_or_first_person": {
"data": {
"type": "people"
}
},
"spouse": {
"data": null
}
}
}
}
]
Fields
data
Type
[Contact / error]
Description Array of both Contact objects that have been successfully created and of errors related to Contact objects that were not created successfully
Contacts [BULK PUT]
Contacts [BULK PUT]
Request
Endpoint
PUT /api/v2/contacts/bulk
Content-Type: application/vnd.api+json
Body
{
"data": [
{
"data": {
"type": "contacts",
"id": "ee65eb2d-a2b1-4532-b211-8cd5614715a4",
"attributes": {
"locale": "en",
"name": "Lockman, Terica",
"notes": "Test Note.",
"pledge_amount": 100,
"pledge_frequency": 1,
"pledge_start_date": "2021-12-08 17:18:31 UTC",
"status": "Partner - Financial",
"website": "http://altenwerth.net/toney_gislason",
"updated_in_db_at": "2022-01-12 17:18:31 UTC"
}
}
}
]
}
Response
Headers
Content-Type: application/vnd.api+json; charset=utf-8
200 OK
Body
[
{
"data": {
"id": "ee65eb2d-a2b1-4532-b211-8cd5614715a4",
"type": "contacts",
"attributes": {
"avatar": "https://mpdx.org/images/avatar.png",
"church_name": null,
"created_at": "2022-01-12T17:18:31Z",
"deceased": false,
"direct_deposit": false,
"envelope_greeting": "Terica Lockman",
"greeting": "",
"last_activity": null,
"last_appointment": null,
"last_donation": null,
"last_letter": null,
"last_phone_call": null,
"last_pre_call": null,
"last_thank": null,
"late_at": "2022-01-08",
"likely_to_give": null,
"locale": "en",
"magazine": false,
"missionary_pages_banner": false,
"name": "Lockman, Terica",
"next_ask": null,
"no_appeals": null,
"no_gift_aid": null,
"notes": "Test Note.",
"notes_saved_at": "2022-01-12T17:18:31Z",
"pledge_amount": "100.0",
"pledge_currency": "USD",
"pledge_currency_symbol": "$",
"pledge_frequency": "1",
"pledge_received": false,
"pledge_start_date": "2021-12-08",
"preferred_contact_method": null,
"relationship_code": null,
"send_newsletter": null,
"source": "MPDX",
"square_avatar": "https://mpdx.org/images/avatar.png",
"starred_at": null,
"status": "Partner - Financial",
"status_valid": null,
"suggested_changes": {
},
"tag_list": [
],
"timezone": null,
"uncompleted_tasks_count": 0,
"updated_at": "2022-01-12T17:18:31Z",
"updated_in_db_at": "2022-01-12T17:18:31Z",
"website": "http://altenwerth.net/toney_gislason"
},
"relationships": {
"account_list": {
"data": {
"id": "16044ec7-4bc2-4b9d-9a79-f882f5407b35",
"type": "account_lists"
}
},
"user": {
"data": null
},
"addresses": {
"data": [
]
},
"appeal_contacts": {
"data": [
]
},
"appeals": {
"data": [
]
},
"contact_referrals_by_me": {
"data": [
]
},
"contact_referrals_to_me": {
"data": [
]
},
"contacts_referred_by_me": {
"data": [
]
},
"contacts_that_referred_me": {
"data": [
]
},
"donor_accounts": {
"data": [
]
},
"excluded_appeal_contacts": {
"data": [
]
},
"last_six_donations": {
"data": [
]
},
"people": {
"data": [
]
},
"pledges": {
"data": [
]
},
"tasks": {
"data": [
]
},
"primary_person": {
"data": null
},
"primary_or_first_person": {
"data": {
"type": "people"
}
},
"spouse": {
"data": null
}
}
}
}
]
Fields
data
Type
[Contact / error]
Description Array of both Contact objects that have been successfully updated and of errors related to Contact objects that were not updated successfully
Last updated