# Purchase transactions

Source: https://developer.avalara.com/services-calculation-en/transactions/purchase/

# Purchase transactions

#### Service purchase with deductions

**Contractor City** 

Rio de Janeiro - RJ

**Taker From**

São Paulo - SP

**Place where the service is taken**

São Paulo - SP

**Payload request**

```
{    "header": {        "messageType": "services",        "transactionDate": "2021-05-26",        "amountCalcType": "gross",        "documentCode": "CompraServicoscomDeducaoINSS",        "eDocCreatorType": "self",        "eDocCreatorPerspective": true,        "companyLocation": "14528925000114",        "operationType": "Purchase",        "locations": {            "establishment": {                "activitySector": {                    "type": "activityLine",                    "code": "industry"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": false,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T"                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityCode": "",                    "cityName": "Rio de Janeiro"                }            },            "entity": {                "activitySector": {                    "type": "activityLine",                    "code": "service"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T"                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": "",                    "cityName": "São Paulo"                }            },            "rendered": {                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": "",                    "cityName": "São Paulo"                }            }        },        "payment": {            "installmentTerms": 0,            "bill": {                "nFat": "123456789",                "vOrig": 50000,                "vDiscount": 0,                "vNet": 50000            }        },        "additionalInfo": {            "complementaryInfo": "Teste"        }    },    "lines": [        {            "lineCode": 1,            "itemCode": 1,            "useType": "production",            "numberOfItems": 1,            "itemDescription": "Telemarketing",            "lineAmount": 50000,            "lineUnitPrice": 50000,            "taxDeductions":{                "inssBasisDiscount":1000            },            "itemDescriptor": {                "hsCode": "4.15",                "serviceCode": "05100",                "serviceCodeOrigin": "05100",                "subjectToIRRFAuto": false,                "withLaborAssignment": true            },            "services": {                "hasCpom": false            }        }    ]}
```

**Payload response**

