chore(sync): sdk from monorepo - #27
Open
Codimow wants to merge 53 commits into
Open
Conversation
- Added PayArkEffectError for Effect-compatible error handling - Implemented EffectHttpClient using @effect/platform - Added Effect schemas for checkout sessions - Exposed effect namespace in PayArk client - Added initial unit tests for Effect API
- Completed implementation of Checkout, Payments, and Projects for Effect API - Added comprehensive Schema validation for all responses - Integrated PayArkConfigService for automatic config injection - Fixed circular imports and type mismatches - Added robust integration tests for all Effect resources
…s, and sdk support
… methods Task 1: DELETE /v1/customers/:id - Ownership verification for API Key and PAT auth - FK constraint handling: 409 when customer has active subscriptions - Returns 204 No Content on success Task 2: SDK CustomersResource update - Added update(id, params) using PATCH - Added delete(id) using DELETE - New UpdateCustomerParams type exported from public API Closes: CUST-02, CUST-03
API Integration Tests (12 tests): - POST: create success, duplicate 409 - PATCH: update success, updated_at verification, empty body 400, cross-project 404, non-existent 404, duplicate email 409 - DELETE: success 204, FK violation 409, non-existent 404, cross-project 404 SDK Unit Tests (11 tests): - create: POST verb + body - retrieve: GET verb + URL encoding - update: PATCH verb + body + URL encoding + 409 conflict - delete: DELETE verb + URL encoding + 409/404 errors Mock factory extended with delete/update-select chains. Closes: Phase 8 verification (08-03)
New: createAutoPaginatingList() in packages/sdk/src/pagination.ts
- for await (const item of payark.payments.list()) { ... }
- Backward-compatible: .data/.meta still accessible
- Applied to payments, customers, subscriptions list() methods
- AutoPaginatingList type exported from public API
5 new unit tests for pagination logic.
The `verify` method on `WebhooksResource` was deprecated in favor of `constructEvent`. This patch: - Removes the deprecated `verify` method from `packages/sdk/src/resources/webhooks.ts`. - Updates all references to `verify()` in SDK documentation and JSDoc comments to `constructEvent()`. - Updates markdown guides and LLM prompt/context files to utilize `constructEvent` where `verify` was previously demonstrated. - Runs and passes all SDK tests to ensure no regressions are introduced. Co-authored-by: Codimow <178092576+Codimow@users.noreply.github.com>
- Added effect, @effect/platform, and @effect/schema to dependencies. - Rewrote HttpClient internals using Effect for retries and timeouts. - Maintained Promise-based public API for zero-friction migration. - Improved reliability with exponential backoff + jitter.
- Created security-effects.ts for higher-order security logic. - Refactored payments and customers routes to use Effect-TS pipelines. - Standardized error handling and ownership verification. - Integrated DbService and runSecure into API handlers. - Fixed SDK HttpClient lint warning.
…0x architectural evolution
This reverts commit 322362f8bf6969939fd7760580e13ff950d586c4.
…oid redundant backoff
…xclude e2e from unit tests
…e repository compatibility
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.
Automated subtree sync from monorepo.
packages/sdk149bc704a014b286072a75b4c4a553f9345970169d3cb7d2026-03-08T11:53:26Z