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

v2 routes - draft #865

Open
arxdsilva opened this issue Jan 2, 2024 Discussed in #854 · 0 comments
Open

v2 routes - draft #865

arxdsilva opened this issue Jan 2, 2024 Discussed in #854 · 0 comments

Comments

@arxdsilva
Copy link
Member

Discussed in #854

Originally posted by arxdsilva December 21, 2023

Current routes

image

problems

  1. no URL versioning (unclear on which version it was released)
  2. When using it as a framework, any route with /a/b will be sent to /{database}/{schema}, same happens with CRUD routes

proposal

  1. add versioning to URL, such as: /v2/query/view/{db}/{schema}/{view}, /v2.2/query/_QUERIES/{location}/{script}
  2. separate URLs by query domain, such as: views, query, plugin, and custom, and place them in the path structures

New routes:

Endpoint operation
/v2/_health healthcheck
/v2/db/{database}/auth db-specific authentication
/v2/views/databases available dbs in the db server
/v2/views/schemas available schemas in the db server
/v2/views/tables available tables in the db server
/v2/views/{db}/{schema} get schema struct
/v2.1/views/{db}/{schema}/{table} get table struct
/v2.3/plugin/{file}/{func} execute plugin
/v2/custom/{location}/{script} CRUD ops on script
/v2.5/query/{db}/{schema}/{table} CRUD operations
/v2/query/batch/{db}/{schema}/{table} POST with batch insert
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant