Repository navigation
feat(generated): Changes to pipes - #777
Conversation
…iKeys, AuditLogs, Authorization, ClientApi, Connect, DirectorySync, Events, FeatureFlags, Groups, MultiFactorAuth, OrganizationDomains, OrganizationMembership, Organizations, Pipes, PipesProvider, PlatformTeams, Radar, SSO, UserManagement, Vault, Webhooks, Widgets
[Medium impact] The updates reach Directory Sync, Pipes, and shared response-model workflows. Preserve existing SSO imports and connected-account positional arguments before merging. FindingsFix with agent prompt### Issue 1
src/workos/common/models/__init__.py:2078-2079
The rename removes `SSORequiredOAuthErrorBodyWithConnectionIdsListEmailPendingAuthenticationToken` even though its fields have not changed. Applications importing that name from `workos.common` or `workos.common.models` now fail at startup with `ImportError`. Keep the old name and module as compatibility aliases while exposing the shorter name.
### Issue 2
src/workos/pipes/models/create_connected_account.py:24
Adding `config` before `access_token` changes the positional arguments of these public dataclasses. For example, `CreateConnectedAccount("label", "account", "token")` previously set `access_token`; it now sets `config`, leaving `access_token` empty. `to_dict()` then emits the token under the wrong key.
Append the new fields after all existing fields, or make only the new fields keyword-only. Apply the same fix to the other three changed connected-account dataclasses.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.SummaryAdds provider ownership selection, connected-account configuration and import metadata, scoped Directory Sync methods, and optional event fields.
Reviews (1) · Last reviewed commit: "chore(generated): add release notes frag..." · Reviewed by Greptile |
| from .sso_required_oauth_error_body_with_connection_ids_list_email import ( | ||
| SSORequiredOAuthErrorBodyWithConnectionIdsListEmail as SSORequiredOAuthErrorBodyWithConnectionIdsListEmail, |
There was a problem hiding this comment.
The rename removes SSORequiredOAuthErrorBodyWithConnectionIdsListEmailPendingAuthenticationToken even though its fields have not changed. Applications importing that name from workos.common or workos.common.models now fail at startup with ImportError. Keep the old name and module as compatibility aliases while exposing the shorter name.
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/workos/common/models/__init__.py
Line: 2078-2079
Comment:
**Existing SSO imports fail**
The rename removes `SSORequiredOAuthErrorBodyWithConnectionIdsListEmailPendingAuthenticationToken` even though its fields have not changed. Applications importing that name from `workos.common` or `workos.common.models` now fail at startup with `ImportError`. Keep the old name and module as compatibility aliases while exposing the shorter name.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.| """A mutable, non-unique connection label; null clears it. Not an account identifier.""" | ||
| account_identifier: str | None = None | ||
| """A developer-attested account identifier; null clears it.""" | ||
| config: dict[str, str] | None = None |
There was a problem hiding this comment.
Account arguments shift fields
Adding config before access_token changes the positional arguments of these public dataclasses. For example, CreateConnectedAccount("label", "account", "token") previously set access_token; it now sets config, leaving access_token empty. to_dict() then emits the token under the wrong key.
Append the new fields after all existing fields, or make only the new fields keyword-only. Apply the same fix to the other three changed connected-account dataclasses.
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/workos/pipes/models/create_connected_account.py
Line: 24
Comment:
**Account arguments shift fields**
Adding `config` before `access_token` changes the positional arguments of these public dataclasses. For example, `CreateConnectedAccount("label", "account", "token")` previously set `access_token`; it now sets `config`, leaving `access_token` empty. `to_dict()` then emits the token under the wrong key.
Append the new fields after all existing fields, or make only the new fields keyword-only. Apply the same fix to the other three changed connected-account dataclasses.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.
Summary
feat(pipes): Update Pipes API surface
PipesProviderOwnership.PipesProvider.listForOrganization.ownership.GET /organizations/{organizationId}/data_integration_configurations.PipesProvider.configure.ownership.Triggered by workos/openapi-spec@d4538c8
BEGIN_COMMIT_OVERRIDE
feat(pipes): Update Pipes API surface (#777)
END_COMMIT_OVERRIDE