drc-vantage 2.0
Thin HTTP client for the Vantage platform. Talks only to the Next.js API (VANTAGE_API_URL) with a developer account API key.
Install
pip install drc-vantage
# or
uv add drc-vantage
Configuration
| Variable | Description | Example |
|---|---|---|
VANTAGE_API_URL |
Next.js API base (includes /api) |
http://localhost:3000/api |
VANTAGE_API_KEY |
Developer account API key | vantage_… |
Quick start (Client-centric)
from vantage import Client
client = Client()
# KPI: create → chain governance on the same handle
my_kpi = client.kpis.create(
name="Monthly revenue",
dataset_id="…",
definition_type="MANUAL",
manual_config={"valueField": "amount", "aggregation": "SUM"},
)
my_kpi.assign_to_team("analytics")
my_kpi.assign_owner("owner@example.com")
# Lookup
record = client.kpis.find_by_name("Monthly revenue")
existing = client.kpis.for_id(record.id)
# Dataset
dataset = client.datasets.register(
location={"schema": "marts", "table": "nps"},
name="NPS",
type="TABLE",
storage_system_slug="postgresql",
)
dataset.assign_to_team("customer-success")
dataset.analyze_and_check_alerts()
# Ingestion
client.ingestion.storage_systems.register(
slug="wh-pg",
env_key="DRC_PG",
name="Warehouse PostgreSQL",
kind="POSTGRESQL",
config={"database": "analytics"},
)
# Platform admin
client.platform.teams.create(name="Analytics")
Public exports
Client, catalogue exceptions (NotFoundError, AmbiguousLookupError), Page, and orchestration helpers (vantage_flow, orchestration_hooks, …).
This package ships a py.typed marker — use Pylance/Pyright basic type checking or stricter for full namespace and create/register parameter hints.
Resource types and records: from vantage.resources import KpiResource or from vantage.catalogue import KpiRecord.
Migration from 1.x
| 1.x | 2.0 |
|---|---|
from vantage import KPI, Dataset, … |
from vantage import Client only |
KPI(client=…, …).create() |
client.kpis.create(…) → returns handle |
KPI.for_id(client, id) |
client.kpis.for_id(id) |
DataStorageSystem(…).register() |
client.ingestion.storage_systems.register(…) |
Team(…).create() |
client.platform.teams.create(…) |
client.kpis was read-only |
client.kpis = read + write |
Orchestration
See previous examples using vantage_flow, orchestration_hooks, and client.ingestion.data_sources.register inside Prefect flows.
Release files for drc-vantage 1.6.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| drc_vantage-1.6.1.tar.gz | 32.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| drc_vantage-1.6.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 81.5 kB
Release files / drc_vantage-1.6.1.tar.gz
| Download URL | drc_vantage-1.6.1.tar.gz |
|---|---|
| Size | 32.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ec3b7c4999e598f1d21a9d0ccbaabe195672c7c1056fae7d0d31ff97f9ac8a05
|
|
BLAKE2b-256 checksum How to use checksums |
a772b54d7f0985a75bcf0878d4c9ca635e44ee018c799ec6146f2f73bc7a4a5f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / drc_vantage-1.6.1-py3-none-any.whl
| Download URL | drc_vantage-1.6.1-py3-none-any.whl |
|---|---|
| Size | 49.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a3668431fd9015255f3c7167fef188ff01aad3230e3df007ef888eb5694d91c9
|
|
BLAKE2b-256 checksum How to use checksums |
1ed01743e20fe4022684183d30b32c3788f039377c4338a2d872912c05f04f75
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|