Processes (ROPA)
Manage processes in your Record of Processing Activities.
List processes
Returns all processes for your company.
Response
Create a process
Creates a new process.
const res = await fetch(
"https://nightly.api.trustview.eu/external/smart-inventory/process/new",
{
method: "POST",
headers: {
"X-API-Key": "tvw_sk_live_your_key_here",
"Content-Type": "application/json",
},
body: JSON.stringify({
name: "Employee onboarding",
description: "<p>Onboarding workflow</p>",
active: true,
}),
}
);
const process = await res.json();
$ch = curl_init('https://nightly.api.trustview.eu/external/smart-inventory/process/new');
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'X-API-Key: tvw_sk_live_your_key_here',
'Content-Type: application/json',
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode([
'name' => 'Employee onboarding',
'description' => '<p>Onboarding workflow</p>',
'active' => true,
]));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = json_decode(curl_exec($ch));
curl_close($ch);
Response
Returns the created process object.
Get a process
Retrieves a single process by its unique ID.
| Name | In | Type | Description |
|---|---|---|---|
ropa |
path | string | Enter process unique ID |
Tip
The process unique ID can be found in the address bar when viewing a process.
Update a process
Updates an existing process. Send only the fields you want to change.
| Name | In | Type | Description |
|---|---|---|---|
ropa |
path | string | Enter process unique ID |
Tip
The process unique ID can be found in the address bar when viewing a process.
$ch = curl_init('https://nightly.api.trustview.eu/external/smart-inventory/process/6a054b8b9ae1a/edit');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PATCH');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'X-API-Key: tvw_sk_live_your_key_here',
'Content-Type: application/json',
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode(['name' => 'Employee onboarding (revised)']));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_exec($ch);
curl_close($ch);
Response
Returns 204 No Content on success.
Delete a process
Removes a process.
| Name | In | Type | Description |
|---|---|---|---|
ropa |
path | string | Enter process unique ID |
Tip
The process unique ID can be found in the address bar when viewing a process.
$ch = curl_init('https://nightly.api.trustview.eu/external/smart-inventory/process/6a054b8b9ae1a/delete');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'DELETE');
curl_setopt($ch, CURLOPT_HTTPHEADER, ['X-API-Key: tvw_sk_live_your_key_here']);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_exec($ch);
curl_close($ch);
Response
Returns 204 No Content on success.