Bulk
Bulk Documentation
People [BULK DELETE]
People [BULK DELETE]
Request
Endpoint
DELETE /api/v2/contacts/people/bulk
Content-Type: application/vnd.api+json
Body
{
"data": [
{
"data": {
"type": "people",
"id": "9de08d12-f053-4f07-8c06-c8701d1bdaa8"
}
},
{
"data": {
"type": "people",
"id": "07923bb1-a488-46f6-ab42-68073857acde"
}
}
]
}
Response
Headers
Content-Type: application/vnd.api+json; charset=utf-8
200 OK
Body
[
{
"data": {
"id": "9de08d12-f053-4f07-8c06-c8701d1bdaa8",
"type": "people",
"attributes": {
"alma_mater": null,
"anniversary_day": null,
"anniversary_month": null,
"anniversary_year": null,
"avatar": "https://mpdx.org/images/avatar.png",
"birthday_day": null,
"birthday_month": null,
"birthday_year": null,
"created_at": "2022-01-12T17:18:13Z",
"deceased": false,
"employer": null,
"first_name": "Frank",
"gender": null,
"last_name": "Schowalter",
"legal_first_name": null,
"marital_status": null,
"middle_name": null,
"occupation": null,
"optout_enewsletter": false,
"parent_contacts": [
"f9342a6a-f55c-42c5-8ce6-d12e5f8afdb2"
],
"suffix": null,
"title": null,
"updated_at": "2022-01-12T17:18:13Z",
"updated_in_db_at": "2022-01-12T17:18:13Z"
},
"relationships": {
"email_addresses": {
"data": [
]
},
"facebook_accounts": {
"data": [
]
},
"family_relationships": {
"data": [
]
},
"linkedin_accounts": {
"data": [
]
},
"phone_numbers": {
"data": [
]
},
"twitter_accounts": {
"data": [
]
},
"websites": {
"data": [
]
}
}
}
},
{
"data": {
"id": "07923bb1-a488-46f6-ab42-68073857acde",
"type": "people",
"attributes": {
"alma_mater": null,
"anniversary_day": null,
"anniversary_month": null,
"anniversary_year": null,
"avatar": "https://mpdx.org/images/avatar.png",
"birthday_day": null,
"birthday_month": null,
"birthday_year": null,
"created_at": "2022-01-12T17:18:13Z",
"deceased": false,
"employer": null,
"first_name": "Moriah",
"gender": null,
"last_name": "Fay",
"legal_first_name": null,
"marital_status": null,
"middle_name": null,
"occupation": null,
"optout_enewsletter": false,
"parent_contacts": [
"f9342a6a-f55c-42c5-8ce6-d12e5f8afdb2"
],
"suffix": null,
"title": null,
"updated_at": "2022-01-12T17:18:13Z",
"updated_in_db_at": "2022-01-12T17:18:13Z"
},
"relationships": {
"email_addresses": {
"data": [
]
},
"facebook_accounts": {
"data": [
]
},
"family_relationships": {
"data": [
]
},
"linkedin_accounts": {
"data": [
]
},
"phone_numbers": {
"data": [
]
},
"twitter_accounts": {
"data": [
]
},
"websites": {
"data": [
]
}
}
}
}
]
Fields
data
Type
[Person]
Description An array of People that have just been deleted
People [BULK POST]
an individual element of the
data
array
{
"data": {
"type": "people",
"id": "1d6393dd-f3f4-49d3-9fd8-7e758b056b1f",
"attributes": {
"first_name": "Steve",
"last_name": "Rogers",
"more_attributes": "...etc"
}
}
}
For this bulk create endpoint, you are required to send an array of items within the data
object. You are also required to send in a related Person. A Person cannot be created without a Contact.
Each member of the array must contain a client generated
id
to be used for the Person being created.Each member of the array must contain a
type
that has the value of'people'
.Each member of the array must have an
attributes
hash of values to be used for the Person being created.
Request
Endpoint
POST /api/v2/contacts/people/bulk
Content-Type: application/vnd.api+json
Body
{
"data": [
{
"data": {
"type": "people",
"id": "93ea940a-f9c1-4a9e-bc15-b7563942213e",
"attributes": {
"first_name": "Hans",
"last_name": "Jerde",
"updated_in_db_at": "2022-01-12 17:18:13 UTC"
},
"relationships": {
"contacts": {
"data": [
{
"type": "contacts",
"id": "fa94fcca-099d-4b1d-9540-96469f34213d"
}
]
}
}
}
}
]
}
Response
Headers
Content-Type: application/vnd.api+json; charset=utf-8
200 OK
Body
[
{
"data": {
"id": "93ea940a-f9c1-4a9e-bc15-b7563942213e",
"type": "people",
"attributes": {
"alma_mater": null,
"anniversary_day": null,
"anniversary_month": null,
"anniversary_year": null,
"avatar": "https://mpdx.org/images/avatar.png",
"birthday_day": null,
"birthday_month": null,
"birthday_year": null,
"created_at": "2022-01-12T17:18:13Z",
"deceased": false,
"employer": null,
"first_name": "Hans",
"gender": null,
"last_name": "Jerde",
"legal_first_name": null,
"marital_status": null,
"middle_name": null,
"occupation": null,
"optout_enewsletter": false,
"parent_contacts": [
"fa94fcca-099d-4b1d-9540-96469f34213d"
],
"suffix": null,
"title": null,
"updated_at": "2022-01-12T17:18:13Z",
"updated_in_db_at": "2022-01-12T17:18:13Z"
},
"relationships": {
"email_addresses": {
"data": [
]
},
"facebook_accounts": {
"data": [
]
},
"family_relationships": {
"data": [
]
},
"linkedin_accounts": {
"data": [
]
},
"phone_numbers": {
"data": [
]
},
"twitter_accounts": {
"data": [
]
},
"websites": {
"data": [
]
}
}
}
}
]
Fields
data
Type
[Person / error]
Description Array of People objects that have been successfully created and of errors related to People objects that were not created successfully
People [BULK PUT]
People [BULK PUT]
Request
Endpoint
PUT /api/v2/contacts/people/bulk
Content-Type: application/vnd.api+json
Body
{
"data": [
{
"data": {
"type": "people",
"id": "8f4ef842-e45d-42e7-80c7-a8af6cf24cb6",
"attributes": {
"first_name": "Maryanna",
"last_name": "Bergnaum",
"updated_in_db_at": "2022-01-12 17:18:13 UTC"
}
}
}
]
}
Response
Headers
Content-Type: application/vnd.api+json; charset=utf-8
200 OK
Body
[
{
"data": {
"id": "8f4ef842-e45d-42e7-80c7-a8af6cf24cb6",
"type": "people",
"attributes": {
"alma_mater": null,
"anniversary_day": null,
"anniversary_month": null,
"anniversary_year": null,
"avatar": "https://mpdx.org/images/avatar.png",
"birthday_day": null,
"birthday_month": null,
"birthday_year": null,
"created_at": "2022-01-12T17:18:13Z",
"deceased": false,
"employer": null,
"first_name": "Maryanna",
"gender": null,
"last_name": "Bergnaum",
"legal_first_name": null,
"marital_status": null,
"middle_name": null,
"occupation": null,
"optout_enewsletter": false,
"parent_contacts": [
"77d64952-0cd6-4cdf-89a8-990e549cc0fc"
],
"suffix": null,
"title": null,
"updated_at": "2022-01-12T17:18:13Z",
"updated_in_db_at": "2022-01-12T17:18:13Z"
},
"relationships": {
"email_addresses": {
"data": [
]
},
"facebook_accounts": {
"data": [
]
},
"family_relationships": {
"data": [
]
},
"linkedin_accounts": {
"data": [
]
},
"phone_numbers": {
"data": [
]
},
"twitter_accounts": {
"data": [
]
},
"websites": {
"data": [
]
}
}
}
}
]
Fields
data
Type
[Person / error]
Description Array of People objects that have been successfully created and of errors related to People objects that were not created successfully
Last updated