{"action":"created","comment":{"url":"https://api.github.com/repos/solidusio/solidus/pulls/comments/89157792","pull_request_review_id":9704473,"id":89157792,"diff_hunk":"@@ -0,0 +1,127 @@\n+# Pricing and Taxation\n+\n+Taxation and prices are two intertwined topics in Solidus, mainly because a large number of jurisdictions in the world use VAT-style taxation, which influences the price at which an item is sold.\n+\n+## Taxation\n+\n+Solidus represents taxes for an order's items by using `Spree::TaxCategory` and `Spree::TaxRate`.\n+\n+Tax rates are associated with a tax category and a zone. If an order's `tax_address` (usually the shipping address) falls within a zone with tax rates, those rates will apply to all line items and shipments with respectively matching tax categories.\n+\n+When a tax rate gets applied to a line item, two things happen: A tax adjustment is created on the line item, and the line item's `additional_tax_total` and `included_tax_total` are changed to reflect the newly created adjustments. The amounts are then added to the order's `*_tax_total` fields.\n+\n+### Tax Categories\n+\n+Products within Solidus can be linked to Tax Categories, which are then used find the taxation rate for the products when they are purchased. One Tax Category can be set to being the default for the entire system, which means that if a product doesn't have a tax category set, then the default tax category would be used.\n+\n+The Solidus default is to treat everything as exempt from tax. Only if a product has a tax category set, or there is a global default tax category, will products be taxed. The tax category is specific to taxation, and is normally never seen by the user so you could call it something generic like \"Taxable Goods.\" If you wish to tax certain products at different rates, however, then you will want to choose something more descriptive (ex. \"Clothing.\").\n+\n+### Tax Rates\n+\n+A tax rate is essentially a percentage amount charged based on the net price. Tax rates also contain other important information.\n+\n+* Whether product prices are inclusive of this tax\n+* The zone within which the order address must fall\n+* The tax category that a product must belong to in order to be considered taxable.\n+\n+Solidus will calculate tax based on all matching tax rates for the order's tax address. It's also possible to have more than one applicable tax rate for a single zone. In order for a tax rate to apply to a particular product, that product must have a tax category that matches the tax category of the tax rate.\n+\n+***\n+To best appreciate how Solidus' taxation system works, have a look at the [taxation integration specs](https://github.com/solidusio/solidus/blob/master/core/spec/models/spree/tax/taxation_integration_spec.rb).\n+***\n+### Sales tax vs. Value-Added Tax\n+\n+In e-Commerce, the type of tax we care most about is consumption tax, of which two main models are found: Sales Tax and Value Added Tax (VAT).\n+\n+The Sales tax policies found in the USA are *additional* taxes. They do not change the amount of a line item, but are added just before calculating the order total. For Sales tax, the prices for items do not change when adding them to an order.\n+\n+With Value-Added Tax (VAT), as found in Europe, but also in many other parts of the world, the prices of products and line items need to be shown *including* the consumption tax. When a product is exported, the price of that product has to change: It will be lower, because there is no included tax anymore.\n+\n+***\n+Most taxes can be considered one of these two types. For instance, in Australia customers pay a Goods and Services Tax (GST). This is basically equivalent to VAT in Europe.","path":"guides/pricing_and_taxation.md","position":41,"original_position":41,"commit_id":"f4178a7e534b96afd4a9c2f32ab61aac2c577f8e","original_commit_id":"f4178a7e534b96afd4a9c2f32ab61aac2c577f8e","user":{"login":"bbuchalter","id":540762,"avatar_url":"https://avatars.githubusercontent.com/u/540762?v=3","gravatar_id":"","url":"https://api.github.com/users/bbuchalter","html_url":"https://github.com/bbuchalter","followers_url":"https://api.github.com/users/bbuchalter/followers","following_url":"https://api.github.com/users/bbuchalter/following{/other_user}","gists_url":"https://api.github.com/users/bbuchalter/gists{/gist_id}","starred_url":"https://api.github.com/users/bbuchalter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbuchalter/subscriptions","organizations_url":"https://api.github.com/users/bbuchalter/orgs","repos_url":"https://api.github.com/users/bbuchalter/repos","events_url":"https://api.github.com/users/bbuchalter/events{/privacy}","received_events_url":"https://api.github.com/users/bbuchalter/received_events","type":"User","site_admin":false},"body":"We probably shouldn't be giving out tax advice:\r\n> For instance, in Australia customers pay a Goods and Services Tax (GST). This is basically equivalent to VAT in Europe.","created_at":"2016-11-22T16:42:35Z","updated_at":"2016-11-22T16:52:36Z","html_url":"https://github.com/solidusio/solidus/pull/1606#discussion_r89157792","pull_request_url":"https://api.github.com/repos/solidusio/solidus/pulls/1606","_links":{"self":{"href":"https://api.github.com/repos/solidusio/solidus/pulls/comments/89157792"},"html":{"href":"https://github.com/solidusio/solidus/pull/1606#discussion_r89157792"},"pull_request":{"href":"https://api.github.com/repos/solidusio/solidus/pulls/1606"}}},"pull_request":{"url":"https://api.github.com/repos/solidusio/solidus/pulls/1606","id":94845002,"html_url":"https://github.com/solidusio/solidus/pull/1606","diff_url":"https://github.com/solidusio/solidus/pull/1606.diff","patch_url":"https://github.com/solidusio/solidus/pull/1606.patch","issue_url":"https://api.github.com/repos/solidusio/solidus/issues/1606","number":1606,"state":"open","locked":false,"title":"Add taxation guide","user":{"login":"mamhoff","id":703401,"avatar_url":"https://avatars.githubusercontent.com/u/703401?v=3","gravatar_id":"","url":"https://api.github.com/users/mamhoff","html_url":"https://github.com/mamhoff","followers_url":"https://api.github.com/users/mamhoff/followers","following_url":"https://api.github.com/users/mamhoff/following{/other_user}","gists_url":"https://api.github.com/users/mamhoff/gists{/gist_id}","starred_url":"https://api.github.com/users/mamhoff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mamhoff/subscriptions","organizations_url":"https://api.github.com/users/mamhoff/orgs","repos_url":"https://api.github.com/users/mamhoff/repos","events_url":"https://api.github.com/users/mamhoff/events{/privacy}","received_events_url":"https://api.github.com/users/mamhoff/received_events","type":"User","site_admin":false},"body":"This adds a guide for pricing and taxation, two related and difficult to grasp areas. It should be merged after https://github.com/solidusio/solidus/pull/1598. \r\n","created_at":"2016-11-22T16:11:38Z","updated_at":"2016-11-22T16:52:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"904ed0c6157a99d9080e6d43bc9f04f352b8e697","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/solidusio/solidus/pulls/1606/commits","review_comments_url":"https://api.github.com/repos/solidusio/solidus/pulls/1606/comments","review_comment_url":"https://api.github.com/repos/solidusio/solidus/pulls/comments{/number}","comments_url":"https://api.github.com/repos/solidusio/solidus/issues/1606/comments","statuses_url":"https://api.github.com/repos/solidusio/solidus/statuses/f4178a7e534b96afd4a9c2f32ab61aac2c577f8e","head":{"label":"mamhoff:add-taxation-guide","ref":"add-taxation-guide","sha":"f4178a7e534b96afd4a9c2f32ab61aac2c577f8e","user":{"login":"mamhoff","id":703401,"avatar_url":"https://avatars.githubusercontent.com/u/703401?v=3","gravatar_id":"","url":"https://api.github.com/users/mamhoff","html_url":"https://github.com/mamhoff","followers_url":"https://api.github.com/users/mamhoff/followers","following_url":"https://api.github.com/users/mamhoff/following{/other_user}","gists_url":"https://api.github.com/users/mamhoff/gists{/gist_id}","starred_url":"https://api.github.com/users/mamhoff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mamhoff/subscriptions","organizations_url":"https://api.github.com/users/mamhoff/orgs","repos_url":"https://api.github.com/users/mamhoff/repos","events_url":"https://api.github.com/users/mamhoff/events{/privacy}","received_events_url":"https://api.github.com/users/mamhoff/received_events","type":"User","site_admin":false},"repo":{"id":53340856,"name":"solidus","full_name":"mamhoff/solidus","owner":{"login":"mamhoff","id":703401,"avatar_url":"https://avatars.githubusercontent.com/u/703401?v=3","gravatar_id":"","url":"https://api.github.com/users/mamhoff","html_url":"https://github.com/mamhoff","followers_url":"https://api.github.com/users/mamhoff/followers","following_url":"https://api.github.com/users/mamhoff/following{/other_user}","gists_url":"https://api.github.com/users/mamhoff/gists{/gist_id}","starred_url":"https://api.github.com/users/mamhoff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mamhoff/subscriptions","organizations_url":"https://api.github.com/users/mamhoff/orgs","repos_url":"https://api.github.com/users/mamhoff/repos","events_url":"https://api.github.com/users/mamhoff/events{/privacy}","received_events_url":"https://api.github.com/users/mamhoff/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mamhoff/solidus","description":"Solidus, Rails eCommerce System","fork":true,"url":"https://api.github.com/repos/mamhoff/solidus","forks_url":"https://api.github.com/repos/mamhoff/solidus/forks","keys_url":"https://api.github.com/repos/mamhoff/solidus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mamhoff/solidus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mamhoff/solidus/teams","hooks_url":"https://api.github.com/repos/mamhoff/solidus/hooks","issue_events_url":"https://api.github.com/repos/mamhoff/solidus/issues/events{/number}","events_url":"https://api.github.com/repos/mamhoff/solidus/events","assignees_url":"https://api.github.com/repos/mamhoff/solidus/assignees{/user}","branches_url":"https://api.github.com/repos/mamhoff/solidus/branches{/branch}","tags_url":"https://api.github.com/repos/mamhoff/solidus/tags","blobs_url":"https://api.github.com/repos/mamhoff/solidus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mamhoff/solidus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mamhoff/solidus/git/refs{/sha}","trees_url":"https://api.github.com/repos/mamhoff/solidus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mamhoff/solidus/statuses/{sha}","languages_url":"https://api.github.com/repos/mamhoff/solidus/languages","stargazers_url":"https://api.github.com/repos/mamhoff/solidus/stargazers","contributors_url":"https://api.github.com/repos/mamhoff/solidus/contributors","subscribers_url":"https://api.github.com/repos/mamhoff/solidus/subscribers","subscription_url":"https://api.github.com/repos/mamhoff/solidus/subscription","commits_url":"https://api.github.com/repos/mamhoff/solidus/commits{/sha}","git_commits_url":"https://api.github.com/repos/mamhoff/solidus/git/commits{/sha}","comments_url":"https://api.github.com/repos/mamhoff/solidus/comments{/number}","issue_comment_url":"https://api.github.com/repos/mamhoff/solidus/issues/comments{/number}","contents_url":"https://api.github.com/repos/mamhoff/solidus/contents/{+path}","compare_url":"https://api.github.com/repos/mamhoff/solidus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mamhoff/solidus/merges","archive_url":"https://api.github.com/repos/mamhoff/solidus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mamhoff/solidus/downloads","issues_url":"https://api.github.com/repos/mamhoff/solidus/issues{/number}","pulls_url":"https://api.github.com/repos/mamhoff/solidus/pulls{/number}","milestones_url":"https://api.github.com/repos/mamhoff/solidus/milestones{/number}","notifications_url":"https://api.github.com/repos/mamhoff/solidus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mamhoff/solidus/labels{/name}","releases_url":"https://api.github.com/repos/mamhoff/solidus/releases{/id}","deployments_url":"https://api.github.com/repos/mamhoff/solidus/deployments","created_at":"2016-03-07T16:34:34Z","updated_at":"2016-03-07T16:34:40Z","pushed_at":"2016-11-22T16:16:46Z","git_url":"git://github.com/mamhoff/solidus.git","ssh_url":"git@github.com:mamhoff/solidus.git","clone_url":"https://github.com/mamhoff/solidus.git","svn_url":"https://github.com/mamhoff/solidus","homepage":"http://solidus.io/","size":64540,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"solidusio:master","ref":"master","sha":"cd5ca0167013d9bc03555ca170b02db19a5d6ffa","user":{"login":"solidusio","id":11045486,"avatar_url":"https://avatars.githubusercontent.com/u/11045486?v=3","gravatar_id":"","url":"https://api.github.com/users/solidusio","html_url":"https://github.com/solidusio","followers_url":"https://api.github.com/users/solidusio/followers","following_url":"https://api.github.com/users/solidusio/following{/other_user}","gists_url":"https://api.github.com/users/solidusio/gists{/gist_id}","starred_url":"https://api.github.com/users/solidusio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/solidusio/subscriptions","organizations_url":"https://api.github.com/users/solidusio/orgs","repos_url":"https://api.github.com/users/solidusio/repos","events_url":"https://api.github.com/users/solidusio/events{/privacy}","received_events_url":"https://api.github.com/users/solidusio/received_events","type":"Organization","site_admin":false},"repo":{"id":30985840,"name":"solidus","full_name":"solidusio/solidus","owner":{"login":"solidusio","id":11045486,"avatar_url":"https://avatars.githubusercontent.com/u/11045486?v=3","gravatar_id":"","url":"https://api.github.com/users/solidusio","html_url":"https://github.com/solidusio","followers_url":"https://api.github.com/users/solidusio/followers","following_url":"https://api.github.com/users/solidusio/following{/other_user}","gists_url":"https://api.github.com/users/solidusio/gists{/gist_id}","starred_url":"https://api.github.com/users/solidusio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/solidusio/subscriptions","organizations_url":"https://api.github.com/users/solidusio/orgs","repos_url":"https://api.github.com/users/solidusio/repos","events_url":"https://api.github.com/users/solidusio/events{/privacy}","received_events_url":"https://api.github.com/users/solidusio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/solidusio/solidus","description":"Solidus, Rails eCommerce System","fork":false,"url":"https://api.github.com/repos/solidusio/solidus","forks_url":"https://api.github.com/repos/solidusio/solidus/forks","keys_url":"https://api.github.com/repos/solidusio/solidus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/solidusio/solidus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/solidusio/solidus/teams","hooks_url":"https://api.github.com/repos/solidusio/solidus/hooks","issue_events_url":"https://api.github.com/repos/solidusio/solidus/issues/events{/number}","events_url":"https://api.github.com/repos/solidusio/solidus/events","assignees_url":"https://api.github.com/repos/solidusio/solidus/assignees{/user}","branches_url":"https://api.github.com/repos/solidusio/solidus/branches{/branch}","tags_url":"https://api.github.com/repos/solidusio/solidus/tags","blobs_url":"https://api.github.com/repos/solidusio/solidus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/solidusio/solidus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/solidusio/solidus/git/refs{/sha}","trees_url":"https://api.github.com/repos/solidusio/solidus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/solidusio/solidus/statuses/{sha}","languages_url":"https://api.github.com/repos/solidusio/solidus/languages","stargazers_url":"https://api.github.com/repos/solidusio/solidus/stargazers","contributors_url":"https://api.github.com/repos/solidusio/solidus/contributors","subscribers_url":"https://api.github.com/repos/solidusio/solidus/subscribers","subscription_url":"https://api.github.com/repos/solidusio/solidus/subscription","commits_url":"https://api.github.com/repos/solidusio/solidus/commits{/sha}","git_commits_url":"https://api.github.com/repos/solidusio/solidus/git/commits{/sha}","comments_url":"https://api.github.com/repos/solidusio/solidus/comments{/number}","issue_comment_url":"https://api.github.com/repos/solidusio/solidus/issues/comments{/number}","contents_url":"https://api.github.com/repos/solidusio/solidus/contents/{+path}","compare_url":"https://api.github.com/repos/solidusio/solidus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/solidusio/solidus/merges","archive_url":"https://api.github.com/repos/solidusio/solidus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/solidusio/solidus/downloads","issues_url":"https://api.github.com/repos/solidusio/solidus/issues{/number}","pulls_url":"https://api.github.com/repos/solidusio/solidus/pulls{/number}","milestones_url":"https://api.github.com/repos/solidusio/solidus/milestones{/number}","notifications_url":"https://api.github.com/repos/solidusio/solidus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/solidusio/solidus/labels{/name}","releases_url":"https://api.github.com/repos/solidusio/solidus/releases{/id}","deployments_url":"https://api.github.com/repos/solidusio/solidus/deployments","created_at":"2015-02-18T20:41:58Z","updated_at":"2016-11-22T13:14:47Z","pushed_at":"2016-11-22T16:16:46Z","git_url":"git://github.com/solidusio/solidus.git","ssh_url":"git@github.com:solidusio/solidus.git","clone_url":"https://github.com/solidusio/solidus.git","svn_url":"https://github.com/solidusio/solidus","homepage":"https://solidus.io/","size":71674,"stargazers_count":1182,"watchers_count":1182,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":370,"mirror_url":null,"open_issues_count":188,"forks":370,"open_issues":188,"watchers":1182,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/solidusio/solidus/pulls/1606"},"html":{"href":"https://github.com/solidusio/solidus/pull/1606"},"issue":{"href":"https://api.github.com/repos/solidusio/solidus/issues/1606"},"comments":{"href":"https://api.github.com/repos/solidusio/solidus/issues/1606/comments"},"review_comments":{"href":"https://api.github.com/repos/solidusio/solidus/pulls/1606/comments"},"review_comment":{"href":"https://api.github.com/repos/solidusio/solidus/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/solidusio/solidus/pulls/1606/commits"},"statuses":{"href":"https://api.github.com/repos/solidusio/solidus/statuses/f4178a7e534b96afd4a9c2f32ab61aac2c577f8e"}}}}
{"actor":{"display_login":"bbuchalter"}}