> For the complete documentation index, see [llms.txt](https://docs.trustlesswork.com/trustless-work/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.trustlesswork.com/trustless-work/v1-pt/api-rest/indexador/update-escrow-properties.md).

# Atualizar a partir do hash da transação

Este endpoint permite alterar as propriedades de um escrow desde que uma série de requisitos seja atendida, os quais serão mencionados nesta seção.

### Requisitos para Uso:

* Você deve ter o `txHash` válido gerado a partir de uma transação enviada diretamente para a rede Stellar.
* Os dados de escrow associados a este `txHash` devem já existir na fila interna.

### Cabeçalhos

<table><thead><tr><th width="366">Nome</th><th>Valor</th></tr></thead><tbody><tr><td>Content-Type</td><td><code>application/json</code></td></tr><tr><td>x-api-key</td><td><code>&#x3C;token></code></td></tr></tbody></table>

### Fluxo de trabalho:

1. O XDR é obtido a partir de qualquer transação (não assinada) gerada com qualquer um dos endpoints da nossa API REST.
2. Um XDR não assinado é gerado e retornado.
3. O XDR é assinado externamente e enviado diretamente para a Stellar.
4. O `txHash` resultante é recuperado.
5. O `txHash` é enviado para `/indexer/update-from-txHash`.
6. As informações de escrow são recuperadas da fila interna e armazenadas no Firebase.

### Open API

## PUT /indexer/update-from-txhash

>

```json
{"openapi":"3.0.0","info":{"title":"Trustless Work API","version":"1.0"},"security":[{}],"paths":{"/indexer/update-from-txhash":{"put":{"operationId":"IndexerController_updateFromTxHash","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveIndexedEscrowClass"}}}},"responses":{"200":{"description":"Returns the escrow object that was just saved/updated in the indexer and the success or failure of the response.","content":{"application/json":{}}},"400":{"description":"Bad request"},"401":{"description":"Unauthorized access"},"429":{"description":"Too Many Requests"},"500":{"description":"\n      <p>Possible errors:</p>\n      <ul>\n        <li>Error processing transaction b0e61d4...f1cb2d29: <error_message></li>\n        <li>An unexpected error occurred</li>\n      </ul>","content":{"application/json":{}}}},"tags":["Indexer"]}}},"components":{"schemas":{"SaveIndexedEscrowClass":{"type":"object","properties":{"txHash":{"type":"string","description":"Transaction hash"}},"required":["txHash"]}}}}
```

### Exemplo de uso:

```typescript
import axios from "axios";

const http = axios.create({
  baseURL: "https://dev.api.trustlesswork.com",
  timeout: 10000,
  headers: {
    "Content-Type": "application/json",
    "x-api-key": sua_chave_api,
  },
});

export const updateEscrowFromTxHash = async (txHash) => {
  const response = await http.post("/indexer/update-from-txHash", { txHash });
  return response.data;
};
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.trustlesswork.com/trustless-work/v1-pt/api-rest/indexador/update-escrow-properties.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
