> ## Documentation Index
> Fetch the complete documentation index at: https://docs.emiti.fravelabs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Estado oficial en SIFEN

> Consulta el estado real de un DE directo en SIFEN y reconcilia con la BD local.

Consulta el estado **oficial actual** de un DE directo al webservice de SIFEN/DNIT y **reconcilia** el estado almacenado en e-Miti si difiere. Útil cuando:

* Sospechás que un DE quedó **colgado** en estado `P` o `E` (el callback async se perdió).
* Querés confirmar antes de un cierre fiscal que lo que tenés en tu sistema coincide con lo que SIFEN tiene oficialmente.
* Auditoría regulatoria — pedir el estado autoritativo.

## Diferencia con el detalle

| Endpoint                                     | Fuente del estado                                                         |
| -------------------------------------------- | ------------------------------------------------------------------------- |
| [`GET /v1/de/{cdc}`](/api-reference/detalle) | Estado **local** de e-Miti (lo que persiste la BD).                       |
| `GET /v1/de/{cdc}/sifen-status`              | Estado **oficial** según SIFEN, con reconciliación automática si difiere. |

Por defecto usá el detalle (más rápido). Usá este endpoint cuando tengas razones para dudar del estado local.

## Errores frecuentes

| Status / código           | Causa                     | Acción              |
| ------------------------- | ------------------------- | ------------------- |
| `503 SIFEN_NO_DISPONIBLE` | SIFEN está caído o lento. | Reintentar después. |
| `404 DE_NO_ENCONTRADO`    | CDC no existe en e-Miti.  | Verificar el CDC.   |


## OpenAPI

````yaml GET /v1/de/{cdc}/sifen-status
openapi: 3.1.0
info:
  title: eMiti API
  description: >-
    API de emisión de Documentos Tributarios Electrónicos (DTE) bajo SIFEN/DNIT
    Paraguay.
  version: 1.1.0
servers:
  - url: https://api.emiti.fravelabs.com
    description: Producción
  - url: https://api.qa.emiti.fravelabs.com
    description: QA
  - url: https://api.dev.emiti.fravelabs.com
    description: Desarrollo (Homologación SIFEN)
security:
  - ApiKeyAuth: []
paths:
  /v1/de/{cdc}/sifen-status:
    get:
      summary: GET /v1/de/{cdc}/sifen-status
      operationId: sifen_status_v1_de__cdc__sifen_status_get
      parameters:
        - required: true
          schema:
            type: string
            title: Cdc
          name: cdc
          in: path
      responses:
        '200':
          description: Successful Response
          content:
            application/json: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization

````