# Get your SRI en Línea comprobantes through an API

> Get the facturas and comprobantes de retención you received or issued in SRI en Línea as JSON, with clave de acceso, IVA and importe total. A workflow can post each weekday morning's new comprobantes recibidos to your accounting system.

Page: https://fous.com/automate/sri-en-linea
Updated: 2026-11-12

Works with your own SRI en Línea account. Fous is an independent product.

## What you can build on SRI en Línea

### Get comprobantes electrónicos recibidos

Reads the list on Comprobantes electrónicos recibidos for one Periodo emisión and Tipo de comprobante, under Facturación Electrónica.

- Takes: Year, month, day (optional), tipo de comprobante
- Returns: Issuer RUC and razón social, type and series, clave de acceso, authorization date and time, issue date, valor sin impuestos, IVA, importe total

### Get comprobantes electrónicos emitidos

Reads the authorized comprobantes your RUC issued on one Fecha emisión, filtered by Tipo de comprobante, Establecimiento and Punto de emisión.

- Takes: Issue date, tipo de comprobante, establecimiento (optional), punto de emisión (optional)
- Returns: Type and series, clave de acceso, authorization date and time, issue date, valor sin impuestos, IVA, importe total

### Check a comprobante by clave de acceso

Looks up one clave de acceso on Validez de comprobantes and reads whether the comprobante is authorized.

- Takes: Clave de acceso
- Returns: Clave de acceso, authorization status

### Upload the monthly ATS

Opens Anexos, chooses the Anexo Transaccional Simplificado and sends the ATmmaaaa.zip file for one period.

- Takes: Year, month, ATS zip file
- Returns: Period, file name, result message

## Automate SRI en Línea with a workflow

A [workflow](/product/workflows) runs your methods as one process, with nobody at the screen. A schedule or a call from your own system starts it, the steps run in order, and the result arrives in your inbox or in the systems you already use.

### New comprobantes recibidos, sent to accounts payable

Starts: Every weekday at 7:00

1. Get the comprobantes electrónicos recibidos of type Factura for the current and the previous month.
2. Keep the facturas that were not there on the last run.
3. Post each one, with issuer RUC, clave de acceso, IVA and importe total, to your ERP webhook.

### Last month's IVA totals, before the declaración

Starts: Monthly on the 2nd at 8:00

1. Get last month's comprobantes recibidos of type Factura, and the comprobantes emitidos for each day of that month.
2. Add up valor sin impuestos, IVA and importe total for purchases and for sales.
3. Email you both totals with the list of comprobantes behind them.

### Supplier facturas checked before payment

Starts: When your system calls the workflow's webhook with a list of claves de acceso

1. For each clave de acceso, check the comprobante on Validez de comprobantes.
2. Keep the ones that are not authorized.
3. Post the clave de acceso and status back to your webhook.

You can run a workflow by hand on every plan, Free included. Schedules and webhook triggers come with the paid plans, from $29 a month.

## Once built, one call from your code

Once you have built a [method](/product/methods), it is one POST to /v1/runs from your backend, or a tool an AI agent calls over MCP. This is what “Get comprobantes electrónicos recibidos” would look like.

Example request:

```
curl https://api.fous.com/v1/runs \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "method": "srienlinea.sri.gob.ec/get_comprobantes_recibidos",
    "input": {
      "year": 2026,
      "month": 11,
      "tipo_comprobante": "Factura"
    }
  }'
```

Example response:

```
{
  "status": "completed",
  "data": {
    "periodo": "2026-11",
    "tipo_comprobante": "Factura",
    "comprobantes": [
      {
        "ruc_emisor": "1799999999001",
        "razon_social_emisor": "NORTHWIND SUMINISTROS S.A.",
        "tipo_y_serie": "Factura 001-003-000004567",
        "clave_acceso": "1011202601179999999900120010030000045671234567819",
        "fecha_hora_autorizacion": "2026-11-10T09:14:52",
        "fecha_emision": "2026-11-10",
        "valor_sin_impuestos": 1250,
        "iva": 187.5,
        "importe_total": 1437.5
      }
    ],
    "count": 1
  }
}
```

