Request a Log Event. A token with scope read:logs is needed.
See https://auth0.com/docs/api/management/v2#!/Logs/get_logs_by_id

@param logEventId the id of the connection to retrieve.
@return a Request to execute.
183087
public Request<LogEvent> get(String logEventId) {
        Asserts.assertNotNull(logEventId, "log event id");

        String url = baseUrl
                .newBuilder()
                .addPathSegments("api/v2/logs")
                .addPathSegment(logEventId)
                .build()
                .toString();
        CustomRequest<LogEvent> request = new CustomRequest<>(client, url, "GET", new TypeReference<LogEvent>() {
        });
        request.addHeader("Authorization", "Bearer " + apiToken);
        return request;
    }
338103
@Override
	public LogEvent rewrite(LogEvent source) {
		// get the markers for the log event. If no markers, nothing can be
		// tagged confidential and we can return
		Marker sourceMarker = source.getMarker();
		if (sourceMarker == null) {
			return source;
		}

		// get the message. If no message we can return
		final Message msg = source.getMessage();
		if (msg == null || !(msg instanceof ParameterizedMessage)) {
			return source;
		}

		// get the parameters. If no params we can return
		Object[] params = msg.getParameters();
		if (params == null || params.length == 0) {
			return source;
		}

		// check if this event is actually marked as confidential. If not,
		// return
		Log4jMarker eventMarker = new Log4jMarker(sourceMarker);
		if (!eventMarker.contains(SecurityMarkers.CONFIDENTIAL)) {
			return source;
		}

		// we have a message, parameters, a marker, and it is confidential.
		// Process
		for (int i = 0; i < params.length; i++) {
			params[i] = MASKED_PASSWORD;
		}

		// create new message
		Message outMessage = new ParameterizedMessage(msg.getFormat(), params,
				msg.getThrowable());

		// build new log event for output
		LogEvent output = new Log4jLogEvent.Builder(source)
				.setMessage(outMessage).build();

		return output;
	}
785462
public static void log(Logger logger, ILoggingEvent event)
    {
        ((ch.qos.logback.classic.Logger) logger).callAppenders(event);
    }
370146
@Override
  public void doAuthRequestEvent(ServerAuthSession appSession, AppRequestEvent request)
      throws InternalException, IllegalDiameterStateException, RouteException, OverloadException {
    logger.info("Diameter Gq AuthorizationSessionFactory :: doAuthRequestEvent :: appSession[{}], Request[{}]", appSession, request);
  }
1216725
function setRequestId(id, cb) {
  var ns = getLoggerNamespace();
  ns.run(function() {
    ns.set('requestId', id);
    cb();
  });
}
958279
function getLogEvent(level, message, rawMessage) {
            return {
                hostname: os.hostname(),
                pid: process.pid,
                gid: hasGetGid ? process.getgid() : null,
                processTitle: process.title,
                level: level,
                levelName: level.name,
                message: message,
                timeStamp: new Date(),
                name: this.fullName,
                rawMessage: rawMessage
            };
        }
830699
function SubscriptionOperation(
    log, cb, streamId, resolveLinkTos, userCredentials, eventAppeared,
    subscriptionDropped, verboseLogging, getConnection
) {
  //TODO: validations
  //Ensure.NotNull(log, "log");
  //Ensure.NotNull(source, "source");
  //Ensure.NotNull(eventAppeared, "eventAppeared");
  //Ensure.NotNull(getConnection, "getConnection");

  this._log = log;
  this._cb = cb;
  this._streamId = streamId || '';
  this._resolveLinkTos = resolveLinkTos;
  this._userCredentials = userCredentials;
  this._eventAppeared = eventAppeared;
  this._subscriptionDropped = subscriptionDropped || function() {};
  this._verboseLogging = verboseLogging;
  this._getConnection = getConnection;

  this._correlationId = null;
  this._unsubscribed = false;
  this._subscription = null;
  this._actionExecuting = false;
  this._actionQueue = [];
}
10064
public FireableEventType getEventId(EventLookupFacility eventLookupFacility,
			Response response) {

		String statusCodeName = null;
		final int responseStatus = response.getStatusCode();
		if (responseStatus == 100) {
			statusCodeName = "TRYING";
		} else if (100 < responseStatus && responseStatus < 200) {
			statusCodeName = "PROVISIONAL";
		} else if (responseStatus < 300) {
			statusCodeName = "SUCCESS";
		} else if (responseStatus < 400) {
			statusCodeName = "REDIRECT";
		} else if (responseStatus < 500) {
			statusCodeName = "CLIENT_ERROR";
		} else if (responseStatus < 600) {
			statusCodeName = "SERVER_ERROR";
		} else {
			statusCodeName = "GLOBAL_FAILURE";
		}

		// in dialog responses use the 1.1 event id prefix
		return getEventId(eventLookupFacility, new StringBuilder(RESPONSE_EVENT_PREFIX).append(statusCodeName).toString());
	}
