This solution uses SST, a framework built on top of the AWS CDK.
- Visual Studio Code must be installed (as well as the Vitest extension for unit testing).
- AWS CLI must be installed with a profile configured to use it.
- Clone this repository using the
Code
link at the top of the page. - Open the cloned repository folder in Visual Studio Code.
- Open a terminal to the root folder of the repository, and execute the following:
# Install dependencies
npm install
# Start SST
npm start
- Follow prompts to configure a stage name (
dev
is used below) or accept the default. - After deployment, the terminal will show something similar to the following:
- Open console.sst.dev.
- Navigate to the
API
tab to observe the defined REST endpoints. - Confirm that the
GET
endpoints function as expected
Warning
DELETE
,POST
, andPUT
endpoints are not implemented, so only the organization data provided is currently used.
Returns all employees (including manager).
Returns a single employee for a valid employeeId
parameter.
Returns a tree of directReports
for the employee when the includeReportingTree=true
query parameter is included.
- Navigate to the
Testing
tab in Visual Studio Code. - Click
Run Tests
.
Warning Test failures shown here indicate unimplemented methods.
# Delete all deployed artifacts from AWS
npx sst remove