---
title: "Sync SAT data"
description: "Refresh one SAT source for the active organization. Use documents for CFDIs/withholdings in a date range, declarations for one fiscal year, or compliance_opinion for the latest SAT opinion. This starts external SAT work; read results with search_documents or get_tax_summary."
language: en
canonical_url: "https://exac.mx/docs/en/mcp/tools/sync_sat_data"
md_url: "https://exac.mx/docs/en/mcp/tools/sync_sat_data.md"
---

# Sync SAT data

Refresh one SAT source for the active organization. Use documents for CFDIs/withholdings in a date range, declarations for one fiscal year, or compliance_opinion for the latest SAT opinion. This starts external SAT work; read results with search_documents or get_tax_summary.

Tool: `sync_sat_data`

## Purpose

Start a refresh for one permitted SAT data source.

### Use when

SAT-backed documents, declarations, or opinions need refreshing.

### Do not use when

You only need to read data already synchronized.

| Detail | Value |
| --- | --- |
| Permissions | sat:manage |
| Side effects | External side effect |
| Idempotency | Idempotent |

## Input schema

```json
{
  "type": "object",
  "properties": {
    "idempotencyKey": {
      "type": "string",
      "minLength": 1,
      "maxLength": 200,
      "description": "Unique retry key for this exact operation. Reuse it only when retrying the same request."
    },
    "input": {
      "oneOf": [
        {
          "$ref": "#/definitions/__schema0"
        },
        {
          "$ref": "#/definitions/__schema2"
        },
        {
          "$ref": "#/definitions/__schema3"
        }
      ],
      "description": "SAT source to refresh and only the arguments required by that source."
    }
  },
  "required": [
    "idempotencyKey",
    "input"
  ],
  "$schema": "http://json-schema.org/draft-07/schema#",
  "additionalProperties": false,
  "definitions": {
    "__schema0": {
      "type": "object",
      "properties": {
        "source": {
          "type": "string",
          "const": "documents"
        },
        "dateFrom": {
          "$ref": "#/definitions/__schema1"
        },
        "dateTo": {
          "$ref": "#/definitions/__schema1"
        },
        "kind": {
          "type": "string",
          "enum": [
            "all",
            "invoices",
            "withholdings"
          ]
        }
      },
      "required": [
        "source",
        "dateFrom",
        "dateTo"
      ],
      "additionalProperties": false
    },
    "__schema1": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$"
    },
    "__schema2": {
      "type": "object",
      "properties": {
        "source": {
          "type": "string",
          "const": "declarations"
        },
        "fiscalYear": {
          "type": "integer",
          "minimum": 2000,
          "maximum": 2100
        }
      },
      "required": [
        "source",
        "fiscalYear"
      ],
      "additionalProperties": false
    },
    "__schema3": {
      "type": "object",
      "properties": {
        "source": {
          "type": "string",
          "const": "compliance_opinion"
        }
      },
      "required": [
        "source"
      ],
      "additionalProperties": false
    }
  }
}
```

## Output schema

```json
{
  "type": "object",
  "properties": {
    "data": {
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "source": {
              "type": "string",
              "const": "documents"
            },
            "status": {
              "type": "string",
              "const": "scheduled"
            },
            "scheduled": {
              "type": "number"
            }
          },
          "required": [
            "source",
            "status",
            "scheduled"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "source": {
              "type": "string",
              "const": "declarations"
            },
            "status": {
              "type": "string",
              "const": "completed"
            },
            "fiscalYear": {
              "type": "number"
            },
            "declarations": {
              "type": "number"
            },
            "paymentsMatched": {
              "type": "number"
            },
            "filesDownloaded": {
              "type": "number"
            }
          },
          "required": [
            "source",
            "status",
            "fiscalYear",
            "declarations",
            "paymentsMatched",
            "filesDownloaded"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "source": {
              "type": "string",
              "const": "compliance_opinion"
            },
            "status": {
              "type": "string",
              "const": "scheduled"
            }
          },
          "required": [
            "source",
            "status"
          ],
          "additionalProperties": false
        }
      ]
    },
    "error": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "type": "object",
      "properties": {
        "code": {
          "type": "string",
          "enum": [
            "validation_error",
            "unauthenticated",
            "forbidden",
            "not_found",
            "method_not_allowed",
            "conflict",
            "idempotency_conflict",
            "operation_in_progress",
            "recovery_required",
            "rate_limited",
            "provider_unavailable",
            "internal"
          ]
        },
        "message": {
          "type": "string"
        },
        "details": {
          "type": "object",
          "properties": {
            "issues": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "path": {
                    "type": "array",
                    "items": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "number"
                        }
                      ]
                    }
                  },
                  "message": {
                    "type": "string"
                  },
                  "code": {
                    "type": "string"
                  }
                },
                "required": [
                  "path",
                  "message"
                ],
                "additionalProperties": false
              }
            },
            "retryable": {
              "type": "boolean"
            },
            "retryAfterSeconds": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991
            }
          },
          "additionalProperties": false
        }
      },
      "required": [
        "code",
        "message"
      ],
      "additionalProperties": false
    }
  },
  "$schema": "http://json-schema.org/draft-07/schema#",
  "additionalProperties": false,
  "oneOf": [
    {
      "required": [
        "data"
      ]
    },
    {
      "required": [
        "error"
      ]
    }
  ]
}
```

## Related tools

- [`search_documents`](/docs/en/mcp/tools/search_documents.md) — **Search documents**: Search one public document family at a time. Use cfdi for income, credit-note, transfer, payroll, and payment-complement documents; use withholding, sales_receipt, quote, expense, declaration, tax_compliance_opinion, or sales_receipt_refund for the other families.

- [`get_tax_summary`](/docs/en/mcp/tools/get_tax_summary.md) — **Get tax summary**: Get authoritative taxes declared, paid, and pending for a fiscal year or month. Tax amounts come only from parsed declarations; CFDI contributor context is informational and never affects tax totals. If declarations are unavailable, tax totals are null rather than estimated.

## Related workflow

[See the canonical workflows in the introduction](/docs/en.md)

## Equivalent REST operations

- [`POST /v1/tax/sync`](/docs/en/api/tax-reports/sat/sync-tax-data.md)

Complete documentation: https://exac.mx/docs/en.md
Agent documentation index: https://exac.mx/docs/en/llms.txt