```
{    "header": {        "messageType": "services",        "transactionDate": "2021-05-26",        "amountCalcType": "gross",        "documentCode": "CompraServicoscomDeducaoINSS",        "eDocCreatorType": "self",        "eDocCreatorPerspective": true,        "companyLocation": "14528925000114",        "operationType": "Purchase",        "locations": {            "establishment": {                "activitySector": {                    "type": "activityLine",                    "code": "industry"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": false,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T",                    "enableCprb": false,                    "usesInssCprbToGrossValue": false,                    "pisCofinsIcmsTaxRelief": false,                    "subjectWithholdingIrrf": true,                    "subjectWithholdingInss": true,                    "subjectWithholdingIss": true                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityCode": 3304557,                    "cityName": "Rio de Janeiro",                    "countryCode": "0",                    "country": "BRA",                    "state": "RJ"                }            },            "entity": {                "activitySector": {                    "type": "activityLine",                    "code": "service"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T",                    "enableCprb": false,                    "usesInssCprbToGrossValue": false,                    "pisCofinsIcmsTaxRelief": false,                    "subjectWithholdingIrrf": true,                    "subjectToSRF1234": false,                    "subjectWithholdingIss": false,                    "subjectWithholdingInss": true                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": 3550308,                    "cityName": "São Paulo",                    "countryCode": "0",                    "country": "BRA",                    "state": "SP"                },                "federalTaxId": ""            },            "rendered": {                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": 3550308,                    "cityName": "São Paulo",                    "countryCode": "0",                    "country": "BRA",                    "state": "SP"                },                "federalTaxId": ""            }        },        "payment": {            "installmentTerms": 0,            "bill": {                "nFat": "123456789",                "vOrig": 50000,                "vDiscount": 0,                "vNet": 50000            },            "installment": [                {                    "documentNumber": "1",                    "date": "2021-05-26",                    "grossValue": 50000,                    "withholdingPIS": 325,                    "withholdingCOFINS": 1500,                    "withholdingCSLL": 500,                    "withholdingMode": "PCC",                    "netValue": 41535                }            ],            "withholdingMode": "PCC"        },        "additionalInfo": {            "complementaryInfo": "Teste"        },        "rpsSerie": "0",        "accountId": "bdf71245-1288-4883-95a5-3a7530ea31af",        "subscriptionId": "9fe9c37a-1da8-4b8e-9d1b-21207b21e9f9",        "services": {}    },    "lines": [        {            "lineCode": 1,            "itemCode": "1",            "useType": "production",            "numberOfItems": 1,            "itemDescription": "Telemarketing",            "lineAmount": 50000,            "lineUnitPrice": 50000,            "taxDeductions": {                "iss": 0,                "inssBasisDiscount": 1000            },            "itemDescriptor": {                "hsCode": "4.15",                "serviceCode": "05100",                "serviceCodeOrigin": "05100",                "subjectToIRRFAuto": false,                "withLaborAssignment": true,                "cnae": "0",                "issBehavior": "normal"            },            "services": {                "hasCpom": false            },            "overwrite": "no",            "benefitsAbroad": false,            "operationType": "Purchase",            "cfop": 1933,            "taxDetails": [                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "asset"                    },                    "taxType": "cofins",                    "citation": "Lei nº 10.833/2003, Artigos 1º e 2º",                    "citationId": "b1fcf7f0-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 50000,                    "rate": 7.6,                    "tax": 3800,                    "exemptionCode": "",                    "cst": "50",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "cofinsRf",                    "citation": "Lei nº 10.833/2003, Artigos 30 e 31, Instrução Normativa nº 459/2004, Artigo 2º c/c Instrução Normativa nº 459/2004, Artigo 1º, Parágrafo 2º, Inciso IV",                    "citationId": "a81199d0-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 50000,                    "rate": 3,                    "tax": 1500,                    "exemptionCode": "",                    "cst": "50",                    "collectionCode": "5952",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "csllRf",                    "citation": "Lei nº 10.833/2003, Artigos 30 e 31, Instrução Normativa nº 459/2004, Artigo 2º c/c Artigo 1º, Parágrafo 2º, Inciso IV",                    "citationId": "a787f770-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 50000,                    "rate": 1,                    "tax": 500,                    "exemptionCode": "",                    "cst": "51",                    "collectionCode": "5952",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "inssAr",                    "subtotalTaxable": 50000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "001"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "inssRf",                    "citation": "Decreto nº 3.048/1999, Artigo 219, §2º, Inciso XXIV,  Instrução Normativa nº 971/2009, Artigo 118, Inciso XXIII, Solução de consulta Cosit nº 72/2014",                    "citationId": "afc77a50-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 49000,                    "rate": 11,                    "tax": 5390,                    "exemptionCode": "",                    "collectionCode": "2631",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "irrf",                    "citation": "Decreto nº 9580/2018, Artigo 714, parágrafo 1º, Inciso XXXII",                    "citationId": "af77aca0-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 50000,                    "rate": 1.5,                    "tax": 750,                    "exemptionCode": "",                    "traceCode": "102",                    "cst": "01",                    "collectionCode": "1708",                    "isCustomCitation": false                },                {                    "jurisdictionName": "SÃO PAULO",                    "jurisdictionType": "City",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "none"                    },                    "taxType": "iss",                    "citation": "Decreto nº 53.151/2012, Artigo 18, Inciso I",                    "citationId": "bc70f0da-0476-4ccc-b4c6-b3d1a09b0e7e",                    "subtotalTaxable": 50000,                    "rate": 2,                    "tax": 1000,                    "exemptionCode": "",                    "cst": "01",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "asset"                    },                    "taxType": "pis",                    "citation": "Lei nº 10.637/2002, Artigos 1º e 2º",                    "citationId": "b2c66270-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 50000,                    "rate": 1.65,                    "tax": 825,                    "exemptionCode": "",                    "cst": "50",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "pisRf",                    "citation": "Lei nº 10.833/2003, Artigos 30 e 31, Instrução Normativa nº 459/2004, Artigo 2º c/c Artigo 1º, Parágrafo 2º, Inciso IV",                    "citationId": "a892b0b0-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 50000,                    "rate": 0.65,                    "tax": 325,                    "exemptionCode": "",                    "cst": "50",                    "collectionCode": "5952",                    "isCustomCitation": false                }            ],            "lineNetAmount": 41535,            "lineNetFigure": 35910        }    ],    "version": "3",    "processingInfo": {        "versionId": "21.11.3",        "duration": "9.021"    },    "summary": {        "numberOfLines": 1,        "totalLineAmounts": 50000,        "totalLineNetAmounts": 41535,        "totalTaxedDiscounts": 0,        "totalUntaxedDiscounts": 0,        "totalInsurances": 0,        "totalFreights": 0,        "totalOtherCosts": 0,        "taxByType": {            "cofins": {                "tax": 3800,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 3800                    }                ]            },            "cofinsRf": {                "tax": 1500,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 1500                    }                ]            },            "csllRf": {                "tax": 500,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 500                    }                ]            },            "inssAr": {                "tax": 0,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "inssRf": {                "tax": 5390,                "subtotalTaxable": 49000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 5390                    }                ]            },            "irrf": {                "tax": 750,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 750                    }                ]            },            "pis": {                "tax": 825,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 825                    }                ]            },            "iss": {                "tax": 1000,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "SÃO PAULO",                        "jurisdictionType": "City",                        "tax": 1000                    }                ]            },            "pisRf": {                "tax": 325,                "subtotalTaxable": 50000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 325                    }                ]            }        },        "taxImpactHighlights": {            "included": [                {                    "taxType": "cofins",                    "tax": 3800,                    "subtotalTaxable": 50000                },                {                    "taxType": "inssAr",                    "tax": 0,                    "subtotalTaxable": 50000                },                {                    "taxType": "iss",                    "tax": 1000,                    "subtotalTaxable": 50000                },                {                    "taxType": "pis",                    "tax": 825,                    "subtotalTaxable": 50000                }            ],            "added": [],            "subtracted": [],            "withheld": [                {                    "taxType": "cofinsRf",                    "tax": 1500,                    "subtotalTaxable": 50000                },                {                    "taxType": "csllRf",                    "tax": 500,                    "subtotalTaxable": 50000                },                {                    "taxType": "inssRf",                    "tax": 5390,                    "subtotalTaxable": 49000                },                {                    "taxType": "irrf",                    "tax": 750,                    "subtotalTaxable": 50000                },                {                    "taxType": "pisRf",                    "tax": 325,                    "subtotalTaxable": 50000                }            ],            "informative": []        }    },    "input": {        "header": {            "messageType": "services",            "transactionDate": "2021-05-26",            "amountCalcType": "gross",            "documentCode": "CompraServicoscomDeducaoINSS",            "eDocCreatorType": "self",            "eDocCreatorPerspective": true,            "companyLocation": "14528925000114",            "operationType": "Purchase",            "locations": {                "establishment": {                    "activitySector": {                        "type": "activityLine",                        "code": "industry"                    },                    "taxesSettings": {                        "issRfRateForSimplesTaxRegime": 0,                        "pCredSN": 0,                        "subjectToPayrollTaxRelief": false,                        "subjectWithholdingPis": true,                        "subjectWithholdingCofins": true,                        "subjectWithholdingCsll": true,                        "cofinsSubjectTo": "T",                        "pisSubjectTo": "T",                        "csllSubjectTo": "T",                        "enableCprb": false,                        "usesInssCprbToGrossValue": false,                        "pisCofinsIcmsTaxRelief": false                    },                    "taxRegime": "realProfit",                    "type": "business",                    "address": {                        "neighborhood": "Centro",                        "zipcode": "20020-030",                        "cityCode": 3304557,                        "cityName": "Rio de Janeiro",                        "countryCode": "0",                        "country": "BRA",                        "state": "RJ"                    }                },                "entity": {                    "activitySector": {                        "type": "activityLine",                        "code": "service"                    },                    "taxesSettings": {                        "issRfRateForSimplesTaxRegime": 0,                        "pCredSN": 0,                        "subjectToPayrollTaxRelief": true,                        "subjectWithholdingPis": true,                        "subjectWithholdingCofins": true,                        "subjectWithholdingCsll": true,                        "cofinsSubjectTo": "T",                        "pisSubjectTo": "T",                        "csllSubjectTo": "T",                        "enableCprb": false,                        "usesInssCprbToGrossValue": false,                        "pisCofinsIcmsTaxRelief": false                    },                    "taxRegime": "realProfit",                    "type": "business",                    "address": {                        "neighborhood": "Centro",                        "zipcode": "04710010",                        "cityCode": 3550308,                        "cityName": "São Paulo",                        "countryCode": "0",                        "country": "BRA",                        "state": "SP"                    },                    "federalTaxId": ""                },                "rendered": {                    "address": {                        "neighborhood": "Centro",                        "zipcode": "04710010",                        "cityCode": 3550308,                        "cityName": "São Paulo",                        "countryCode": "0",                        "country": "BRA",                        "state": "SP"                    },                    "federalTaxId": ""                }            },            "payment": {                "installmentTerms": 0,                "bill": {                    "nFat": "123456789",                    "vOrig": 50000,                    "vDiscount": 0,                    "vNet": 50000                }            },            "additionalInfo": {                "complementaryInfo": "Teste"            },            "rpsSerie": "0",            "accountId": "bdf71245-1288-4883-95a5-3a7530ea31af",            "subscriptionId": "9fe9c37a-1da8-4b8e-9d1b-21207b21e9f9"        },        "lines": [            {                "lineCode": 1,                "itemCode": "1",                "useType": "production",                "numberOfItems": 1,                "itemDescription": "Telemarketing",                "lineAmount": 50000,                "lineUnitPrice": 50000,                "taxDeductions": {                    "inssBasisDiscount": 1000                },                "itemDescriptor": {                    "hsCode": "4.15",                    "serviceCode": "05100",                    "serviceCodeOrigin": "05100",                    "subjectToIRRFAuto": false,                    "withLaborAssignment": true,                    "cnae": "0"                },                "services": {                    "hasCpom": false                },                "overwrite": "no",                "benefitsAbroad": false            }        ],        "version": "3"    }}
```

