Risk Cloud API: Record Search
Updated on: January 17, 2023
The Risk Cloud API contains the Record Search endpoint GET /api/v1/records/search
to provide a means of searching and filtering Records based on various parameters.
Endpoint
The Record Search endpoint GET /api/v1/records/search
is a Paginated endpoint that returns a Page of Records for a given page
and size
. Feel free to reference Risk Cloud API: Pagination for more information on how Paginated endpoints function in the Risk Cloud API.
While page
and size
are optional query parameters for some Paginated endpoints, page
and size
are required query parameters for the Record Search endpoint.
The response payload of the Record Search endpoint can be found in our API documentation.
Request
Records by Workflow
To filter the Record Search to only return a Page of Records from a specific Workflow, add the workflow
query parameter to the Record Search request.
workflow
: the unique ID of a Workflow, filtering the Record Search to only return
Records from the specified Workflow
To obtain a Workflow ID, reference Risk Cloud API: View Applications, Workflows, and Steps
Note: page
and size
query parameters are required for the Record Search endpoint
GET /api/v1/records/search?workflow={workflowId}&page=0&size=20
Linked Child Records
To filter the Record Search to return a Page of Linked Records, add the following query parameters to the Record Search request.
parent
: the unique ID of the parent Record to seek linked child Records fromsourceWorkflow
: the unique ID of the Workflow that theparent
Record is fromworkflow
: the unique ID of the linked Workflow from which linked child Records are soughtmapped
: whether the returned Records are linked to theparent
Record or not
Note: page
and size
query parameters are required for the Record Search endpoint
GET /api/v1/records/search?page=0&size=20&parent={recordId}&sourceWorkflow={workflowId}&wo rkflow={linkedWorkflowId}&mapped=true
Response
The Record Search endpoint returns a Page of Record objects, where the Records are within an array of the content
property of the Page. Each Record object of Page’s content
array is formatted as shown below.
Property | Type | Description |
properties |
array | A list of Custom Field and System Field properties |
properties[].header |
string | The name of the Custom Field or System Field |
properties[].fieldType |
enum | The Custom Field type for Custom Fields or null for System Fields |
properties[].systemField |
enum | The System Field type for System Fields or null for custom Fields |
properties[].recordId |
string | The unique ID of the Record containing this property |
properties[].url |
string | The path extension to the Field, only on Record Names |
properties[].rawValue |
object / string / array | Either a single Value object, a list of Value objects, or a string representing, depending on the type of Field |
properties[].formattedValue |
string | The string representation of the Value or Values |
record |
object | A returned Record |
record.id |
string | The unique ID of the Record |
record.depth |
integer | The depth of the Record |
record.name |
string | The name of the Record |
record.dueDate |
long | The Due Date of the Record measured in milliseconds since the Unix epoch |
record.user |
boolean | Whether the Record has an assignee |
record.canEdit |
boolean | Whether the current User is allowed to edit this Record |
record.canRead |
boolean | Whether the current User is allowed to read this Record |
record.step |
Step | The current Step of the Record |
recird.workflow |
Workflow | The Workflow of the Record |
record.application |
Application | The Application of the Record |
record.jiraKey |
string | The Jira Key of the Record if |
record.stepId |
string | The ID of the current Step of the Record |
record.stepEnd |
boolean | Whether the current Step of the Record is an End Step |