393762
public LogEvent[] getLogEvents() {
        if (mLogEvents == null) {
            return new LogEvent[0];
        }
        else {
            LogEvent[] events = new LogEvent[mLogEvents.size()];
            return (LogEvent[])mLogEvents.toArray(events);
        }
    }
1224475
def get_log(request):
    
    query = d1_gmn.app.models.EventLog.objects.all().order_by('timestamp', 'id')
    if not d1_gmn.app.auth.is_trusted_subject(request):
        query = d1_gmn.app.db_filter.add_access_policy_filter(
            request, query, 'sciobj__id'
        )
        query = d1_gmn.app.db_filter.add_redact_annotation(request, query)
    query = d1_gmn.app.db_filter.add_datetime_filter(
        request, query, 'timestamp', 'fromDate', 'gte'
    )
    query = d1_gmn.app.db_filter.add_datetime_filter(
        request, query, 'timestamp', 'toDate', 'lt'
    )
    query = d1_gmn.app.db_filter.add_string_filter(
        request, query, 'event__event', 'event'
    )
    if d1_gmn.app.views.util.is_v1_api(request):
        query = d1_gmn.app.db_filter.add_string_begins_with_filter(
            request, query, 'sciobj__pid__did', 'pidFilter'
        )
    elif d1_gmn.app.views.util.is_v2_api(request):
        query = d1_gmn.app.db_filter.add_sid_or_string_begins_with_filter(
            request, query, 'sciobj__pid__did', 'idFilter'
        )
    else:
        assert False, 'Unable to determine API version'
    total_int = query.count()
    query, start, count = d1_gmn.app.views.slice.add_slice_filter(
        request, query, total_int
    )
    return {
        'query': query,
        'start': start,
        'count': count,
        'total': total_int,
        'type': 'log',
    }
973883
public LruList<LoggingEvent> getEvents() {
        if (events == null) {
            events = new LruList<LoggingEvent>(LoggingEvent.class, getSize());
        }
        return events;
    }
992604
def LogHttpFrontendAccess(self, request, source=None, message_count=None):
    
    # TODO(user): generate event_id elsewhere and use it for all the log
    # messages that have to do with handling corresponding request.
    event_id = self.GetNewEventId()

    log_msg = "%s-%s [%s]: %s %s %s %s (%d)" % (
        event_id, request.source_ip, source or "<unknown>", request.method,
        request.url, request.user_agent, request.user, message_count or 0)
    logging.info(log_msg)
1251305
public LogEvent decode(LogBuffer buffer, LogContext context) throws IOException {
        final int limit = buffer.limit();

        if (limit >= FormatDescriptionLogEvent.LOG_EVENT_HEADER_LEN) {
            LogHeader header = new LogHeader(buffer, context.getFormatDescription());

            final int len = header.getEventLen();
            if (limit >= len) {
                LogEvent event;

                /* Checking binary-log's header */
                if (handleSet.get(header.getType())) {
                    buffer.limit(len);
                    try {
                        /* Decoding binary-log to event */
                        event = decode(buffer, header, context);
                    } catch (IOException e) {
                        if (logger.isWarnEnabled()) {
                            logger.warn("Decoding " + LogEvent.getTypeName(header.getType()) + " failed from: "
                                        + context.getLogPosition(), e);
                        }
                        throw e;
                    } finally {
                        buffer.limit(limit); /* Restore limit */
                    }
                } else {
                    /* Ignore unsupported binary-log. */
                    event = new UnknownLogEvent(header);
                }

                if (event != null) {
                    // set logFileName
                    event.getHeader().setLogFileName(context.getLogPosition().getFileName());
                    event.setSemival(buffer.semival);
                }

                /* consume this binary-log. */
                buffer.consume(len);
                return event;
            }
        }

        /* Rewind buffer's position to 0. */
        buffer.rewind();
        return null;
    }
1102924
private String getEventLogName(String subject, String id) {
    return String.format("%s-%s", subject, id);
  }
460782
public Long createEventLog(String pEventName, String pEventCategory, String pEventSubCat, String pEventSource,
        String pEventOwner, Long pEventOwnerId, String user, String modUser, String comments)
    throws DataAccessException, EventException {
        TransactionWrapper transaction = null;
        EngineDataAccessDB edao = new EngineDataAccessDB();
        try {
            transaction = edao.startTransaction();
            Long id = edao.recordEventLog(pEventName, pEventCategory, pEventSubCat,
                    pEventSource, pEventOwner, pEventOwnerId, user, modUser, comments);
            return id;
        } catch (SQLException e) {
            edao.rollbackTransaction(transaction);
            throw new EventException("Failed to create event log", e);
        } finally {
            edao.stopTransaction(transaction);
        }
    }
191423
@Nullable
    public static ClientConnectionTimings get(RequestLog log) {
        requireNonNull(log, "log");
        if (log.hasAttr(TIMINGS)) {
            return log.attr(TIMINGS).get();
        }
        return null;
    }
1225263
def get_log_events(self, login=None, **kwargs):
        

        _login = kwargs.get(
            'login',
            login
        )
        log_events_url = GSA_EVENTS_URL.format(login=_login)
        return self._request_api(url=log_events_url).json()