#### Services Purchase Out of Origin Company City

**Contractor City** 

Rio de Janeiro - RJ

**Taker City** 

São Paulo - SP

**Place where the service is taken**

São Paulo - SP

**Payload request**

```
{    "header": {        "messageType": "services",        "transactionDate": "2021-05-26",        "amountCalcType": "gross",        "documentCode": "TesteServicosForaCidadeOrigemEmpresaCashMode",        "eDocCreatorType": "self",        "eDocCreatorPerspective": true,        "companyLocation": "14528925000114",        "operationType": "Sale",        "locations": {            "establishment": {                "activitySector": {                    "type": "activityLine",                    "code": "industry"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T"                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityCode": "",                    "cityName": "Rio de Janeiro"                }            },            "entity": {                "activitySector": {                    "type": "activityLine",                    "code": "service"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T"                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": "",                    "cityName": "São Paulo",                    "cuntry": "BRA"                }            },            "rendered": {                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": "",                    "cityName": "São Paulo",                    "cuntry": "BRA"                }            }        },        "payment": {            "installmentTerms": 0,            "bill": {                "nFat": "123456789",                "vOrig": 10000,                "vDiscount": 500,                "vNet": 9500            }        },        "additionalInfo": {            "complementaryInfo": "Marketing and publicity services to TV"        }    },    "lines": [        {            "lineCode": 1,            "itemCode": 1,            "numberOfItems": 1,            "itemDescription": "Teste Descricao",            "lineAmount": 10000,            "lineUnitPrice": 10000,            "itemDescriptor": {                "hsCode": "10.08",                "serviceCode": "06394",                "serviceCodeOrigin": "06394",                "subjectToIRRFAuto": false,                "withLaborAssignment": false            },            "services": {                "hasCpom": false            }        }    ]}
```

