-
Notifications
You must be signed in to change notification settings - Fork 0
Sharing Service API Documentation
6 edited this page Jan 5, 2013
·
3 revisions
Bandido has a RESTful JSON API that supports both HTTP and HTTPS for sharing search records and UGC photos and stories.
- Dev: http://sharing.ancestrydev.com
- Stage: http://sharing.ancestrystage.com
- Production: http(s)://sharing.ancestry.com
CONTENT-TYPE: application/json- User authentication (choose 1)
X-ACOM-ATT: att_token_valueX-ACOM-USER-TOKEN: user_token_value
- Search Records
-
collection_idandrecord_idare required strings -
tree_id,person_id,referrer, andlocaleare optional
-
{
"collection_id": "collection_id",
"record_id": "record_id",
"tree_id": "tree_id",
"person_id": "person_id",
"referrer": {
"client": "web", //web, iOS, android, or 3rd-party API token
"page": "page" //any string
},
"locale": "locale" // see below
}
- UGC photos and stories # TODO consider adding audios and videos
-
object_idandtree_idare required strings -
person_id,referrer, andlocaleare optional
-
{
"object_id": "object_id",
"tree_id": "tree_id",
"person_id": "person_id",
"referrer": {
"client": "web", //web, iOS, android, or 3rd-party API token
"page": "page" //any string
},
"locale": "locale" // see below
}
-
localeString or Windows codes (as strings or integers)
"en-US" : 1033
"en-CA" : 4105
"fr-CA" : 3084
"en-UK" : 2057
"sv-SE" : 1053
"it-IT" : 1040
"de-DE" : 1031
"fr-FR" : 1036
We return JSON with sharable url and other helpful data.
{
"url": "http:\/\/sharing.ancestry.com\/?h=ac091e",
"title": "Discovered in the 1930 U.S. census",
"caption": null,
"category": "search_record",
"sharer": {
"first_name": "Sharer"
},
"subject": null, // nested "first_name" and "full_name" if there is a subject
"image": {
"thumbnail": "http:\/\/sharing.ancestry.com\/\/image.jpg?h=ac091e",
}
}