{"id":15780270,"url":"https://github.com/luismeyer/duenamodb","last_synced_at":"2025-09-19T00:16:14.714Z","repository":{"id":57698285,"uuid":"461178577","full_name":"luismeyer/duenamodb","owner":"luismeyer","description":"Simple DynamoDB client","archived":false,"fork":false,"pushed_at":"2024-02-02T12:08:38.000Z","size":181,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-10-04T18:41:35.854Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/luismeyer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2022-02-19T12:00:30.000Z","updated_at":"2022-02-19T12:00:54.000Z","dependencies_parsed_at":"2024-02-02T12:47:16.985Z","dependency_job_id":null,"html_url":"https://github.com/luismeyer/duenamodb","commit_stats":{"total_commits":49,"total_committers":2,"mean_commits":24.5,"dds":"0.10204081632653061","last_synced_commit":"6765aff2dd5dac9f81cc6d3bd60759234facf185"},"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/luismeyer/duenamodb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luismeyer%2Fduenamodb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luismeyer%2Fduenamodb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luismeyer%2Fduenamodb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luismeyer%2Fduenamodb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/luismeyer","download_url":"https://codeload.github.com/luismeyer/duenamodb/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/luismeyer%2Fduenamodb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":275857342,"owners_count":25541033,"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-09-18T02:00:09.552Z","response_time":77,"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":[],"created_at":"2024-10-04T18:41:04.458Z","updated_at":"2025-09-19T00:16:14.620Z","avatar_url":"https://github.com/luismeyer.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# dÜnamodb 📀\n\nSimple DynamoDB client written in TypeScript.\n\n## Setup 🛠\n\nInstall the package\n\n```bash\npnpm install duenamodb\n```\n\n```bash\nnpm install duenamodb\n```\n\nIf not running in AWS Lambda configure the Client using the static accessor on the DDBClient class.\n\n```ts\nDDBClient.params = {\n  region: 'localhost',\n  endpoint: `http://localhost:8000`,\n};\n```\n\nAlso you might need to provide mock AWS credentials inside the environment variables.\n\n## API 📄\n\nThe API of dÜnamodb is straight forward. There is a create Function for every DynamoDB action.\n\n### Create the Functions 🏗\n\nTo interact with your DynamoDB use the create-functions from the dÜnamodb lib\n\nPut item:\n\n```ts\nconst putItem = createPutItem\u003cAttributes\u003e(tableName);\n```\n\nGet item:\n\n```ts\nconst getItem = createGetItem\u003cAttributes, string\u003e(tableName, partitionKeyName);\n```\n\nUpdate item:\n\n```ts\nconst updateItem = createUpdateItem\u003cAttributes\u003e(tableName);\n```\n\nScan items:\n\n```ts\nconst scanItems = createScanItems\u003cAttributes\u003e(tableName);\n```\n\nQuery items:\n\n```ts\nconst queryItems = createQueryItems\u003cAttributes, number\u003e(tableName, {\n  name,\n  partitionKeyName,\n});\n```\n\nDelete item:\n\n```ts\nconst deleteItem = createDeleteItem\u003cAttributes, string\u003e(\n  tablename,\n  partitionKeyName\n);\n```\n\n### Utilites\n\nThere is also a utility function that creates the scan, put, update, get and delete function.\n\n```ts\nconst { getItem, scanItems, updateItem } = createTableFunctions\u003c\n  Attributes,\n  string\n\u003e(tablename, partitionKeyName);\n```\n\n### Use the Functions 👷‍♀️\n\nUse the functions to read and write data from the DB\n\nPut item:\n\n```ts\nawait saveItem({ id: \"1\", name: \"foo\", ... });\n```\n\nGet item:\n\n```ts\nconst getResult = await getItem('1');\n```\n\nUpdate item:\n\n```ts\nconst updateResult = await updateItem(\n  { ...item, name: 'bar' },\n  { updateKeys: ['name'] }\n);\n```\n\nScan items:\n\n```ts\nconst scanResult = await scanItems();\n```\n\nQuery items:\n\n```ts\nconst queryResult = await queryItems('foo');\n```\n\nDelete item:\n\n```ts\nconst success = await deleteItem('1');\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluismeyer%2Fduenamodb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fluismeyer%2Fduenamodb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluismeyer%2Fduenamodb/lists"}