An example with invented data, not a ready-made endpoint. The method exists in your organization once you build it, and its name, inputs and fields follow your request.

## SRI en Línea’s own options

The SRI publishes web services for issuers: one receives comprobantes electrónicos, one returns their authorization, and a consultation service gives a comprobante's status by clave de acceso. The ficha técnica describes no web service that lists the comprobantes you received. Annexes such as the ATS are prepared as XML files and sent through SRI en Línea.

| Option | What it covers | What it takes |
| --- | --- | --- |
| Recepción and Autorización web services | Send comprobantes electrónicos in batches of up to 50 and get back RECIBIDA or DEVUELTA, then AUTORIZADO or NO AUTORIZADO by clave de acceso. | Authorization to issue comprobantes electrónicos through Solicitud de emisión, and tests in the pruebas environment before producción. |
| ConsultaComprobante web service | Returns one comprobante's status by clave de acceso: AUTORIZADO, NO AUTORIZADO, PENDIENTE DE ANULAR or ANULADO. | The clave de acceso of the comprobante. |
| DIMM and the ATS program | SRI programs that produce annex XML files, including the Anexo Transaccional Simplificado, to send in SRI en Línea. | DIMM and the ATS program version for the period (v1.19.0 from September 2026), with the SRI's ats.xsd schema. |
| SRI en Línea by hand | Comprobantes recibidos and emitidos, Validez de comprobantes, Declaraciones, Anexos, Deudas and Certificados, for the RUC you signed in with. | A Clave for your RUC, cédula or passport number. |

