Skip to main content

SendInvoice-TestSetId Articulos Con impuesto Licores

Endpoint

  • Método: POST
  • Ruta: /api/ubl2.1/invoice
  • URL ejemplo: http://apidian2024.oo/api/ubl2.1/invoice

Descripción

ENVIO DE FACTURA CON ARTICULOS QUE TENGAN DOS IMPUESTOS

  • Aplica la misma documentacion que el PRIMER ENVIO DE FACTURA de la seccion 02 - PRIMEROS ENVIOS.

  • Este ejemplo ilustra como se debe utilizar la API para enviar una factura que incluya articulos que lleven dos impuestos, aunque esto es muy poco frecuente, se da en casos como la telefonia celular que tiene IVA e Impuesto al Consumo.

Autenticación

  • Tipo: Bearer Token
  • Header: Authorization: Bearer {{API_TOKEN}}

Headers

KeyValue
Content-Typeapplication/json
Acceptapplication/json
  • host: apidian2021.oo

Body

{
"number": 990001109,
"type_document_id": 1,
"date": "2024-06-28",
"time": "04:08:12",
"resolution_number": "18760000001",
"prefix": "SETP",
"sendmail": false,
"sendmailtome": false,
"send_customer_credentials": false,
"notes": "ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA",
"disable_confirmation_text": true,
"establishment_name": "TORRE SOFTWARE",
"establishment_address": "BRR LIMONAR MZ 6 CS 3 ET 1 PISO 2",
"establishment_phone": "3226563672",
"establishment_municipality": 600,
"establishment_email": "alternate_email@alternate.com",
"head_note": "PRUEBA DE TEXTO LIBRE QUE DEBE POSICIONARSE EN EL ENCABEZADO DE PAGINA DE LA REPRESENTACION GRAFICA DE LA FACTURA ELECTRONICA VALIDACION PREVIA DIAN",
"foot_note": "PRUEBA DE TEXTO LIBRE QUE DEBE POSICIONARSE EN EL PIE DE PAGINA DE LA REPRESENTACION GRAFICA DE LA FACTURA ELECTRONICA VALIDACION PREVIA DIAN",
"customer": {
"identification_number": 89008003,
"dv": 2,
"name": "INVERSIONES DAVAL SAS",
"phone": "3103891693",
"address": "CLL 4 NRO 33-90",
"email": "alexanderobandolondono@gmail.com",
"merchant_registration": "0000000-00",
"type_document_identification_id": 6,
"type_organization_id": 1,
"type_liability_id": 7,
"municipality_id": 822,
"type_regime_id": 1
},
"payment_form": {
"payment_form_id": 2,
"payment_method_id": 2,
"payment_due_date": "2024-06-28",
"duration_measure": 0
},
"legal_monetary_totals": {
"line_extension_amount": "11512000.000",
"tax_exclusive_amount": "11512000.000",
"tax_inclusive_amount": "14500000.000",
"allowance_total_amount": null,
"charge_total_amount": "0",
"payable_amount": "14500000.000"
},
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.000",
"percent": "0.00",
"taxable_amount": "11512000.000",
"unit_measure_id": null,
"per_unit_amount": null,
"base_unit_measure": null
},
{
"tax_id": 19,
"tax_amount": "2988000.000",
"percent": "0",
"taxable_amount": "0",
"unit_measure_id": "70",
"per_unit_amount": null,
"base_unit_measure": null
}
],
"with_holding_tax_total": [
{
"tax_id": 6,
"tax_amount": "287800.000",
"percent": "2.500",
"taxable_amount": "11512000.000",
"unit_measure_id": null,
"per_unit_amount": null,
"base_unit_measure": null
}
],
"invoice_lines": [
{
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.000000",
"percent": "0.00",
"taxable_amount": "11512000.000",
"unit_measure_id": null,
"per_unit_amount": null,
"base_unit_measure": null
},
{
"tax_id": 19,
"tax_amount": "2988000.000",
"percent": "0",
"taxable_amount": "0",
"unit_measure_id": "70",
"per_unit_amount": "250.000",
"base_unit_measure": "11952"
}
],
"unit_measure_id": 1076,
"invoiced_quantity": "250.000",
"line_extension_amount": "11512000.000",
"free_of_charge_indicator": false,
"description": "AGUILA RN 330CC X 30 ",
"notes": "",
"code": "100003",
"type_item_identification_id": 4,
"price_amount": "46048.000",
"base_quantity": "1"
}
]
}

