Get Transaction Status - Get Transaction Status
取得交易標識碼所識別之項目的狀態。
GET {ledgerEndpoint}/app/transactions/{transactionId}/status?api-version=2022-05-13
URI 參數
名稱 | 位於 | 必要 | 類型 | Description |
---|---|---|---|---|
ledger
|
path | True |
string (url) |
機密總賬 URL,例如 |
transaction
|
path | True |
string |
標識寫入事務。 |
api-version
|
query | True |
string |
要與 HTTP 要求搭配使用的 API 版本。 |
回應
名稱 | 類型 | Description |
---|---|---|
200 OK |
在指定交易 ID 處記錄的條目的狀態。 |
|
Other Status Codes |
描述作業為何失敗的錯誤回應 |
範例
GetTransactionStatus
範例要求
GET {ledgerEndpoint}/app/transactions/4.2/status?api-version=2022-05-13
範例回覆
{
"state": "Committed",
"transactionId": "4.2"
}
定義
名稱 | Description |
---|---|
Confidential |
機密總賬的錯誤回應。 |
Confidential |
機密總賬的錯誤回應。 |
Transaction |
表示交易的狀態。 |
Transaction |
傳回交易狀態查詢的回應 |
ConfidentialLedgerError
機密總賬的錯誤回應。
名稱 | 類型 | Description |
---|---|---|
error |
機密總賬的錯誤回應。 |
ConfidentialLedgerErrorBody
機密總賬的錯誤回應。
名稱 | 類型 | Description |
---|---|---|
code |
string |
錯誤碼。 |
message |
string |
錯誤訊息。 |
TransactionState
表示交易的狀態。
值 | Description |
---|---|
Committed | |
Pending |
TransactionStatus
傳回交易狀態查詢的回應
名稱 | 類型 | Description |
---|---|---|
state |
表示交易的狀態。 |
|
transactionId |
string |
總賬狀態的唯一標識碼。 如果當做 LedgerEntry 的一部分傳回,表示從中讀取項目的狀態。 |