Skip to content

Commit bf5bd02

Browse files
“saileshwar-skyflow”claude
andcommitted
docs: add v2 and v3 installation and usage guide
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent ad095e4 commit bf5bd02

1 file changed

Lines changed: 78 additions & 0 deletions

File tree

docs/v2-v3-installation.md

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
# Skyflow Python SDK — v2 (PDB) and v3 (FlowDB) Installation
2+
3+
## v2 — PDB SDK
4+
5+
### Install
6+
7+
```bash
8+
pip install "skyflow-python==2.0.0"
9+
```
10+
11+
### Initialize client
12+
13+
```python
14+
from skyflow import SkyflowClient, SkyflowConfig, Credentials
15+
16+
client = SkyflowClient(
17+
SkyflowConfig(
18+
vault_id="<VAULT_ID>",
19+
cluster_id="<CLUSTER_ID>",
20+
credentials=Credentials(api_key="<API_KEY>"),
21+
)
22+
)
23+
```
24+
25+
### Insert
26+
27+
```python
28+
from skyflow import InsertRequest
29+
30+
response = client.vault().insert(
31+
InsertRequest(
32+
table="cards",
33+
values=[{"card_number": "4111111111111111", "cardholder_name": "John Doe"}],
34+
return_tokens=True,
35+
)
36+
)
37+
print(response)
38+
# {"records": [{"skyflow_id": "...", "table": "cards"}], "errors": []}
39+
```
40+
41+
---
42+
43+
## v3 — FlowDB SDK
44+
45+
### Install
46+
47+
```bash
48+
pip install "skyflow-python==3.0.0"
49+
```
50+
51+
### Initialize client
52+
53+
```python
54+
from skyflow import SkyflowClient, SkyflowConfig, Credentials
55+
56+
client = SkyflowClient(
57+
SkyflowConfig(
58+
vault_id="<VAULT_ID>",
59+
cluster_id="<CLUSTER_ID>",
60+
credentials=Credentials(api_key="<API_KEY>"),
61+
)
62+
)
63+
```
64+
65+
### Insert
66+
67+
```python
68+
from skyflow import InsertRequest
69+
70+
response = client.vault().insert(
71+
InsertRequest(
72+
table="records",
73+
values=[{"field_name": "value"}],
74+
)
75+
)
76+
print(response)
77+
# {"records": [{"skyflow_id": "...", "table": "records"}], "errors": []}
78+
```

0 commit comments

Comments
 (0)