Skip to content

align API docs with java-tron v4.8.2#353

Open
abn2357 wants to merge 1 commit into
tronprotocol:masterfrom
abn2357:align_api_with_482
Open

align API docs with java-tron v4.8.2#353
abn2357 wants to merge 1 commit into
tronprotocol:masterfrom
abn2357:align_api_with_482

Conversation

@abn2357

@abn2357 abn2357 commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Align the HTTP and JSON-RPC API docs with java-tron v4.8.2 behavior (Chinese translation).

  • Replace node.maxMessageSize error rows with node.http.maxMessageSize and HTTP 413 SizeLimitHandler behavior
  • Add oversized-body HTTP 413 rows to endpoints that lacked them
  • Document int64_as_string=true GET flag on applicable endpoints
  • Add blockTimestamp to JSON-RPC log outputs
  • Document maxLogFilterNum, maxAddressSize, maxResponseSize, maxBatchSize, and data/input alias handling for eth_call, eth_estimateGas, and buildTransaction
  • Align documented JSON parse errors with org.tron.json.JSONException after fastjson removal
  • Expand smart-contract trigger/constant/estimate error response rows with concrete CONTRACT_VALIDATE_ERROR messages
  • Document JSON-RPC safe block tag handling and eth_newFilter pending/safe errors
  • Correct JSON-RPC servlet-level error codes for parse errors, invalid requests, oversized responses, batch limits, and internal errors
  • Update demo JSONObject import to org.tron.json.JSONObject
  • Unify terminology: 区块号 -> 区块高度, 无效果 -> 无影响, abi.encode -> ABI 编码

Test plan

  • Verified changed config keys, error messages, and JSON values against java-tron v4.8.2
  • Cross-checked against the English docs for parity

@abn2357 abn2357 force-pushed the align_api_with_482 branch from 13d8c86 to 64d5c27 Compare July 8, 2026 09:08
- Replace node.maxMessageSize error rows with node.http.maxMessageSize and HTTP 413 SizeLimitHandler behavior
- Add oversized-body HTTP 413 rows to endpoints that lacked them
- Document int64_as_string=true GET flag on applicable endpoints
- Add blockTimestamp to JSON-RPC log outputs
- Document maxLogFilterNum, maxAddressSize, maxResponseSize, maxBatchSize, and data/input alias handling for eth_call, eth_estimateGas, and buildTransaction
- Align documented JSON parse errors with org.tron.json.JSONException after fastjson removal
- Expand smart-contract trigger/constant/estimate error response rows with concrete CONTRACT_VALIDATE_ERROR messages
- Document JSON-RPC safe block tag handling and eth_newFilter pending/safe errors
- Correct JSON-RPC servlet-level error codes for parse errors, invalid requests, oversized responses, batch limits, and internal errors
- Clarify unstable JSON-RPC error mappings and parameter-level validation for eth_chainId, net_version, eth_getStorageAt, eth_getLogs, and eth_estimateGas
- Update demo JSONObject import to org.tron.json.JSONObject
- Unify terminology: 区块号 -> 区块高度, 无效果 -> 无影响, abi.encode -> ABI 编码
@abn2357 abn2357 force-pushed the align_api_with_482 branch from 64d5c27 to 139efc7 Compare July 8, 2026 10:22
@vivian1912

Copy link
Copy Markdown
Contributor

The API docs were updated for java-tron v4.8.2 behavior, but the machine-readable OpenAPI/OpenRPC definitions were not updated in the same PR.

This creates a contract mismatch for SDK generators, tool integrations, and AI agents. For example, the human docs now describe int64_as_string, CallArguments.input / BuildArguments.input, and blockTimestamp, but docs/api/openapi.yaml, docs/api/openrpc.json, and the per-endpoint files under docs/api/specs/ still omit those fields or response variants.

@abn2357

abn2357 commented Jul 9, 2026

Copy link
Copy Markdown
Contributor Author

The API docs were updated for java-tron v4.8.2 behavior, but the machine-readable OpenAPI/OpenRPC definitions were not updated in the same PR.

This creates a contract mismatch for SDK generators, tool integrations, and AI agents. For example, the human docs now describe int64_as_string, CallArguments.input / BuildArguments.input, and blockTimestamp, but docs/api/openapi.yaml, docs/api/openrpc.json, and the per-endpoint files under docs/api/specs/ still omit those fields or response variants.

Thanks. They are separated for now, and the spec will be updated later. To keep consistency, the maintainer of this repo can merge them together afterwards.
Your suggestion is great, I will consider combining them for future updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants