sorted

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Sorted — Freelancer Tax & Invoicing Automation

Sorted — 自由职业者税务与发票自动化

Automates getSorted.de via real Chrome Beta browser for invoicing, expense tracking, and German tax report submissions.
通过真实Chrome Beta浏览器自动化getSorted.de的发票开具、费用追踪以及德国税务报告提交流程。

Prerequisites

前置条件

  • Chrome Beta with
    --remote-debugging-port=9222
    (use
    /real-browser
    launch sequence)
  • Google account session persisted in
    ~/.chrome-beta-profile
  • agent-browser
    CLI installed
  • 启用
    --remote-debugging-port=9222
    参数的Chrome Beta(使用
    /real-browser
    启动序列)
  • 已在
    ~/.chrome-beta-profile
    中持久化的Google账户会话
  • 已安装
    agent-browser
    CLI

Commands

命令

invoice create

invoice create

Create a new invoice on Sorted.
Required params: client name, amount Optional: hours, rate, description, due date, service date, client type (business/person)
在Sorted上创建新发票。
必填参数: 客户名称、金额 可选参数: 工时、费率、描述、到期日、服务日期、客户类型(企业/个人)

invoice download <invoice-number>

invoice download <invoice-number>

Download a properly formatted PDF from Sorted (not browser print).
从Sorted下载格式规范的PDF文件(非浏览器打印版)。

invoice send <invoice-number> --email <email>

invoice send <invoice-number> --email <email>

Send invoice via email directly from Sorted (paid plan only). On free plan, downloads PDF and sends via Telegram instead.
直接从Sorted通过电子邮件发送发票(仅付费计划可用)。免费计划下,将下载PDF并通过Telegram发送。

invoice list

invoice list

List all invoices with status (paid/unpaid).
列出所有发票及其状态(已支付/未支付)。

expense add

expense add

Add an expense entry.
添加费用条目。

tax status

tax status

Show current tax obligations, deadlines, and overdue reports.
显示当前税务义务、截止日期及逾期报告。

tax preview <report-type> <period>

tax preview <report-type> <period>

Preview a tax report before submission.
提交前预览税务报告。

tax submit <report-type> <period>

tax submit <report-type> <period>

Submit a tax report to Finanzamt via ELSTER (requires paid plan).
通过ELSTER向Finanzamt提交税务报告(需付费计划)。

Sorted Navigation

Sorted导航

App URL:
https://app.getsorted.de/
SectionSidebar linkPurpose
DashboardSorted (logo)Overview: taxes owed, income, expenses
TaxesTaxesTax reports, deadlines, submissions
IncomeIncomeInvoice list, create/edit invoices
ExpensesExpensesExpense tracking, receipts
Tax consultantTax consultantAdvisor connection
Personal detailsProfile → Personal detailsFreelancer info, Steuernummer
Bank accountsProfile → Bank accounts (Beta)Connected banks
SubscriptionProfile → SubscriptionPlan management
ImportProfile → Import your dataBulk data import
SettingsProfile → SettingsApp preferences
应用URL:
https://app.getsorted.de/
板块侧边栏链接用途
仪表盘Sorted(logo)概览:应缴税款、收入、支出
税务Taxes税务报告、截止日期、提交
收入Income发票列表、创建/编辑发票
支出Expenses费用追踪、收据管理
税务顾问Tax consultant顾问关联
个人信息Profile → Personal details自由职业者信息、Steuernummer
银行账户Profile → Bank accounts (Beta)关联银行账户
订阅Profile → Subscription计划管理
导入Profile → Import your data批量数据导入
设置Profile → Settings应用偏好设置

Tax Report Types

税务报告类型

ReportGerman nameFrequencyDescription
Advance VATUmsatzsteuer-Voranmeldung (UStVA)QuarterlyVAT collected on invoices
EU SummaryZusammenfassende Meldung (ZM)QuarterlyRevenue from EU customers
Annual ReturnsEÜR + EinkommensteuererklärungYearlyProfit/loss + income tax
报告德语名称频率描述
增值税预缴Umsatzsteuer-Voranmeldung (UStVA)按季度发票收取的增值税
EU汇总报告Zusammenfassende Meldung (ZM)按季度来自欧盟客户的收入
年度申报表EÜR + Einkommensteuererklärung按年度盈亏 + 所得税

Invoice Creation Flow

发票创建流程

Step-by-step browser automation:

分步浏览器自动化:

  1. Navigate:
    Income
    → click
    Add
    Create invoice
  2. Set client: Click
    Client details
    area on invoice preview
    • Search existing clients or click
      Add new client
    • Choose
      Business
      or
      Private person
    • Fill: name, VAT/TIN, street, city, zip, country (autocomplete dropdown — type then click match), email (optional)
    • Click
      Save
      in dialog
  3. Set invoice date: Click the date next to "Invoice date" (defaults to today)
  4. Set service date (REQUIRED): Click the empty area to the right of invoice date labeled "Service date"
    • This is a date range picker — select start date, then end date
    • If same-day service, click the same date twice
    • Without service date, Save will fail silently — the field shows "Required" in red
    • The clickable element has class
      clickable
      and is positioned at ~x:734 y:413 on the invoice preview
    • If snapshot doesn't show it, use JS: find div with text "Service dateRequired" and click it
  5. Set due date: Click "Select date" under "Due date" → pick from calendar
  6. Add line item: Click
    Add a line
    • Fields: description (text), quantity (number), unit dropdown (h/pcs/etc), rate (number)
    • Click on collapsed values to re-edit them
  7. VAT: Automatically 0% for Kleinunternehmer accounts. Shows "Service not taxable in Germany" in notes
  8. Save: Click
    Save
    button. Title changes from "Add invoice" to "Edit invoice" on success
  1. 导航:
    Income
    → 点击
    Add
    Create invoice
  2. 设置客户: 点击发票预览区的
    Client details
    区域
    • 搜索现有客户或点击
      Add new client
    • 选择
      Business
      Private person
    • 填写:名称、VAT/TIN、街道、城市、邮编、国家(自动补全下拉框 — 输入后点击匹配项)、电子邮件(可选)
    • 点击对话框中的
      Save
  3. 设置发票日期: 点击“Invoice date”旁的日期(默认当天)
  4. 设置服务日期(必填): 点击发票日期右侧标有“Service date”的空白区域
    • 这是一个日期范围选择器 — 选择开始日期,再选择结束日期
    • 若为当日服务,点击同一日期两次
    • 未设置服务日期时,Save会静默失败 — 该字段会显示红色的“Required”
    • 可点击元素带有
      clickable
      类,在发票预览上的位置约为x:734 y:413
    • 若快照未显示该元素,使用JS:找到文本为“Service dateRequired”的div并点击
  5. 设置到期日: 点击“Due date”下的“Select date” → 从日历中选择
  6. 添加行项目: 点击
    Add a line
    • 字段:描述(文本)、数量(数字)、单位下拉框(h/pcs等)、费率(数字)
    • 点击已折叠的值可重新编辑
  7. VAT: Kleinunternehmer账户自动设为0%。备注中显示“Service not taxable in Germany”
  8. 保存: 点击
    Save
    按钮。成功后标题会从“Add invoice”变为“Edit invoice”

Gotchas

注意事项

  • Service date is mandatory but easy to miss — it's not highlighted until you try to save
  • German number formatting: dots are thousands separators (1.000 = one thousand), commas are decimals
  • Collapsed fields: After saving, line item fields collapse to display-only. Click the displayed value to re-open the editable field
  • Invoice number: Auto-generated sequentially (e.g., 2025-03-21). Can be edited by clicking it
  • 服务日期为必填项但容易遗漏 — 只有尝试保存时才会高亮提示
  • 德语数字格式: 点号是千位分隔符(1.000 = 一千),逗号是小数点
  • 折叠字段: 保存后,行项目字段会折叠为仅显示状态。点击显示的值可重新打开编辑字段
  • 发票编号: 自动按顺序生成(例如:2025-03-21)。点击可编辑

