fix: Comprehensive TypeScript definitions audit and fixes#534
Merged
Justintime50 merged 2 commits intomasterfrom Feb 3, 2026
Merged
fix: Comprehensive TypeScript definitions audit and fixes#534Justintime50 merged 2 commits intomasterfrom
Justintime50 merged 2 commits intomasterfrom
Conversation
fa7e2e4 to
15f05e8
Compare
15f05e8 to
dcd24d1
Compare
This commit addresses multiple issues with TypeScript definitions: ## Critical Fixes - Fix #515: Export ReferralCustomer property correctly - Add missing api_keys field to Referral interface - Consolidate duplicate Rate definitions (removed types/Shipment/Rate.d.ts) - Add missing exports: Claim, CustomerPortal, Embeddable, Luma, Referral, SmartRate - Add missing services to EasyPost client: Claim, CustomerPortal, Embeddable, Luma, SmartRate ## New Type Definitions - Create Luma type definitions (types/Luma/) - Create SmartRate index file - Create TaxIdentifier type definition for Shipment ## Type Corrections - Fix Pickup.instructions: now optional nullable - Fix Order properties: return_address, buyer_address, is_return now optional nullable - Add missing User.reference field - Fix typo: pickup_man_datetime → pickup_max_datetime - Standardize ScanForm.getNextPage() return type to use scan_forms - Standardize Referral.getNextPage() return type to use referral_customers ## Files Modified (12) - types/EasyPost.d.ts - types/Order/Order.d.ts - types/Pickup/Pickup.d.ts - types/Referral/Referral.d.ts - types/ScanForm/ScanForm.d.ts - types/Shipment/Options/Options.d.ts - types/Shipment/Shipment.d.ts - types/Shipment/ShipmentCreateParameters.d.ts - types/Shipment/index.d.ts - types/User/User.d.ts - types/index.d.ts ## Files Created (5) - types/Luma/Luma.d.ts - types/Luma/index.d.ts - types/SmartRate/index.d.ts - types/Shipment/TaxIdentifier.d.ts ## Files Deleted (1) - types/Shipment/Rate.d.ts (duplicate) Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
dcd24d1 to
88bf64c
Compare
sroomberg-ep
approved these changes
Feb 3, 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
This PR addresses multiple critical issues with TypeScript definitions found during a comprehensive audit of the codebase.
Closes #438 (partially)
Closes #515
Fixes
ReferralCustomer(notReferral) to match JavaScript implementationapi_keysfield to Referral interfaceChanges
Critical Issues Fixed
1. Duplicate Rate Definitions
types/Rate/Rate.d.tsandtypes/Shipment/Rate.d.tstypes/Shipment/Rate.d.ts, updatedtypes/Shipment/index.d.tsto re-export from../Rate2. Missing Exports
Added missing exports to
types/index.d.ts:3. Missing Service Definitions
Added missing services to EasyPost client (
types/EasyPost.d.ts):4. Missing Type Definitions
src/services/luma_service.jstypes/Luma/Luma.d.tstypes/Luma/index.d.tstypes/SmartRate/index.d.tstypes/Shipment/TaxIdentifier.d.tsfor embedded tax identifier objectsHigh Priority Fixes
5. Interface/Class Property Mismatches
return_address,buyer_address,is_returnto be optional nullable6. Typos and Inconsistencies
pickup_man_datetime→pickup_max_datetimegetNextPage()return type to usescan_formsgetNextPage()return type to usereferral_customersTesting
npm run buildFiles Changed
Modified (12):
Created (5):
Deleted (1):
🤖 Generated with Claude Code