---
title: Gestión de Facturación
slug: gestion-de-facturacion
createdAt: 2025-01-27T01:23:22.681Z
---

Este módulo le permite gestionar la facturación y el estado de cuenta de un subcomercio. Al crear nuevas facturas el comercio verá reflejada la misma en su cuenta con el saldo a pagar, adicionalmente el mismo podrá pagar sus facturas desde el panel de Estado de Cuenta en la consola.

Este módulo es optativo y debe pedirse su habiltación al equipo comercial.

:::ApiMethodV2
```json
{
  "name": "Crear Factura",
  "method": "POST",
  "url": "https://{suga-id}.sugaway.io/p/operator/billing",
  "description": "Crea una nueva Factura",
  "tab": "examples",
  "examples": {
    "languages": [
      {
        "id": "15lX5KIX6ZbmX_BAD-OvD",
        "language": "javascript",
        "code": "var myHeaders = new Headers();\nmyHeaders.append(\"Accept\", \"application/json\");\nmyHeaders.append(\"Content-Type\", \"application/json\");\n\nvar raw = JSON.stringify({\n   \"id\": \"String\"\n});\n\nvar requestOptions = {\n   method: 'GET',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"https://api.cakes.com\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "15lX5KIX6ZbmX_BAD-OvD"
  },
  "results": {
    "languages": [
      {
        "id": "EQCVd7w0tJOAehi-lIela",
        "language": "200",
        "customLabel": "",
        "code": "{\n  \"name\": \"Cake's name\",\n}"
      },
      {
        "id": "puhdbFwrCv9QbvpX9nSCe",
        "language": "404",
        "customLabel": "",
        "code": "{\n  \"message\": \"Ain't no cake like that.\"\n}"
      }
    ],
    "selectedLanguageId": "EQCVd7w0tJOAehi-lIela"
  },
  "request": {
    "pathParameters": [],
    "queryParameters": [],
    "headerParameters": [],
    "bodyDataParameters": [
      {
        "name": "total",
        "kind": "optional",
        "type": "Number",
        "description": "Total de la Factura",
        "children": []
      },
      {
        "name": "currency",
        "kind": "optional",
        "type": "string",
        "description": "Moneda de la Factura. Valores admitidos: ARS, USD, CLP, MXN, UYU.",
        "children": []
      },
      {
        "name": "uid",
        "kind": "optional",
        "type": "string",
        "description": "Identificator único de la Factura a crear",
        "children": []
      },
      {
        "name": "entity",
        "kind": "optional",
        "type": "string",
        "description": "Entity UID o Referencia de la entidad",
        "children": []
      }
    ],
    "formDataParameters": []
  },
  "currentNewParameter": {
    "label": "Body Parameter",
    "value": "bodyDataParameters"
  },
  "autoGeneratedAnchorSlug": "crear-factura",
  "legacyHash": "ysLgsStvUjVpjUIRUb_7o"
}
```
:::

