List Property
curl --request POST \
--url https://cloudapi.mailercloud.com/v1/contact/property/search \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"limit": 0,
"page": 0
}
'import requests
url = "https://cloudapi.mailercloud.com/v1/contact/property/search"
payload = {
"limit": 0,
"page": 0
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({limit: 0, page: 0})
};
fetch('https://cloudapi.mailercloud.com/v1/contact/property/search', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://cloudapi.mailercloud.com/v1/contact/property/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'limit' => 0,
'page' => 0
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://cloudapi.mailercloud.com/v1/contact/property/search"
payload := strings.NewReader("{\n \"limit\": 0,\n \"page\": 0\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<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))
}{
"count": 20,
"data": [
{
"field_description": "Created via webform as a template property.",
"field_name": "Message",
"field_type": "Textarea",
"field_value": "message",
"id": "dcK",
"is_default": 0
},
{
"field_description": " ",
"field_name": "Countryin",
"field_type": "Text",
"field_value": "countryin",
"id": "szB",
"is_default": 0
},
{
"field_description": "IP address of the subscriber",
"field_name": "IP",
"field_type": "Text",
"field_value": "userip",
"id": "Bg",
"is_default": 1
},
{
"field_description": "Lead source",
"field_name": "Lead source",
"field_type": "Text",
"field_value": "lead_source",
"id": "BF",
"is_default": 1
},
{
"field_description": "Salary of the subscriber",
"field_name": "Salary",
"field_type": "Number",
"field_value": "salary",
"id": "kv",
"is_default": 1
},
{
"field_description": "Job of the subscriber",
"field_name": "Job title",
"field_type": "Text",
"field_value": "job_title",
"id": "Ku",
"is_default": 1
},
{
"field_description": "Department of the subscriber",
"field_name": "Department",
"field_type": "Text",
"field_value": "department",
"id": "bC",
"is_default": 1
},
{
"field_description": "company name of the subscriber",
"field_name": "company_name",
"field_type": "Text",
"field_value": "organization",
"id": "kb",
"is_default": 1
}
]
}List Property
Using this API, you can list all the properties of your contacts in your Mailercloud account. You can also make segments based on these properties
POST
/
contact
/
property
/
search
List Property
curl --request POST \
--url https://cloudapi.mailercloud.com/v1/contact/property/search \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"limit": 0,
"page": 0
}
'import requests
url = "https://cloudapi.mailercloud.com/v1/contact/property/search"
payload = {
"limit": 0,
"page": 0
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({limit: 0, page: 0})
};
fetch('https://cloudapi.mailercloud.com/v1/contact/property/search', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://cloudapi.mailercloud.com/v1/contact/property/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'limit' => 0,
'page' => 0
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://cloudapi.mailercloud.com/v1/contact/property/search"
payload := strings.NewReader("{\n \"limit\": 0,\n \"page\": 0\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<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))
}{
"count": 20,
"data": [
{
"field_description": "Created via webform as a template property.",
"field_name": "Message",
"field_type": "Textarea",
"field_value": "message",
"id": "dcK",
"is_default": 0
},
{
"field_description": " ",
"field_name": "Countryin",
"field_type": "Text",
"field_value": "countryin",
"id": "szB",
"is_default": 0
},
{
"field_description": "IP address of the subscriber",
"field_name": "IP",
"field_type": "Text",
"field_value": "userip",
"id": "Bg",
"is_default": 1
},
{
"field_description": "Lead source",
"field_name": "Lead source",
"field_type": "Text",
"field_value": "lead_source",
"id": "BF",
"is_default": 1
},
{
"field_description": "Salary of the subscriber",
"field_name": "Salary",
"field_type": "Number",
"field_value": "salary",
"id": "kv",
"is_default": 1
},
{
"field_description": "Job of the subscriber",
"field_name": "Job title",
"field_type": "Text",
"field_value": "job_title",
"id": "Ku",
"is_default": 1
},
{
"field_description": "Department of the subscriber",
"field_name": "Department",
"field_type": "Text",
"field_value": "department",
"id": "bC",
"is_default": 1
},
{
"field_description": "company name of the subscriber",
"field_name": "company_name",
"field_type": "Text",
"field_value": "organization",
"id": "kb",
"is_default": 1
}
]
}Authorizations
Your Mailercloud API key (plain text, no Bearer prefix). Create keys in Settings → API.
Headers
Request body type
Body
application/json
Maximum number of elements to return.
Maximum: 100 Minimum: 10
Required range:
10 <= x <= 100You can retrieve a subset of records starting from the page value you have specified. You can add a limit, which will determine the number of records you can retrieve on a single page.
Starts From: 1
Filter property list by name , giving name as search keyword
Minimum string length:
1Filter property based on type.
Available types - default,custom
⌘I