**Payload response**

```
{    "header": {        "messageType": "services",        "transactionDate": "2021-05-26",        "amountCalcType": "gross",        "documentCode": "TesteServicosForaCidadeOrigemEmpresaCashMode",        "eDocCreatorType": "self",        "eDocCreatorPerspective": true,        "companyLocation": "14528925000114",        "operationType": "Sale",        "locations": {            "establishment": {                "activitySector": {                    "type": "activityLine",                    "code": "industry"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T",                    "enableCprb": false,                    "usesInssCprbToGrossValue": false,                    "pisCofinsIcmsTaxRelief": false,                    "subjectWithholdingIrrf": true,                    "subjectWithholdingInss": true,                    "subjectWithholdingIss": true                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityCode": 3304557,                    "cityName": "Rio de Janeiro",                    "countryCode": "0",                    "country": "BRA",                    "state": "RJ"                }            },            "entity": {                "activitySector": {                    "type": "activityLine",                    "code": "service"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": false,                    "subjectWithholdingCofins": false,                    "subjectWithholdingCsll": false,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T",                    "enableCprb": false,                    "usesInssCprbToGrossValue": false,                    "pisCofinsIcmsTaxRelief": false,                    "subjectToSRF1234": false,                    "subjectWithholdingIss": false,                    "subjectWithholdingIrrf": true,                    "subjectWithholdingInss": true                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": 3550308,                    "cityName": "São Paulo",                    "cuntry": "BRA",                    "countryCode": "0",                    "country": "BRA",                    "state": "SP"                },                "federalTaxId": ""            },            "rendered": {                "address": {                    "neighborhood": "Centro",                    "zipcode": "04710010",                    "cityCode": 3550308,                    "cityName": "São Paulo",                    "cuntry": "BRA",                    "countryCode": "0",                    "country": "BRA",                    "state": "SP"                },                "federalTaxId": ""            }        },        "payment": {            "installmentTerms": 0,            "bill": {                "nFat": "123456789",                "vOrig": 10000,                "vDiscount": 500,                "vNet": 9500            },            "installment": [                {                    "documentNumber": "1",                    "date": "2021-05-26",                    "grossValue": 10000,                    "withholdingMode": "xxx",                    "withholdingPIS": 0,                    "withholdingCOFINS": 0,                    "withholdingCSLL": 0,                    "netValue": 9350                }            ],            "withholdingMode": "xxx"        },        "additionalInfo": {            "complementaryInfo": "Marketing and publicity services to TV\nValor Líq: R$ 9350,00 Trib aprox R$: 1345,00 Federal e R$ 323,00 Municipal Fonte: IBPT"        },        "rpsSerie": "0",        "accountId": "bdf71245-1288-4883-95a5-3a7530ea31af",        "subscriptionId": "9fe9c37a-1da8-4b8e-9d1b-21207b21e9f9",        "services": {},        "ediSyncState": "STORED"    },    "lines": [        {            "lineCode": 1,            "itemCode": "1",            "numberOfItems": 1,            "itemDescription": "Teste Descricao",            "lineAmount": 10000,            "lineUnitPrice": 10000,            "itemDescriptor": {                "hsCode": "10.08",                "serviceCode": "06394",                "serviceCodeOrigin": "06394",                "subjectToIRRFAuto": false,                "withLaborAssignment": false,                "cnae": "0",                "issBehavior": "normal"            },            "services": {                "hasCpom": false            },            "useType": "notApplicable",            "overwrite": "no",            "benefitsAbroad": false,            "taxDeductions": {                "iss": 0            },            "operationType": "Sale",            "cfop": 6933,            "taxDetails": [                {                    "jurisdictionName": "RIO DE JANEIRO",                    "jurisdictionType": "City",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "aproxtribCity",                    "citation": "Trib aprox R$ 323,00 Municipal, Fonte: IBPT",                    "subtotalTaxable": 10000,                    "rate": 3.23,                    "tax": 323,                    "exemptionCode": "",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "aproxtribFed",                    "citation": "Trib aprox R$ 1.345,00 Federal, Fonte: IBPT",                    "subtotalTaxable": 10000,                    "rate": 13.45,                    "tax": 1345,                    "exemptionCode": "",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "cofins",                    "citation": "Lei nº 10.833/2003, Artigos 1º e 2º",                    "citationId": "b2343490-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 10000,                    "rate": 7.6,                    "tax": 760,                    "exemptionCode": "",                    "cst": "01",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "cofinsRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "W999",                    "cst": "01"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "csll",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "001",                    "cst": "01"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "csllRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "W999",                    "cst": "01"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "asset"                    },                    "taxType": "inssRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "004"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "irpj",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "001"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "asset"                    },                    "taxType": "irrf",                    "citation": "Decreto nº 9.580/2018, Artigo 718",                    "citationId": "afb1f680-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 10000,                    "rate": 1.5,                    "tax": 150,                    "exemptionCode": "",                    "cst": "01",                    "collectionCode": "8045",                    "isCustomCitation": false                },                {                    "jurisdictionName": "RIO DE JANEIRO",                    "jurisdictionType": "City",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "iss",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "cst": "01"                },                {                    "jurisdictionName": "SÃO PAULO",                    "jurisdictionType": "City",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "asset"                    },                    "taxType": "issRf",                    "citation": "Decreto nº 53.151/2012, Artigo 18, Inciso III",                    "citationId": "cae0f3af-b8ec-49be-be33-182c82cb41fd",                    "subtotalTaxable": 10000,                    "rate": 5,                    "tax": 500,                    "exemptionCode": "",                    "cst": "66",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "pis",                    "citation": "Lei nº 10.637/2002, Artigos 1º e 2º",                    "citationId": "b2fcb4b0-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 10000,                    "rate": 1.65,                    "tax": 165,                    "exemptionCode": "",                    "cst": "01",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "pisRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "W999",                    "cst": "01"                }            ],            "lineNetAmount": 9350,            "lineNetFigure": 8425        }    ],    "version": "3",    "processingInfo": {        "versionId": "21.11.3",        "duration": "5.986"    },    "summary": {        "numberOfLines": 1,        "totalLineAmounts": 10000,        "totalLineNetAmounts": 9350,        "totalTaxedDiscounts": 0,        "totalUntaxedDiscounts": 0,        "totalInsurances": 0,        "totalFreights": 0,        "totalOtherCosts": 0,        "taxByType": {            "aproxtribCity": {                "tax": 323,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "RIO DE JANEIRO",                        "jurisdictionType": "City",                        "tax": 323                    }                ]            },            "aproxtribFed": {                "tax": 1345,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 1345                    }                ]            },            "cofins": {                "tax": 760,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 760                    }                ]            },            "cofinsRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "csll": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "csllRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "inssRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "irpj": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "irrf": {                "tax": 150,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 150                    }                ]            },            "pis": {                "tax": 165,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 165                    }                ]            },            "iss": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "RIO DE JANEIRO",                        "jurisdictionType": "City",                        "tax": 0                    }                ]            },            "issRf": {                "tax": 500,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "SÃO PAULO",                        "jurisdictionType": "City",                        "tax": 500                    }                ]            },            "pisRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            }        },        "taxImpactHighlights": {            "included": [                {                    "taxType": "cofins",                    "tax": 760,                    "subtotalTaxable": 10000                },                {                    "taxType": "csll",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "irpj",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "iss",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "pis",                    "tax": 165,                    "subtotalTaxable": 10000                }            ],            "added": [],            "subtracted": [],            "withheld": [                {                    "taxType": "cofinsRf",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "csllRf",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "inssRf",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "irrf",                    "tax": 150,                    "subtotalTaxable": 10000                },                {                    "taxType": "issRf",                    "tax": 500,                    "subtotalTaxable": 10000                },                {                    "taxType": "pisRf",                    "tax": 0,                    "subtotalTaxable": 10000                }            ],            "informative": [                {                    "taxType": "aproxtribCity",                    "tax": 323,                    "subtotalTaxable": 10000                },                {                    "taxType": "aproxtribFed",                    "tax": 1345,                    "subtotalTaxable": 10000                }            ]        }    },    "input": {        "header": {            "messageType": "services",            "transactionDate": "2021-05-26",            "amountCalcType": "gross",            "documentCode": "TesteServicosForaCidadeOrigemEmpresaCashMode",            "eDocCreatorType": "self",            "eDocCreatorPerspective": true,            "companyLocation": "14528925000114",            "operationType": "Sale",            "locations": {                "establishment": {                    "activitySector": {                        "type": "activityLine",                        "code": "industry"                    },                    "taxesSettings": {                        "issRfRateForSimplesTaxRegime": 0,                        "pCredSN": 0,                        "subjectToPayrollTaxRelief": true,                        "subjectWithholdingPis": true,                        "subjectWithholdingCofins": true,                        "subjectWithholdingCsll": true,                        "cofinsSubjectTo": "T",                        "pisSubjectTo": "T",                        "csllSubjectTo": "T",                        "enableCprb": false,                        "usesInssCprbToGrossValue": false,                        "pisCofinsIcmsTaxRelief": false                    },                    "taxRegime": "realProfit",                    "type": "business",                    "address": {                        "neighborhood": "Centro",                        "zipcode": "20020-030",                        "cityCode": 3304557,                        "cityName": "Rio de Janeiro",                        "countryCode": "0",                        "country": "BRA",                        "state": "RJ"                    }                },                "entity": {                    "activitySector": {                        "type": "activityLine",                        "code": "service"                    },                    "taxesSettings": {                        "issRfRateForSimplesTaxRegime": 0,                        "pCredSN": 0,                        "subjectToPayrollTaxRelief": true,                        "subjectWithholdingPis": true,                        "subjectWithholdingCofins": true,                        "subjectWithholdingCsll": true,                        "cofinsSubjectTo": "T",                        "pisSubjectTo": "T",                        "csllSubjectTo": "T",                        "enableCprb": false,                        "usesInssCprbToGrossValue": false,                        "pisCofinsIcmsTaxRelief": false                    },                    "taxRegime": "realProfit",                    "type": "business",                    "address": {                        "neighborhood": "Centro",                        "zipcode": "04710010",                        "cityCode": 3550308,                        "cityName": "São Paulo",                        "cuntry": "BRA",                        "countryCode": "0",                        "country": "BRA",                        "state": "SP"                    },                    "federalTaxId": ""                },                "rendered": {                    "address": {                        "neighborhood": "Centro",                        "zipcode": "04710010",                        "cityCode": 3550308,                        "cityName": "São Paulo",                        "cuntry": "BRA",                        "countryCode": "0",                        "country": "BRA",                        "state": "SP"                    },                    "federalTaxId": ""                }            },            "payment": {                "installmentTerms": 0,                "bill": {                    "nFat": "123456789",                    "vOrig": 10000,                    "vDiscount": 500,                    "vNet": 9500                }            },            "additionalInfo": {                "complementaryInfo": "Marketing and publicity services to TV"            },            "rpsSerie": "0",            "accountId": "bdf71245-1288-4883-95a5-3a7530ea31af",            "subscriptionId": "9fe9c37a-1da8-4b8e-9d1b-21207b21e9f9"        },        "lines": [            {                "lineCode": 1,                "itemCode": "1",                "numberOfItems": 1,                "itemDescription": "Teste Descricao",                "lineAmount": 10000,                "lineUnitPrice": 10000,                "itemDescriptor": {                    "hsCode": "10.08",                    "serviceCode": "06394",                    "serviceCodeOrigin": "06394",                    "subjectToIRRFAuto": false,                    "withLaborAssignment": false,                    "cnae": "0"                },                "services": {                    "hasCpom": false                },                "useType": "notApplicable",                "overwrite": "no",                "benefitsAbroad": false            }        ],        "version": "3"    }}
```

