Audits priv/endpoints/nfe_4.00.json.
mix sefaz.endpoints
mix sefaz.endpoints --max-age 90AD-004 makes the endpoint table data owned by the RFB, not by this repository, refreshed from the official portal. The portal blocks automated fetching, so this task deliberately does not scrape it: a scraper that silently returns a login page would replace a stale table with a wrong one. It audits what is vendored and prints the manual procedure instead.
Reports a non-zero exit when the snapshot is older than --max-age days
(default 180) or fails a structural check, so CI can fail on a stale table
rather than a production call discovering it.
Refresh procedure
- Open https://www.nfe.fazenda.gov.br/portal/webServices.aspx and read the table for layout 4.00, model 55.
- Update
priv/endpoints/nfe_4.00.json:authorizersholds one entry per authorizer withhomologationandproductionURLs per service,uf_authorizermaps each UF to its authorizer,uf_codethe IBGE code the envelopes carry ascUF. - Set
snapshot_dateto the date you read the portal. - Run
mix sefaz.endpointsandmix test.
The nfephp wsnfe_4.00_mod55.xml mirror is a useful cross-check, never the
source of truth.
Summary
Functions
Every problem found in snapshot, as human-readable strings. Empty means it
is usable.
Functions
@spec audit(map(), pos_integer()) :: [String.t()]
Every problem found in snapshot, as human-readable strings. Empty means it
is usable.