flutter_txms 0.1.3 copy "flutter_txms: ^0.1.3" to clipboard
flutter_txms: ^0.1.3 copied to clipboard

A Flutter package for encoding and decoding hex messages for TxMS transport

Flutter TxMS #

A Flutter package for encoding and decoding hex messages for SMS/MMS communication. This package provides a robust solution for handling hex-encoded messages across multiple platforms.

pub package License: CORE

Features #

  • πŸ”„ Hex encoding and decoding
  • πŸ“± SMS/MMS message generation
  • πŸ“Š Message segmentation counting
  • πŸ’Ύ File download support
  • πŸ“² Direct SMS/MMS client opening
  • 🌐 Cross-platform support (iOS, Android, Web, Desktop)
  • ✨ Zero external runtime dependencies
  • πŸ”’ Null safety
  • πŸ“š Comprehensive documentation

Getting Started #

Add this to your package's pubspec.yaml file:

dependencies:
  flutter_txms: ^0.1.0

Usage #

Basic Example #

import 'package:flutter_txms/flutter_txms.dart';

void main() {
  final txms = Txms();

  // Encode a hex string
  final encoded = txms.encode('0x48656c6c6f20576f726c64'); // "Hello World"
  print('Encoded: $encoded');

  // Decode back to hex
  final decoded = txms.decode(encoded);
  print('Decoded: $decoded');
}

SMS Generation and Opening #

final txms = Txms();

// Generate SMS URI
final smsUri = txms.sms(
  number: '+12019715152',
  message: '0x48656c6c6f',
  network: 'mainnet',
);
print('SMS URI: $smsUri');

// Open SMS client directly with encoded message
await txms.openSmsClient(
  number: '+12019715152',
  message: '0x48656c6c6f',
  network: 'mainnet',
);

// Open MMS client directly with encoded message
await txms.openMmsClient(
  number: '+12019715152',
  message: '0x48656c6c6f',
  network: 'mainnet',
);

File Operations #

final txms = Txms();

// Save message to file
final filePath = await txms.downloadMessage(
  '0x48656c6c6f20576f726c64',
  optionalFilename: 'hello',
);
print('Saved to: $filePath');

Message Counting #

final txms = Txms();

// Count SMS segments
final smsCount = txms.count('0x48656c6c6f20576f726c64', 'sms');
print('Number of SMS segments: $smsCount');

// Count MMS segments
final mmsCount = txms.count('0x48656c6c6f20576f726c64', 'mms');
print('Number of MMS segments: $mmsCount');

Platform Support #

Android iOS Web macOS Windows Linux
βœ… βœ… βœ… βœ… βœ… βœ…

Additional Features #

  • Custom network aliases
  • Country-specific endpoints
  • Batch message processing
  • Platform-specific URI generation
  • Comprehensive error handling
  • Direct SMS/MMS client launching

Contributing #

Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

License #

This project is licensed under the CORE License - see the LICENSE file for details.

1
likes
150
points
41
downloads

Publisher

verified publisherblockchainhub.digital

Weekly Downloads

A Flutter package for encoding and decoding hex messages for TxMS transport

Repository (GitHub)
View/report issues

Topics

#txms #hex #sms #mms #communication

Documentation

Documentation
API reference

Funding

Consider supporting this project:

github.com
blockindex.net

License

unknown (license)

Dependencies

flutter, http, path, path_provider, url_launcher

More

Packages that depend on flutter_txms