Through this endpoint it’s possible to consult the list of nsNRecs linked to a CT-e using its access key.
URL
Production: POST https://cte.ns.eti.br/util/list/nsnrecs
Input data
The input data of this method can be sent in the request body in JSON format or as QueryString in the URL of the method.
Field | Description | Data Type | Occurrence | Notes |
---|---|---|---|---|
X-AUTH-TOKEN | User access token | String | 1-1 | |
chCTe | CT-e access key | Int | 1-1 |
Request example
NSNRecs List Request
curl -X POST \
-H "Content-Type: application/json" \
-d '{
"X-AUTH-TOKEN": "YOUR_TOKEN",
"chCTe": "35170120121850000156570010002037451076558734"
}'\
https://cte.ns.eti.br/util/list/nsnrecs
Returned data
Field | Description | Data Type | Occurrence | Parent | Notes |
---|---|---|---|---|---|
status | Processing status code | Int | 1-1 | ||
motivo | Processing status literal description | String | 1-1 | ||
nsNRecs | Object contaning the requested person's data | Array | 1-1 | Will only contain items if found nsNRecs linked to given CT-e key | |
nsNRec | Linked nsNRec | Int | 1-1 | nsNRecs | |
cStat | nsNRec status code | Int | 1-1 | nsNRecs | |
xMotvo | nsNRec status literal description | String | 1-1 | nsNRecs |
Return example
Successful return
{
"status": 200,
"motivo": "Consulta realizada com sucesso",
"nsNRecs": [
{
"nsNRec": 210584,
"cStat": 100,
"xMotivo": "Autorizado o uso do CT-e"
}
]
}
Return codes
Code | Description |
---|---|
200 | Consult carried out successfully |
-2 | Invalid access key |