Invoice PDF Download Flow

发票PDF下载流程

CRITICAL: Do NOT use Chrome CDP
Page.printToPDF
— it captures the entire page including sidebar and settings panel. Always use Sorted's native PDF.
重要提示:请勿使用Chrome CDP的
Page.printToPDF
— 它会捕获包括侧边栏和设置面板在内的整个页面。请始终使用Sorted的原生PDF。

Step-by-step:

分步操作:

  1. Open the invoice (click from Income list, or navigate after creating)
  2. Click
    Save and send
    button (top right, teal button)
  3. An "Email invoice" dialog appears with:
    • To field (email)
    • Subject (auto-filled)
    • Message textarea
    • Attachments section at the bottom showing the PDF filename
  4. Click the PDF link (e.g.,
    ALL3 DOO BELGRADE-2025-03-21-20260506.pdf
    )
    • It's a
      generic
      element with
      cursor:pointer
      and
      onclick
    • The text matches pattern:
      {CLIENT_NAME}-{INVOICE_NUMBER}-{DATE}.pdf
  5. PDF downloads to
    ~/Downloads/
  6. Close the dialog (click
    Close
    or
    ×
    )
  1. 打开发票(从Income列表点击,或创建后导航至发票页面)
  2. 点击
    Save and send
    按钮(右上角,蓝绿色按钮)
  3. 弹出**“Email invoice”**对话框,包含:
    • 收件人字段(邮箱)
    • 主题(自动填充)
    • 消息文本框
    • 底部的附件区域,显示PDF文件名
  4. 点击PDF链接(例如:
    ALL3 DOO BELGRADE-2025-03-21-20260506.pdf
    • 这是一个
      generic
      元素,带有
      cursor:pointer
      onclick
      属性
    • 文本匹配模式:
      {CLIENT_NAME}-{INVOICE_NUMBER}-{DATE}.pdf
  5. PDF下载至
    ~/Downloads/
    目录
  6. 关闭对话框(点击
    Close
    ×

Email sending (paid plan)

邮件发送(付费计划)

On paid plans, the "Email invoice" dialog is fully functional:
  1. Fill
    To
    field with client email (
    @e49
    )
  2. Edit
    Subject
    if needed (auto-filled as "Gleb Kalinin sent you an invoice (#INVOICE-NUMBER)")
  3. Write a
    Message
    in the textarea
  4. Toggle "Send a copy to my email" checkbox (checked by default)
  5. Click
    Email invoice
    button (
    @e15
    ) to send
On the free plan, the dialog shows "Sending invoices by email is not available in your plan" with a "Change my plan" link. The PDF download still works regardless.
付费计划下,“Email invoice”对话框功能完整:
  1. To
    字段填写客户邮箱(
    @e49
  2. 按需编辑
    Subject
    (自动填充为“Gleb Kalinin sent you an invoice (#INVOICE-NUMBER)”)
  3. 在文本框中撰写
    Message
  4. 切换“Send a copy to my email”复选框(默认已勾选)
  5. 点击
    Email invoice
    按钮(
    @e15
    )发送
免费计划下,对话框会显示“Sending invoices by email is not available in your plan”及“Change my plan”链接。无论如何,PDF下载功能仍可正常使用。

Fallback: Telegram delivery (free plan)

备用方案:Telegram发送(免费计划)

When email sending is unavailable, download the PDF and send via Telethon (see "Sending Invoice After Download" section below).
当邮件发送不可用时,下载PDF后通过Telethon发送(见下方“下载后发送发票”部分)。

PDF filename pattern

PDF文件名模式

{CLIENT_NAME}-{INVOICE_NUMBER}-{YYYYMMDD}.pdf
Example:
ALL3 DOO BELGRADE-2025-03-21-20260506.pdf
{CLIENT_NAME}-{INVOICE_NUMBER}-{YYYYMMDD}.pdf
示例:
ALL3 DOO BELGRADE-2025-03-21-20260506.pdf

Client Management

客户管理

Existing clients are stored and reusable. When creating an invoice:
  • The client picker shows all saved clients
  • Search by name in the search box
  • Edit/delete clients via small buttons next to each name
现有客户会被存储并可重复使用。创建发票时:
  • 客户选择器显示所有已保存的客户
  • 在搜索框中按名称搜索
  • 通过每个名称旁的小按钮编辑/删除客户

Client fields (Business)

客户字段(企业)

  • Business name (required)
  • VAT number / TIN (optional)
  • Street & Number
  • City
  • Zip Code
  • Country (autocomplete — type and click match)
  • Email
  • 企业名称(必填)
  • VAT编号/TIN(可选)
  • 街道及门牌号
  • 城市
  • 邮编
  • 国家(自动补全 — 输入后点击匹配项)
  • 电子邮件

Client fields (Private person)

客户字段(个人)

  • First name, Last name
  • Address fields same as business
  • 名、姓
  • 地址字段与企业客户相同

Sending Invoice After Download

下载后发送发票

After downloading the PDF, send via Telegram using Telethon:
python
from telethon.sync import TelegramClient
import json
from pathlib import Path

config = json.loads((Path.home() / '.telegram_dl' / 'config.json').read_text())
session = str(Path.home() / '.telegram_dl' / 'user')

with TelegramClient(session, config['api_id'], config['api_hash']) as client:
    client.send_file("username", "/path/to/invoice.pdf", caption="message")
下载PDF后,使用Telethon通过Telegram发送:
python
from telethon.sync import TelegramClient
import json
from pathlib import Path

config = json.loads((Path.home() / '.telegram_dl' / 'config.json').read_text())
session = str(Path.home() / '.telegram_dl' / 'user')

with TelegramClient(session, config['api_id'], config['api_hash']) as client:
    client.send_file("username", "/path/to/invoice.pdf", caption="message")

Gleb's Sorted Account Details

Gleb的Sorted账户详情

  • Status: Kleinunternehmer (no VAT charged)
  • Finanzamt: Berlin - Wedding
  • VAT-ID: DE369692682
  • Tax Number: 2337201265
  • Bank: Revolut Bank UAB, Zweigniederlassung
  • IBAN: DE38 1001 0178 8157 1777 30
  • BIC/SWIFT: REVODEB2
  • Plan: Free (invoicing works, tax submission requires upgrade)
  • 状态: Kleinunternehmer(无需收取VAT)
  • 税务局: Berlin - Wedding
  • VAT-ID: DE369692682
  • 税号: 2337201265
  • 银行: Revolut Bank UAB, Zweigniederlassung
  • IBAN: DE38 1001 0178 8157 1777 30
  • BIC/SWIFT: REVODEB2
  • 计划: 免费版(发票功能可用,税务提交需升级)

Browser Session Setup

浏览器会话设置

Always use the
/real-browser
skill's launch sequence. Session name should be unique per run:
bash
SESSION=$(LC_ALL=C tr -dc 'a-z0-9' < /dev/urandom | head -c 6)
agent-browser --cdp 9222 --session "$SESSION" open "https://app.getsorted.de/"
Google login is persisted — no need to re-authenticate each time.
请始终使用
/real-browser
技能的启动序列。每次运行的会话名称应唯一:
bash
SESSION=$(LC_ALL=C tr -dc 'a-z0-9' < /dev/urandom | head -c 6)
agent-browser --cdp 9222 --session "$SESSION" open "https://app.getsorted.de/"
Google登录状态已持久化 — 无需每次重新验证。