1.0.3 • Published 1 year ago

@seabaas/shared-backend v1.0.3

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

node-shared-backend

re-usable packages used across all our node services

Send audit log request

Installation

Simply run npm install @seabass/shared-backend

Usage

To use, simply import the function and pass in the necessary body parameters: Also, pass in AUDIT_LOG_API_URL as part of your environment variable.

const {sendAPILogRequest} = require('audit-log')

async function doSomething() {
    await someRequest()
    sendAPILogRequest({})
    return someValue
}

Possible list of parameters to be passed in are:

{
  "auditID": "uuid",
  "action": "string",
  "sourceIP": "string",
  "roleId": "string",
  "fullName": "string",
  "userActivityType": "string",
  "microserviceName": "string",
  "endpointName": "string",
  "oldValuesJson": "string",
  "payloadCreatedDate": "string",
  "newValuesJson": "string",
  "affectedColumns": "string",
  "role": "string",
  "userName": "string",
  "userID": "string",
  "createdDate": "string",
  "ipAddress": "string",
  "startDate": "string",
  "endDate": "string",
  "branchCode": "string",
  "location": "string",
  "branchName": "string",
  "clientInfo": "string",
  "actionStatus": "string",
  "lastLogin": "string",
  "sessionID": "string",
  "module": "string",
  "moduleID": "string",
  "timestamp": "string"
}

NOTE: timestamp and lastLogin are required.

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago