SendCreditNote-TestSetId Varias Lineas
Endpoint
- Método: POST
- Ruta:
/api/ubl2.1/credit-note - URL ejemplo:
http://apidian2023.oo/api/ubl2.1/credit-note
Descripción
ENVIO DE FACTURA CON VARIAS LINEAS DE DETALLE
-
Aplica la misma documentacion que el PRIMER ENVIO DE FACTURA de la seccion 02 - PRIMEROS ENVIOS.
-
Utilice este ejemplo cuando desee enviar varias lineas de productos o lineas de detalle en una misma factura.
Autenticación
- Tipo: Bearer Token
- Header:
Authorization: Bearer {{API_TOKEN}}
Headers
| Key | Value |
|---|---|
Content-Type | application/json |
Accept | application/json |
Body
{
"billing_reference": {
"number": "990000360",
"uuid": "43408510e1fa4ce24159b4a339b0e223b31de9431df4d50af37d627a86669a520fe87f9938ace108f9ce91b6636aad90",
"issue_date": "2021-08-17"
},
"discrepancyresponsecode": 2,
"discrepancyresponsedescription": "PRUEBA DE MOTIVO NOTA CREDITO",
"notes": "PRUEBA DE NOTA CREDITO",
"resolution_number": "0000000000",
"prefix": "NC",
"number": 35,
"type_document_id": 4,
"date": "2021-08-17",
"time": "10:00:52",
"customer": {
"identification_number": 89008003,
"name": "ALEXANDER OBANDO LONDONO",
"phone": 3103891693,
"address": "BRR EL CARDAL MZ 4 CS 7 ET 1",
"email": "alexander_obando@hotmail.com",
"merchant_registration": "0000-00",
"type_document_identification_id": 3,
"type_organization_id": 2,
"municipality_id": 149,
"type_regime_id": 2
},
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.00",
"taxable_amount": "15000.00",
"percent": "0.00"
},
{
"tax_id": 1,
"tax_amount": "3193.28",
"taxable_amount": "16806.72",
"percent": "19.00"
}
],
"legal_monetary_totals": {
"line_extension_amount": "31806.72",
"tax_exclusive_amount": "31806.72",
"tax_inclusive_amount": "35000.00",
"allowance_total_amount": "0.00",
"charge_total_amount": "0.00",
"payable_amount": "35000.00"
},
"credit_note_lines": [
{
"unit_measure_id": 70,
"invoiced_quantity": "1",
"line_extension_amount": "10084.03",
"free_of_charge_indicator": false,
"allowance_charges": [
{
"charge_indicator": false,
"allowance_charge_reason": "DESCUENTO GENERAL",
"amount": "0.00",
"base_amount": "12000.00"
}
],
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "1915.97",
"taxable_amount": "10084.03",
"percent": "19.00"
}
],
"description": "COMISION POR SERVICIOS",
"code": "COMISION",
"type_item_identification_id": 4,
"price_amount": "10084.03",
"base_quantity": "1"
},
{
"unit_measure_id": 70,
"invoiced_quantity": "1",
"line_extension_amount": "6722.69",
"free_of_charge_indicator": false,
"allowance_charges": [
{
"charge_indicator": false,
"allowance_charge_reason": "DESCUENTO GENERAL",
"amount": "0.00",
"base_amount": "8000.00"
}
],
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "1277.31",
"taxable_amount": "6722.69",
"percent": "19.00"
}
],
"description": "BONOS POR SERVICIOS",
"code": "BONOS",
"type_item_identification_id": 4,
"price_amount": "6722.69",
"base_quantity": "1"
},
{
"unit_measure_id": 70,
"invoiced_quantity": "1",
"line_extension_amount": "15000.00",
"free_of_charge_indicator": false,
"allowance_charges": [
{
"charge_indicator": false,
"allowance_charge_reason": "DESCUENTO GENERAL",
"amount": "0.00",
"base_amount": "15000.00"
}
],
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.00",
"taxable_amount": "15000.00",
"percent": "0.00"
}
],
"description": "CESANTIA MERCANTIL",
"code": "CESANTIA",
"type_item_identification_id": 4,
"price_amount": "15000.00",
"base_quantity": "1"
}
]
}
cURL
curl -X POST "http://apidian2023.oo/api/ubl2.1/credit-note" \
-H "Authorization: Bearer {API_TOKEN}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"billing_reference": {
"number": "990000360",
"uuid": "43408510e1fa4ce24159b4a339b0e223b31de9431df4d50af37d627a86669a520fe87f9938ace108f9ce91b6636aad90",
"issue_date": "2021-08-17"
},
"discrepancyresponsecode": 2,
"discrepancyresponsedescription": "PRUEBA DE MOTIVO NOTA CREDITO",
"notes": "PRUEBA DE NOTA CREDITO",
"resolution_number": "0000000000",
"prefix": "NC",
"number": 35,
"type_document_id": 4,
"date": "2021-08-17",
"time": "10:00:52",
"customer": {
"identification_number": 89008003,
"name": "ALEXANDER OBANDO LONDONO",
"phone": 3103891693,
"address": "BRR EL CARDAL MZ 4 CS 7 ET 1",
"email": "alexander_obando@hotmail.com",
"merchant_registration": "0000-00",
"type_document_identification_id": 3,
"type_organization_id": 2,
"municipality_id": 149,
"type_regime_id": 2
},
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.00",
"taxable_amount": "15000.00",
"percent": "0.00"
},
{
"tax_id": 1,
"tax_amount": "3193.28",
"taxable_amount": "16806.72",
"percent": "19.00"
}
],
"legal_monetary_totals": {
"line_extension_amount": "31806.72",
"tax_exclusive_amount": "31806.72",
"tax_inclusive_amount": "35000.00",
"allowance_total_amount": "0.00",
"charge_total_amount": "0.00",
"payable_amount": "35000.00"
},
"credit_note_lines": [
{
"unit_measure_id": 70,
"invoiced_quantity": "1",
"line_extension_amount": "10084.03",
"free_of_charge_indicator": false,
"allowance_charges": [
{
"charge_indicator": false,
"allowance_charge_reason": "DESCUENTO GENERAL",
"amount": "0.00",
"base_amount": "12000.00"
}
],
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "1915.97",
"taxable_amount": "10084.03",
"percent": "19.00"
}
],
"description": "COMISION POR SERVICIOS",
"code": "COMISION",
"type_item_identification_id": 4,
"price_amount": "10084.03",
"base_quantity": "1"
},
{
"unit_measure_id": 70,
"invoiced_quantity": "1",
"line_extension_amount": "6722.69",
"free_of_charge_indicator": false,
"allowance_charges": [
{
"charge_indicator": false,
"allowance_charge_reason": "DESCUENTO GENERAL",
"amount": "0.00",
"base_amount": "8000.00"
}
],
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "1277.31",
"taxable_amount": "6722.69",
"percent": "19.00"
}
],
"description": "BONOS POR SERVICIOS",
"code": "BONOS",
"type_item_identification_id": 4,
"price_amount": "6722.69",
"base_quantity": "1"
},
{
"unit_measure_id": 70,
"invoiced_quantity": "1",
"line_extension_amount": "15000.00",
"free_of_charge_indicator": false,
"allowance_charges": [
{
"charge_indicator": false,
"allowance_charge_reason": "DESCUENTO GENERAL",
"amount": "0.00",
"base_amount": "15000.00"
}
],
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.00",
"taxable_amount": "15000.00",
"percent": "0.00"
}
],
"description": "CESANTIA MERCANTIL",
"code": "CESANTIA",
"type_item_identification_id": 4,
"price_amount": "15000.00",
"base_quantity": "1"
}
]
}'