# aws cognito
Create a python script that perform the following tasks
create a new user pool on aws cognito
create two groups in the user pool: 1. users, 2. admins
create a user named ‘alice’ assigned to the users group
create a user named ‘bob’ assigned to the admins group
## cloud formation
Create a cloud formation script that define:
api gateway that with 3 resources:
Each resource will define a HTTP proxy with passthrough configuration to each of the provided endpoints.
the /public will be accessible to anyone
the /user will be accessible only to users that authenticated with the users group or the admin group
the /admin will be accessible only to users authenticated with the admins group
a web server that allows to enter a username and password authenticate with the userpool
3 buttons that perform GET request to each of the 3 endpoints and display the response.
## Endpoint server
Create a web server with 3 endpoints http://example.com/public http://example.com/user http://example.com/admin
The response from each endpoint will contain the username and group that associated with the user that invoked the request.
If the user is not authenticated the username will be “anonymous” and no group will be associated with theat user. (only /public endpoint will allow “anonymous” user invocation)
The endpoint server backend will be implemented in python 3.6 enviroment.
the authentication must occur by aws API Gateway.
The deliverable should be a aws cloud formation script
## Approve design
Send a design of the proposed solution.
It should include the units that will be implemented to achieve the goal.
Which Amazon services are to be integrated.
Which external libraries are to be used.
Which design choices were made
It should include a sketch of the system (i.e what components will be used, how they will interact)
It should highlight suggested deviation from requested approach,
A list of boundary conditions that the system is expect
## Approve tests
The test will be delivered as code written in Python node.js is also allowed
The test will call a stub (skeleton) code that will not yet call the lambda system api and therefore will fail.
The tests must include all the boundary condition that the system may encounter.
The tests will verify the system work as expected - that different path get directed correctly
The skeleton code should be completed and all tests must pass.
The test should work on a clean system without any preconfiguration.
The code will setup the server with the endpoints
The code will setup the server that calls the endpoints
The code will call the cloud formation script that will construct:
aws cognito user pool
aws cognito groups
aws cognito users
aws api gateway authorizer
aws api gateway deployment.
This job was posted from a mobile device, so please pardon any typos or any missing details.
February 24, 2018
I am looking for a mix of experience and value