Skip to content
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
12 changes: 6 additions & 6 deletions docs/python-sdk/api-reference/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Where:
- `project_id` is your Python project identifier (chosen by you, used to deduplicate and identify reported assets)
- `api_key` is your API token (generated from the steps above)
- `url` is the full SDK ingest endpoint URL (the Elementary team will provide you with this URL): `{base_url}/sdk-ingest/{env_id}/batch`
- Example: `https://app.elementary-data.com/sdk-ingest/a6b2425d-36e2-4e13-8458-9825688ca1f2/batch`
- Example: `https://prod.api.elementary-data.com/sdk-ingest/a6b2425d-36e2-4e13-8458-9825688ca1f2/batch`

## Test Context

Expand Down Expand Up @@ -86,7 +86,7 @@ You can also use context managers for inline tests:
with elementary_test_context(asset=asset) as ctx:
# Using context managers
with ctx.boolean_test(name="my_test", description="Inline test") as my_bool_test:
my_bool_test.assert_value(my_test_function())
my_bool_test.check_value(my_test_function())

with ctx.expected_values_test(
name="country_count",
Expand All @@ -95,23 +95,23 @@ with elementary_test_context(asset=asset) as ctx:
metadata={"my_metadata_field": "my_metadata_value"},
) as my_expected_values_test:
# This will fail
my_expected_values_test.assert_value(5)
my_expected_values_test.check_value(5)
# This will pass
my_expected_values_test.assert_value(3)
my_expected_values_test.check_value(3)

with ctx.expected_range_test(
name="age_range",
min=18,
max=50,
) as my_range_test:
my_range_test.assert_value(25.5)
my_range_test.check_value(25.5)

with ctx.row_count_test(
name="row_count",
min=1,
max=1000,
) as my_row_count_test:
my_row_count_test.assert_value(users_df) # Passes DataFrame, list, etc.
my_row_count_test.check_value(users_df) # Passes DataFrame, list, etc.
```

## Supported Objects
Expand Down
2 changes: 1 addition & 1 deletion docs/python-sdk/installation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ To use the Python SDK, you'll need:
1. **Project ID** - Your Python project identifier (choose any string to identify your code project; used to deduplicate and identify reported assets)
2. **API Key** - Your Elementary Cloud API token
3. **URL** - The full endpoint URL: `{base_url}/sdk-ingest/{env_id}/batch`
- Example: `https://app.elementary-data.com/sdk-ingest/a6b2425d-36e2-4e13-8458-9825688ca1f2/batch`
- Example: `https://prod.api.elementary-data.com/sdk-ingest/a6b2425d-36e2-4e13-8458-9825688ca1f2/batch`

### Generate an Access Token

Expand Down
4 changes: 2 additions & 2 deletions docs/python-sdk/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ def main():
# Send results to Elementary Cloud
PROJECT_ID = "my-python-project" # Your Python project identifier (used to deduplicate and identify assets)
API_KEY = "your-api-key"
URL = "https://app.elementary-data.com/sdk-ingest/{env_id}/batch"
URL = "https://prod.api.elementary-data.com/sdk-ingest/{env_id}/batch"

client = ElementaryCloudClient(PROJECT_ID, API_KEY, URL)
client.send_to_cloud(ctx)
Expand Down Expand Up @@ -191,7 +191,7 @@ def main():
# Initialize client and send results
PROJECT_ID = "my-python-project" # Your Python project identifier (used to deduplicate and identify assets)
API_KEY = "your-api-key"
URL = "https://app.elementary-data.com/sdk-ingest/{env_id}/batch"
URL = "https://prod.api.elementary-data.com/sdk-ingest/{env_id}/batch"

client = ElementaryCloudClient(PROJECT_ID, API_KEY, URL)
client.send_to_cloud(ctx)
Expand Down
Loading