Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zod API response validation #94

Draft
wants to merge 13 commits into
base: master
Choose a base branch
from
Draft

Conversation

pajcho
Copy link
Contributor

@pajcho pajcho commented Aug 9, 2023

This PR serves as a starting point for us to discuss around the topic of validating API responses using Zod library.

  • Both wallet and Contract models have been migrated to Zod.
  • Wallet and Contract related tests now have api response validation as a part of every test.
  • I have renamed types.ts --> common.types.ts in order to be able to add common.schema.ts (schema.ts seems weird)

@pajcho pajcho requested a review from maleksandar August 9, 2023 12:32
@changeset-bot
Copy link

changeset-bot bot commented Aug 9, 2023

🦋 Changeset detected

Latest commit: 64d5777

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@tenderly/sdk Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pajcho pajcho temporarily deployed to CI August 9, 2023 12:32 — with GitHub Actions Inactive
@pajcho pajcho changed the base branch from master to feature/strict-mode August 9, 2023 12:32
@pajcho pajcho changed the title Add zod api response validation as a poc Zod API response validation Aug 11, 2023
@pajcho pajcho self-assigned this Aug 14, 2023
Base automatically changed from feature/strict-mode to master August 15, 2023 08:31
# Conflicts:
#	lib/core/ApiClientProvider.ts
#	lib/executors/Simulator.ts
#	lib/repositories/wallets/wallets.types.ts
#	test/contracts.repository.test.ts
#	test/wallets.repository.test.ts
@pajcho pajcho temporarily deployed to CI October 13, 2023 14:02 — with GitHub Actions Inactive
This was already merged into master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant