Skip to main content

SearchContractFiles

Searches contract files by full-text query, optionally filtered by group and account.

Request

GET /nxt?requestType=searchContractFiles

All endpoints use port 22024 by default.

Parameters

NameTypeDescriptionRequired
querystringSearch queryYes
keywordstringKeyword filterNo
groupstringGroup filterNo
accountstringAccount ID or SHAMWARI addressNo
firstIndexintPagination startNo
lastIndexintPagination endNo
includeDatabooleanInclude file data (default false)No

Response

{
"data": [
{
"transactionFullHash": "abc123...",
"name": "mycontract",
"description": "Smart contract",
"type": "text/plain",
"group": "default",
"isText": true,
"filename": "contract.wasm",
"timestamp": 1700000000
}
],
"errorCode": 0,
"errorDescription": ""
}

Example

curl "http://localhost:22024/nxt?requestType=searchContractFiles&query=mycontract"