How purplemashu/me-cli-sunset works
MYnyak Engsel Sunset is a terminal client for managing an Indonesian mobile-provider account and its packages. The main workflow selects or logs into an account, retrieves account/package data, and lets the user browse packages and initiate purchases; separate menus cover family plans, circles, notifications, bookmarks, and transaction history. Authentication state is maintained by the auth service, while client modules communicate with provider APIs and encrypt/sign requests. The excerpts show several key calls, but not every menu implementation, so unsampled feature wiring is represented conservatively.
Main entry points: engsel.py Provider API client · main.py Main menu · purchase.py Package purchases · auth.py Auth service
Components 26
CLI workflow
- Main menu
main.py
Account identity
- Account menu
app/menus/account.py - Auth service
app/service/auth.py - Login registration
app/client/registration.py - CIAM client
app/client/ciam.py - Refresh token state
app/service/auth.py
Packages and purchase
- Package browsing
app/menus/package.py - Store browsing
app/menus/store/search.py - Package purchases
app/menus/purchase.py - Balance settlement
app/client/purchase/balance.py - E-wallet payment
app/client/purchase/ewallet.py - QRIS payment
app/client/purchase/qris.py - Rewards redemption
app/client/purchase/redeem.py - Hot package lists
hot_data/hot.json - Decoy package data
decoy_data/decoy-default-balance.json
Account features
- Family plans
app/menus/family.py - Family organizer
app/menus/famplan.py - Circle management
app/menus/circle.py - Bookmarks
app/menus/bookmark.py - Notifications
app/menus/notification.py
Provider interface
- Store search API
app/client/store/search.py - Provider API client
app/client/engsel.py - Request encryption
app/client/encrypt.py - Payment utilities
app/client/purchase/common.py
Other components
- CLI user
- Mobile provider
Connections 38
- CLI user → Main menu: selects options
- Main menu → Auth service: gets active account
- Main menu → Account menu: opens account menu
- Main menu → Package browsing: browses packages
- Main menu → Package purchases: starts purchase
- Main menu → Family plans: opens family plans
- Main menu → Family organizer: opens organizer
- Main menu → Circle management: opens circles
- Account menu → Auth service: selects account
- Auth service → Refresh token state: reads and writes tokens
- Auth service → CIAM client: refreshes tokens
- Auth service → Provider API client: loads profile
- Login registration → CIAM client: authenticates
- Package browsing → Provider API client: loads package data
- Package browsing → Balance settlement: settles purchase
- Package browsing → Bookmarks: uses bookmarks
- Store browsing → Store search API: searches catalog
- Store browsing → Package browsing: opens package details
- Package purchases → Provider API client: loads package details
- Package purchases → Balance settlement: settles by balance
- Package purchases → Decoy package data: reads optional decoy
- Package purchases → Hot package lists: reads hot lists
- Balance settlement → Request encryption: encrypts and signs
- E-wallet payment → Request encryption: encrypts and signs
- QRIS payment → Request encryption: encrypts and signs
- Rewards redemption → Request encryption: encrypts and signs
- Balance settlement → Mobile provider: submits settlement
- E-wallet payment → Mobile provider: submits payment
- QRIS payment → Mobile provider: submits payment
- Rewards redemption → Mobile provider: submits redemption
- Store search API → Provider API client: sends API request
- Provider API client → Request encryption: encrypts requests
- Provider API client → Mobile provider: requests account data
- Family plans → Provider API client: loads family data
- Family organizer → Provider API client: manages plan
- Circle management → Provider API client: manages circle
- Notifications → Provider API client: fetches notifications
- Bookmarks → Mobile provider: stores bookmarks