Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wilsonsergio2500/aws-watson-lambda
.NET IBM Watson + Lambda Integration
https://github.com/wilsonsergio2500/aws-watson-lambda
aws-lambda ibm-watson-services lambda netcore2 personality-insights tone-analyzer
Last synced: 9 days ago
JSON representation
.NET IBM Watson + Lambda Integration
- Host: GitHub
- URL: https://github.com/wilsonsergio2500/aws-watson-lambda
- Owner: wilsonsergio2500
- Created: 2018-04-05T15:41:27.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-04-05T19:27:47.000Z (over 6 years ago)
- Last Synced: 2024-11-05T16:13:08.843Z (about 2 months ago)
- Topics: aws-lambda, ibm-watson-services, lambda, netcore2, personality-insights, tone-analyzer
- Language: C#
- Size: 78.1 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# aws-watson-lambda
.NET IBM Watson + Lambda Integration## About
###### Ready to go .net core 2 lambda application for IBM Watson. Currently supporting two main services - Personal Insights, and Tone Analyzer.## Getting Started
###### Install .NET AWS Toolkit
###### Request API access @ https://console.bluemix.net and generate proper credentials for Personal Insights and Tone Analyzer APIs
###### When deploying the lambda ensure to enter the obtained API credentials, as such:![install-lambda](https://user-images.githubusercontent.com/2171533/38385962-e4d90c9e-38d8-11e8-974f-bd1d7805fbe7.PNG)
###### Create AWS API Gateway to target your created Lamba Functions.
###### In the method of the API Gateway -> Go To Integration Request -> Body Mapping Templates
###### Add content type "application/json"
###### If the method is "GET" add the following template
```
{"method": "$context.httpMethod",
"body" : {
#foreach($queryParam in $input.params().querystring.keySet())
"$queryParam": "$util.escapeJavaScript($input.params().querystring.get($queryParam))" #if($foreach.hasNext),#end#end
},"headers": {
#foreach($param in $input.params().header.keySet())
"$param": "$util.escapeJavaScript($input.params().header.get($param))"
#if($foreach.hasNext),#end
#end
}
}
```
###### If the method is "POST" then the following template
```
{"method": "$context.httpMethod",
"body" : $input.json('$'),
"headers": {
#foreach($param in $input.params().header.keySet())
"$param": "$util.escapeJavaScript($input.params().header.get($param))"
#if($foreach.hasNext),#end
#end
}
}
```