Skip to main content

API Reference

ZKT OpenAPI Specification

Click here to go to our OpenAPI documentation site for the Zero-Knowledge Transactions (ZKT) API. This includes the request schemas (V1 and V2), response objects (success or error), error fields and an OpenAPI YAML download link.

How to Use the Specification

  • You can copy the OpenAPI YAML above into a file named openapi.yaml (or similar).
  • This specification is compatible with tools like Swagger UI, Redoc, or any OpenAPI v3.0.3-compatible library.
  • It documents how to submit V1 and V2 style transactions, along with the standardized success and error response formats.

Request Types

Select a Tab Below

ZKT supports three different request types. Use the tabs below to toggle between them:

ZktV1: Write Message to Blockchain

Use ZktV1 to post simple messages to the blockchain without interacting with smart contracts.


Parameters

FieldTypeDescriptionRequired
argumentsstringThe message you want to post to the blockchainYes

Request Example

curl -X POST "https://rpc.stabilityprotocol.com/zkt/try-it-out" \
-H "Content-Type: application/json" \
--data '{ "arguments": "Your message here" }'

Response:

{
"success": true,
"hash": "0x48b3861c7e04e82fd7bfcec4a1e370950abb65851b6a676515bbc8bee01b470d"
}

After submitting a transaction, you may want to check its status. The next section covers how to monitor your transactions.