{"id":15965682,"url":"https://github.com/swinton/guestbook","last_synced_at":"2026-02-04T13:39:39.443Z","repository":{"id":52301133,"uuid":"110641343","full_name":"swinton/guestbook","owner":"swinton","description":"A serverless guestbook","archived":false,"fork":false,"pushed_at":"2022-12-08T06:55:22.000Z","size":34,"stargazers_count":2,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-13T17:52:48.531Z","etag":null,"topics":["aws-dynamodb","aws-lambda","aws-lambda-python","serverless"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/swinton.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-11-14T04:40:39.000Z","updated_at":"2023-03-09T00:38:27.000Z","dependencies_parsed_at":"2023-01-24T20:45:39.001Z","dependency_job_id":null,"html_url":"https://github.com/swinton/guestbook","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swinton%2Fguestbook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swinton%2Fguestbook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swinton%2Fguestbook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swinton%2Fguestbook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/swinton","download_url":"https://codeload.github.com/swinton/guestbook/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247675599,"owners_count":20977378,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aws-dynamodb","aws-lambda","aws-lambda-python","serverless"],"created_at":"2024-10-07T18:00:22.112Z","updated_at":"2026-02-04T13:39:39.414Z","avatar_url":"https://github.com/swinton.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `guestbook`\n\nA _serverless_ guestbook using AWS Lambda.\n\n## Installation\n\n1. Sign up for AWS Lambda\n1. Install and configure the `aws` command-line client\n1. Run `script/bootstrap`\n\n### Sign up for AWS Lambda\n\nSign up for AWS [**here**](https://aws.amazon.com/).\n\nThe Lambda free tier includes 1M free requests per month and 400,000 GB-seconds of compute time per month.\n\n### Install and configure the `aws` command-line client\n\nTo install the `aws` command-line client use `pip`:\n\n```\npip install awscli --upgrade --user\n```\n\nTo configure `aws`, follow these [**quick configuration steps**](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html#cli-quick-configuration).\n\nOnce configured, you should see `config` and `credentials` files in `~/.aws`.\n\n### Run `script/bootstrap`\n\n```bash\nscript/bootstrap\nscript/pack_lambda .\nscript/push_lambda guestbook_add package.zip\nscript/push_lambda guestbook_list package.zip\nscript/push_lambda message_add package.zip\nscript/push_lambda messages_received_list package.zip\nscript/push_lambda messages_sent_list package.zip\n```\n\nThis will:\n\n1. Ensure the Lambda function role is created, with the correct policy attached\n1. Create the DynamoDB table\n1. Package the Lambda function and all its dependencies\n1. Create the Lambda functions, `guestbook_add`, `guestbook_list`, `message_add`, `messages_received_list`, and `messages_sent_list` on AWS\n\n## Usage\n\nUse the `script/exec_lambda` script.\n\n### Guestbook\n\nE.g. to create an entry in the guestbook:\n\n```bash\n# Create an entry in the guestbook\nscript/exec_lambda guestbook_add '{\"name\":\"Florian\", \"message\":\"I program my home computer, beam myself into the future\"}'\n```\n\nAnd to list today's guestbook entries:\n\n```bash\n# List today's guestbook entries\nscript/exec_lambda guestbook_list\n```\n\n### Messages\n\nTo send a message:\n\n```bash\nscript/exec_lambda message_add '{\"toId\": 2993937, \"to\": \"imjohnbo\", \"fromId\": 27806, \"from\": \"swinton\", \"message\": \"Hello, John, how are you?\"}'\n```\n\nTo list the 50 most recently received messages:\n\n```bash\nscript/exec_lambda messages_received_list '{\"toId\": 2993937}'\n```\n\nTo list the 50 most recently sent messages:\n\n```bash\nscript/exec_lambda messages_sent_list '{\"fromId\": 27806}'\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswinton%2Fguestbook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fswinton%2Fguestbook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswinton%2Fguestbook/lists"}