Documentation for JSON RPC Endpoint: queryGroupMessages
Overview
The queryGroupMessages method is used to retrieve messages within a specified conversation. This method requires two parameters: a unique identifier for the conversation (conversationId) and the maximum number of results to return (limit).
JSON RPC Endpoint Specification
Request:
Method:POST
URL:/rpc/v1/queryGroupMessages
Headers:
Content-Type: application/json
Body:
JSON Object:
jsonrpc: "2.0"
method: "queryGroupMessages"
params: Array (optional parameters as required)
id: Request identifier (integer or string)
Method Name
queryGroupMessages
Request Parameters
conversationId: A unique identifier for the conversation. This is a 32-byte string, typically in hexadecimal format.
limit: The limit on the number of messages to return, server will enforce a maximum of 500
lastBlock: The last block to consider for this request, optionally empty, indicating the most recent block
jsonrpc: Specifies the version of the JSON RPC protocol being used. Always "2.0".
method: The name of the method being called. Here it is "rewindMessage".
params: A structured value holding the parameters necessary for the method. It contains:
conversationId: The unique identifier for the conversation.
limit: The maximum number of messages to return, server enforced limit is 500
id: A unique identifier established by the client that must be number or string. Used for correlating the response with the request.
Response Format
The response will include the result of the operation or an error if the operation was unsuccessful. The included array (message) will contain the messages requested. The block range covered by this operation, (startBlock –endBlock) will be included in the result. The block range may be using for paging over past results.
Documentation for JSON RPC Endpoint:
queryGroupMessages
Overview
The
queryGroupMessages
method is used to retrieve messages within a specified conversation. This method requires two parameters: a unique identifier for the conversation (conversationId
) and the maximum number of results to return (limit
).JSON RPC Endpoint Specification
Request:
POST
/rpc/v1/queryGroupMessages
Content-Type: application/json
jsonrpc
:"2.0"
method
:"queryGroupMessages"
params
: Array (optional parameters as required)id
: Request identifier (integer or string)Method Name
queryGroupMessages
Request Parameters
conversationId
: A unique identifier for the conversation. This is a 32-byte string, typically in hexadecimal format.limit
: The limit on the number of messages to return, server will enforce a maximum of 500lastBlock
: The last block to consider for this request, optionally empty, indicating the most recent blockRequest Format
jsonrpc
: Specifies the version of the JSON RPC protocol being used. Always "2.0".method
: The name of the method being called. Here it is "rewindMessage".params
: A structured value holding the parameters necessary for the method. It contains:conversationId
: The unique identifier for the conversation.limit
: The maximum number of messages to return, server enforced limit is 500id
: A unique identifier established by the client that must be number or string. Used for correlating the response with the request.Response Format
The response will include the result of the operation or an error if the operation was unsuccessful. The included array (
message
) will contain the messages requested. The block range covered by this operation, (startBlock
–endBlock
) will be included in the result. The block range may be using for paging over past results.Success Response
result
: Specifies success of the operation. The nature of this specification can vary based on the implementation.Error Response
error
: An object containing details about the error.code
: A numeric error code.message
: A human-readable string describing the error.Example Usage
Request
Response
Possible Implementation
Notes
conversationId
is valid and exists