Skip to content
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions packages/starknet_paymaster/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.1.0] - 2024-01-XX

### Added
- Initial release of SNIP-29 compliant Paymaster SDK for Dart
- Full implementation of SNIP-29 Paymaster API specification
- Support for gasless (sponsored) transactions
- Support for ERC-20 token fee payments
- Comprehensive type-safe API with proper error handling
- Transaction tracking and status monitoring
- Integration with AVNU Paymaster service
- Complete test coverage including unit, integration, and E2E tests
- Comprehensive documentation and examples
- Validation utilities for all paymaster data types
- JSON-RPC client with automatic error handling
- Support for time-bounded transactions
- Backwards compatibility with existing starknet.dart applications

### Features
- `PaymasterClient` - Main client for SNIP-29 API interactions
- `PaymasterConfig` - Configuration management with AVNU presets
- `PaymasterTransaction` - Type-safe transaction models
- `PaymasterExecution` - Execution parameter management
- Complete error handling with specific exception types
- Automatic transaction tracking and polling
- Fee estimation capabilities
- Support for deploy, invoke, and deploy+invoke transactions
- Signature utilities and validation
- Network resilience and timeout handling

### API Methods
- `isAvailable()` - Check paymaster service status
- `getSupportedTokensAndPrices()` - Get supported tokens and pricing
- `buildTypedData()` - Build typed data for signing
- `execute()` - Execute signed transactions
- `executeTransaction()` - Complete transaction flow
- `executeSponsoredTransaction()` - Gasless transaction execution
- `executeErc20Transaction()` - ERC-20 fee payment execution
- `trackingIdToLatestHash()` - Transaction status tracking
- `waitForTransaction()` - Wait for transaction completion
- `getFeeEstimate()` - Get transaction fee estimates
21 changes: 21 additions & 0 deletions packages/starknet_paymaster/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 AVNU Labs
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copyright is wrong here.


Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading