Inspect dApp state REST API
GET/:payload
This method sends an inspect-state request to the dApp backend passing the payload string in the URL. The payload string should be URL-encoded; the inspect server will decode the string to UTF-8. If the dApp frontend needs to pass a binary string to the backend then it is advised to use the base64 encoding.
The response contains a status string and the reports generated by the dApp backend. The status string can be either 'accept', 'reject', or 'exception'. In case of exception, the field exception_payload will contain the exception payload; Otherwise, this field will be null.
When running on machine mode, the whole Cartesi Machine is rolled back after processing the inspect-state request. On host mode, it is advised against changing the dApp backend state when processing an inspect-state request. Notice that this method is synchronous, so it is not advised to perform resource-intensive operations.
Request
Responses
- 200
- default
Inspect state response.
Error response.