stripe-import

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Stripe Import

Stripe 导入

Overview

概述

Import transaction data from Stripe CSV exports into Open Accountant. Handles charges (revenue), Stripe processing fees, and refunds as separate line items. Payouts are skipped since they appear in your bank import and would cause double-counting.
将 Stripe CSV 导出文件中的交易数据导入 Open Accountant。将 charges(收入)、Stripe processing fees 和 refunds 作为独立的 line items 处理。由于 payouts 已出现在银行导入记录中,因此导入时会跳过 payouts,以免重复计数。

Wilson Tools Used

使用的 Wilson 工具

  • transaction_search
    — check for existing Stripe transactions to prevent duplicates
  • categorize
    — assign categories to imported Stripe transactions
  • export_transactions
    — export reconciled Stripe data
  • transaction_search
    — 检查是否已有 Stripe 交易,防止重复导入
  • categorize
    — 为导入的 Stripe 交易分配类别
  • export_transactions
    — 导出已完成对账的 Stripe 数据

Column Mapping

列映射

Stripe CSV ColumnOpen Accountant FieldNotes
id
reference_id
Stripe charge ID (ch_xxx)
Created (UTC)
date
Transaction date
Description
description
Customer-facing description
Amount
amount
Gross charge amount (positive = income)
Fee
amount
(separate row)
Stripe processing fee (negative = expense)
Net
—Calculated field, not stored directly
Currency
currency
3-letter ISO code
Status
—Only import
succeeded
charges
Customer Email
notes
Optional, stored in notes
Stripe CSV 列Open Accountant 字段备注
id
reference_id
Stripe charge ID(ch_xxx)
Created (UTC)
date
交易日期
Description
description
面向客户的描述
Amount
amount
Charge 总金额(正数 = 收入)
Fee
amount
(独立行)
Stripe processing fee(负数 = 支出)
Net
—计算字段,不直接存储
Currency
currency
3 位 ISO 代码
Status
—仅导入
succeeded
charges
Customer Email
notes
可选,存储在 notes 中

Workflow

工作流

  1. Ask the user for the Stripe CSV file path.
  2. Parse the CSV and validate expected Stripe column headers.
  3. Filter rows:
    • Import: rows where
      Type
      is
      charge
      and
      Status
      is
      succeeded
    • Import: rows where
      Type
      is
      refund
    • Skip: rows where
      Type
      is
      payout
      or
      transfer
      (these appear in bank imports)
    • Skip: rows where
      Status
      is
      failed
      or
      pending
  4. For each charge, create two transactions:
    • Revenue: positive amount from the
      Amount
      column, category "Revenue:Stripe"
    • Fee: negative amount from the
      Fee
      column, category "Fees:Payment Processing"
  5. For refunds, create a negative revenue transaction with category "Revenue:Refunds"
  6. Deduplicate using the Stripe charge ID (
    id
    column) as the reference.
  7. Preview the import summary: total charges, total fees, total refunds, net revenue.
  8. Insert transactions and confirm.
  1. 询问用户 Stripe CSV 文件的路径。
  2. 解析 CSV,并验证预期的 Stripe 列标题。
  3. 筛选行:
    • 导入:
      Type
      为
      charge
      且
      Status
      为
      succeeded
      的行
    • 导入:
      Type
      为
      refund
      的行
    • 跳过:
      Type
      为
      payout
      或
      transfer
      的行(这些记录会出现在银行导入中)
    • 跳过:
      Status
      为
      failed
      或
      pending
      的行
  4. 为每条 charge 创建两笔交易:
    • 收入:取自
      Amount
      列的正数金额,类别为 "Revenue:Stripe"
    • 费用:取自
      Fee
      列的负数金额,类别为 "Fees:Payment Processing"
  5. 为 refunds 创建一笔负数收入交易,类别为 "Revenue:Refunds"
  6. 使用 Stripe charge ID(
    id
    列)作为 reference 进行去重。
  7. 预览导入摘要:charges 总数、fees 总数、refunds 总数和净收入。
  8. 插入交易并进行确认。

Without Wilson

不使用 Wilson

To work with Stripe exports manually:
如需手动处理 Stripe 导出文件:

Downloading from Stripe

从 Stripe 下载

  1. Log in to dashboard.stripe.com
  2. Go to Payments (left sidebar)
  3. Click Export (top right of the payments list)
  4. Select date range and columns:
    • Recommended:
      id
      ,
      Created (UTC)
      ,
      Description
      ,
      Amount
      ,
      Fee
      ,
      Net
      ,
      Currency
      ,
      Status
      ,
      Type
      ,
      Customer Email
  5. Choose CSV format and download
  1. 登录 dashboard.stripe.com
  2. 进入 Payments(左侧边栏)
  3. 点击 Export(付款列表右上角)
  4. 选择日期范围和列:
    • 推荐使用:
      id
      、
      Created (UTC)
      、
      Description
      、
      Amount
      、
      Fee
      、
      Net
      、
      Currency
      、
      Status
      、
      Type
      、
      Customer Email
  5. 选择 CSV 格式并下载

Manual Processing in a Spreadsheet

在电子表格中手动处理

  1. Open the CSV in Google Sheets or Excel.
  2. Filter out non-succeeded: Data > Filter > Status column > select only "succeeded"
  3. Remove payouts: Filter Type column > deselect "payout" and "transfer"
  4. Create revenue rows:
    • Column for category: set to "Revenue:Stripe" for all charge rows
    • Amount column already has the gross charge amount
  5. Create fee rows: Add rows for each charge with:
    • Same date
    • Description: "Stripe fee — [original description]"
    • Amount: negative value from the Fee column (e.g., if Fee = 2.90, enter -2.90)
    • Category: "Fees:Payment Processing"
  6. Handle refunds: Refund rows should have negative amounts in the Amount column. Set category to "Revenue:Refunds"
  7. Summary formulas:
    Gross Revenue:    =SUMIFS(Amount, Type, "charge", Status, "succeeded")
    Total Fees:       =SUMIFS(Fee, Type, "charge", Status, "succeeded")
    Total Refunds:    =ABS(SUMIFS(Amount, Type, "refund"))
    Net Revenue:      =GrossRevenue - TotalFees - TotalRefunds
    Effective Rate:   =TotalFees / GrossRevenue * 100
  8. Reconcile with bank: Your bank payout amounts should equal the sum of
    Net
    column values between payout dates.
  1. 在 Google Sheets 或 Excel 中打开 CSV。
  2. 过滤掉非 succeeded 记录:Data > Filter > Status 列 > 仅选择 "succeeded"
  3. 移除 payouts:在 Type 列中筛选,取消选择 "payout" 和 "transfer"
  4. 创建收入行:
    • 类别列:对所有 charge 行设置为 "Revenue:Stripe"
    • Amount 列中已是 charge 总金额
  5. 创建费用行:为每条 charge 添加一行,其中包含:
    • 相同日期
    • Description:"Stripe fee — [original description]"
    • Amount:Fee 列中的负值(例如,如果 Fee = 2.90,则输入 -2.90)
    • Category:"Fees:Payment Processing"
  6. 处理 refunds:refund 行的 Amount 应为负数。将类别设置为 "Revenue:Refunds"
  7. 汇总公式:
    Gross Revenue:    =SUMIFS(Amount, Type, "charge", Status, "succeeded")
    Total Fees:       =SUMIFS(Fee, Type, "charge", Status, "succeeded")
    Total Refunds:    =ABS(SUMIFS(Amount, Type, "refund"))
    Net Revenue:      =GrossRevenue - TotalFees - TotalRefunds
    Effective Rate:   =TotalFees / GrossRevenue * 100
  8. 与银行对账:你的银行 payout 金额应等于 payout 日期之间
    Net
    列值之和。

Important Notes

重要说明

  • Stripe amounts are in the smallest currency unit in the API but in standard units in CSV exports (e.g., $10.00, not 1000).
  • Multi-currency: if you accept payments in multiple currencies, each currency is imported with its original amount. Wilson does not perform currency conversion.
  • Stripe fee percentage is typically 2.9% + $0.30 per transaction but varies by plan. The actual fee is in the CSV.
  • Do not import payouts. Payouts are the transfer from Stripe to your bank account. These appear in your bank statement import and importing them from Stripe would double-count the money.
  • Connect/platform charges: if you use Stripe Connect, application fees appear as separate line items. Import these under "Fees:Platform" if applicable.
  • 在 API 中,Stripe 金额使用货币的最小单位,但在 CSV 导出文件中使用标准单位(例如 $10.00,而不是 1000)。
  • 多币种:如果接受多种货币付款,每种货币都会按原始金额导入。Wilson 不执行货币换算。
  • Stripe 费率通常为每笔交易 2.9% + $0.30,但会因套餐而异。实际费用以 CSV 中的数据为准。
  • 不要导入 payouts。 Payouts 是 Stripe 向你的银行账户进行的转账。这些记录会出现在银行对账单导入中;如果再从 Stripe 导入,会导致金额重复计算。
  • Connect/platform charges:如果使用 Stripe Connect,application fees 会显示为独立的 line items。如适用,请将这些费用导入到 "Fees:Platform" 类别下。