This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getCognitoCreds() { | |
console.log("starting function getCognitoCreds"); | |
var cognitoUser = cognitoFactory.getCognitoUser(); | |
cognitoUser.getSession(function(err, session) { | |
if (err) { | |
console.log(err, err.stack); | |
console.log("error getting the session"); | |
} else { | |
if (session.isValid() === false) { | |
console.log("session is not valid"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ContactUsFormApi: | |
Properties: | |
Body: | |
basePath: /dksheffield/ContactUsForm/1.0.0 | |
host: virtserver.swaggerhub.com | |
info: | |
contact: | |
email: jeremiah.sheffield@gmail.com | |
description: Contact Us API | |
license: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ContactUsFormApi: | |
Type: "AWS::ApiGateway::RestApi" | |
Properties: | |
Description: "A test API" | |
Name: | |
Ref: AWS::StackName | |
Body: | |
swagger: '2.0' | |
info: | |
description: Contact Us API |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ContactUsFormApi: | |
Type: "AWS::Serverless::Api" | |
Properties: | |
StageName: prod | |
DefinitionBody: | |
swagger: '2.0' | |
info: | |
description: Contact Us API | |
version: 1.0.0 | |
title: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log('Loading function'); | |
var Promise = require('promise'); | |
doPromiseOne() | |
.then(doPromiseTwo) | |
.then(doPromiseThree); | |
function doPromiseOne() { |