Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/4ov/dena
A promise based Deta http api wrapper for deno.
https://github.com/4ov/dena
deno deta typescript
Last synced: about 2 months ago
JSON representation
A promise based Deta http api wrapper for deno.
- Host: GitHub
- URL: https://github.com/4ov/dena
- Owner: 4ov
- Created: 2020-10-10T10:29:46.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2022-07-22T14:29:54.000Z (over 2 years ago)
- Last Synced: 2024-10-16T19:16:01.830Z (3 months ago)
- Topics: deno, deta, typescript
- Language: TypeScript
- Homepage:
- Size: 46.9 KB
- Stars: 13
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-deta - Dena - A library for intracting with deta API from deno. (SDK's / JavaScript SDK)
README
# Dena
>A library for intracting with [deta](https://deta.sh) API from deno
## Getting started
```js
import Dena from 'https://deno.land/x/[email protected]/mod.ts'
const dena = new Dena("API_KEY", "PROJECT_ID")
const users = dena.Base("users")
const photos = dena.Drive("photos")
await users.insert({
key : "KEY", // optional
username : "mustafa"
})
photos.put("me.png", {
data : new Uint8Array([0]), //Uint8Array
//OR
path : "./path-to-me.png"
})
```
## Supported methods
### Base
- [x] put `Base.put`
- [x] get `Base.get`
- [x] delete `Base.delete`
- [x] insert `Base.insert`
- [x] update `Base.update`
- [x] query `Base.query`
### Drive
- [x] put `Drive.put`
- [ ] Initialize Chunked Upload
- [ ] Upload Chunked Part
- [ ] End Chunked Upload
- [ ] Abort Chunked Upload
- [x] Download File `Drive.get`
- [x] List Files `Drive.list`
- [x] Delete Files `Drive.delete`