{"id":24792989,"url":"https://github.com/adityaoberai/url-shortener-appwrite","last_synced_at":"2026-04-20T10:03:45.175Z","repository":{"id":274706669,"uuid":"923813411","full_name":"adityaoberai/url-shortener-appwrite","owner":"adityaoberai","description":"A free-to-use, self-hostable URL shortener, made entirely with Appwrite","archived":false,"fork":false,"pushed_at":"2025-01-30T11:19:59.000Z","size":27,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-18T21:39:27.791Z","etag":null,"topics":["appwrite","appwrite-database","appwrite-function","css","html","nodejs","url-shortener"],"latest_commit_sha":null,"homepage":"https://67994c1ba299ca0c4bcd.appwrite.global/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/adityaoberai.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":"2025-01-28T21:35:21.000Z","updated_at":"2025-01-30T11:20:02.000Z","dependencies_parsed_at":"2025-01-29T15:20:17.788Z","dependency_job_id":"27a504d9-bc25-4c82-988f-cc172257a2f6","html_url":"https://github.com/adityaoberai/url-shortener-appwrite","commit_stats":null,"previous_names":["adityaoberai/github-edu-appwrite-stream-demo","adityaoberai/url-shortener-appwrite"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/adityaoberai/url-shortener-appwrite","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adityaoberai%2Furl-shortener-appwrite","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adityaoberai%2Furl-shortener-appwrite/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adityaoberai%2Furl-shortener-appwrite/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adityaoberai%2Furl-shortener-appwrite/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/adityaoberai","download_url":"https://codeload.github.com/adityaoberai/url-shortener-appwrite/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adityaoberai%2Furl-shortener-appwrite/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32042294,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T00:18:06.643Z","status":"online","status_checked_at":"2026-04-20T02:00:06.527Z","response_time":94,"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":["appwrite","appwrite-database","appwrite-function","css","html","nodejs","url-shortener"],"created_at":"2025-01-29T21:39:23.624Z","updated_at":"2026-04-20T10:03:45.156Z","avatar_url":"https://github.com/adityaoberai.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# URL Shortener\n\nA URL shortener app that offers a landing page, creation of short links, listing of all store URLs, and copy and delete actions for all short URLs.\n\n## 🧰 Usage\n\n### GET `/`\n\n- Returns an HTML landing page as a static file.\n\n### GET `/styles`\n\n- Returns an CSS file for the HTML landing page as a static file.\n\n### GET `/:shortCode`\n\n- Redirects to the full URL affiliated with the short code.\n\n### GET `/listUrls`\n\n- Gets list of all stored URLs and short codes.\n\n**Response**\n\nSample `200` Response:\n\n```json\n{\n  \"ok\": true,\n  \"data\": [\n    {\n      \"url\": \"https://appwrite.io\",\n      \"$id\": \"appwrite\"\n    },\n    {\n      \"url\": \"https://twitter.com/adityaoberai1\",\n      \"$id\": \"twitter\"\n    },\n    {\n      \"url\": \"https://appwrite.io/education\",\n      \"$id\": \"edu\"\n    }\n  ]\n}\n```\n\n### POST `/`\n\n- Add URL and short code (as the document ID) to the database.\n\n**Request**\n\n```json\n{\n  \"short\": \"appwrite\",\n  \"url\": \"https://appwrite.io\" \n}\n```\n\n**Response**\n\nSample `200` Response:\n\n```json\n{\n  \"ok\": true,\n  \"data\": {\n    \"short\": \"appwrite\",\n    \"url\": \"https://appwrite.io\"\n  }\n}\n```\n\n### DELETE `/:shortCode`\n\n- Deletes the short code and affiliated full URL from the database.\n\n**Response**\n\nSample `200` Response:\n\n```json\n{\n  \"ok\": true\n}\n```\n\n## ⚙️ Configuration\n\n| Setting           | Value         |\n| ----------------- | ------------- |\n| Runtime           | Node (22.0)   |\n| Entrypoint        | `src/main.js` |\n| Function path     | `functions/url-shortener` |\n| Build Commands    | `npm install` |\n| Permissions       | `any`         |\n| Timeout (Seconds) | 15            |\n| Specifiation      | s-1vcpu-512mb |\n| Scopes            | `databases.write`, `databases.read`, `collections.write`,  `collections.read`, `attributes.write`, `documents.write`, `documents.read` |\n\n## 🔒 Environment Variables\n\nNo environment variables required mandatorily. There are two **optional** environment variables, however:\n\n- `APPWRITE_DB_ID`: ID of Appwrite Database which will contain collection of short codes and URLs\n- `APPWRITE_COLLECTION_ID`: ID of Appwrite Collection which will contain short codes and URLs\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadityaoberai%2Furl-shortener-appwrite","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadityaoberai%2Furl-shortener-appwrite","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadityaoberai%2Furl-shortener-appwrite/lists"}