Skip to main content

A low-code data application framework that uses dbt Core and OpenAPI

Project description

Jinjat

Develop data applications with dbt, SQL, and OpenAPI

Installation

pip install jinjat

Create your first API

Create an analysis in analysis/my_first_api.sql:

{%- set query = request().query %}

select '{{query.example}}' as col1

And create a YML file in analysis/schema.yml:

version: 2

analyses:
  - name: my_first_api
    config:
      jinjat:
        method: get
        openapi:
          parameters:
            - in: query
              name: example
              schema:
                type: number

Start Jinjat as follows:

jinjat serve --project-dir [YOUR_DBT_PROJECT_DIRECTORY]

And then run the following CURL command to test the API:

curl -XGET 'http://127.0.0.1:8581?example=value'

It should return the following response:

[
  "col1": "3"
]

Jinjat uses OpenAPI to validate the requests and create an API documentation automatically for your API.

Integrations

poetry install --extras "duckdb"

Playground

poetry install --extras "playground"

Installation

pip install jinjat[playground]

Jinjat Playground is a Streamlit app that lets you develop APIs in your browser. Once you write the template, you can save it to your dbt project as an analysis and expose the API.

Refine.dev Integration

Installation

pip install jinjat[refine]

Jinjat Refine integration creates a Refine app from your OpenAPI spec

Jinjat is a fork of dbt-osmosis

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jinjat-0.3.tar.gz (33.7 kB view details)

Uploaded Source

Built Distribution

jinjat-0.3-py3-none-any.whl (38.8 kB view details)

Uploaded Python 3

File details

Details for the file jinjat-0.3.tar.gz.

File metadata

  • Download URL: jinjat-0.3.tar.gz
  • Upload date:
  • Size: 33.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.3

File hashes

Hashes for jinjat-0.3.tar.gz
Algorithm Hash digest
SHA256 2dd8b75dbf2ecd98c80712f21cf52b34fbba745411a4628f0f7214381b345ba0
MD5 7135aa8b4490c8086dd149a26bd5b4be
BLAKE2b-256 a4120dc0cfc51277924cfe23f3e523a211d9cf105b0f4cec3eb587ac778adbfe

See more details on using hashes here.

File details

Details for the file jinjat-0.3-py3-none-any.whl.

File metadata

  • Download URL: jinjat-0.3-py3-none-any.whl
  • Upload date:
  • Size: 38.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.3

File hashes

Hashes for jinjat-0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 281a849334f9a96029e2d83b0ade8173353b1e65a91cc395bd6c70a9ad9a52bd
MD5 47b14ddaf584b92468805bd2c1d617a2
BLAKE2b-256 24d76dc2f8d291ae8f73ac24d50dd9c594ad160a8342d812dc3abd3939a9b6b3

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page