:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
feat(data-warehouse): expand impact.com source with contracts, action updates, invoice line items (#79897)
posthog[bot]cd099de5f78e
diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/canonical_descriptions.py b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/canonical_descriptions.pyindex 177dfc106941..5b37d8e511f6 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/canonical_descriptions.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/canonical_descriptions.py@@ -55,4 +55,78 @@ CANONICAL_DESCRIPTIONS: CanonicalDescriptions = {"MediaPartnerName": "Name of the partner credited with the action.",},},+ "ActionUpdates": {+ "description": "The lifecycle history of actions: one row per state change, including when a payout locks and can no longer be reversed.",+ "docs_url": "https://integrations.impact.com/brand-api-reference/reference/actions/action-updates",+ "columns": {+ "Id": "Unique identifier for the action update record.",+ "ActionId": "The action this update belongs to.",+ "CampaignId": "Campaign the action was tracked against.",+ "State": "Approval state at this update: PENDING, APPROVED, or REVERSED.",+ "StateDetail": "Additional state code for this update.",+ "StateDetailDescription": "Plain-text meaning of the state detail.",+ "Disposition": "The change/disposition code for this update.",+ "DeltaPayout": "Change to the action's payout recorded by this update.",+ "DeltaAmount": "Change to the action's sale amount recorded by this update.",+ "Currency": "ISO 4217 currency code of the payout/amount.",+ "ContractId": "Contract the payout terms for this update came from.",+ "ActionDate": "When the underlying action's tracked event occurred.",+ "UpdateDate": "When this update (state change) was recorded.",+ "LockingDate": "Date after which the action can no longer be modified (payout is finalized).",+ "ClearingDate": "When the payout cleared.",+ "MediaPartnerId": "Partner credited with the action.",+ },+ },+ "Contracts": {+ "description": "Partner contracts and their payout terms per campaign — the expected affiliate cost to reconcile against invoices.",+ "docs_url": "https://integrations.impact.com/brand-api-reference/reference/contracts/contracts",+ "columns": {+ "Id": "Unique identifier for the contract.",+ "CampaignId": "Campaign the contract applies to.",+ "PartnerId": "Partner the contract is with.",+ "Status": "Contract status, e.g. ACTIVE or EXPIRED.",+ "StartDate": "When the contract takes effect.",+ "EndDate": "When the contract expires (null if open-ended).",+ "DateCreated": "When the contract was created.",+ "DateLastUpdated": "When the contract was last updated.",+ "TemplateTerms": "Payout terms (EventPayouts, PayoutGroups, Tiers, Rules) currently in effect.",+ "ScheduledTerms": "Payout terms scheduled to take effect in the future.",+ "CampaignTerms": "Campaign-level payout term overrides.",+ },+ },+ "InvoiceLineItems": {+ "description": "Summary invoice line items, one row per campaign/description on an invoice, split out of the Invoices payload.",+ "docs_url": "https://integrations.impact.com/brand-api-reference/reference/invoices/invoices",+ "columns": {+ "InvoiceId": "The invoice this line item belongs to.",+ "LineNumber": "1-based position of the line within its invoice.",+ "CampaignId": "Campaign the line item is for.",+ "CampaignName": "Name of the campaign the line item is for.",+ "Description": "Line item type, e.g. MEDIA_PAYOUT or BONUS.",+ "EventMonthYear": "Month and year (MYYYY) the underlying actions occurred.",+ "Actions": "Number of actions covered by the line item.",+ "NetItemAmount": "Net amount for the line item.",+ "VatItemAmount": "VAT amount for the line item.",+ "TotalItemAmount": "Total amount for the line item.",+ "Status": "Payment status of the line item: PENDING, PAID, or OVERDUE.",+ "DueDate": "When the line item is due.",+ "PaidDate": "When the line item was paid (null if unpaid).",+ },+ },+ "InvoiceDetailedLineItems": {+ "description": "Detailed invoice line items with a program-level breakdown, split out of the Invoices payload.",+ "docs_url": "https://integrations.impact.com/brand-api-reference/reference/invoices/invoices",+ "columns": {+ "InvoiceId": "The invoice this line item belongs to.",+ "LineNumber": "1-based position of the line within its invoice.",+ "AccountId": "Account the line item is attributed to.",+ "Name": "Name associated with the line item.",+ "ProgramId": "Program (campaign) the line item is for.",+ "ProgramName": "Name of the program the line item is for.",+ "EventMonthYear": "Month and year (MYYYY) the underlying actions occurred.",+ "ActionAmount": "Amount from actions for the line item.",+ "OtherAmount": "Other (non-action) amount for the line item.",+ "TotalAmount": "Total amount for the line item.",+ },+ },}diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/impact.py b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/impact.pyindex 59af79c5ff9d..96688a969186 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/impact.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/impact.py@@ -125,12 +125,16 @@ def _paginate_endpoint(params: dict[str, Any],logger: FilteringBoundLogger,start_page: int = 1,+ path: Optional[str] = None,) -> Iterator[tuple[int, list[dict[str, Any]]]]:- """Yield (page_number, rows) from `start_page` to the last page (`@numpages`)."""+ """Yield (page_number, rows) from `start_page` to the last page (`@numpages`).++ `path` overrides `config.path` for endpoints whose campaign id lives in the URL (Contracts)."""+ request_path = path if path is not None else config.pathpage = start_pagewhile True:page_params = {**params, "Page": page, "PageSize": config.page_size}- data = _fetch(session, account_sid, config.path, page_params, logger)+ data = _fetch(session, account_sid, request_path, page_params, logger)rows = _rows_from_response(config, data)yield page, rows@@ -199,7 +203,7 @@ def _get_rows_simple(resumable_source_manager.save_state(ImpactResumeConfig(page=page))-def _get_rows_actions(+def _get_rows_fanout(session: requests.Session,account_sid: str,config: ImpactEndpointConfig,@@ -208,41 +212,95 @@ def _get_rows_actions(db_incremental_field_last_value: Any,resumable_source_manager: ResumableSourceManager[ImpactResumeConfig],) -> Iterator[list[dict[str, Any]]]:- # Only the Actions config reaches this path, and it always declares both date params.- assert config.incremental_start_param is not None- assert config.incremental_end_param is not None- start_param = config.incremental_start_param- end_param = config.incremental_end_param+ """Fetch a campaign-scoped endpoint once per campaign (Actions, ActionUpdates, Contracts).+ Date-windowed endpoints (the action endpoints) are additionally walked in 44-day windows;+ Contracts has no such cap and runs a single pass per campaign."""campaign_ids = _discover_campaign_ids(session, account_sid, logger)if not campaign_ids:- logger.warning("Impact: no campaigns found for account; nothing to sync for Actions")+ logger.warning(f"Impact: no campaigns found for account; nothing to sync for {config.name}")return- windows = _windows_for_actions(should_use_incremental_field, db_incremental_field_last_value)+ windows: list[Optional[tuple[datetime, datetime]]]+ if config.date_windowed:+ windows = list(_windows_for_actions(should_use_incremental_field, db_incremental_field_last_value))+ else:+ windows = [None]+# Windows OUTER, campaigns INNER so rows arrive in globally ascending date order across every# campaign — required for the `sort_mode="asc"` watermark to advance monotonically.- work_items = [(window, campaign_id) for window in windows for campaign_id in campaign_ids]+ work_items: list[tuple[Optional[tuple[datetime, datetime]], int]] = [+ (window, campaign_id) for window in windows for campaign_id in campaign_ids+ ]resume = resumable_source_manager.load_state() if resumable_source_manager.can_resume() else Nonestart_index = _resume_index(work_items, resume)if start_index > 0:- logger.debug(f"Impact: resuming Actions from item {start_index}/{len(work_items)}")+ logger.debug(f"Impact: resuming {config.name} from item {start_index}/{len(work_items)}")for window, campaign_id in work_items[start_index:]:- params: dict[str, Any] = {- "CampaignId": campaign_id,- start_param: _format_datetime(window[0]),- end_param: _format_datetime(window[1]),- }- for _page, rows in _paginate_endpoint(session, account_sid, config, params, logger):+ params: dict[str, Any] = {}+ if config.campaign_id_in_path:+ path: Optional[str] = config.path.format(campaign_id=campaign_id)+ else:+ path = None+ params["CampaignId"] = campaign_id+ if window is not None:+ assert config.incremental_start_param is not None+ assert config.incremental_end_param is not None+ params[config.incremental_start_param] = _format_datetime(window[0])+ params[config.incremental_end_param] = _format_datetime(window[1])++ for _page, rows in _paginate_endpoint(session, account_sid, config, params, logger, path=path):if rows:+ if config.campaign_id_in_path:+ # Path-based fan-out doesn't echo the campaign id on each row; inject it so the+ # composite primary key stays unique across campaigns.+ for row in rows:+ row.setdefault("CampaignId", campaign_id)yield rows# Save once the whole (window, campaign) item is drained. A crash re-fetches it from page# 1 on resume; merge dedupes the re-yielded rows.- resumable_source_manager.save_state(- ImpactResumeConfig(campaign_id=campaign_id, window_start=window[0].isoformat())- )+ window_start = window[0].isoformat() if window is not None else None+ resumable_source_manager.save_state(ImpactResumeConfig(campaign_id=campaign_id, window_start=window_start))+++def _get_rows_nested(+ session: requests.Session,+ account_sid: str,+ config: ImpactEndpointConfig,+ logger: FilteringBoundLogger,+ resumable_source_manager: ResumableSourceManager[ImpactResumeConfig],+) -> Iterator[list[dict[str, Any]]]:+ """Flatten a nested array carried on a parent endpoint's rows into its own table.++ Reuses the parent endpoint's fetch (e.g. Invoices) and splits each nested array (LineItems,+ DetailedLineItems) into child rows tagged with a foreign key back to the parent."""+ nested = config.nested+ assert nested is not None+ parent_config = IMPACT_ENDPOINTS[nested.parent_endpoint]++ resume = resumable_source_manager.load_state() if resumable_source_manager.can_resume() else None+ start_page = resume.page if resume and resume.page else 1++ for page, parent_rows in _paginate_endpoint(session, account_sid, parent_config, {}, logger, start_page=start_page):+ child_rows: list[dict[str, Any]] = []+ for parent_row in parent_rows:+ items = parent_row.get(nested.array_key)+ if not isinstance(items, list):+ continue+ parent_id = parent_row.get(nested.parent_id_field)+ for line_number, item in enumerate(items, start=1):+ if not isinstance(item, dict):+ continue+ child = dict(item)+ child[nested.fk_name] = parent_id+ child[nested.line_number_field] = line_number+ child_rows.append(child)+ if child_rows:+ yield child_rows+ # Save after yielding: a crash re-fetches this same page and merge dedupes it.+ resumable_source_manager.save_state(ImpactResumeConfig(page=page))def get_rows(@@ -257,8 +315,12 @@ def get_rows(config = IMPACT_ENDPOINTS[endpoint]session = _get_session(account_sid, auth_token)+ if config.nested is not None:+ yield from _get_rows_nested(session, account_sid, config, logger, resumable_source_manager)+ return+if config.requires_campaign_fanout:- yield from _get_rows_actions(+ yield from _get_rows_fanout(session,account_sid,config,diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/settings.py b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/settings.pyindex f6133560501e..b8e2e94bf9b8 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/settings.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/settings.py@@ -16,19 +16,43 @@ DEFAULT_PAGE_SIZE = 1000ACTIONS_PAGE_SIZE = 2000+@dataclass+class NestedTableConfig:+ """A child table derived by flattening a nested array already present on a parent endpoint's+ rows — no extra API call. Impact ships invoice line items inside the Invoices payload, so we+ fetch Invoices once and split each nested array into its own queryable table."""++ # Endpoint whose already-fetched rows carry the nested array.+ parent_endpoint: str+ # Key of the nested array on each parent row.+ array_key: str+ # Field on the parent row copied onto each child row as a foreign key...+ parent_id_field: str+ # ...under this name.+ fk_name: str+ # Impact gives invoice line items no id of their own, so a 1-based index within the parent keeps+ # the (fk, line_number) primary key unique table-wide.+ line_number_field: str = "LineNumber"++@dataclassclass ImpactEndpointConfig:name: str- # Path relative to https://api.impact.com/Advertisers/{account_sid}.+ # Path relative to https://api.impact.com/Advertisers/{account_sid}. When campaign_id_in_path is+ # set, this is a `{campaign_id}` format template resolved per campaign during fan-out.path: str# Key the response wraps its row array under.data_key: strprimary_keys: list[str]- # Actions is the only endpoint that requires a CampaignId filter, so it's fetched once per- # campaign discovered from the Campaigns endpoint.+ # Endpoints scoped to a single campaign are fetched once per campaign discovered from Campaigns.+ # Actions/ActionUpdates take the campaign as a `CampaignId` query param; Contracts takes it in+ # the path (see campaign_id_in_path).requires_campaign_fanout: bool = False- # Actions is also the only endpoint whose date filter is capped at a 45-day span, so history- # is walked in bounded windows.+ # Contracts nests the campaign in the path (/Campaigns/{campaign_id}/Contracts) and, unlike the+ # action endpoints, doesn't echo it back on each row, so the fan-out injects CampaignId itself.+ campaign_id_in_path: bool = False+ # The action endpoints cap their date filter at a 45-day span, so history is walked in bounded+ # windows.date_windowed: bool = Falseincremental_start_param: Optional[str] = Noneincremental_end_param: Optional[str] = None@@ -37,6 +61,8 @@ class ImpactEndpointConfig:incremental_fields: list[IncrementalField] = field(default_factory=list)should_sync_default: bool = Truedescription: Optional[str] = None+ # Set on tables derived from another endpoint's nested array (invoice line items).+ nested: Optional[NestedTableConfig] = NoneIMPACT_ENDPOINTS: dict[str, ImpactEndpointConfig] = {@@ -94,6 +120,78 @@ IMPACT_ENDPOINTS: dict[str, ImpactEndpointConfig] = {"(an Impact.com API limit). Only syncs the last 3 years on initial sync."),),+ "ActionUpdates": ImpactEndpointConfig(+ name="ActionUpdates",+ path="/ActionUpdates",+ data_key="ActionUpdates",+ primary_keys=["Id"],+ requires_campaign_fanout=True,+ date_windowed=True,+ # StartDate/EndDate filter on the update (modification) date, matching the UpdateDate cursor.+ incremental_start_param="StartDate",+ incremental_end_param="EndDate",+ partition_key="ActionDate",+ incremental_fields=[+ {+ "label": "UpdateDate",+ "type": IncrementalFieldType.DateTime,+ "field": "UpdateDate",+ "field_type": IncrementalFieldType.DateTime,+ },+ ],+ description=(+ "The lifecycle history of each action: one row per state change, carrying State, "+ "DeltaPayout/DeltaAmount, and LockingDate. Use it to tell whether a payout is locked "+ "(finalized) or still reversible — the flat Actions table only shows a snapshot. "+ "Fetched per campaign in 44-day windows; only syncs the last 3 years on initial sync."+ ),+ ),+ "Contracts": ImpactEndpointConfig(+ name="Contracts",+ path="/Campaigns/{campaign_id}/Contracts",+ data_key="Contracts",+ # Contract Id is scoped per campaign in the fan-out, so pair it with the injected CampaignId.+ primary_keys=["CampaignId", "Id"],+ requires_campaign_fanout=True,+ campaign_id_in_path=True,+ description=(+ "Partner contracts and their payout terms (EventPayouts, PayoutGroups, Tiers, Rules) "+ "per campaign. The terms needed to reconcile expected affiliate cost against invoices. "+ "Impact returns active contracts by default. Full refresh only."+ ),+ ),+ "InvoiceLineItems": ImpactEndpointConfig(+ name="InvoiceLineItems",+ path="/Invoices",+ data_key="Invoices",+ primary_keys=["InvoiceId", "LineNumber"],+ nested=NestedTableConfig(+ parent_endpoint="Invoices",+ array_key="LineItems",+ parent_id_field="Id",+ fk_name="InvoiceId",+ ),+ description=(+ "Summary invoice line items (one row per campaign/description on an invoice), split out "+ "of the Invoices payload with an InvoiceId foreign key. Full refresh only."+ ),+ ),+ "InvoiceDetailedLineItems": ImpactEndpointConfig(+ name="InvoiceDetailedLineItems",+ path="/Invoices",+ data_key="Invoices",+ primary_keys=["InvoiceId", "LineNumber"],+ nested=NestedTableConfig(+ parent_endpoint="Invoices",+ array_key="DetailedLineItems",+ parent_id_field="Id",+ fk_name="InvoiceId",+ ),+ description=(+ "Detailed invoice line items with a program-level breakdown, split out of the Invoices "+ "payload with an InvoiceId foreign key. Full refresh only."+ ),+ ),}ENDPOINTS = tuple(IMPACT_ENDPOINTS.keys())diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact.py b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact.pyindex 4383ca6ee20a..daa8c8721d86 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact.py@@ -376,6 +376,104 @@ class TestGetRowsActions:)+class TestGetRowsNested:+ def test_line_items_split_out_with_fk_and_line_number(self) -> None:+ manager = FakeResumableManager()+ invoices = {+ "Invoices": [+ {+ "Id": "INV-1",+ "LineItems": [+ {"CampaignId": 10, "TotalItemAmount": "5.00"},+ {"CampaignId": 20, "TotalItemAmount": "7.00"},+ ],+ },+ {"Id": "INV-2", "LineItems": [{"CampaignId": 30, "TotalItemAmount": "9.00"}]},+ ],+ "@numpages": "1",+ }+ with patch.object(impact, "make_tracked_session"), patch.object(impact, "_fetch", return_value=invoices):+ batches = list(get_rows("sid", "token", "InvoiceLineItems", MagicMock(), manager)) # type: ignore[arg-type]++ rows = [row for batch in batches for row in batch]+ # Foreign key + 1-based per-invoice line number keep the composite PK unique table-wide.+ assert [(r["InvoiceId"], r["LineNumber"]) for r in rows] == [("INV-1", 1), ("INV-1", 2), ("INV-2", 1)]+ assert rows[0]["CampaignId"] == 10++ def test_detailed_line_items_use_their_own_array(self) -> None:+ manager = FakeResumableManager()+ invoices = {+ "Invoices": [+ {+ "Id": "INV-1",+ "LineItems": [{"CampaignId": 10}],+ "DetailedLineItems": [{"ProgramId": 99}],+ }+ ],+ "@numpages": "1",+ }+ with patch.object(impact, "make_tracked_session"), patch.object(impact, "_fetch", return_value=invoices):+ batches = list(get_rows("sid", "token", "InvoiceDetailedLineItems", MagicMock(), manager)) # type: ignore[arg-type]++ rows = [row for batch in batches for row in batch]+ assert rows == [{"ProgramId": 99, "InvoiceId": "INV-1", "LineNumber": 1}]++ def test_invoice_without_the_array_is_skipped(self) -> None:+ manager = FakeResumableManager()+ invoices = {"Invoices": [{"Id": "INV-1"}, {"Id": "INV-2", "LineItems": []}], "@numpages": "1"}+ with patch.object(impact, "make_tracked_session"), patch.object(impact, "_fetch", return_value=invoices):+ batches = list(get_rows("sid", "token", "InvoiceLineItems", MagicMock(), manager)) # type: ignore[arg-type]+ assert batches == []+++class TestGetRowsContractsFanout:+ def test_campaign_id_goes_in_path_and_is_injected_on_rows(self) -> None:+ manager = FakeResumableManager()+ seen_paths: list[str] = []++ def fake_fetch(session: Any, account_sid: str, path: str, params: Any, logger: Any) -> Any:+ if path == "/Campaigns":+ return {"Campaigns": [{"Id": 10}, {"Id": 20}], "@numpages": "1"}+ seen_paths.append(path)+ # Contracts is not scoped by a query param — the campaign lives in the path only.+ assert "CampaignId" not in params+ return {"Contracts": [{"Id": "C-1"}], "@numpages": "1"}++ with patch.object(impact, "make_tracked_session"), patch.object(impact, "_fetch", side_effect=fake_fetch):+ batches = list(get_rows("sid", "token", "Contracts", MagicMock(), manager)) # type: ignore[arg-type]++ assert seen_paths == ["/Campaigns/10/Contracts", "/Campaigns/20/Contracts"]+ injected = {row["CampaignId"] for batch in batches for row in batch}+ assert injected == {10, 20}+++class TestGetRowsActionUpdates:+ @freeze_time("2024-06-01")+ def test_sends_start_and_end_date_params(self) -> None:+ manager = FakeResumableManager()++ def fake_fetch(session: Any, account_sid: str, path: str, params: Any, logger: Any) -> Any:+ if path == "/Campaigns":+ return {"Campaigns": [{"Id": 10}], "@numpages": "1"}+ assert path == "/ActionUpdates"+ assert params["CampaignId"] == 10+ assert "StartDate" in params and "EndDate" in params+ return {"ActionUpdates": [], "@numpages": "1"}++ with patch.object(impact, "make_tracked_session"), patch.object(impact, "_fetch", side_effect=fake_fetch):+ list(+ get_rows(+ "sid",+ "token",+ "ActionUpdates",+ MagicMock(),+ manager, # type: ignore[arg-type]+ should_use_incremental_field=True,+ db_incremental_field_last_value=datetime(2024, 5, 30, tzinfo=UTC),+ )+ )++class TestImpactSourceResponse:@parameterized.expand([@@ -383,6 +481,10 @@ class TestImpactSourceResponse:("MediaPartners", ["Id"], None),("Invoices", ["Id"], None),("Actions", ["Id"], "EventDate"),+ ("ActionUpdates", ["Id"], "ActionDate"),+ ("Contracts", ["CampaignId", "Id"], None),+ ("InvoiceLineItems", ["InvoiceId", "LineNumber"], None),+ ("InvoiceDetailedLineItems", ["InvoiceId", "LineNumber"], None),])def test_source_response_shape(self, endpoint: str, expected_pks: list[str], partition_key: Optional[str]) -> None:diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact_source.py b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact_source.pyindex 75cb3b1ca661..e8fa9fa3bb97 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact_source.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/impact/tests/test_impact_source.py@@ -56,14 +56,27 @@ class TestImpactSourceClass:def test_get_schemas_returns_all_endpoints(self) -> None:schemas = ImpactSource().get_schemas(ImpactSourceConfig(account_sid="s", auth_token="t"), team_id=1)names = {s.name for s in schemas}- assert names == {"Campaigns", "MediaPartners", "Invoices", "Actions"}+ assert names == {+ "Campaigns",+ "MediaPartners",+ "Invoices",+ "Actions",+ "ActionUpdates",+ "Contracts",+ "InvoiceLineItems",+ "InvoiceDetailedLineItems",+ }@parameterized.expand([("Actions", True),("MediaPartners", True),+ ("ActionUpdates", True),("Campaigns", False),("Invoices", False),+ ("Contracts", False),+ ("InvoiceLineItems", False),+ ("InvoiceDetailedLineItems", False),])def test_supports_incremental_per_endpoint(self, endpoint: str, expected: bool) -> None:@@ -83,7 +96,16 @@ class TestImpactSourceClass:def test_documented_tables_render_without_credentials(self) -> None:tables = ImpactSource().get_documented_tables()names = {t["name"] for t in tables}- assert names == {"Campaigns", "MediaPartners", "Invoices", "Actions"}+ assert names == {+ "Campaigns",+ "MediaPartners",+ "Invoices",+ "Actions",+ "ActionUpdates",+ "Contracts",+ "InvoiceLineItems",+ "InvoiceDetailedLineItems",+ }@parameterized.expand([