> For the complete documentation index, see [llms.txt](https://docs.giro.tech/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.giro.tech/desenvolvedores/api-gtsign/documentos/buscar-documento-por-uuid-ou-referencia.md).

# Buscar Documento por UUID ou Referência

O processo para buscar um documento por UUID ou Referência pode ser feito seguindo esta requisição:

## GET /documents/my-company/{uuid}

> Busca um documento pelo UUID

```json
{"openapi":"3.0.0","info":{"title":"GTSign API","version":"1.0.0"},"servers":[{"url":"https://app.staging.gtsign.giro.tech/api","description":"Ambiente de Staging"},{"url":"https://api.gtsign.giro.tech","description":"Ambiente de Produção"}],"security":[{"jwtAuth":[]}],"components":{"securitySchemes":{"jwtAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"JWT token fornecido pelo administrador"}}},"paths":{"/documents/my-company/{uuid}":{"get":{"summary":"Busca um documento pelo UUID","parameters":[{"name":"uuid","in":"path","required":true,"description":"UUID do documento criado","schema":{"type":"string"}}],"responses":{"200":{"description":"Documento retornado com sucesso","content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"uuid":{"type":"string"},"name":{"type":"string"},"externalIdentification":{"type":"string"},"hashMD5":{"type":"string"},"hashSha256":{"type":"string"},"originalDocument":{"type":"object","properties":{"id":{"type":"integer"},"contentType":{"type":"string"},"fileName":{"type":"string"},"presignedUrl":{"type":"string"},"processed":{"type":"boolean"}}},"signedDocument":{"type":"object","properties":{"id":{"type":"integer"},"contentType":{"type":"string"},"fileName":{"type":"string"},"presignedUrl":{"type":"string"},"processed":{"type":"boolean"}}},"status":{"type":"string","enum":["CREATED","SIGNING","FINISHED","CANCELED"]},"deadline":{"type":"string","format":"date"},"notificationPeriodDelivery":{"type":"integer","enum":[3,6,9,12]},"personSignatures":{"type":"array","items":{"type":"object","properties":{"uuid":{"type":"string"},"email":{"type":"string"},"name":{"type":"string"},"status":{"type":"string","enum":["PENDING","SIGNED","CANCELED","EXPIRED"]},"signatureType":{"type":"string","enum":["PART","WITNESS","CONTRACTOR","HIRED","ADMINISTRATOR","GUARANTOR","TRANSFEROR","TRANSFEREE","JOINT_DEBTOR","ISSUER","ENDORSER","ENDORSEE","WARRANTOR","MANAGER","LESSOR","LESSEE","PURCHASER","SELLER","ATTORNEY","LEGAL_REPRESENTATIVE","VALIDATOR"]},"notificationChannel":{"type":"string","enum":["EMAIL","WHATSAPP","WEBHOOK"]},"person":{"type":"object","properties":{"uuid":{"type":"string"},"cpf":{"type":"string"}}},"birth":{"type":"string","format":"date"},"personSignatureDate":{"type":"string","format":"date-time"}}}}}},{"type":"object","properties":{"company":{"type":"object","properties":{"id":{"type":"integer"}}},"originalDocumentDate":{"type":"string","format":"date-time"},"signedDocumentDate":{"type":"string","format":"date-time"}}}]}}}},"404":{"description":"Documento não encontrado"}}}}}}
```

## GET /documents/my-company/external-identification/{externalIdentification}

> Busca um documento pela Identificação Externa

```json
{"openapi":"3.0.0","info":{"title":"GTSign API","version":"1.0.0"},"servers":[{"url":"https://app.staging.gtsign.giro.tech/api","description":"Ambiente de Staging"},{"url":"https://api.gtsign.giro.tech","description":"Ambiente de Produção"}],"security":[{"jwtAuth":[]}],"components":{"securitySchemes":{"jwtAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"JWT token fornecido pelo administrador"}}},"paths":{"/documents/my-company/external-identification/{externalIdentification}":{"get":{"summary":"Busca um documento pela Identificação Externa","parameters":[{"name":"externalIdentification","in":"path","required":true,"description":"Identificação Externa do documento criado","schema":{"type":"string"}}],"responses":{"200":{"description":"Documento retornado com sucesso","content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"uuid":{"type":"string"},"name":{"type":"string"},"externalIdentification":{"type":"string"},"hashMD5":{"type":"string"},"hashSha256":{"type":"string"},"originalDocument":{"type":"object","properties":{"id":{"type":"integer"},"contentType":{"type":"string"},"fileName":{"type":"string"},"presignedUrl":{"type":"string"},"processed":{"type":"boolean"}}},"signedDocument":{"type":"object","properties":{"id":{"type":"integer"},"contentType":{"type":"string"},"fileName":{"type":"string"},"presignedUrl":{"type":"string"},"processed":{"type":"boolean"}}},"status":{"type":"string","enum":["CREATED","SIGNING","FINISHED","CANCELED"]},"deadline":{"type":"string","format":"date"},"notificationPeriodDelivery":{"type":"integer","enum":[3,6,9,12]},"personSignatures":{"type":"array","items":{"type":"object","properties":{"uuid":{"type":"string"},"email":{"type":"string"},"name":{"type":"string"},"status":{"type":"string","enum":["PENDING","SIGNED","CANCELED","EXPIRED"]},"signatureType":{"type":"string","enum":["PART","WITNESS","CONTRACTOR","HIRED","ADMINISTRATOR","GUARANTOR","TRANSFEROR","TRANSFEREE","JOINT_DEBTOR","ISSUER","ENDORSER","ENDORSEE","WARRANTOR","MANAGER","LESSOR","LESSEE","PURCHASER","SELLER","ATTORNEY","LEGAL_REPRESENTATIVE","VALIDATOR"]},"notificationChannel":{"type":"string","enum":["EMAIL","WHATSAPP","WEBHOOK"]},"person":{"type":"object","properties":{"uuid":{"type":"string"},"cpf":{"type":"string"}}},"birth":{"type":"string","format":"date"},"personSignatureDate":{"type":"string","format":"date-time"}}}}}},{"type":"object","properties":{"company":{"type":"object","properties":{"id":{"type":"integer"}}},"originalDocumentDate":{"type":"string","format":"date-time"},"signedDocumentDate":{"type":"string","format":"date-time"}}}]}}}},"404":{"description":"Documento não encontrado"}}}}}}
```

<figure><img src="https://978140111-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FF6l1W0qI0y7eF7f0QRDC%2Fuploads%2Fgit-blob-f5d2064d02c970341ca52b2c083eb1f585bc436a%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

{% embed url="<https://giro.tech/central-de-atendimento/>" %}