Read on November 12, 2026: [Ficha técnica, comprobantes electrónicos, esquema offline 2.34](https://www.sri.gob.ec/o/sri-portlet-biblioteca-alfresco-internet/descargar/f8d9bb36-5632-4f96-b463-b9265b55338c/FICHA%20TE%cc%81CNICA%20COMPROBANTES%20ELECTRO%cc%81NICOS%20ESQUEMA%20OFFLINE%20Versio%cc%81n%202.34.pdf), [Guía para contribuyentes: comprobantes electrónicos, Internet](https://www.sri.gob.ec/o/sri-portlet-biblioteca-alfresco-internet/descargar/6162dad8-05c9-46e0-8a94-dabf556aceb5/Gu%c3%ada%20comprobantes%20electr%c3%b3nicos%20%20-%20Internet.pdf), [Formularios e instructivos (DIMM, ATS)](https://www.sri.gob.ec/formularios-e-instructivos1).

## Signing in to SRI en Línea

SRI en Línea signs you in with your RUC, cédula or passport number and your Clave, with an optional C.I. adicional field, and no second step is described in the SRI's guide. With Fous you sign in once through SRI en Línea's own sign-in with your own account: the login is sealed with AES-256, and an expired session is signed back in.

## Worth knowing

- **One period and one type at a time**: Comprobantes electrónicos recibidos is queried by Periodo emisión and one Tipo de comprobante, so facturas and comprobantes de retención are separate calls. The RUC search and the clave de acceso search are mutually exclusive.
- **Authorization can take up to 24 hours**: The SRI gives itself up to 24 hours after RECIBIDA to authorize a comprobante. A factura dated yesterday can appear today, which is why a comparison with the last run is safer than a query for one day.
- **The ATS is one zipped XML a month**: The annex puts the matriz and every sucursal in one XML file, zipped as ATmmaaaa.zip, and only the zipped file is accepted online. SRI offices take a flash drive only for annexes over 8 MB when online channels are unavailable.
- **IVA due dates follow the ninth digit of the RUC**: Monthly IVA returns are due on the 10th to the 28th of the following month, by the ninth digit of the RUC. A due date on a weekend or holiday moves to the next business day.

## More in Government: Latin America

- [Mis Comprobantes](https://fous.com/automate/mis-comprobantes.md)
- [Facturación Electrónica DIAN](https://fous.com/automate/facturacion-electronica-dian.md)
- [Simplificación Registral](https://fous.com/automate/simplificacion-registral.md)
- [ARCA - servicios con Clave Fiscal](https://fous.com/automate/arca-servicios-con-clave-fiscal.md)
- [Portal Empresarial INFONAVIT](https://fous.com/automate/portal-empresarial-infonavit.md)
- [SIFERE Web](https://fous.com/automate/sifere-web.md)
- [Declaración en Línea (F.931)](https://fous.com/automate/declaracion-en-linea-f-931.md)
- [AFPnet](https://fous.com/automate/afpnet.md)
- [ARBA](https://fous.com/automate/arba.md)
- [SEACE](https://fous.com/automate/seace.md)
- [SECOP II](https://fous.com/automate/secop-ii.md)
- [BPS Servicios en Línea](https://fous.com/automate/bps-servicios-en-linea.md)
- [IESS - Portal de Empleadores](https://fous.com/automate/iess-portal-de-empleadores.md)
- [Oficina Virtual CCSS (SICERE)](https://fous.com/automate/oficina-virtual-ccss-sicere.md)
- [SUIR](https://fous.com/automate/suir.md)
- [Previred](https://fous.com/automate/previred.md)
- [Aportes en Línea](https://fous.com/automate/aportes-en-linea.md)
- [SOI](https://fous.com/automate/soi.md)
- [SIPARE](https://fous.com/automate/sipare.md)
- [DGI Servicios en Línea](https://fous.com/automate/dgi-servicios-en-linea.md)
- [e-Tax 2.0](https://fous.com/automate/e-tax-2-0.md)
- [Agencia Virtual SAT](https://fous.com/automate/agencia-virtual-sat.md)
- [Oficina Virtual DGII](https://fous.com/automate/oficina-virtual-dgii.md)
- [Portal del SAT (Factura Electrónica)](https://fous.com/automate/portal-del-sat-factura-electronica.md)
- [SII (Mi SII)](https://fous.com/automate/sii-mi-sii.md)
- [SUNAT Operaciones en Línea (SOL)](https://fous.com/automate/sunat-operaciones-en-linea-sol.md)
- [TRIBU-CR](https://fous.com/automate/tribu-cr.md)
- [Declaraciones y Pagos (SAT)](https://fous.com/automate/declaraciones-y-pagos-sat.md)
- [DIAN MUISCA](https://fous.com/automate/dian-muisca.md)

Other industries: [Egyptian Tax Authority e-Services](/automate/egyptian-tax-authority-e-services), [EU Funding & Tenders Portal](/automate/eu-funding-and-tenders-portal), [Chorus Pro](/automate/chorus-pro), [LOOP](/automate/loop), [Encompass TPO Connect](/automate/encompass-tpo-connect), [USPTO Trademark Center](/automate/uspto-trademark-center).

## Frequently asked questions

### Does SRI en Línea have an API?

Partly. The SRI publishes web services for issuers to send comprobantes electrónicos, get their authorization and check a comprobante's status by clave de acceso. The ficha técnica describes no web service that lists the comprobantes you received, and annexes and returns are filed in SRI en Línea.

### How do I download the facturas I received from the SRI?

In SRI en Línea, open Facturación Electrónica, then Comprobantes electrónicos recibidos, choose the Periodo emisión and Tipo de comprobante and select Consultar. The list shows each comprobante's issuer, clave de acceso, IVA and importe total, with its RIDE in PDF and a Descargar reporte link.

### How do I check whether an electronic invoice is valid?

Enter its clave de acceso or número de autorización, or upload its XML, on Validez de comprobantes under Facturación Electrónica; no sign-in is needed. The SRI also offers this check as the ConsultaComprobante web service, which returns AUTORIZADO, NO AUTORIZADO, PENDIENTE DE ANULAR or ANULADO.

### In what format is the ATS sent?

As one XML file with the matriz and all sucursales, compressed into a zip named ATmmaaaa.zip for the month and year. The SRI's ATS program and DIMM produce that XML, and the SRI publishes the ats.xsd schema and an example file.

### Is Fous affiliated with the Servicio de Rentas Internas?

No. Fous is an independent product. You use it with your own SRI en Línea account, and a method reads and does only what that account can.

Fous is an independent product: it is not affiliated with, endorsed by or sponsored by the operator of SRI en Línea (Servicio de Rentas Internas (SRI)). The name is used only to say which system this page is about. Something here wrong or out of date? Write to legal@fous.com.
