awslabs / awslabs/aws-lambda-cpp

Lambda return types through HTTP API Gateway - only json array or json object are working , else error 500

オープン
#118 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
C++
スター
465
フォーク
98
平均マージ
12時間 47分
マージ済み PR(30日)
3

説明

I'd like to return binary data through the HTTP API Gateway (HTTP , NOT REST API!), but the response has to be a json object, always. Is there some workaround to make that happen like it is possible for the REST API ?

```
#include
using namespace aws::lambda_runtime;
static invocation_response my_handler(invocation_request const& req)
{
return invocation_response::success("binarygoeshere", "application/zip");
}

int main()
{
run_handler(my_handler);
return 0;
}
```
^this returns error code 500

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。