```json
{
    "invoiceDate": "2024-06-30T00:00:00.000Z",
    "uid": "ARG20409501827_06-2024",
    "items": [
        {
            "netoGrabado": 1745.45,
            "netoNoGrabado": 0,
            "totalExento": 0,
            "description": "LICENCIA FRESA",
            "taxType": 21,
            "productId": 10,
            "product": {
                "code": 10,
                "description": "LICENCIA FRESA",
                "isPlus": true,
                "isAlreadyPaid": true,
                "isPaidToPartner": true
            },
            "quantity": 1,
            "itemTaxTotal": 366.54,
            "itemTotal": 1745.45
        }
    ],
    "entity": "REF / UID",
    "isInvoicePaid": true,
    "period": "06-2024",
    "fiscalData": {
        "fiscalAuthorizationMode": "CAE",
        "fullNumber": "FA 00005-00056976",
        "shortFullNumber": "FA 00005-00056976",
        "longFullNumber": "FACTURA A  00005-00056976",
        "nationalAuthorizationCode": "74270691349491",
        "nationalAuthorizationCodeExpires": "10/07/2024",
        "governmentMessage": "10217 - El credito fiscal discriminado en el presente comprobante solo podra ser computado a efectos del Procedimiento permanente de transicion al Regimen General.",
        "number": 56976,
        "shortCode": "FA",
        "pos": "00005",
        "posId": 651,
        "generalDocumentTypeId": 1,
        "generalDocumentType": "Factura",
        "documentTypeId": 1,
        "documentType": "A",
        "documentCode": "01",
        "invoiceNumber": "00005-00056976",
        "pointOfSale": "00005",
        "documentNumber": "00056976",
        "barcode": "20409501827010000574270691349491202407100",
        "qrCode": {
            "ver": 1,
            "fecha": "2024-06-30",
            "cuit": "30715123580",
            "ptoVta": 5,
            "tipoCmp": 1,
            "nroCmp": 56976,
            "importe": "211199",
            "moneda": "PES",
            "ctz": 1,
            "tipoDocRec": 80,
            "nroDocRec": "20409501827",
            "tipoCodAut": "E",
            "codAut": "74270691349491"
        }
    },
    "total": 2111.9945,
    "currency": "ARS",
    "dates": {
        "issueDate": "30/06/2024",
        "serviceStartDate": "01/06/2024",
        "serviceEndDate": "30/06/2024"
    },
    "totals": {
        "subtotal": 1745.45,
        "taxes": {
            "21": 366.54
        },
        "total": 2111.99,
        "paid": 2111.99,
        "balance": 0
    },
    "dueInfo": {
        "firstDueDate": "12/07/2024",
        "secondDueDate": "19/07/2024",
        "secondDueSurcharge": 0,
        "secondDueTotal": 0,
        "firstDueTimestamp": 1720839599000,
        "secondDueTimestamp": 1721444399000
    },
    "file": {
        "uri": "https://prod/ARG20409501827/invoices/ARG20409501827_06-2024.pdf",
        "contentType": "application/pdf",
        "name": "ARG20409501827_06-2024.pdf"
    }
}
```

:::ApiMethodV2
```json
{
  "name": "Eliminar Factura",
  "method": "DELETE",
  "url": "https://{suga-id}.sugaway.io/p/operator/billing/:uid",
  "description": "Elimina una Factura mediante su UID",
  "tab": "examples",
  "examples": {
    "languages": [
      {
        "id": "PJafN73cQwvz8co0ittQW",
        "language": "javascript",
        "code": "var myHeaders = new Headers();\nmyHeaders.append(\"Accept\", \"application/json\");\nmyHeaders.append(\"Content-Type\", \"application/json\");\n\nvar raw = JSON.stringify({\n   \"id\": \"String\"\n});\n\nvar requestOptions = {\n   method: 'GET',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"https://api.cakes.com\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "PJafN73cQwvz8co0ittQW"
  },
  "results": {
    "languages": [
      {
        "id": "XSIPU9xljzJwtXfgvjKBi",
        "language": "200",
        "customLabel": "",
        "code": "{\n  \"name\": \"Cake's name\",\n}"
      },
      {
        "id": "Y9gTDNeCh9x3Ub7qqqMD1",
        "language": "404",
        "customLabel": "",
        "code": "{\n  \"message\": \"Ain't no cake like that.\"\n}"
      }
    ],
    "selectedLanguageId": "XSIPU9xljzJwtXfgvjKBi"
  },
  "request": {
    "pathParameters": [
      {
        "name": "uid",
        "kind": "optional",
        "type": "string",
        "description": "UID con el que se creó la Factura",
        "children": []
      }
    ],
    "queryParameters": [],
    "headerParameters": [],
    "bodyDataParameters": [],
    "formDataParameters": []
  },
  "currentNewParameter": {
    "label": "Path Parameter",
    "value": "pathParameters"
  },
  "autoGeneratedAnchorSlug": "eliminar-factura",
  "legacyHash": "Mk2VHhC2HBW7zkwrtr1rd"
}
```
:::

