Appearance
SAP Audit Log Service
Write, store, and retrieve audit data for your subaccount and global account.
SAP Audit Log is a core, security, and compliance-based SAP BTP service to provide means for audit purposes. The default and advanced capabilities of Audit Log Service are available for SAP BTP Applications and Services. The advanced features enable you to comply with the SAP Product Standards and Business Industry regulations you're subject to. To enable the advanced features, you need to enable the premium edition service plan, where additional costs are applied based on the consumed volumes.

Feature | Description |
---|---|
Audit Log Retrieval API | (default) Download and preview audit data within the default retention period with the Auditlog Management Service. |
Audit Log Viewer | (default) The SAP Audit Log Viewer displays the audit logs for your subaccount, produced by SAP applications and services you’ve subscribed to. |
Audit Log Write API | (default) Write compliance audit data from SAP BTP services and applications through oAuth2 service plan. (advanced) Write audit data from your own BTP applications. |
Audit Log Retention | (default) Securely store audit data for a default retention time of 90 days with no additional costs applied. (advanced) Configure the retention period. To do so, create a support ticket on support.sap.com with component BC-CP-CF-SEC-AUDITLG. |
How to get started?
Find relevant SAP Community Blogs.
AppRouter Extension
js
const xsenv = require('@sap/xsenv');
const AuditLog = require('@sap/audit-logging'); // REST v2 Client
const credentials = xsenv.cfServiceCredentials({
label: 'auditlog'
});
const audit = await AuditLog.v2(credentials);
module.exports = function logSecurityEvent(req, res, next) {
// important! mask sensible header data
const { authorization, cookie, ...safeHeaders } = req.headers;
audit.securityMessage('HTTP %s %s', req.method, req.originalUrl)
.by('$USER')
.externalIP(req.ip) // DSGO conform?
.data({
headers: safeHeaders,
status: res.statusCode
})
.log(err => { if (err) console.error(err); });
next();
};
Support
Component Name | Component Description |
---|---|
BC-CP-CF-SEC-AUDITLG | Support component for this service |