refactor: Use Pydantic models instead of custom dict representations#650
Merged
refactor: Use Pydantic models instead of custom dict representations#650
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #650 +/- ##
==========================================
- Coverage 96.59% 96.52% -0.07%
==========================================
Files 46 45 -1
Lines 4433 4318 -115
==========================================
- Hits 4282 4168 -114
+ Misses 151 150 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
1b03bbc to
36d710a
Compare
vdusek
added a commit
to apify/apify-docs
that referenced
this pull request
Feb 27, 2026
These changes align the OpenAPI specs with the Pydantic models generated for apify-client-python (PR apify/apify-client-python#650), so that `datamodel-codegen` produces matching output without manual edits. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2 tasks
vdusek
added a commit
to apify/apify-docs
that referenced
this pull request
Feb 27, 2026
## Summary - Adds missing `ActorStandby` schema, missing fields (`actorStandby`, `exampleRunInput`, `isDeprecated`, `title`, `maxItems`, `forcePermissionLevel`), and removes incorrect `required` constraints from request schemas. - Cleans up `UpdateTaskRequest` to only contain mutable fields (removes read-only fields like `id`, `userId`, `createdAt`, etc.). ## Related PRs - apify/apify-client-python#650 Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Pijukatel
approved these changes
Feb 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
_representations.pyhelper functions (302 lines deleted) with Pydantic request models (UpdateActorRequest,ScheduleCreate,WebhookCreate,WebhookUpdate, etc.) for constructing API payloads._update()/_create()inResourceClientto accept**kwargsand use a new_clean_json_payload()static method onResourceClientBaseinstead of the removedfilter_none_values()utility.enum_to_value()andfilter_none_values()from_utils.py— Pydantic serialization handles enum conversion andNonefiltering.populate_by_name=Trueto all generated Pydantic model configs viadatamodel-codegenconfiguration, so models can be initialized using eithersnake_casefield names orcamelCasealiases.Test plan
🤖 Generated with Claude Code