insta-note-clock/README.md

55 lines
1.3 KiB
Markdown

# insta-note-clock
A lightweight Rust CLI daemon that updates your Instagram Note with the current time at a configurable, safe interval.
> **Disclaimer:** Instagram has no public API for Notes. This tool interacts with private mobile endpoints, which violates Instagram's Terms of Service. Frequent updates risk rate limits (HTTP 429) or account suspension. Default interval is 120s with exponential backoff. Use at your own risk.
---
## Quick Start
### 1. Build
```bash
cargo build --release
```
### 2. Authenticate
```bash
# Option A: Direct session cookie import (recommended)
cargo run -- login --session-id "YOUR_SESSION_ID" --user-id "YOUR_DS_USER_ID"
# Option B: Interactive login (supports 2FA)
cargo run -- login
```
Session data will be stored securely in `session.json`.
### 3. Run
```bash
# Test run without hitting Instagram
cargo run -- --dry-run once
# Update once and exit
cargo run -- once
# Run continuous sync loop
cargo run -- run
```
---
## Configuration (`config.toml`)
```toml
[instagram]
session_file = "./session.json"
timezone = "Asia/Kolkata"
[note]
interval_seconds = 120 # Minimum recommended: 120s
time_format = "%H:%M" # strftime syntax
prefix = ""
suffix = ""
max_requests_per_hour = 30
```
Environment variables with prefix `INSTA_` (e.g. `INSTA_NOTE__INTERVAL_SECONDS=120`) are also supported.