UNPKG

alpha-version-dce-check-in-api

Version:

API for taking attendance and checking people in.

33 lines (30 loc) 1.1 kB
// Import express types import { Request } from 'express'; /** * Record an error * @author Gabe Abrams * @param {string} message - the error message * @param {string|number} code - the error code * @param {object} req - Express request object * @param {number} [userId=value in session] - the Canvas id of the user who is * attending * @param {string} [userFirstName=value in session] - the first name of the user * @param {string} [userLastName=value in session] - the last name of the user * @param {number} [courseId=value in session] - the Canvas Course Id * @param {object} [metadata={}] - additional metadata object * @param {boolean} [isLearner=value in session] - true if the user is a learner * @param {boolean} [isAdmin=value in session] - true if the user is an admin */ type LogError = (opts: { message: string, code: string | number, req: Request, userId?: number, userFirstName?: string, userLastName?: string, courseId?: number, metadata?: { [key in string]: any }, isLearner?: boolean, isAdmin?: boolean, }) => Promise<void>; export default LogError;