JSON-RPC는 클라이언트가 JSON 형식의 요청 메시지를 노드에 전송하여 노드는 이를 처리하고 결과를 JSON 형식의 응답 메시지로 반환합니다.
원격 프로시저 호출(Remote Procedure Call) 프로토콜의 약자로써, 통신을 위한 방식입니다.
Locus Chain 노드는 JSON-RPC API를 제공합니다. 개인이 실행하거나 몇몇의 공적인 서비스로 제공되는 노드를 통해 사용자는 쉽게 블록체인 네트워크의 정보를 조회할 수 있습니다.
한 번의 호출로 결과를 받을 수 있습니다.
파라메트에 'Sig'가 포함되어 있으면 Tx를 생성하는 RPC입니다.
동일한 RPC를 두 번 호출합니다.
아래와 같이 4단계로 진행하십시오.
- [STEP1: 첫번째 호출] 노드에서 Tx와 Hash를 받습니다.
- [STEP2: Tx 검증] 받은 Tx를 로커스 라이브러리의 VerifyTx 함수로 검증합니다.
- [STEP3: 서명] Tx에 이상이 없으면 로커스 라이브러리나 지갑을 통해 서명을 합니다.
- [STEP4: 두 번째 호출] 첫번째 호출 파라메트에 서명을 추가하여 두번째 호출을 하면 Tx가 생성됩니다.
{
"jsonrpc": "2.0",
"method": "locus_getAccountDetail",
"params": [{ "account": "D4YLP5B3NC3RWVXYDWFPCT6IG2ASCVP32ANLOAD73I" }],
"id": 1
}
기본적인 응답값은 다음과 같은 형식을 가집니다.
호출된 Function에 따라 result 값이 변경됩니다.
성공
{
"jsonrpc": "2.0",
"id": 1,
"result": {}
}
실패
{
"jsonrpc": "2.0",
"id": 1,
"error": {
"code": 1,
"message": ""
}
}
RPC 호출에 대해 노드가 응답을 잘 하는지 확인하는 용도로 사용할 수 있습니다.
입력값에 현재 시간을 추가하여 응답합니다.
| Key | Type | Description |
|---|
| str | string | 문자열 |
| Key | Type | Description |
|---|
| - | string | 입력 문자열 + 현재 시간 |
노드의 현재 동기화 상태를 구합니다.
[없음]
| Key | Type | Description |
|---|
| syncState | string | NODE_STATE_IN_INIT NODE_STATE_IN_SYNC NODE_STATE_IN_RESYNC NODE_STATE_SYNC_COMPLETE NODE_STATE_STABLE Unknown NodeState |
제네시스 계정의 주소를 구합니다.
[없음]
| Key | Type | Description |
|---|
| genesis | base32 | 제네시스 계정의 주소 |
계정을 로커스체인 네트워크에 등록합니다.
| Key | Type | Description |
|---|
| account | base32 | 대상 계정 주소 |
| sender | base32 | 코인을 보낸 계정 |
| index | int | 코인을 보낸 Tx의 height |
| args | []string | Arguments |
| pk | base32 | Normal public key |
| keySign | base32 | Key signature |
| mpk | base32 | Master public key |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
지정한 계정을 해당 노드의 호스트로 설정합니다.
지정한 계정은 게스트가 없어야 하고, 해당 노드는 호스트가 없는 빈 노드여야 합니다.
| Key | Type | Description |
|---|
| account | base32 | 호스트가 될 계정 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
지정한 계정을 해당 노드의 게스트로 설정합니다.
지정한 계정은 게스트가 없어야 하고, 해당 노드는 호스트가 존재해야 합니다.
| Key | Type | Description |
|---|
| account | base32 | 게스트가 될 계정 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
계정의 노말키를 변경합니다.
| Key | Type | Description |
|---|
| account | base32 | 키를 변경할 계정 |
| masterPkey | base32 | Master public key |
| newNormalPkey | base32 | New Normal public key |
| signByMasterKey | base64 | New Normal public key를 Master public key로 서명한 값 |
| sign | base64 | 서명 |
| signedHeight | int | 두번째 호출 파라미터에 포함될 tx height |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
코인을 다른 계정에 보냅니다.
| Key | Type | Description |
|---|
| from | base32 | 보내는 계정 |
| to | base32 | 받는 계정 |
| amount | string | 보낼 수량 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
계정의 특정 Height의 Tx 정보를 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| height | int | 계정의 Height |
| Key | Type | Description |
|---|
| tx | string | Tx 정보 |
locus_getAccountHistory
계정의 Tx 목록을 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| height | int | 구하고자 하는 시작 Height Height가 -1이면, 최상위 Tx 부터. |
| count | int | 구하고자 하는 Tx 갯수 (시작 위치에서 이전 몇개) |
| Key | Type | Description |
|---|
| txs | []string | Tx string list |
계정의 상세정보를 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| Key | Type | Description |
|---|
| identity | string | Host : 해당 노드의 호스트 계정 Guest : 해당 노드의 게스트 계정 Neighbor : 해당 노드가 속한 샤드의 이웃 계정. 질의 당시의 상태이며, 동기 상태에 따라서 부정확한 값일 수도 있다. no identity : 위의 것에 아무 것도 해당되지 않음, 즉 존재하지 않거나, 다른 샤드에 속했거나 |
| fromNoAlive | bool | OpenAccount 를 했지만, 아직 합의에 포함되지 않은 경우에 이 flag 가 true 가 된다. |
| balance | string | 보유한 로커스 코인 |
| unactBalance | string | 아직은 Activate 되지 않아 사용할 수 없는 Balance |
| representative | base32 | 위임한 계정 (Host 계정) |
| grant | uint64 | 보유한 Grant |
| publicKey | base32 | 계정의 Normal public key |
| txChainHeight | int | 계정의 Height |
| txLink | string | 마지막 Tx link |
World Round State (WRS) 목록을 구합니다.
| Key | Type | Description |
|---|
| round | int | 구하고자 하는 시작 Round |
| count | int | 구하고자 하는 갯수 (시작 위치에서 이전 몇개), Max 500. |
| Key | Type | Description |
|---|
| nextRoundList | []int | WRS 목록 |
World Round State (WRS) 상세 정보를 구합니다.
| Key | Type | Description |
|---|
| round | int | 구하고자 하는 Round |
| Key | Type | Description |
|---|
| nextRound | int | Round |
| addShardRound | int | 0 : 샤드 분할 예정 없음. 1 : 샤드 분할해야 하는 상황이지만, 언제인지 정해지지 않았음. 2 이상 : 해당 Round에 샤드 분할 예정됨. |
| rootAcctHash | string | |
| worldInfoHash | string | |
| currentHash | string | |
| prevLink | string | |
| prevNextRound | int | |
| sigHash | string | 아래 서명 정보의 해시값. 아래의 서명 정보는 프루닝 될 수 있다. |
| validatorsWeight | int | Validator의 Weight 총합 |
| validators | []types.Validator | {Validator's Addr, Weight, Sign} |
types.Validator
| Key | Type | Description |
|---|
| addr | base32 | 검증자 주소 |
| weight | uint16 | 가중치 |
| sign | string | 서명 |
계정의 아직 Activate되지 않은 Tx 목록을 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| Key | Type | Description |
|---|
| timeOutTxs | []types.ListTx | 1차 Target 이 Activation 하지 않아, Time out 되어 들어온 Tx 목록. |
| txs | []types.ListTx | Sender 쪽의 합의가 완료된 Tx 목록. |
| unconfirmedTxs | []types.ListTx | Sender 쪽의 합의를 대기중인 Tx 목록. |
| pendingTxs | []types.ListTx | Propose 된지 10초 미만의 Tx 목록. |
| unspreadTxs | []types.ListTx | Unspread Tx 목록. |
| conflictedTxs | []types.ListTx | 충돌난 Tx 목록. |
| contractResults | types.ContractResults | Contract results |
types.ListTx
| Key | Type | Description |
|---|
| sender | base32 | 보낸 계정 |
| index | int | 인덱스 |
| tx | string | Tx 내용 |
| vtx | object | 상세 Tx 정보 |
types.ContractResults
| Key | Type | Description |
|---|
| pending | []types.ListTx | Pending 상태의 Tx 목록 |
| conflicting | []types.ListTx | 충돌난 Tx 목록 |
계정의 Mont(MOnitoring seNT) 목록을 구합니다.
노드의 호스트/게스트 계정의 것만 구할 수 있습니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| Key | Type | Description |
|---|
| proofedTxs | []types.MontTx | Sender 쪽의 합의가 완료된 Tx 목록. |
| pendingTxs | []types.MontTx | Propose만 된 Tx 목록. |
types.MontTx
| Key | Type | Description |
|---|
| index | int | 인덱스 |
| tx | string | Tx 내용 |
시스템 토큰을 생성합니다.
계정당 하나의 시스템 토큰을 생성할 수 있습니다.
| Key | Type | Description |
|---|
| account | base32 | 토큰을 생성할 계정 |
| tokenBalance | string | 생성할 토큰 갯수 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
토큰을 다른 계정에 보냅니다.
| Key | Type | Description |
|---|
| from | base32 | 토큰을 보내는 계정 |
| to | base32 | 토큰을 받을 계정 |
| amount | string | 보낼 수량 |
| tokenAmounts | []types.TokenAmount | 보낼 토큰 목록 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| source | types.Source | Source |
types.TokenAmount
| Key | Type | Description |
|---|
| tokenId | string | 토큰 ID |
| amountToken | string | 토큰 수량 |
types.Source
| Key | Type | Description |
|---|
| owner | string | 소유자 |
| height | int | 높이 |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
계정이 소유한 토큰 목록과 Balance를 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 토큰을 생성할 계정 |
| Key | Type | Description |
|---|
| tokenList | map[base32]string | {"TokenID": Balance} |
계정이 생성한 시스템 토큰이 존재하는 여 부와 존재하면 토큰 ID를 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| Key | Type | Description |
|---|
| having | bool | 시스템 토큰이 존재하는지 여부 |
| tokenId | string | Having 이 true 이면, 시스템 토큰 ID를 돌린다. |
locus_postData
데이터를 게시합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| label | int | 체인 내에서 같은 라벨의 Tx끼리 링크됨. 해당 Tx에 대해 Proof를 Verify할 때 같은 라벨의 더 최신의 Tx가 있는지를 확인하는 용도로 사용됨. |
| data | base64 | 게시할 데이터 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
계정의 Tx 목록과 Proof를 함께 구합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| baseHeight | int | 시작 Height |
| count | uint | 구하고자 하는 갯수 (시작 위치에서 이전 몇개) |
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| txs | []string | Tx string 목록 |
| proof | string | 요청한 Tx 목록의 Merkle Proof |
| checkRoundP1 | int | Proof 가 생성된 Round + 1 |
Tx 목록의 Proof를 검증합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| txs | []string | 검증할 Tx 목록 |
| proof | MerkleProof | 검증할 Tx 목록의 Merkle Proof |
| checkRoundP1 | int | proof 가 생성된 Round + 1 |
| Key | Type | Description |
|---|
| - | bool | 검증 성공 여부 |
특정 label의 TxPostData가 가장 최신인지 증명하는 Proof를 생성합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| height | int | Proof를 생성할 첫번째 TxPostData의 height |
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| latestProof | string | Tx가 최신 StoredDataHash에 포함되어 있다는 Proof |
locus_generateLatestStoredDataProof RPC로 생성한 Proof를 검증합니다.
| Key | Type | Description |
|---|
| account | base32 | Tx 목록의 Proof를 생성할 계정 |
| latestProof | string | Tx가 최신 StoredDataHash에 포함되어 있다는 Proof |
| Key | Type | Description |
|---|
| - | bool | 검증 성공 여부 |
Stake를 Lock합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| vmeId | base32 | VME ID |
| lockAmount | uint32 | Lock할 Stake 수량 (1 UnitStakeLock = 100 Locus) |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
Stake를 unlock합니다.
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| vmeId | base32 | VME ID |
| unlockAmount | uint32 | Unlock할 Stake (1 UnitStakeLock = 100 Locus) |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
Core Script를 배포합니다.
| Key | Type | Description |
|---|
| provider | base32 | 배포할 계정 |
| target | base32 | Time lock 이내에 Core script를 실행하여, provider가 send한 coin 이나 token을 activation할 계정 |
| targetAfterTimeLock | base32 | Time lock 이후에 provider가 send한 coin 이나 token을 자동으로 activation할 계정 |
| timeLock | int | Time lock 이 걸리는 round duration, 현재 Max = 30, Min = 3 으로 설정되어 있음. |
| args | []hex | Target이 provider의 script (ScriptSig)를 실행할 때, 사용될 아규먼트, 최대 4개까지 입력가능. |
| scriptProvide | hex | Target이 실행할 provider의 script, 현재 MaxSize = 32 bytes |
| scriptAccept | hex | Target이 실행할 target의 script, 현재 MaxSize = 32 bytes |
| amount | string | Target이 Core script 실행에 성공할 경우, activation 시킬 수 있는 coin amount |
| tokenAmounts | []types.TokenAmount | Target이 Core script 실행에 성공할 경우, activation 시킬 수 있는 token amounts |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
types.TokenAmount
| Key | Type | Description |
|---|
| tokenId | string | 토큰 ID |
| amountToken | string | 토큰 수량 |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
Core Script를 실행합니다.
| Key | Type | Description |
|---|
| acceptor | base32 | TxProvideScript에서 Target으로 지정된, Core Script를 activation 시킬 계정 Time lock 이내에만 activation이 가능함. |
| provider | base32 | TxProvideScript를 배포한 계정 |
| index | int | LeadTx(TxProvideScript)의 height |
| args | []hex | Target이 Target의 script (ScriptSig)를 실행할 때 사용될 아규먼트., 최대 4개까지 입력가능. |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
Key Address로 Full Address를 조회합니다.
| Key | Type | Description |
|---|
| addr | base32 | Key Address |
| Key | Type | Description |
|---|
| addr | base32 | Full Address |
동기화할 계정 블록 높이 목록 조회
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| heightChunks | []types.HeightChunk | Height Chunk 목록 |
types.HeightChunk
| Key | Type | Description |
|---|
| bottom | int | 하한 |
| top | int | 상한 |
| Key | Type | Description |
|---|
| heightChunks | []types.HeightChunk | Height Chunk 목록 |
업로드할 계정 블록 높이 목록 조회
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| heightChunks | []types.HeightChunk | Height Chunk 목록 |
types.HeightChunk
| Key | Type | Description |
|---|
| bottom | int | 하한 |
| top | int | 상한 |
| Key | Type | Description |
|---|
| heightChunks | []types.HeightChunk | Height Chunk 목록 |
| validTop | int | 유효한 Top |
| validBottom | int | 유효한 Bottom |
Express로 소비된 금액 계산
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| sender | base32 | 보낸 계정 |
| sentHeight | int | 보낸 Height |
| Key | Type | Description |
|---|
| amount | string | 수량 |
검증자 키(VKey) 변경
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
주소 존재 여부 확인
| Key | Type | Description |
|---|
| keyAddr | base32 | Key 주소 |
| Key | Type | Description |
|---|
| addr | base32 | Address |
| exist | bool | 존재 여부 |
클라이언트 메시지 전송
| Key | Type | Description |
|---|
| msg | string | 메시지 |
계정 폐쇄
| Key | Type | Description |
|---|
| from | base32 | From Account |
| to | base32 | To Account |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
자산 객체 생성
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| assetType | string | 자산 타입 |
| amount | string | 수량 |
| operator | string | 운영자 |
| metaData | string | 메타데이터 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
VME(Virtual Machine Environment) 생성
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| sysId | base32 | 시스템 ID |
| sysType | string | 시스템 타입 |
| lockAmount | string | Lock 수량 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
계정 트랜잭션 다운로드
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| heightChunks | []types.HeightChunk | Height Chunk 목록 |
types.HeightChunk
| Key | Type | Description |
|---|
| bottom | int | 하한 |
| top | int | 상한 |
| heights | []int | Heights |
| Key | Type | Description |
|---|
| heights | []int | Height 목록 |
| txs | []string | Tx 목록 |
중복 구독자 확인
| Key | Type | Description |
|---|
| published | string | 게시자 |
| Key | Type | Description |
|---|
| exist | bool | 존재 여부 |
계정 자산 목록 조회
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| maxCount | int | 최대 갯수 |
| Key | Type | Description |
|---|
| assetList | []types.AccountAsset | 자산 목록 |
types.AccountAsset
| Key | Type | Description |
|---|
| assetId | string | 자산 ID |
| amount | string | 수량 |
| objects | []types.AssetObject | 자산 객체 목록 |
| unactAmount | string | 비활성 수량 |
| unactObjects | []types.AssetObject | 비활성 자산 객체 목록 |
types.AssetObject
| Key | Type | Description |
|---|
| id | string | 자산 객체 ID |
| value | string | 값 |
| owner | base32 | 소유자 |
| operator | base32 | 운영자 |
| rentStart | int | 임대 시작 Height |
| rentEnd | int | 임대 종료 Height |
계정 자산 객체 조회
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| assetId | []string | 자산 ID 목록 |
| Key | Type | Description |
|---|
| objects | []types.AssetObject | 객체 목록 |
| unactObjects | []types.AssetObject | 비가용 객체 목록 |
types.AssetObject
| Key | Type | Description |
|---|
| id | string | 자산 객체 ID |
| value | string | 값 |
| owner | base32 | 소유자 |
| operator | base32 | 운영자 |
| rentStart | int | 임대 시작 Height |
| rentEnd | int | 임대 종료 Height |
간략한 노드 상태 조회
[없음]
| Key | Type | Description |
|---|
| nodeId | base32 | 노드 ID |
| host | base32 | 호스트 |
| reliable | bool | reliable 여부 |
| round | int | 라운드 |
| epoch | int | Epoch |
| shardId | int | 샤드 ID |
| networkId | int | 네트워크 ID |
| totalHeight | string | 총 Height |
| intraPeerCount | int | 내부 피어 수 |
| interPeerCount | int | 외부 피어 수 |
| syncState | string | 동기화 상태 |
| detailState | string | 상세 상태 |
| presyncState | string | 사전 동기화 상태 |
| buildTime | string | 빌드 시간 |
| rsNextRound | int | RS 다음 라운드 |
| wrsNextRound | int | WRS 다음 라운드 |
노드 상태 조회
[없음]
| Key | Type | Description |
|---|
| nodeId | base32 | 노드 ID |
| baseTime | int | 기준 시간 |
| host | base32 | 호스트 |
| reliable | bool | reliable 여부 |
| roundTime | int | 라운드 시간 |
| roundCycle | int | 라운드 주기 |
| prunedRound | int | Pruned 라운드 |
| round | int | 라운드 |
| epoch | int | Epoch |
| shardId | int | 샤드 ID |
| homeShardId | int | 홈 샤드 ID |
| totalShard | int | 총 샤드 수 |
| networkId | int | 네트워크 ID |
| totalHeight | string | 총 Height |
| intraPeerCount | int | 내부 피어 수 |
| interPeerCount | int | 외부 피어 수 |
| syncState | string | 동기화 상태 |
| detailState | string | 상세 상태 |
| presyncState | string | 사전 동기화 상태 |
| buildTime | string | 빌드 시간 |
| avgTxTime | string | 평균 Tx 시간 |
| rsNextRound | int | RS 다음 라운드 |
| rsf | int | RSF |
| vmInfo | string | VM 정보 |
| wrsNextRound | int | WRS 다음 라운드 |
| wrsHeight | int | WRS Height |
소유자 잔액 조회
[없음]
| Key | Type | Description |
|---|
| - | []types.OwnerBalance | 소유자 잔액 목록 |
types.OwnerBalance
| Key | Type | Description |
|---|
| account | string | 계정 |
| balance | string | 잔액 |
라운드 상태 조회
| Key | Type | Description |
|---|
| round | int | Round |
| Key | Type | Description |
|---|
| nextRound | int | 다음 라운드 |
| prevNextRound | int | 이전 다음 라운드 |
| hash | string | 해시 |
| totalHeight | int | 총 Height |
| proposer | base32 | 제안자 |
| validatorsWeight | int | 검증자 가중치 |
| validators | []types.VoteInfoRPC | 검증자 목록 |
| incentiveExist | bool | 인센티브 존재 여부 |
| totalIncentive | string | 총 인센티브 |
| startRound | int | 시작 라운드 |
| endRound | int | 종료 라운드 |
| newEpoch | int | 새로운 Epoch |
| newEpochRound | int | 새로운 Epoch 라운드 |
types.VoteInfoRPC
| Key | Type | Description |
|---|
| addr | base32 | 검증자 주소 |
| weight | uint16 | 가중치 |
| sign | string | 서명 |
라운드 상태 목록 조회
| Key | Type | Description |
|---|
| round | int | Round |
| count | int | 갯수 |
| Key | Type | Description |
|---|
| - | []types.RoundStateAbstract | 라운드 상태 목록 |
types.RoundStateAbstract
| Key | Type | Description |
|---|
| round | int | 라운드 |
| hash | string | 해시 |
| totalHeight | int | 총 Height |
계정의 샤드 정보 조회
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| Key | Type | Description |
|---|
| shard | int | 샤드 |
| acceptable | bool | 수용 가능 여부 |
트랜잭션 증명 생성
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| txs | []string | Tx 목록 |
| count | int | 갯수 |
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| txs | []string | Tx string 목록 |
| proof | string | 요청한 Tx 목록의 Merkle Proof |
| checkRoundP1 | int | Proof 가 생성된 Round + 1 |
데이터 거래 요청
| Key | Type | Description |
|---|
| requester | base32 | 요청자 |
| dataType | int | 데이터 타입 |
| reqHash | string | 요청 해시 |
| reward | string | 보상 |
| key | string | 키 |
| trader | base32 | 거래자 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| key | string | 키 |
| target | string | 타겟 |
호스트 설정
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| otp | string | OTP |
| Key | Type | Description |
|---|
| - | bool | 성공 여부 |
구독
| Key | Type | Description |
|---|
| published | string | 게시자 |
| add | bool | 추가 여부 |
[없음]
자산 객체 전송
| Key | Type | Description |
|---|
| from | base32 | 보내는 계정 |
| to | base32 | 받는 계정 |
| assetId | string | 자산 ID |
| amount | string | 수량 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
Express 코인 전송
| Key | Type | Description |
|---|
| from | base32 | 보내는 계정 |
| to | base32 | 받는 계정 |
| amount | string | 수량 |
| sign | base64 | 서명 |
| signedHeight | int | 1차 응답의 signedHeight |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
| source | types.Source | 자금 출처 |
types.Source
| Key | Type | Description |
|---|
| owner | string | 소유자 |
| height | int | 높이 |
| Key | Type | Description |
|---|
| hash | base64 | Tx Hash |
| tx | object | 생성된 Tx |
| success | bool | 성공 여부 |
| signedHeight | int | 서명된 tx height |
| feeType | int | 수수료 유형 (AUTO:0, GRANT_ONLY:1) |
계정 트랜잭션 업로드
| Key | Type | Description |
|---|
| account | base32 | 계정 |
| txs | []string | Tx 목록 |
| Key | Type | Description |
|---|
| - | []int | 결과 |