#### Services Purchase Within Origin Company City

**Contractor City**

Rio de Janeiro - RJ

**Taker Country**

Rio de Janeiro - RJ

**Place where the service is taken**

Rio de Janeiro - RJ

**Payload request**

```
{    "header": {        "messageType": "services",        "transactionDate": "2021-05-26",        "amountCalcType": "gross",        "documentCode": "TesteServicosCompraDentroCidadeOrigemEmpresaCashMode",        "companyLocation": "14528925000114",        "operationType": "Purchase",        "locations": {            "establishment": {                "activitySector": {                    "type": "activityLine",                    "code": "wholesale"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T"                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityName": "Rio de Janeiro"                }            },            "entity": {                "activitySector": {                    "type": "activityLine",                    "code": "service"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T"                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityName": "Rio de Janeiro",                    "country": "BRA"                }            },            "rendered": {                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityName": "Rio de Janeiro",                    "country": "BRA"                }            }        },        "payment": {            "installmentTerms": 0,            "bill": {                "nFat": "123456789",                "vOrig": 10000,                "vDiscount": 0,                "vNet": 10000            }        },        "additionalInfo": {            "complementaryInfo": "Marketing and publicity services to TV"        }    },    "lines": [        {            "lineCode": 1,            "itemCode": 1,            "useType": "production",            "numberOfItems": 1,            "lineAmount": 10000,            "lineUnitPrice": 10000,            "itemDescriptor": {                "hsCode": "10.08",                "serviceCode": "100801",                "serviceCodeOrigin": "100801",                "withLaborAssignment": false            },            "services": {                "hasCpom": false            }        }    ]}
```

