Custom Authorizer $LATEST Version

I am able to make custom authorizers like this:

        arn: ${cf:deploy-authorizer-${self:provider.stage}.AuthorizeLambdaFunctionQualifiedArn}
        name: ${cf:deploy-authorizer-${self:provider.stage}.AuthorizerName}
        type: ${cf:deploy-authorizer-${self:provider.stage}.AuthorizerType}
        identitySource: ${cf:deploy-authorizer-${self:provider.stage}.AuthorizerIdentitySource}

But when I do that, AWS puts a version number on the end of the name. This locks the authorizer to THAT version of the lambda, any future updates to the authorizer are NOT passed on to the lambda’s that use it.

I am able to manually add the wildcard $LATEST to the end of the custom authorizer name in API GATEWAY, which will update to the latest version of the custom authorizer, but is there a way to indicated I want the latest version in the severless.yml?

I have tried,

arn: ${cf:deploy-authorizer-${self:provider.stage}.AuthorizeLambdaFunctionQualifiedArn}:$LATEST


arn: ${cf:deploy-authorizer-${self:provider.stage}.AuthorizeLambdaFunctionQualifiedArn:$LATEST}

neither seems to work…


Any update on this topic ? Did you find a workaround to use the $LATEST version of it ?

You don’t want the version at all. AuthorizeLambdaFunctionQualifiedArn already contains the version so adding $LATEST won’t work.

Surely you know the name of your lambda function? Given that, this pseudo works: