Repository navigation
docs(agent-launch): add tax setup step (ENG-2405) - #176
Conversation
Otto SummaryVerdict: ✅ Approved This is a docs-only change that adds a Tax subsection to Step 4, plus matching rows in "What to have ready" and in the merchant table. All five API reference links match operations in the specs: FindingsNo new findings. Tip Merge confidence: 5/5 — Docs-only change whose links and API field names match the specs in the repo. Confidence trend (oldest → newest): 5/5 → 5/5 → 5/5 → 5/5 |
There was a problem hiding this comment.
Otto reviewed 98cfb4b. 1 new inline finding.
Tip
Merge confidence: 5/5 — Docs-only change: the links resolve to existing spec operations and the claims match the specs and the help page.
The full summary and review history are in Otto's pinned summary comment, updated on every review.
|
|
||
| - **Back-office credentials**, if the merchant has a back office to connect in Step 2. Each [Connect guide](/setup/overview) lists exactly which values its platform needs. | ||
| - **Payments documents** for Step 3: business registration, bank statements, ID for each owner, and financial statements. [Payments onboarding](/setup/payments-onboarding) has the full list. | ||
| - **Avalara credentials**, only if the merchant calculates tax on their own Avalara (AvaTax) account: the account ID, license key, and company code. Without them, Fluid calculates tax for the store ([Step 4](#tax)). |
There was a problem hiding this comment.
Map credential names to API fields
This uses the admin UI's labels (account ID, license key), but the PUT /api/settings/avalara_account body calls these fields username and password, next to company_code. Since this guide is for agents calling the API, a short parenthetical such as "(sent as username and password)" here or in step 1 of the Tax section would save a lookup.
Prompt To Fix With AI
This is a comment left during a code review.
Path: api/agent-launch.mdx
Line: 54
Severity: P3
Comment:
**Map credential names to API fields**
This uses the admin UI's labels (account ID, license key), but the `PUT /api/settings/avalara_account` body calls these fields `username` and `password`, next to `company_code`. Since this guide is for agents calling the API, a short parenthetical such as "(sent as `username` and `password`)" here or in step 1 of the Tax section would save a lookup.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.
Note: If this feedback doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
There was a problem hiding this comment.
Fixed. Step 1 of the Tax section now maps account ID → username and license key → password.
|
The red |
There was a problem hiding this comment.
Otto reviewed fe42485. No new inline findings.
Tip
Merge confidence: 5/5 — Docs-only change: the claims have sources, the links resolve, and the earlier finding is fixed.
The full summary and review history are in Otto's pinned summary comment, updated on every review.
cwcarlson10
left a comment
There was a problem hiding this comment.
Approving. I checked each claim in the new Tax section against the app, and they hold: a new store defaults to Fluid's tax calculation, the first Avalara environment saved becomes the active one, the Avalara mode is refused until an environment is active, switching the mode clears each country's tax strategy, and commits are US and Canada only. The call order is right too.
One suggestion on step 2. Its reason is a little off. The mode switch clears the tax strategy, but it doesn't touch the fields step 3 sets. The real reason to switch first is that Fluid refuses to turn on commits until the country's tax mode is Avalara. Saying that tells an agent why a step 3 call fails if it runs out of order. I also left a small nit about the company code. Neither one blocks the merge.
The red validate check is the TikTok link and the admin page map from main. #175 fixes both, as you said.
| If the merchant calculates tax on their own Avalara (AvaTax) account, connect it over the API in this order: | ||
|
|
||
| 1. Save the credentials with [Create or update a merchant Avalara account slot](/api-reference/taxes/create-or-update-a-merchant-avalara-account-slot): the account ID as `username`, the license key as `password`, the `company_code`, and the `environment` (`sandbox` or `production`). Then check them with [Test a merchant Avalara connection](/api-reference/taxes/test-a-merchant-avalara-connection). The first environment you save becomes the active one, and Fluid refuses the Avalara tax mode until one is active. | ||
| 2. Switch the company to Avalara with [Set the tax class for a company](/api-reference/companies/set-the-tax-class-for-a-company). This clears each country's tax strategy, so do it before step 3. |
There was a problem hiding this comment.
The mode switch clears each country's tax strategy, but it leaves the commit and company code settings alone, so that isn't why step 3 has to wait. The reason is that Fluid refuses to turn on Commit transactions to Avalara until the country's tax mode is Avalara. Suggested wording: "Switch the company to Avalara with Set the tax class for a company. Fluid turns on commits only for a country that uses Avalara, so do this before step 3. The switch also clears each country's tax strategy."
There was a problem hiding this comment.
Done in 91755c9, with your wording.
|
|
||
| - **Back-office credentials**, if the merchant has a back office to connect in Step 2. Each [Connect guide](/setup/overview) lists exactly which values its platform needs. | ||
| - **Payments documents** for Step 3: business registration, bank statements, ID for each owner, and financial statements. [Payments onboarding](/setup/payments-onboarding) has the full list. | ||
| - **Avalara credentials**, only if the merchant calculates tax on their own Avalara (AvaTax) account: the account ID, license key, and company code. Without them, Fluid calculates tax for the store ([Step 4](#tax)). |
There was a problem hiding this comment.
Nit: this reads as if all three values are required. The API saves the slot without a company code, and the help page says the code is needed only to commit transactions. Maybe: "the account ID and license key, plus the company code if they commit transactions to Avalara."
There was a problem hiding this comment.
Done in 91755c9. Step 1 said the same thing, so I fixed it there too.
There was a problem hiding this comment.
Otto reviewed 91755c9. No new inline findings.
Tip
Merge confidence: 5/5 — The change is docs-only, its claims are sourced, the links are checked and the earlier finding is fixed.
The full summary and review history are in Otto's pinned summary comment, updated on every review.
There was a problem hiding this comment.
Otto reviewed 99bf5df. No new inline findings.
Tip
Merge confidence: 5/5 — Docs-only change whose links and API field names match the specs in the repo.
The full summary and review history are in Otto's pinned summary comment, updated on every review.
Summary
Part of ENG-2405
Where each claim comes from
main)Company#tax_classdefaults tofluid(company.rb:236). A new country's strategy defaults to the first option, which is Fluid's own calculation (company_country.rb:133, 387-400). Signup doesn't change either. The onboarding checklist counts tax as set up (onboarding_service.rb:137)PUT /api/settings/avalara_accountdescription insettings-v0.yamlcompany.rb:1070set_tax_class_action.rb:19company_country.rb:473-507; help page §Country tax settingsChecks
eval/check-guide-claims.mjsandeval/check-advertised-docs-links.mjspass locally.eval/check-broken-links.mjsresolves every new link. It still fails on one link insetup/sales-channel-tiktok.mdx, which this PR doesn't touch, and that failure is already onmainat0115979.mint validatewas not run locally.agent-launch.mdxisn't in the claims registry, so there is no registry change.