{"id":21897843,"url":"https://github.com/luvies/urlshortener","last_synced_at":"2026-04-09T23:39:09.670Z","repository":{"id":96648073,"uuid":"163780267","full_name":"luvies/UrlShortener","owner":"luvies","description":"A simple serverless URL shortener app","archived":false,"fork":false,"pushed_at":"2019-01-04T16:11:24.000Z","size":65,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-07T06:36:19.660Z","etag":null,"topics":["aws","aws-lambda","dotnet","dotnet-core","serverless","url","url-shortener"],"latest_commit_sha":null,"homepage":null,"language":"C#","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/luvies.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-01-02T01:29:25.000Z","updated_at":"2019-01-04T16:11:25.000Z","dependencies_parsed_at":"2023-03-26T02:18:13.097Z","dependency_job_id":null,"html_url":"https://github.com/luvies/UrlShortener","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/luvies/UrlShortener","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luvies%2FUrlShortener","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luvies%2FUrlShortener/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luvies%2FUrlShortener/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luvies%2FUrlShortener/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/luvies","download_url":"https://codeload.github.com/luvies/UrlShortener/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luvies%2FUrlShortener/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278909700,"owners_count":26066887,"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","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","aws-lambda","dotnet","dotnet-core","serverless","url","url-shortener"],"created_at":"2024-11-28T14:20:01.510Z","updated_at":"2025-10-08T07:35:31.613Z","avatar_url":"https://github.com/luvies.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Serverless URL Shortener\nThis project provides an easy-to-set-up serverless URL shortener that can be run for little-to-no cost.\n\n## Serverless\n\"Does serverless mean something beyond a good buzzword?\"\n\nYes. Thanks to what AWS provides, serverless means that:\n\n- If you have the AWS CLI set up (and AWS Serverless dotnet tool installed), deployment is ridiculously easy\n  - This includes every single thing that the app requires\n  - You can essentially set up a single config file, run a command, and have the whole app working\n- It will cost about $0.01 a month to run with a medium-low trafficked site\n  - Only S3 will cost something, since it has a minimum of 1 cent when hosting things\n    - This only applies if you leave the deployment artefacts in S3 (these can be removed after deployment)\n  - Both Lambda and DynamoDB (the only main dependencies of the app) have permanent free tiers\n\n# Setup\nTo deploy this app, follow these steps:\n\n## AWS CLI\nEnsure you have the AWS CLI set up and working properly. You can test your config with `aws sts get-caller-identity`.\n\n## AWS Lambda dotnet Tool\nYou will need to have the AWS Lambda tool installed (and by extension, the .NET Core 2.1 sdk), which can be done by `dotnet tool install -g Amazon.Lambda.Tools`.\n\n## Config\nYou will need to define a config file at `scripts/.env.local`. This will contain all of the config you need to deploy the app. It looks something like this:\n\n```conf\nSERVERLESS_NAME=MyUrlShortener\nS3_BUCKET=my-url-shortener-build\nAUTH_KEY=secure-auth-key\nCURRENT_ORIGIN=https://myshortener.com\n```\n\n- `SERVERLESS_NAME`\n  - This is the name of the app used by AWS CloudFormation\n  - In order to ensure that you don't redeploy the app multiple times, set this once and *never* change it\n- `S3_BUCKET`\n  - This is the bucket the build result is set to for use by CloudFormation when deploying\n  - It has to exist already, but the default config works fine\n- `AUTH_KEY`\n  - This is the authentication key that will be used to log into the admin console\n  - To make this secure, make it a long \u0026 complex enough\n  - If you think someone has gained access to it, you will have to edit the lambda directly and change the key\n    - CloudFormation doesn't yet support updating environment variables\n  - If empty, then the admin console won't let anyone sign in at all\n    - You can use this behaviour to disable logging in completely\n- `CURRENT_ORIGIN`\n  - This is the origin to use when displaying the short URLs in the admin console\n  - Purely a graphical option, doesn't change behaviour\n\n## Deployment\nIf you have set up all the other parts correctly, you can just call `scripts/build.sh deploy` and CloudFormation will deploy the app to AWS, along with all its dependencies.\n\n### Custom URL\nYou can set up a custom URL like normal in the AWS API Gateway console. \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluvies%2Furlshortener","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fluvies%2Furlshortener","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluvies%2Furlshortener/lists"}