Add a contributor

POST /contributors

This endpoint allows you to add new contacts or existing contacts as contributors of a request.

application/json

Body

  • requestId string

    The ID of the request you want to add the contributor to.

  • contacts array[string | object]

    An array of the contributors you want to add to the request. You can add up to 10 contributors per API cal. Each contributors can be a string representing the ID of an existing contact or a contact object in JSON format. (click here for more details)

    One of:

Responses

  • 200 application/json

    List of requests of a campaigns.

    Hide response attributes Show response attributes object
    • request object

      Additional properties are allowed.

      Hide request attributes Show request attributes object
      • _id string
      • campaignId string
      • createdAt string(date-time)
      • portalUrl string
      • status string
      • dueDate string(date-time)
      • privacy string
      • contact object

        Additional properties are allowed.

        Hide contact attributes Show contact attributes object
        • _id string
        • email string(email)
        • firstName string
        • lastName string
        • company string
        • tag array[string]
        • custom array[object]
          Hide custom attributes Show custom attributes object
          • _id string
          • name string
          • variable string
          • value string
      • branding object

        Additional properties are allowed.

        Hide branding attributes Show branding attributes object
        • useBranding boolean
        • brandingId string
    • errors array
  • 400

    Bad Request -- Your request is invalid.

  • 401

    Unauthorized -- Your API key is wrong.

  • 403

    Forbidden -- The object requested is hidden for administrators only.

  • 404

    Not Found -- The specified object could not be found.

  • 429

    Too Many Requests -- You're requesting too many objects! Slow down!

  • 500

    Internal Server Error -- We had a problem with our server. Try again later.

  • 503

    Service Unavailable -- We're temporarily offline for maintenance. Please try again later.

POST /contributors
curl \
 --request POST 'https://api.usecollect.com/v1/contributors' \
 --header "Content-Type: application/json" \
 --data '{"contact":{"data":{"brand":"Tesla","model":"Roadster"},"email":"elon@example.com","company":"Tesla","lastName":"Musk","firstName":"Elon"},"requestId":"xvr69EYLKXvTkfYuk"}'
Request examples
{
  "contact": {
    "data": {
      "brand": "Tesla",
      "model": "Roadster"
    },
    "email": "elon@example.com",
    "company": "Tesla",
    "lastName": "Musk",
    "firstName": "Elon"
  },
  "requestId": "xvr69EYLKXvTkfYuk"
}
{
  "contact": "WmTjsFknzHdmfs3Ra",
  "requestId": "xvr69EYLKXvTkfYuk"
}
Response examples (200)
{
  "errors": [],
  "request": {
    "_id": "nw42MmBsJoccgutST",
    "status": "pending",
    "contact": {
      "_id": "xtPWKQqcAk8MJfoz5",
      "email": "maincontact@example.com",
      "lastName": "Doe",
      "createdAt": "2022-07-03T13:51:27Z",
      "firstName": "John",
      "nbRequest": 5,
      "lastActivity": "2022-07-04T07:20:06Z"
    },
    "dueDate": "2022-07-11T21:59:00Z",
    "privacy": "private",
    "branding": {
      "useBranding": false
    },
    "createdAt": "2022-07-04T07:20:06Z",
    "portalUrl": "https://app.usecollect.com/portal/uGFRDeEL3Ct2uYo2c/nw42MmBsJoccgutST",
    "campaignId": "xvr69EYLKXvTkfYuk",
    "contributors": [
      {
        "_id": "WmTjsFknzHdmfs3Ra",
        "email": "johndoe@example.com",
        "lastName": "Musk",
        "createdAt": "2022-07-03T13:51:27Z",
        "firstName": "Elon"
      }
    ]
  }
}