Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

D1 API dialect #7

Open
tom-sherman opened this issue Nov 18, 2022 · 7 comments · May be fixed by #12
Open

D1 API dialect #7

tom-sherman opened this issue Nov 18, 2022 · 7 comments · May be fixed by #12

Comments

@tom-sherman
Copy link
Contributor

A D1 API dialect would be cool, it would allow you use kysely in node or deno to work with D1 databases

@tom-sherman
Copy link
Contributor Author

tom-sherman commented Nov 20, 2022

I've created a POC implementation here: https://github.com/tom-sherman/kysely-d1-api

Let me know if you think this is something that could be included in this lib and I'll be happy to clean it up and open a pull request. If not no worries, I can publish it as a complimentary library.

The API is currently undocumented/internal/private, although will be open and stable in the future I'm sure. I think it's worth including in the package and marking as unstable: unstable_D1ApiDialiect or something.

@aidenwallis
Copy link
Owner

I think we can merge this in, can you open a PR and I can check it out then?

@tom-sherman tom-sherman linked a pull request Nov 21, 2022 that will close this issue
1 task
@aidenwallis
Copy link
Owner

Apologies for completely missing the second part of that, if the API is not formally supported by Cloudflare, I don't want to merge it in here and encourage use of APIs that they may not want people using. I'm happy to revisit this when/if they document the API for this!

@tom-sherman
Copy link
Contributor Author

tom-sherman commented Nov 21, 2022

Cloudflare are happy for users to use this API, they even promoted a tool using it in the open alpha blog post. It's just unstable and doesn't have documentation.

Totally get the point about only shopping stable APIs in this library though 👍

@aidenwallis
Copy link
Owner

Yeah, I think we should totally work on adding this FWIW and would like to combine it into this library!

I just don't want to risk shipping a library that breaks for people randomly, lets keep this open and revisit merging the two projects once the API is documented?

@ngraef
Copy link

ngraef commented Apr 30, 2024

Any interest in picking this back up now that the D1 REST API is public, stable, and documented?

@aidenwallis
Copy link
Owner

If someone picks up a PR or submits another, I'm happy to take a look and hopefully merge. To be a little transparent, i don't really use this package at all anymore and have been extremely busy with work, but will try to look at this when I have time. Thank you for bearing with me and sorry for the delays. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants