Alterar status do marco
Responsável por alterar o status do marco de um escrow por meio do provedor de serviço.
Cabeçalhos
Nome
Valor
Content-Type
application/json
x-api-key
<token>
Open API
post
Autorizações
Corpo
contractIdstringObrigatórioExample:
ID (address) that identifies the escrow contract
CAZ6UQX7...milestoneIndexstringObrigatórioExample:
milestone within the group of milestones in the escrow
1newEvidencestringObrigatórioExample:
New value for the evidence property within the escrow milestone
EvidencenewStatusstringObrigatórioExample:
New value for the status property within the escrow milestone
CompletedserviceProviderstringObrigatórioExample:
Address of the entity providing the service
CompletedRespostas
201
This endpoint returns an unsigned transaction in XDR format. This XDR is then used to sign the transaction using the “/helper/send-transaction” endpoint.
application/json
400
Bad request
401
Unauthorized access
429
Too Many Requests
500
Possible errors:
- Escrow not found
- Only the service provider can change milestone status
- Invalid milestone index
- Escrow initialized without milestone
- An unexpected error occurred
application/json
post/escrow/single-release/change-milestone-status
POST /escrow/single-release/change-milestone-status HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 177
{
"contractId": "CAZ6UQX7...",
"milestoneIndex": "1",
"newEvidence": "Any evidence that the milestone is completed",
"newStatus": "Completed",
"serviceProvider": "GAPPROVER1234567890..."
}{
"status": "SUCCESS",
"unsignedTransaction": "AAAAAgAAAAAtWsgedQ...."
}
O que este Endpoint retorna?
Este endpoint retorna a transação não assinada para que a transação possa ser assinada por meio da carteira do cliente.
Exemplo de uso:
Atualizado