Create an extraction
Create an extraction for a specific entity, extractor, and options.
If an equivalent extraction is already pending or running for the same entity, extractor, and options, the API returns 409 Conflict instead of starting a duplicate. Retrieve the in-progress extraction to track its status rather than retrying the request.
Authorizations
Your API key is available in the Production and Sandbox dashboards.
Body
- Option 1
- Option 2
Entity IRI reference
"/entities/7b3a25a9-a53a-4846-abe6-f2574c9c2d5d"
Extractor to run, which retrieves resources from the corresponding datasource
invoice, monthly_tax_return, annual_tax_return, rif_tax_return, tax_status, tax_retention, tax_compliance, electronic_accounting, sat_certificates, rpc, buro_de_credito_report, bil, rug, background_check, infonavit Extractor options; check the available options for each extractor in Extractions
Response
Extraction resource response
Extraction IRI reference
"/extractions/91106968-1abd-4d64-85c1-4e73d96fb997"
JSON-LD resource type
Unique extraction ID
"91106968-1abd-4d64-85c1-4e73d96fb997"
Extractor to run, which retrieves resources from the corresponding datasource
invoice, monthly_tax_return, annual_tax_return, rif_tax_return, tax_status, tax_retention, tax_compliance, electronic_accounting, sat_certificates, rpc, buro_de_credito_report, bil, rug, background_check, infonavit Extractor options; check the available options for each extractor in Extractions
pending, running, finished, failed, stopping, stopped Time when the status changed from pending to running
Time when the status changed from running to finished or failed
This field returns a date when the taxpayer reached the max amount of downloaded CFDI files allowed by SAT in a range of 24hrs. You should retry this extraction 24hrs later. If your taxpayer has not reached the max amount this value should be NULL
"2019-01-03T21:10:40.000Z"
invalid_credentials, login_failed, unrecoverable, sat_unavailable, internal_error, undefined null
This is the number of created resources. For example, if 1 invoice was created with its XML and PDF file this value should be 3. And If you previously extracted all the resources and there are no more resources to create this value is 0.
3
When your taxpayer has resources by a previous extraction and new extraction found changes between our data and Sat data it would update this resource. For example, when a new extraction finds a Canceled invoice which you previously extracted as an Active invoice.
2
Date and time the resource was created
"2020-01-01T12:15:00.000Z"
Date and time the resource was last updated
"2020-01-01T12:15:00.000Z"