**Payload response**

```
{    "header": {        "messageType": "services",        "transactionDate": "2021-05-26",        "amountCalcType": "gross",        "documentCode": "TesteServicosCompraDentroCidadeOrigemEmpresaCashMode",        "companyLocation": "14528925000114",        "operationType": "Purchase",        "locations": {            "establishment": {                "activitySector": {                    "type": "activityLine",                    "code": "wholesale"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": true,                    "subjectWithholdingCofins": true,                    "subjectWithholdingCsll": true,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T",                    "enableCprb": false,                    "usesInssCprbToGrossValue": false,                    "pisCofinsIcmsTaxRelief": false,                    "subjectWithholdingIrrf": true,                    "subjectWithholdingInss": true,                    "subjectWithholdingIss": true                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityName": "Rio de Janeiro",                    "cityCode": 3304557,                    "countryCode": "0",                    "country": "BRA",                    "state": "RJ"                }            },            "entity": {                "activitySector": {                    "type": "activityLine",                    "code": "service"                },                "taxesSettings": {                    "issRfRateForSimplesTaxRegime": 0,                    "pCredSN": 0,                    "subjectToPayrollTaxRelief": true,                    "subjectWithholdingPis": false,                    "subjectWithholdingCofins": false,                    "subjectWithholdingCsll": false,                    "cofinsSubjectTo": "T",                    "pisSubjectTo": "T",                    "csllSubjectTo": "T",                    "enableCprb": false,                    "usesInssCprbToGrossValue": false,                    "pisCofinsIcmsTaxRelief": false,                    "subjectWithholdingIrrf": true,                    "subjectToSRF1234": false,                    "subjectWithholdingIss": false,                    "subjectWithholdingInss": true                },                "taxRegime": "realProfit",                "type": "business",                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityName": "Rio de Janeiro",                    "country": "BRA",                    "cityCode": 3304557,                    "countryCode": "0",                    "state": "RJ"                },                "federalTaxId": ""            },            "rendered": {                "address": {                    "neighborhood": "Centro",                    "zipcode": "20020-030",                    "cityName": "Rio de Janeiro",                    "country": "BRA",                    "cityCode": 3304557,                    "countryCode": "0",                    "state": "RJ"                },                "federalTaxId": ""            }        },        "payment": {            "installmentTerms": 0,            "bill": {                "nFat": "123456789",                "vOrig": 10000,                "vDiscount": 0,                "vNet": 10000            },            "installment": [                {                    "documentNumber": "1",                    "date": "2021-05-26",                    "grossValue": 10000,                    "withholdingMode": "xxx",                    "withholdingPIS": 0,                    "withholdingCOFINS": 0,                    "withholdingCSLL": 0,                    "netValue": 9850                }            ],            "withholdingMode": "xxx"        },        "additionalInfo": {            "complementaryInfo": "Marketing and publicity services to TV"        },        "eDocCreatorType": "self",        "eDocCreatorPerspective": true,        "rpsSerie": "0",        "accountId": "bdf71245-1288-4883-95a5-3a7530ea31af",        "subscriptionId": "9fe9c37a-1da8-4b8e-9d1b-21207b21e9f9",        "services": {}    },    "lines": [        {            "lineCode": 1,            "itemCode": "1",            "useType": "production",            "numberOfItems": 1,            "lineAmount": 10000,            "lineUnitPrice": 10000,            "itemDescriptor": {                "hsCode": "10.08",                "serviceCode": "100801",                "serviceCodeOrigin": "100801",                "withLaborAssignment": false,                "cnae": "0",                "issBehavior": "normal"            },            "services": {                "hasCpom": false            },            "overwrite": "no",            "benefitsAbroad": false,            "taxDeductions": {                "iss": 0            },            "operationType": "Purchase",            "cfop": 1933,            "taxDetails": [                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "asset"                    },                    "taxType": "cofins",                    "citation": "Lei nº 10.833/2003, Artigos 1º e 2º",                    "citationId": "b2343490-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 10000,                    "rate": 7.6,                    "tax": 760,                    "exemptionCode": "",                    "cst": "50",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "cofinsRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "999",                    "cst": "50"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "csllRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "999",                    "cst": "51"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "liability"                    },                    "taxType": "inssAr",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "001"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "inssRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "504"                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Subtracted",                        "accounting": "liability"                    },                    "taxType": "irrf",                    "citation": "Decreto nº 9.580/2018, Artigo 718",                    "citationId": "afb1f680-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 10000,                    "rate": 1.5,                    "tax": 150,                    "exemptionCode": "",                    "traceCode": "102",                    "cst": "01",                    "collectionCode": "8045",                    "isCustomCitation": false                },                {                    "jurisdictionName": "RIO DE JANEIRO",                    "jurisdictionType": "City",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "none"                    },                    "taxType": "iss",                    "citation": "Decreto nº 10.514/1991, Artigo 19, Inciso I",                    "citationId": "c71f58be-2479-45af-83dd-3c585900572c",                    "subtotalTaxable": 10000,                    "rate": 5,                    "tax": 500,                    "exemptionCode": "",                    "cst": "01",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Included",                        "impactOnNetAmount": "Included",                        "accounting": "asset"                    },                    "taxType": "pis",                    "citation": "Lei nº 10.637/2002, Artigos 1º e 2º",                    "citationId": "b2fcb4b0-a2dd-11eb-be1b-3386425f4aaa",                    "subtotalTaxable": 10000,                    "rate": 1.65,                    "tax": 165,                    "exemptionCode": "",                    "cst": "50",                    "isCustomCitation": false                },                {                    "jurisdictionName": "BRASIL",                    "jurisdictionType": "Country",                    "taxImpact": {                        "impactOnFinalPrice": "Informative",                        "impactOnNetAmount": "Informative",                        "accounting": "none"                    },                    "taxType": "pisRf",                    "subtotalTaxable": 10000,                    "rate": 0,                    "tax": 0,                    "exemptionCode": "",                    "traceCode": "999",                    "cst": "50"                }            ],            "lineNetAmount": 9850,            "lineNetFigure": 8425        }    ],    "version": "3",    "processingInfo": {        "versionId": "21.11.3",        "duration": "6.873"    },    "summary": {        "numberOfLines": 1,        "totalLineAmounts": 10000,        "totalLineNetAmounts": 9850,        "totalTaxedDiscounts": 0,        "totalUntaxedDiscounts": 0,        "totalInsurances": 0,        "totalFreights": 0,        "totalOtherCosts": 0,        "taxByType": {            "cofins": {                "tax": 760,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 760                    }                ]            },            "cofinsRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "csllRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "inssAr": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "inssRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            },            "irrf": {                "tax": 150,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 150                    }                ]            },            "pis": {                "tax": 165,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 165                    }                ]            },            "iss": {                "tax": 500,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "RIO DE JANEIRO",                        "jurisdictionType": "City",                        "tax": 500                    }                ]            },            "pisRf": {                "tax": 0,                "subtotalTaxable": 10000,                "jurisdictions": [                    {                        "jurisdictionName": "BRASIL",                        "jurisdictionType": "Country",                        "tax": 0                    }                ]            }        },        "taxImpactHighlights": {            "included": [                {                    "taxType": "cofins",                    "tax": 760,                    "subtotalTaxable": 10000                },                {                    "taxType": "inssAr",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "iss",                    "tax": 500,                    "subtotalTaxable": 10000                },                {                    "taxType": "pis",                    "tax": 165,                    "subtotalTaxable": 10000                }            ],            "added": [],            "subtracted": [],            "withheld": [                {                    "taxType": "cofinsRf",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "csllRf",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "inssRf",                    "tax": 0,                    "subtotalTaxable": 10000                },                {                    "taxType": "irrf",                    "tax": 150,                    "subtotalTaxable": 10000                },                {                    "taxType": "pisRf",                    "tax": 0,                    "subtotalTaxable": 10000                }            ],            "informative": []        }    },    "input": {        "header": {            "messageType": "services",            "transactionDate": "2021-05-26",            "amountCalcType": "gross",            "documentCode": "TesteServicosCompraDentroCidadeOrigemEmpresaCashMode",            "companyLocation": "14528925000114",            "operationType": "Purchase",            "locations": {                "establishment": {                    "activitySector": {                        "type": "activityLine",                        "code": "wholesale"                    },                    "taxesSettings": {                        "issRfRateForSimplesTaxRegime": 0,                        "pCredSN": 0,                        "subjectToPayrollTaxRelief": true,                        "subjectWithholdingPis": true,                        "subjectWithholdingCofins": true,                        "subjectWithholdingCsll": true,                        "cofinsSubjectTo": "T",                        "pisSubjectTo": "T",                        "csllSubjectTo": "T",                        "enableCprb": false,                        "usesInssCprbToGrossValue": false,                        "pisCofinsIcmsTaxRelief": false                    },                    "taxRegime": "realProfit",                    "type": "business",                    "address": {                        "neighborhood": "Centro",                        "zipcode": "20020-030",                        "cityName": "Rio de Janeiro",                        "cityCode": 3304557,                        "countryCode": "0",                        "country": "BRA",                        "state": "RJ"                    }                },                "entity": {                    "activitySector": {                        "type": "activityLine",                        "code": "service"                    },                    "taxesSettings": {                        "issRfRateForSimplesTaxRegime": 0,                        "pCredSN": 0,                        "subjectToPayrollTaxRelief": true,                        "subjectWithholdingPis": true,                        "subjectWithholdingCofins": true,                        "subjectWithholdingCsll": true,                        "cofinsSubjectTo": "T",                        "pisSubjectTo": "T",                        "csllSubjectTo": "T",                        "enableCprb": false,                        "usesInssCprbToGrossValue": false,                        "pisCofinsIcmsTaxRelief": false                    },                    "taxRegime": "realProfit",                    "type": "business",                    "address": {                        "neighborhood": "Centro",                        "zipcode": "20020-030",                        "cityName": "Rio de Janeiro",                        "country": "BRA",                        "cityCode": 3304557,                        "countryCode": "0",                        "state": "RJ"                    },                    "federalTaxId": ""                },                "rendered": {                    "address": {                        "neighborhood": "Centro",                        "zipcode": "20020-030",                        "cityName": "Rio de Janeiro",                        "country": "BRA",                        "cityCode": 3304557,                        "countryCode": "0",                        "state": "RJ"                    },                    "federalTaxId": ""                }            },            "payment": {                "installmentTerms": 0,                "bill": {                    "nFat": "123456789",                    "vOrig": 10000,                    "vDiscount": 0,                    "vNet": 10000                }            },            "additionalInfo": {                "complementaryInfo": "Marketing and publicity services to TV"            },            "eDocCreatorType": "self",            "eDocCreatorPerspective": true,            "rpsSerie": "0",            "accountId": "bdf71245-1288-4883-95a5-3a7530ea31af",            "subscriptionId": "9fe9c37a-1da8-4b8e-9d1b-21207b21e9f9"        },        "lines": [            {                "lineCode": 1,                "itemCode": "1",                "useType": "production",                "numberOfItems": 1,                "lineAmount": 10000,                "lineUnitPrice": 10000,                "itemDescriptor": {                    "hsCode": "10.08",                    "serviceCode": "100801",                    "serviceCodeOrigin": "100801",                    "withLaborAssignment": false,                    "cnae": "0"                },                "services": {                    "hasCpom": false                },                "overwrite": "no",                "benefitsAbroad": false            }        ],        "version": "3"    }}
```

[Previous](/for-review-only/en/leila-paul/services-calculation-en/transactions/sales)

[Next](/for-review-only/en/leila-paul/services-calculation-en/transactions/important_points_response_payload)