To retrieve a shield information barrier report by its ID, call the shieldInformationBarrierReports.getById(options, callback)
method.
const barrierReport = await client.shieldInformationBarrierReports.getById({
shield_information_barrier_report_id: '12345',
});
console.log(`Shield information barrier report id ${barrierReport.id}`);
To retrieves a list of shield information barrier reports based on provided barrier ID, call the shieldInformationBarrierReports.getAll(options, callback)
method.
const result = await client.shieldInformationBarrierReports.getAll({
shield_information_barrier_id: '123'
});
console.log(`There are ${result.entries.length} shield information barrier reports`);
To create a shield information barrier report for a given barrier, call the shieldInformationBarrierReports.create(options, callback)
method with a shield_information_barrier
object in the body of the request.
const barrierReport = await client.shieldInformationBarrierReports.create({
shield_information_barrier: {
id: '123',
type: 'shield_information_barrier'
}
});
console.log(`Shield information barrier report with id ${barrierReport.id} was created`);