import BrainbaseLabs from 'brainbase-labs';
const client = new BrainbaseLabs({
apiKey: process.env['BRAINBASE_LABS_API_KEY'], // This is the default and can be omitted
});
const history = await client.workers.deployments.history.retrieve('deploymentId', {
workerId: 'workerId',
});
console.log(history.data);{
"data": [
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"deploymentId": "<string>",
"changeType": "FLOW_VERSION",
"committedFlowVersionId": "<string>",
"previousValue": {},
"newValue": {},
"comment": "<string>",
"changedById": "<string>",
"deployedAt": "2023-11-07T05:31:56Z",
"status": "<string>",
"flowVersion": 123,
"metadata": {}
}
],
"total": 123,
"hasMore": true
}Returns paginated change history for a deployment
import BrainbaseLabs from 'brainbase-labs';
const client = new BrainbaseLabs({
apiKey: process.env['BRAINBASE_LABS_API_KEY'], // This is the default and can be omitted
});
const history = await client.workers.deployments.history.retrieve('deploymentId', {
workerId: 'workerId',
});
console.log(history.data);{
"data": [
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"deploymentId": "<string>",
"changeType": "FLOW_VERSION",
"committedFlowVersionId": "<string>",
"previousValue": {},
"newValue": {},
"comment": "<string>",
"changedById": "<string>",
"deployedAt": "2023-11-07T05:31:56Z",
"status": "<string>",
"flowVersion": 123,
"metadata": {}
}
],
"total": 123,
"hasMore": true
}API key authentication
1 <= x <= 100x >= 0FLOW_VERSION, CONFIG, VOICE_SETTINGS, STATUS, PARAMETERS