Record View Search

Search for a record and get a collection of list view objects grouped by record type. Results include record data and metadata describing the search list view.
Available in: Unlimited, Enterprise, and Developer Editions
Resource
1/connect/records
Available since version
30.0
Requires Chatter
No
HTTP methods
GET or HEAD
Request parameters for GET
Property Type Description Required or Optional Available Version
maxRecordsPerType Integer The maximum number of rows to return for each list view (each list view contains one object). The minimum value is 1. The maximum value is 25. The default value is 5. Optional 30.0
q String Specifies the string to search. The search string must contain at least two characters, not including wildcards. See Wildcards. Required 30.0
Response body
Record Search Results
Usage
This resource uses a whitelist. If the object type requested is not in the whitelist, the request returns a 400 response with an "INVALID_TYPE" error code. These are the supported objects:
Object Type Available
Custom objects 30.0
Account 30.0
Campaign 30.0
Case 30.0
CollaborationGroup 30.0
Contact 30.0
ContentDocument 30.0
ContentVersion 30.0
Contract 30.0
Dashboard 30.0
Event 30.0
Lead 30.0
LiveChatTranscript 30.0
Opportunity 30.0
OpportunityLineItem 30.0
Product 30.0
ServiceContract 30.0
Solution 30.0
Task 30.0
User 30.0
Example
This GET request searches for any records whose fields contain the characters “th” plus any additional characters:
1GET /connect/records?q=th*
This is the response:
1{
2  "resultGroups" : [ {
3    "definition" : {
4      "columns" : [ {
5        "dataType" : "Name",
6        "fieldId" : "Name",
7        "label" : "Account Name",
8        "name" : "Name"
9      }, {
10        "dataType" : "Text",
11        "fieldId" : "Site",
12        "label" : "Account Site",
13        "name" : "Site"
14      }, {
15        "dataType" : "Phone",
16        "fieldId" : "Phone",
17        "label" : "Account Phone",
18        "name" : "Phone"
19      }, {
20        "dataType" : "Reference",
21        "fieldId" : "OwnerId",
22        "label" : "Owner ID",
23        "name" : "OwnerId"
24      } ],
25      "label" : "Accounts",
26      "objectType" : {
27        "fieldId" : null,
28        "type" : "Account"
29      },
30      "rowLimit" : 5,
31      "sortColumns" : [ ]
32    },
33    "foundMoreRecords" : false,
34    "minRecordsFound" : 3,
35    "records" : [ {
36      "fields" : [ {
37        "fields" : [ {
38          "label" : "Account Name",
39          "text" : "Baghdad Theater",
40          "type" : "Text"
41        } ],
42        "label" : "Account Name",
43        "text" : "Baghdad Theater",
44        "type" : "Name"
45      }, {
46        "label" : "Account Site",
47        "text" : null,
48        "type" : "Text"
49      }, {
50        "label" : "Phone",
51        "text" : null,
52        "type" : "Phone"
53      }, {
54        "label" : "Account Owner",
55        "reference" : {
56          "id" : "005D0000001LL8OIAW",
57          "motif" : {
58            "color" : "20aeb8",
59            "largeIconUrl" : "/img/icon/profile64.png",
60            "mediumIconUrl" : "/img/icon/profile32.png",
61            "smallIconUrl" : "/img/icon/profile16.png"
62          },
63          "mySubscription" : null,
64          "name" : "Deanna Li",
65          "recordViewUrl" : "/services/data/v32.0/connect/records/005D0000001LL8OIAW",
66          "type" : "User",
67          "url" : "/services/data/v32.0/chatter/users/005D0000001LL8OIAW"
68        },
69        "text" : "Deanna Li",
70        "type" : "Reference"
71      } ],
72      "id" : "001D000000I8elzIAB",
73      "motif" : {
74        "color" : "236FBD",
75        "largeIconUrl" : "/img/icon/accounts64.png",
76        "mediumIconUrl" : "/img/icon/accounts32.png",
77        "smallIconUrl" : "/img/icon/accounts16.png"
78      },
79      "mySubscription" : null,
80      "name" : "Baghdad Theater",
81      "recordViewUrl" : "/services/data/v32.0/connect/records/001D000000I8elzIAB",
82      "type" : "Account",
83      "url" : "/services/data/v32.0/connect/records/001D000000I8elzIAB"
84    }, {
85      "fields" : [ {
86        "fields" : [ {
87          "label" : "Account Name",
88          "text" : "Hawthorne Theater",
89          "type" : "Text"
90        } ],
91        "label" : "Account Name",
92        "text" : "Hawthorne Theater",
93        "type" : "Name"
94      }, {
95        "label" : "Account Site",
96        "text" : null,
97        "type" : "Text"
98      }, {
99        "label" : "Phone",
100        "text" : null,
101        "type" : "Phone"
102      }, {
103        "label" : "Account Owner",
104        "reference" : {
105          "id" : "005D0000001LL8OIAW",
106          "motif" : {
107            "color" : "20aeb8",
108            "largeIconUrl" : "/img/icon/profile64.png",
109            "mediumIconUrl" : "/img/icon/profile32.png",
110            "smallIconUrl" : "/img/icon/profile16.png"
111          },
112          "mySubscription" : null,
113          "name" : "Deanna Li",
114          "recordViewUrl" : "/services/data/v32.0/connect/records/005D0000001LL8OIAW",
115          "type" : "User",
116          "url" : "/services/data/v32.0/chatter/users/005D0000001LL8OIAW"
117        },
118        "text" : "Deanna Li",
119        "type" : "Reference"
120      } ],
121      "id" : "001D000000I8eltIAB",
122      "motif" : {
123        "color" : "236FBD",
124        "largeIconUrl" : "/img/icon/accounts64.png",
125        "mediumIconUrl" : "/img/icon/accounts32.png",
126        "smallIconUrl" : "/img/icon/accounts16.png"
127      },
128      "mySubscription" : null,
129      "name" : "Hawthorne Theater",
130      "recordViewUrl" : "/services/data/v32.0/connect/records/001D000000I8eltIAB",
131      "type" : "Account",
132      "url" : "/services/data/v32.0/connect/records/001D000000I8eltIAB"
133    }, {
134      "fields" : [ {
135        "fields" : [ {
136          "label" : "Account Name",
137          "text" : "The Whole Bowl",
138          "type" : "Text"
139        } ],
140        "label" : "Account Name",
141        "text" : "The Whole Bowl",
142        "type" : "Name"
143      }, {
144        "label" : "Account Site",
145        "text" : null,
146        "type" : "Text"
147      }, {
148        "label" : "Phone",
149        "text" : null,
150        "type" : "Phone"
151      }, {
152        "label" : "Account Owner",
153        "reference" : {
154          "id" : "005D0000001LL8OIAW",
155          "motif" : {
156            "color" : "20aeb8",
157            "largeIconUrl" : "/img/icon/profile64.png",
158            "mediumIconUrl" : "/img/icon/profile32.png",
159            "smallIconUrl" : "/img/icon/profile16.png"
160          },
161          "mySubscription" : null,
162          "name" : "Deanna Li",
163          "recordViewUrl" : "/services/data/v32.0/connect/records/005D0000001LL8OIAW",
164          "type" : "User",
165          "url" : "/services/data/v32.0/chatter/users/005D0000001LL8OIAW"
166        },
167        "text" : "Deanna Li",
168        "type" : "Reference"
169      } ],
170      "id" : "001D000000I8eloIAB",
171      "motif" : {
172        "color" : "236FBD",
173        "largeIconUrl" : "/img/icon/accounts64.png",
174        "mediumIconUrl" : "/img/icon/accounts32.png",
175        "smallIconUrl" : "/img/icon/accounts16.png"
176      },
177      "mySubscription" : null,
178      "name" : "The Whole Bowl",
179      "recordViewUrl" : "/services/data/v32.0/connect/records/001D000000I8eloIAB",
180      "type" : "Account",
181      "url" : "/services/data/v32.0/connect/records/001D000000I8eloIAB"
182    } ]
183  }, {
184    "definition" : {
185      "columns" : [ {
186        "dataType" : "Name",
187        "fieldId" : "Name",
188        "label" : "Full Name",
189        "name" : "Name"
190      }, {
191        "dataType" : "Text",
192        "fieldId" : "Title",
193        "label" : "Title",
194        "name" : "Title"
195      }, {
196        "dataType" : "Phone",
197        "fieldId" : "Phone",
198        "label" : "Phone",
199        "name" : "Phone"
200      }, {
201        "dataType" : "Text",
202        "fieldId" : "Company",
203        "label" : "Company",
204        "name" : "Company"
205      }, {
206        "dataType" : "Email",
207        "fieldId" : "Email",
208        "label" : "Email",
209        "name" : "Email"
210      }, {
211        "dataType" : "Picklist",
212        "fieldId" : "Status",
213        "label" : "Status",
214        "name" : "Status"
215      } ],
216      "label" : "Leads",
217      "objectType" : {
218        "fieldId" : null,
219        "type" : "Lead"
220      },
221      "rowLimit" : 5,
222      "sortColumns" : [ ]
223    },
224    "foundMoreRecords" : false,
225    "minRecordsFound" : 1,
226    "records" : [ {
227      "fields" : [ {
228        "fields" : [ {
229          "label" : "Salutation",
230          "text" : null,
231          "type" : "Picklist"
232        }, {
233          "label" : "First Name",
234          "text" : null,
235          "type" : "Text"
236        }, {
237          "label" : "Last Name",
238          "text" : null,
239          "type" : "Text"
240        } ],
241        "label" : "Name",
242        "text" : "Thea",
243        "type" : "Name"
244      }, {
245        "label" : "Title",
246        "text" : null,
247        "type" : "Text"
248      }, {
249        "label" : "Phone",
250        "text" : null,
251        "type" : "Phone"
252      }, {
253        "label" : "Company",
254        "text" : "Key Shoppe",
255        "type" : "Text"
256      }, {
257        "label" : "Email",
258        "text" : null,
259        "type" : "Email"
260      }, {
261        "label" : "Lead Status",
262        "text" : "Open - Not Contacted",
263        "type" : "Picklist"
264      } ],
265      "id" : "00QD000000GGUyqMAH",
266      "motif" : {
267        "color" : "E39321",
268        "largeIconUrl" : "/img/icon/leads64.png",
269        "mediumIconUrl" : "/img/icon/leads32.png",
270        "smallIconUrl" : "/img/icon/leads16.png"
271      },
272      "mySubscription" : null,
273      "name" : "Thea, Key Shoppe",
274      "recordViewUrl" : "/services/data/v32.0/connect/records/00QD000000GGUyqMAH",
275      "type" : "Lead",
276      "url" : "/services/data/v32.0/connect/records/00QD000000GGUyqMAH"
277    } ]
278  } ],
279  "url" : "/services/data/v32.0/connect/records?q=th*"
280}