curl --request POST \
--url https://api.stardex.ai/v1/deals/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"offset": 0,
"limit": 100,
"sort_by": "<string>",
"sort_order": "desc",
"keywords": [
"<string>"
],
"deal_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"list_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"deal_status_ids_included": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"deal_status_ids_excluded": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"owner_ids_included": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"owner_ids_excluded": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"show_open_deals_only": true,
"show_archived": true,
"closed_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": false
},
"open_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": false
},
"select_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": false,
"include_empty": false
}
],
"numeric_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"min": 123,
"max": 123,
"include_empty": false
}
],
"date_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"start_date": "<string>",
"end_date": "<string>",
"include_empty": false
}
],
"team_member_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": false,
"include_empty": false
}
],
"include": [
"custom_fields"
]
}
'import requests
url = "https://api.stardex.ai/v1/deals/search"
payload = {
"offset": 0,
"limit": 100,
"sort_by": "<string>",
"sort_order": "desc",
"keywords": ["<string>"],
"deal_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"list_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"deal_status_ids_included": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"deal_status_ids_excluded": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"owner_ids_included": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"owner_ids_excluded": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"show_open_deals_only": True,
"show_archived": True,
"closed_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": False
},
"open_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": False
},
"select_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": False,
"include_empty": False
}
],
"numeric_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"min": 123,
"max": 123,
"include_empty": False
}
],
"date_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"start_date": "<string>",
"end_date": "<string>",
"include_empty": False
}
],
"team_member_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": False,
"include_empty": False
}
],
"include": ["custom_fields"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
offset: 0,
limit: 100,
sort_by: '<string>',
sort_order: 'desc',
keywords: ['<string>'],
deal_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
list_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
deal_status_ids_included: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
deal_status_ids_excluded: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
owner_ids_included: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
owner_ids_excluded: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
show_open_deals_only: true,
show_archived: true,
closed_date_filter: {start_date: '<string>', end_date: '<string>', include_empty: false},
open_date_filter: {start_date: '<string>', end_date: '<string>', include_empty: false},
select_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
values: [],
excluded_values: [],
require_all: false,
include_empty: false
}
],
numeric_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
min: 123,
max: 123,
include_empty: false
}
],
date_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
start_date: '<string>',
end_date: '<string>',
include_empty: false
}
],
team_member_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
values: [],
excluded_values: [],
require_all: false,
include_empty: false
}
],
include: ['custom_fields']
})
};
fetch('https://api.stardex.ai/v1/deals/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://api.stardex.ai/v1/deals/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([
'offset' => 0,
'limit' => 100,
'sort_by' => '<string>',
'sort_order' => 'desc',
'keywords' => [
'<string>'
],
'deal_ids' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'list_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'deal_status_ids_included' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'deal_status_ids_excluded' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'owner_ids_included' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'owner_ids_excluded' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'show_open_deals_only' => true,
'show_archived' => true,
'closed_date_filter' => [
'start_date' => '<string>',
'end_date' => '<string>',
'include_empty' => false
],
'open_date_filter' => [
'start_date' => '<string>',
'end_date' => '<string>',
'include_empty' => false
],
'select_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'values' => [
],
'excluded_values' => [
],
'require_all' => false,
'include_empty' => false
]
],
'numeric_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'min' => 123,
'max' => 123,
'include_empty' => false
]
],
'date_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'start_date' => '<string>',
'end_date' => '<string>',
'include_empty' => false
]
],
'team_member_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'values' => [
],
'excluded_values' => [
],
'require_all' => false,
'include_empty' => false
]
],
'include' => [
'custom_fields'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://api.stardex.ai/v1/deals/search"
payload := strings.NewReader("{\n \"offset\": 0,\n \"limit\": 100,\n \"sort_by\": \"<string>\",\n \"sort_order\": \"desc\",\n \"keywords\": [\n \"<string>\"\n ],\n \"deal_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"list_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"deal_status_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"deal_status_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"show_open_deals_only\": true,\n \"show_archived\": true,\n \"closed_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"open_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"select_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"numeric_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"min\": 123,\n \"max\": 123,\n \"include_empty\": false\n }\n ],\n \"date_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n }\n ],\n \"team_member_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"include\": [\n \"custom_fields\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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))
}HttpResponse<String> response = Unirest.post("https://api.stardex.ai/v1/deals/search")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"offset\": 0,\n \"limit\": 100,\n \"sort_by\": \"<string>\",\n \"sort_order\": \"desc\",\n \"keywords\": [\n \"<string>\"\n ],\n \"deal_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"list_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"deal_status_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"deal_status_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"show_open_deals_only\": true,\n \"show_archived\": true,\n \"closed_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"open_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"select_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"numeric_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"min\": 123,\n \"max\": 123,\n \"include_empty\": false\n }\n ],\n \"date_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n }\n ],\n \"team_member_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"include\": [\n \"custom_fields\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.stardex.ai/v1/deals/search")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"offset\": 0,\n \"limit\": 100,\n \"sort_by\": \"<string>\",\n \"sort_order\": \"desc\",\n \"keywords\": [\n \"<string>\"\n ],\n \"deal_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"list_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"deal_status_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"deal_status_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"show_open_deals_only\": true,\n \"show_archived\": true,\n \"closed_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"open_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"select_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"numeric_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"min\": 123,\n \"max\": 123,\n \"include_empty\": false\n }\n ],\n \"date_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n }\n ],\n \"team_member_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"include\": [\n \"custom_fields\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": [
{
"id": "aaa11111-bbbb-cccc-dddd-eeeeeeee1111",
"name": "Acme Corp Staffing Agreement",
"amount": 150000,
"currency_code": "USD",
"compensation": 750000,
"compensation_currency_code": "USD",
"pricing_rate": 20,
"win_probability": 75,
"closed_date": "2024-06-30T00:00:00Z",
"last_contacted_at": "2024-05-20T14:30:00Z",
"deal_status": {
"id": "ccc33333-dddd-eeee-ffff-000000003333",
"name": "Proposal Sent"
},
"created_at": "2024-01-15T10:00:00Z",
"client_name": "Acme Corp",
"client_id": "bbb22222-cccc-dddd-eeee-ffffffff2222",
"owners": [
{
"id": "ddd44444-eeee-ffff-0000-111111114444",
"name": "Jane Smith"
}
],
"custom_fields": [
{
"attribute_id": "f1e2d3c4-b5a6-7890-abcd-ef1234567890",
"attribute_name": "Deal Priority",
"data_type": "single-select",
"value": null,
"tag": {
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"name": "High"
},
"team_member": null
}
]
}
],
"meta": {
"total": 100,
"offset": 0,
"limit": 20
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>"
}
}Search deals
Search and filter deals with pagination and sorting using the deals_list_query RPC.
Filters: keywords (name + company search), deal_status_ids_included/excluded, owner_ids_included/excluded, show_open_deals_only, show_archived, closed_date_filter, open_date_filter, and custom attribute filters (select_attribute_filters, numeric_attribute_filters, date_attribute_filters, team_member_attribute_filters).
Sorting: name, amount, win_probability, company, status, closed_date, last_contacted_at, created_at, or custom_<attribute_id> for custom attribute sorting.
Include: Pass ["custom_fields"] to include deal custom attribute values.
curl --request POST \
--url https://api.stardex.ai/v1/deals/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"offset": 0,
"limit": 100,
"sort_by": "<string>",
"sort_order": "desc",
"keywords": [
"<string>"
],
"deal_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"list_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"deal_status_ids_included": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"deal_status_ids_excluded": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"owner_ids_included": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"owner_ids_excluded": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"show_open_deals_only": true,
"show_archived": true,
"closed_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": false
},
"open_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": false
},
"select_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": false,
"include_empty": false
}
],
"numeric_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"min": 123,
"max": 123,
"include_empty": false
}
],
"date_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"start_date": "<string>",
"end_date": "<string>",
"include_empty": false
}
],
"team_member_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": false,
"include_empty": false
}
],
"include": [
"custom_fields"
]
}
'import requests
url = "https://api.stardex.ai/v1/deals/search"
payload = {
"offset": 0,
"limit": 100,
"sort_by": "<string>",
"sort_order": "desc",
"keywords": ["<string>"],
"deal_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"list_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"deal_status_ids_included": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"deal_status_ids_excluded": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"owner_ids_included": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"owner_ids_excluded": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"show_open_deals_only": True,
"show_archived": True,
"closed_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": False
},
"open_date_filter": {
"start_date": "<string>",
"end_date": "<string>",
"include_empty": False
},
"select_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": False,
"include_empty": False
}
],
"numeric_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"min": 123,
"max": 123,
"include_empty": False
}
],
"date_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"start_date": "<string>",
"end_date": "<string>",
"include_empty": False
}
],
"team_member_attribute_filters": [
{
"attribute_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"values": [],
"excluded_values": [],
"require_all": False,
"include_empty": False
}
],
"include": ["custom_fields"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
offset: 0,
limit: 100,
sort_by: '<string>',
sort_order: 'desc',
keywords: ['<string>'],
deal_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
list_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
deal_status_ids_included: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
deal_status_ids_excluded: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
owner_ids_included: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
owner_ids_excluded: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
show_open_deals_only: true,
show_archived: true,
closed_date_filter: {start_date: '<string>', end_date: '<string>', include_empty: false},
open_date_filter: {start_date: '<string>', end_date: '<string>', include_empty: false},
select_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
values: [],
excluded_values: [],
require_all: false,
include_empty: false
}
],
numeric_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
min: 123,
max: 123,
include_empty: false
}
],
date_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
start_date: '<string>',
end_date: '<string>',
include_empty: false
}
],
team_member_attribute_filters: [
{
attribute_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
values: [],
excluded_values: [],
require_all: false,
include_empty: false
}
],
include: ['custom_fields']
})
};
fetch('https://api.stardex.ai/v1/deals/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://api.stardex.ai/v1/deals/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([
'offset' => 0,
'limit' => 100,
'sort_by' => '<string>',
'sort_order' => 'desc',
'keywords' => [
'<string>'
],
'deal_ids' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'list_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'deal_status_ids_included' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'deal_status_ids_excluded' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'owner_ids_included' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'owner_ids_excluded' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'show_open_deals_only' => true,
'show_archived' => true,
'closed_date_filter' => [
'start_date' => '<string>',
'end_date' => '<string>',
'include_empty' => false
],
'open_date_filter' => [
'start_date' => '<string>',
'end_date' => '<string>',
'include_empty' => false
],
'select_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'values' => [
],
'excluded_values' => [
],
'require_all' => false,
'include_empty' => false
]
],
'numeric_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'min' => 123,
'max' => 123,
'include_empty' => false
]
],
'date_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'start_date' => '<string>',
'end_date' => '<string>',
'include_empty' => false
]
],
'team_member_attribute_filters' => [
[
'attribute_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'values' => [
],
'excluded_values' => [
],
'require_all' => false,
'include_empty' => false
]
],
'include' => [
'custom_fields'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://api.stardex.ai/v1/deals/search"
payload := strings.NewReader("{\n \"offset\": 0,\n \"limit\": 100,\n \"sort_by\": \"<string>\",\n \"sort_order\": \"desc\",\n \"keywords\": [\n \"<string>\"\n ],\n \"deal_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"list_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"deal_status_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"deal_status_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"show_open_deals_only\": true,\n \"show_archived\": true,\n \"closed_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"open_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"select_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"numeric_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"min\": 123,\n \"max\": 123,\n \"include_empty\": false\n }\n ],\n \"date_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n }\n ],\n \"team_member_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"include\": [\n \"custom_fields\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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))
}HttpResponse<String> response = Unirest.post("https://api.stardex.ai/v1/deals/search")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"offset\": 0,\n \"limit\": 100,\n \"sort_by\": \"<string>\",\n \"sort_order\": \"desc\",\n \"keywords\": [\n \"<string>\"\n ],\n \"deal_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"list_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"deal_status_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"deal_status_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"show_open_deals_only\": true,\n \"show_archived\": true,\n \"closed_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"open_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"select_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"numeric_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"min\": 123,\n \"max\": 123,\n \"include_empty\": false\n }\n ],\n \"date_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n }\n ],\n \"team_member_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"include\": [\n \"custom_fields\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.stardex.ai/v1/deals/search")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"offset\": 0,\n \"limit\": 100,\n \"sort_by\": \"<string>\",\n \"sort_order\": \"desc\",\n \"keywords\": [\n \"<string>\"\n ],\n \"deal_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"list_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"deal_status_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"deal_status_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_included\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"owner_ids_excluded\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"show_open_deals_only\": true,\n \"show_archived\": true,\n \"closed_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"open_date_filter\": {\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n },\n \"select_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"numeric_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"min\": 123,\n \"max\": 123,\n \"include_empty\": false\n }\n ],\n \"date_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"start_date\": \"<string>\",\n \"end_date\": \"<string>\",\n \"include_empty\": false\n }\n ],\n \"team_member_attribute_filters\": [\n {\n \"attribute_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"values\": [],\n \"excluded_values\": [],\n \"require_all\": false,\n \"include_empty\": false\n }\n ],\n \"include\": [\n \"custom_fields\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": [
{
"id": "aaa11111-bbbb-cccc-dddd-eeeeeeee1111",
"name": "Acme Corp Staffing Agreement",
"amount": 150000,
"currency_code": "USD",
"compensation": 750000,
"compensation_currency_code": "USD",
"pricing_rate": 20,
"win_probability": 75,
"closed_date": "2024-06-30T00:00:00Z",
"last_contacted_at": "2024-05-20T14:30:00Z",
"deal_status": {
"id": "ccc33333-dddd-eeee-ffff-000000003333",
"name": "Proposal Sent"
},
"created_at": "2024-01-15T10:00:00Z",
"client_name": "Acme Corp",
"client_id": "bbb22222-cccc-dddd-eeee-ffffffff2222",
"owners": [
{
"id": "ddd44444-eeee-ffff-0000-111111114444",
"name": "Jane Smith"
}
],
"custom_fields": [
{
"attribute_id": "f1e2d3c4-b5a6-7890-abcd-ef1234567890",
"attribute_name": "Deal Priority",
"data_type": "single-select",
"value": null,
"tag": {
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"name": "High"
},
"team_member": null
}
]
}
],
"meta": {
"total": 100,
"offset": 0,
"limit": 20
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"success": false,
"error": {
"code": "<string>",
"message": "<string>"
}
}Authorizations
Authenticate with a Bearer token: API key, OAuth token, or session token.
Body
Records to skip for pagination. Defaults to 0.
x >= 0Max records to return (1–100). Defaults to 100.
1 <= x <= 100Column to sort by. Accepted values:
name— deal name (alphabetical)amount— deal monetary amountwin_probability— win probability percentagecompany— client company name (alphabetical)status— deal status (by stage order)closed_date— expected or actual close datelast_contacted_at— most recent engagement with client contactscreated_at— creation timestamp (default)custom_<attribute_id>— any custom attribute UUID prefixed withcustom_(e.g.custom_e5f6a7b8-...). Sorts by the attribute's decimal, date, string, or tag value.
Sort direction. Defaults to desc (newest first).
asc, desc Full-text search across deal name, client company name, and domain. Multiple keywords use OR logic.
Pre-filter to a specific set of deal UUIDs.
Filter to deals belonging to this list.
Include only deals with these status UUIDs.
Exclude deals with these status UUIDs.
Include only deals owned by these team members. Get IDs from GET /v1/team-members.
Exclude deals owned by these team members.
When true, only return deals with an "active" status type.
When true, return archived (soft-deleted) deals instead of active ones.
Filter by closed_date range. Supports start_date, end_date, and include_empty.
Show child attributes
Show child attributes
Filter by creation date (open date) range. Supports start_date, end_date, and include_empty.
Show child attributes
Show child attributes
Filter by select/multi-select custom fields. Get attribute_id and tag IDs from GET /v1/custom-fields/deals.
Show child attributes
Show child attributes
Filter by numeric custom fields (min/max range). Get attribute_id from GET /v1/custom-fields/deals.
Show child attributes
Show child attributes
Filter by date custom fields (date range). Get attribute_id from GET /v1/custom-fields/deals.
Show child attributes
Show child attributes
Filter by team-member custom fields. Get attribute_id from GET /v1/custom-fields/deals.
Show child attributes
Show child attributes
Extra sections to embed. Values: custom_fields. Omit for base fields only.
custom_fields Was this page helpful?