Enviar transação
A maioria dos endpoints da Trustless Work retorna uma transação não assinada no formato XDR. Este endpoint é usado para assinar essas transações não assinadas e enviá-las para a rede Stellar.
Cabeçalhos
Nome
Valor
Content-Type
application/json
x-api-key
<token>
Open API
post
Autorizações
Corpo
signedXdrstringObrigatórioExample:
The sign's hash. This come from the wallet
AAAAAgAAAAB...Respostas
200
The transaction has been successfully sent to the Stellar network
application/json
400
Bad request
401
Unauthorized access
429
Too Many Requests
500Erro
application/json
post/helper/send-transaction
POST /helper/send-transaction HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 30
{
"signedXdr": "AAAAAgAAAAB..."
}{
"status": "SUCCESS",
"message": "The transaction has been successfully sent to the Stellar network.",
"contractId": "CAATN5D...",
"escrow": {
"amount": 50,
"roles": {
"approver": "GAWVVSA...",
"serviceProvider": "GAWVVSA6...",
"disputeResolver": "GAWVVSA...",
"receiver": "GAWVVSA...",
"platformAddress": "GAWVVSA...",
"releaseSigner": "GAWVVSA..."
},
"flags": {
"disputed": false,
"released": false,
"resolved": false
},
"description": "This is a sample TW escrow for testing purposes",
"engagementId": "ENG12345",
"milestones": [
{
"approved": false,
"description": "Initial milestone",
"evidence": "",
"status": "pending"
},
{
"approved": false,
"description": "Second milestone",
"evidence": "",
"status": "pending"
}
],
"platformFee": 5,
"title": "Sample TW Escrow",
"trustline": {
"address": "CBIELTK...",
"name": "USDC"
},
"receiverMemo": 90909090
}
}Exemplo de Uso:
Atualizado