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

Use orb-billing SDK #11

Merged
merged 8 commits into from
Jul 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/extension_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
- name: Cargo format
run: cargo +nightly fmt --all --check
- name: Clippy
run: cargo clippy
run: cargo clippy -- -Dwarnings

# figure out how to test work
# test:
Expand Down Expand Up @@ -83,7 +83,7 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
pg: [14, 15, 16]
pg: [ 14, 15, 16 ]
steps:
- uses: actions/checkout@v4
- name: Install Rust stable toolchain
Expand Down
119 changes: 9 additions & 110 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 4 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "orb_fdw"
version = "0.12.0"
version = "0.12.1"
edition = "2021"
publish = false

Expand All @@ -15,20 +15,16 @@ pg16 = ["pgrx/pg16", "pgrx-tests/pg16", "supabase-wrappers/pg16"]
pg_test = []

[dependencies]
reqwest-retry = "0.2.2"
pgrx = "=0.11.3"
orb-billing = "0.9.0"
orb-billing = "0.11.0"
# supabase-wrappers = "=0.1.18"
supabase-wrappers = { git = "https://github.com/supabase/wrappers.git", default-features = false, rev = "99242d70eb7e551b700e2db31cc618850d835bc2" }
tokio = { version = "1", features = ["full"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
futures = "0.3.28"
thiserror = "1.0.48"
http = "0.2.4"
reqwest = { version = "0.11.4", features = ["json"] }
futures = "0.3.28"
reqwest-middleware = "0.2.4"
url = "2.2.2"
reqwest = { version = "0.11.4", features = ["json"] }

[dev-dependencies]
pgrx-tests = "=0.11.3"
Expand Down
18 changes: 11 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## Orb_fdw

This is a simple open-source data wrapper that bridges the gap between your Postgres database and [Orb](https://www.withorb.com/) a leading usage-based billing solution.
This is a simple open-source data wrapper that bridges the gap between your Postgres database
and [Orb](https://www.withorb.com/) a leading usage-based billing solution.

[![Tembo Cloud Try Free](https://tembo.io/tryFreeButton.svg)](https://cloud.tembo.io/sign-up)

Expand All @@ -9,7 +10,7 @@ This is a simple open-source data wrapper that bridges the gap between your Post

### Pre-requisistes

- have the v0.12.0 of `orb_fdw` extension enabled in your instance
- have the v0.12.1 of `orb_fdw` extension enabled in your instance

Create the foreign data wrapper:

Expand Down Expand Up @@ -41,7 +42,8 @@ create foreign table orb_customers (
first_name text,
email text,
stripe_id text,
created_at text
created_at timestamp,
attrs jsonb
)
server my_orb_server
options (
Expand All @@ -59,8 +61,9 @@ create foreign table orb_subscriptions (
organization_id text,
status text,
plan text,
started_date text,
end_date text
started_date timestamp,
end_date timestamp,
attrs jsonb
)
server my_orb_server
options (
Expand All @@ -78,8 +81,9 @@ create foreign table orb_invoices (
subscription_id text,
organization_id text,
status text,
due_date text,
amount text
due_date timestamp,
amount text,
attrs jsonb
)
server my_orb_server
options (
Expand Down
2 changes: 1 addition & 1 deletion Trunk.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description = "Postgres Foreign Data Wrapper for withorb.com Backend API"
homepage = "https://github.com/tembo-io/orb_fdw"
documentation = "https://github.com/tembo-io/orb_fdw"
categories = ["connectors"]
version = "0.12.0"
version = "0.12.1"

[build]
postgres_version = "15"
Expand Down
File renamed without changes.
Empty file added sql/orb_fdw--0.11.3--0.12.0.sql
Empty file.
Empty file added sql/orb_fdw--0.12.0--0.12.1.sql
Empty file.
Loading
Loading