Create Lead
curl --request POST \
--url https://api.eqho.ai/v1/leads \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--header 'x-org-id: <api-key>' \
--data '
{
"lead": {
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
},
"list_ids": []
}
'import requests
url = "https://api.eqho.ai/v1/leads"
payload = {
"lead": {
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
},
"list_ids": []
}
headers = {
"X-API-KEY": "<api-key>",
"x-org-id": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-API-KEY': '<api-key>',
'x-org-id': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
lead: {
created_at: '2021-08-25T00:00:00+00:00',
email: '[email protected]',
first_name: 'Jane',
last_name: 'Smith',
phone: '+18015551831',
phone_extension: '123'
},
list_ids: []
})
};
fetch('https://api.eqho.ai/v1/leads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.eqho.ai/v1/leads"
payload := strings.NewReader("{\n \"lead\": {\n \"created_at\": \"2021-08-25T00:00:00+00:00\",\n \"email\": \"[email protected]\",\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone\": \"+18015551831\",\n \"phone_extension\": \"123\"\n },\n \"list_ids\": []\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
req.Header.Add("x-org-id", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Leads
Create Lead
POST
/
v1
/
leads
Create Lead
curl --request POST \
--url https://api.eqho.ai/v1/leads \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--header 'x-org-id: <api-key>' \
--data '
{
"lead": {
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
},
"list_ids": []
}
'import requests
url = "https://api.eqho.ai/v1/leads"
payload = {
"lead": {
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
},
"list_ids": []
}
headers = {
"X-API-KEY": "<api-key>",
"x-org-id": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-API-KEY': '<api-key>',
'x-org-id': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
lead: {
created_at: '2021-08-25T00:00:00+00:00',
email: '[email protected]',
first_name: 'Jane',
last_name: 'Smith',
phone: '+18015551831',
phone_extension: '123'
},
list_ids: []
})
};
fetch('https://api.eqho.ai/v1/leads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.eqho.ai/v1/leads"
payload := strings.NewReader("{\n \"lead\": {\n \"created_at\": \"2021-08-25T00:00:00+00:00\",\n \"email\": \"[email protected]\",\n \"first_name\": \"Jane\",\n \"last_name\": \"Smith\",\n \"phone\": \"+18015551831\",\n \"phone_extension\": \"123\"\n },\n \"list_ids\": []\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
req.Header.Add("x-org-id", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
APIKeyHeader & OrgImpersonationOAuth2PasswordBearer & OrgImpersonation
Your API key for authentication.
Org impersonation via x-org-id. Superadmins may impersonate any org; admins may impersonate their direct sub-organizations. Enter the target organization ID to act as that org.
Body
application/json
Show child attributes
Show child attributes
Example:
{
"created_at": "2021-08-25T00:00:00+00:00",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Smith",
"phone": "+18015551831",
"phone_extension": "123"
}
Response
Successful Response
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Was this page helpful?