The Spanish version is the authoritative reference. View in Spanish
Brazil: Methods and Parameters (API)
Authentication
NDD supports both authentication methods of the Gosocket API. They are not alternatives on the same endpoint: each method lives on a different version of the URL.
| Basic Auth | OAuth 2.0 | |
|---|---|---|
| Endpoint version | /api/v1/Document/... | /api/v2/Document/... |
| How it's sent | Authorization header, username = API Key, password = API Secret, on every request | Bearer token obtained from /oauth2/token (client_id = API Key, client_secret = API Secret); expires after a limited time and must be renewed |
| Credentials | Generated in the Gosocket portal | Same Gosocket portal credentials — nothing additional to request |
All three NDD methods (SendDocumentToAuthority, GetDocument, ChangeDocumentStatus) are available on both v1 and v2 with the same request/response contract — only the version segment in the URL and the authentication mechanism change. Pick one version for the whole integration; don't combine v1 and v2 calls in the same session.
For the step-by-step on how to obtain and renew the OAuth 2.0 token (/oauth2/token parameters, validity, how to use it as a Bearer Token), see the general authentication reference — it applies the same way to NDD.
Environments
Basic Auth — v1
https://developers-sbx.gosocket.net/api/v1/Documenthttps://developers.gosocket.net/api/v1/DocumentOAuth 2.0 — v2
https://developers-sbx.gosocket.net/api/v2/Documenthttps://developers.gosocket.net/api/v2/DocumentAvailable methods
SendDocumentToAuthorityPOSTSends an electronic document to the tax authority (SEFAZ or Prefeitura) via NDD.GetDocumentPOSTQueries the status and metadata of a document registered on the Gosocket platform.ChangeDocumentStatusPOSTExecutes events on a document: cancellation, correction letter, operation confirmation, among others.