feat(generated): Changes to pipes - #738
workos-sdk-automation[bot] wants to merge 4 commits into
Conversation
|
| object: Literal["credential"] | None = None | ||
| """Distinguishes the credential object.""" | ||
| auth_method: Literal["oauth"] | None = None | ||
| """The authentication method for this credential. Additional values may be added in the future; handle unknown values gracefully.""" |
There was a problem hiding this comment.
Credential type excludes supported methods The new public
auth_method annotation permits only "oauth", while this model documents API-key and client-credentials responses too. Type-checked consumers cannot handle those documented variants without working around the SDK's annotation.
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/workos/pipes/models/data_integration_vended_credential.py
Line: 18
Comment:
**Credential type excludes supported methods** The new public `auth_method` annotation permits only `"oauth"`, while this model documents API-key and client-credentials responses too. Type-checked consumers cannot handle those documented variants without working around the SDK's annotation.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.| if self.expires_at is not None: | ||
| result["expires_at"] = self.expires_at | ||
| else: | ||
| result["expires_at"] = None |
There was a problem hiding this comment.
Absent expiry becomes null API-key credentials are documented to omit
expires_at, but deserializing one and calling to_dict() inserts "expires_at": null. A valid response therefore changes shape when it is round-tripped through this model.
Prompt To Fix With AI
This is a comment left during a code review.
Path: src/workos/pipes/models/data_integration_vended_credential.py
Line: 58-61
Comment:
**Absent expiry becomes null** API-key credentials are documented to omit `expires_at`, but deserializing one and calling `to_dict()` inserts `"expires_at": null`. A valid response therefore changes shape when it is round-tripped through this model.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.| result = workos.pipes.update_data_integration_api_key( | ||
| "test_slug", | ||
| body=load_fixture("data_integrations_upsert_api_key_request.json"), | ||
| ) |
There was a problem hiding this comment.
Typed update bodies remain untested The updated API-key and client-credentials PUT tests pass fixture dictionaries, so neither exercises the new
body.to_dict() path. A test using a typed body, especially an exact-connection variant, would catch regressions in how connected_account_id and connection_intent are sent.
Prompt To Fix With AI
This is a comment left during a code review.
Path: tests/test_pipes.py
Line: 135-138
Comment:
**Typed update bodies remain untested** The updated API-key and client-credentials PUT tests pass fixture dictionaries, so neither exercises the new `body.to_dict()` path. A test using a typed body, especially an exact-connection variant, would catch regressions in how `connected_account_id` and `connection_intent` are sent.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Summary
feat(pipes): Change Pipes API surface
Triggered by workos/openapi-spec@0b0182d
BEGIN_COMMIT_OVERRIDE
feat(pipes): Change Pipes API surface (#738)
END_COMMIT_OVERRIDE