- style
Create Request
DRAFT
The following endpoint can be used to creates a new request. This is the same endpoint we use for creating requests in zapier, web and mobile! It introduces an advanced payload body structure for linked objects to make creating objects a lot easier. See below for more information.
POST /requests
Standard Parameters
Table of allowed parameters. Required fields are underlined.
title | String | The title of the request. e.g, "Website has become unresponsive" |
---|---|---|
body | Unsigned Integer | The body/content of the request. |
type_id | Unsigned Integer | The type id of the request. Want to get a list of types? See the get request types endpoint. We use this endpoint for populating our request types when registering create request zapier action. |
affiliation_id | Unsigned Integer | The affiliation id of the request. If this is not provided, lead_id or affiliation details must be specified. |
priority_id | Unsigned Integer | The priority id of the request. If you leave this as blank, it will default for you. |
source | String | Only no value or "email" are accepted. |
lead_id | Unsigned Integer | The lead id of the request. If this is not provided, affiliation_id or affiliation details must be specified. See |
Linked Object Parameters
Here you can conditionally apply a new contact to the request. The linked object parameters we accept are as follows.
affiliation_email | String | If you do not provide an affiliation id you can provide a email to assigned to the new affiliation. An affiliation links a contact to a company. |
---|---|---|
affiliation_contact_id | Unsigned Integer | The unique identifier of the contact. You can use this to create a new affiliation associated with the request. If you don't have this information, leave blank and provide the name and email of the contact. |
affiliation_contact_firstname affiliation_contact_surname | String | If you do not provide a contact id you can provide their name and other details to create a new contact. This contact will be automatically linked to the new request and company linked in the payload. |
affiliation_email affiliation_phone | String | If you do not provide an affiliation id, you may provide an email or phone that will be used to create a new affiliation. |
affiliation_company_id | Unsigned Integer | The unique identifier of the company you wish this affiliation to be created against. If you don't know an id. You can provide contact details or a company name and one will be created and linked for you. |
affiliation_company_name affiliation_company_phone | String | If you do not provide a company id we will use whatever other details you provide to create a new company for you. This company will be linked to the contact as an affiliation. The affiliation will then be linked to your new request. |
 The link object parameters and create request payload can also come in as "application/json". This can simplify the clients implementation. For example, to create a request without knowing an affiliation, you can
{ "type_id": 30, "subject": "The website has become unresponsive", "body": "Your home page is no timing out?", "affiliation": { "contact" : { "firstname": "Jack", "surname": "Black" }, "company": { "name": "Jack and Co.", "phone": "+13 3234 2324" }, "email": "jack.black@jack-and-co.com", "phone": "64 444 444 444" } }
Don't forget to set the content type to "application/json"
Requirements
The create request endpoint requires a type id, title, body and affiliation to create on behalf of. If you do not have an affiliation id you must provide
- A firstname and surname;
- A firstname and company name; or
- An email
If you provide a firstname, surname, email and company name, we will attempt to match it to an existing affiliation for you. Each of these fields must exactly match for them to be considered the same person. If you provide a firstname, surname and email without a company name, we will also attempt to match to an existing affiliation using an exact match. For this reason it's recommended to send a firstname, surname, company name and email when possible, where company name is optional.
Handling the response
Please see the get request for controlling the response.