cURL

curl -X POST "http://apidian2024.oo/api/ubl2.1/invoice" \
-H "Authorization: Bearer {API_TOKEN}" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "host: apidian2021.oo" \
-H "Content-Type: application/json" \
-d '{
"number": 990001109,
"type_document_id": 1,
"date": "2024-06-28",
"time": "04:08:12",
"resolution_number": "18760000001",
"prefix": "SETP",
"sendmail": false,
"sendmailtome": false,
"send_customer_credentials": false,
"notes": "ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA, ESTA ES UNA NOTA DE PRUEBA",
"disable_confirmation_text": true,
"establishment_name": "TORRE SOFTWARE",
"establishment_address": "BRR LIMONAR MZ 6 CS 3 ET 1 PISO 2",
"establishment_phone": "3226563672",
"establishment_municipality": 600,
"establishment_email": "alternate_email@alternate.com",
"head_note": "PRUEBA DE TEXTO LIBRE QUE DEBE POSICIONARSE EN EL ENCABEZADO DE PAGINA DE LA REPRESENTACION GRAFICA DE LA FACTURA ELECTRONICA VALIDACION PREVIA DIAN",
"foot_note": "PRUEBA DE TEXTO LIBRE QUE DEBE POSICIONARSE EN EL PIE DE PAGINA DE LA REPRESENTACION GRAFICA DE LA FACTURA ELECTRONICA VALIDACION PREVIA DIAN",
"customer": {
"identification_number": 89008003,
"dv": 2,
"name": "INVERSIONES DAVAL SAS",
"phone": "3103891693",
"address": "CLL 4 NRO 33-90",
"email": "alexanderobandolondono@gmail.com",
"merchant_registration": "0000000-00",
"type_document_identification_id": 6,
"type_organization_id": 1,
"type_liability_id": 7,
"municipality_id": 822,
"type_regime_id": 1
},
"payment_form": {
"payment_form_id": 2,
"payment_method_id": 2,
"payment_due_date": "2024-06-28",
"duration_measure": 0
},
"legal_monetary_totals": {
"line_extension_amount": "11512000.000",
"tax_exclusive_amount": "11512000.000",
"tax_inclusive_amount": "14500000.000",
"allowance_total_amount": null,
"charge_total_amount": "0",
"payable_amount": "14500000.000"
},
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.000",
"percent": "0.00",
"taxable_amount": "11512000.000",
"unit_measure_id": null,
"per_unit_amount": null,
"base_unit_measure": null
},
{
"tax_id": 19,
"tax_amount": "2988000.000",
"percent": "0",
"taxable_amount": "0",
"unit_measure_id": "70",
"per_unit_amount": null,
"base_unit_measure": null
}
],
"with_holding_tax_total": [
{
"tax_id": 6,
"tax_amount": "287800.000",
"percent": "2.500",
"taxable_amount": "11512000.000",
"unit_measure_id": null,
"per_unit_amount": null,
"base_unit_measure": null
}
],
"invoice_lines": [
{
"tax_totals": [
{
"tax_id": 1,
"tax_amount": "0.000000",
"percent": "0.00",
"taxable_amount": "11512000.000",
"unit_measure_id": null,
"per_unit_amount": null,
"base_unit_measure": null
},
{
"tax_id": 19,
"tax_amount": "2988000.000",
"percent": "0",
"taxable_amount": "0",
"unit_measure_id": "70",
"per_unit_amount": "250.000",
"base_unit_measure": "11952"
}
],
"unit_measure_id": 1076,
"invoiced_quantity": "250.000",
"line_extension_amount": "11512000.000",
"free_of_charge_indicator": false,
"description": "AGUILA RN 330CC X 30 ",
"notes": "",
"code": "100003",
"type_item_identification_id": 4,
"price_amount": "46048.000",
"base_quantity": "1"
}
]
}'

Probar endpoint

POST
Enviar Factura (Casuística)
BASE URL
Se guarda localmente en tu navegador.
BEARER TOKEN
Se guarda solo en esta sesión/pestaña.
URL FINAL
/api/ubl2.1/invoice
BODY JSON
RESPUESTA
Envía la solicitud para ver la respuesta aquí.