code: function configureEventAwsContextAndStage(context, event, awsContext) {
    // Configure context.event with the given AWS event
    if (event) {
      context.event = event;
    }
  
    // Configure context.awsContext with the given AWS context
    if (awsContext) {
      context.awsContext = awsContext;
  
      // Resolve the invoked Lambda's function name, version & alias (if possible)
      context.invokedLambda = lambdas.getFunctionNameVersionAndAlias(awsContext);
    }
  
    // Resolve the current stage (e.g. dev, qa, prod, ...) if possible and configure context.stage with it, if it is not
    // already configured
    if (event && awsContext) {
      stages.configureStage(context, event, awsContext, true);
    }
  
    return context;
  }
docs: Configures the given context with the given event, given AWS context and the resolved stage. In order to resolve the
  stage, stage handling settings and logging must already be configured on the given context (see {@linkcode
  stages#configureStageHandling} for details).
  @param {StandardContext|StageHandling} context - the context to configure
  @param {AWSEvent} event - the AWS event, which was passed to your lambda
  @param {AWSContext} awsContext - the AWS context, which was passed to your lambda
  @return {StandardContext|EventAWSContextAndStageAware} the given context configured with the given AWS event, AWS context & resolved stage
  @throws {Error} if the resolved stage is blank