繁体   English   中英

AWS API 网关 Lambda 授权方REQUEST类型没有methodArn?

[英]AWS API Gateway Lambda authorizer REQUEST type does not have methodArn?

使用 C# 编写自定义 API 网关 Lambda 授权方,并使用REQUEST授权方(非 TOKEN)编写 Im。 查看他们的文档,我应该有一个名为methodArn的可用参数,但查看 class APIGatewayProxyRequest它没有从他们的 SDK 中列出。

这是用于我的 lambda 授权方的正确输入参数吗?

namespace Amazon.Lambda.APIGatewayEvents
{
    public class APIGatewayProxyRequest
    {
        public APIGatewayProxyRequest();

        public string Resource { get; set; }
        public string Path { get; set; }
        public string HttpMethod { get; set; }
        public IDictionary<string, string> Headers { get; set; }
        public IDictionary<string, IList<string>> MultiValueHeaders { get; set; }
        public IDictionary<string, string> QueryStringParameters { get; set; }
        public IDictionary<string, IList<string>> MultiValueQueryStringParameters { get; set; }
        public IDictionary<string, string> PathParameters { get; set; }
        public IDictionary<string, string> StageVariables { get; set; }
        public ProxyRequestContext RequestContext { get; set; }
        public string Body { get; set; }
        public bool IsBase64Encoded { get; set; }

        <...SNIP...>
    }
}

尝试使用APIGatewayCustomAuthorizerRequest而不是APIGatewayProxyRequest

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM