Conversation
DanielEmmanuel1
approved these changes
Apr 28, 2025
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.
Description
This PR introduces the Make Offer functionality, which is a core part of the peer-to-peer lending protocol.
The ability for a lender to make an offer on a borrower's collateral listing is a critical interaction that drives the entire lending lifecycle. Securely creating and validating offers ensures the trust, safety, and reliability of the protocol, making this feature essential for core protocol operations.
Key Changes:
Onchain Signature Verification:
starknet.py).Listing Status Check:
Offer Duration Validation:
Repayment Amount Validation:
repayment_amountis greater than theprincipal(guaranteeing a positive yield for the lender).Signature Data Integrity Check:
Why This Is Core Functionality:
Trustless Interaction:
Verifying lender offers securely enables borrowers to interact with unknown lenders without requiring trust.
Protocol Safety:
Ensures that offers cannot be spoofed, mismatched, or forged, preserving the financial integrity of loans.
Lifecycle Foundation:
Making an offer is the starting point of the loan negotiation and execution process. Without reliable offers, no loans can be initiated.
Acceptance Criteria:
Notes:
Related Issue
Fixes #14
Type of Change
How Has This Been Tested?
Checklist
Security Considerations
Performance Impact