Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Endpoints for Batch Processing
- There are 3 endpoints available for batch processing up to 50 prospects at a time:
- /api/prospect/version/3/do/batchCreate
- /api/prospect/version/3/do/batchUpdate
- /api/prospect/version/3/do/batchUpsert
- These endpoints expect a query variable called "prospects" which holds either JSON or XML encoded data.
- JSON Example:
- {
- "prospects": {
- "1234": {
- "first_name": "New first name",
- "last_name": "New last name"
- },
- "some@email.com": {
- "first_name": "New first name",
- "last_name": "New last name"
- },
- "some.other@email.com": {
- "first_name": "New first name",
- "last_name": "New last name"
- }
- }
- }
- XML Example:
- <prospects>
- <prospect identifier="1234">
- <first_name>New first name</first_name>
- <last_name>New last name</last_name>
- </prospect>
- <prospect identifier="some@email.com">
- <first_name>New first name</first_name>
- <last_name>New last name</last_name>
- </prospect>
- <prospect identifier="some.other@email.com">
- <first_name>New first name</first_name>
- <last_name>New last name</last_name>
- </prospect>
- </prospects>
- If using batchCreate, you'll need to provide a valid and unique email address for each prospect. The batchUpdate and batchUpsert endpoints allow the use of a prospect ID or prospect email address.
- Example:
- /api/prospect/version/3/do/batchUpdate?prospects={"prospects":{"some@email.com":{"first_name":"New first name","last_name":"New last name"},"1234":{"first_name":"New first name","last_name":"New last name"}}}&api_key=&user_key=
- The endpoints will return either:
- - a generic error in case of a global error (for instance authentication failed, or invalid format of “prospects” variable);
- - an array of errors for individual prospects that were not processed successfully (prospects that were processed successfully will not be listed);
- - a “success” type response if everything went OK
- The return value will either be XML or JSON (XML by default. If you want JSON, then add “&format=json” to your HTTP query).
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement