1. Inicio
  2. Documentos
  3. NS CTe (English)
  4. CTe Utility Functions
  5. List of nsNRecs linked to a CT-e

List of nsNRecs linked to a CT-e

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.

FieldDescriptionData TypeOccurrenceNotes
X-AUTH-TOKENUser access tokenString1-1
chCTeCT-e access keyInt1-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
FieldDescriptionData TypeOccurrenceParentNotes
statusProcessing status codeInt1-1
motivoProcessing status literal descriptionString1-1
nsNRecsObject contaning the requested person's dataArray1-1Will only contain items if found nsNRecs linked to given CT-e key
nsNRecLinked nsNRecInt1-1nsNRecs
cStatnsNRec status codeInt1-1nsNRecs
xMotvonsNRec status literal descriptionString1-1nsNRecs
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
CodeDescription
200Consult carried out successfully
-2Invalid access key

Como podemos ajudar?