Read-only Insolar MainNet API (v1.1.4)

Download OpenAPI specification:Download

Read-only MainNet API documentation

Welcome to Insolar documentation for a read-only MainNet REST-like API provided by an Observer node.

The Observer node pulls data from Insolar MainNet and offloads read requests from it by hosting a fast report service.

Additionally, Observer provides coin statistics and notification messages.

Definitions Overview

Insolar is being developed to provide interoperability between enterprises.

From a business perspective:

  • Any enterprise is regarded as an entity with a corresponding identity—a member object stored on the blockchain.
  • Any member has its own account to/from which this member can transfer funds.

From a technical perspective:

  • Every member object is identified by a reference on the blockchain.
  • The reference is effectively the member's address.

Therefore, an entity wishing to transfer funds to/from its account from/to a particular address, in Insolar's terms, is a member object identified by its reference wishing to transfer funds to another member object identified by the corresponding reference.

Insolar uses these terms in method and parameter names.

Versioning

API changes in particular Insolar releases and uses the SemVer 2.0 versioning system.

Read-only MainNet API versions do not have to tally with Insolar Observer versions.

Member

Member requests return details on member objects created by users of Insolar MainNet.

Member

Gets the following information on a member object:

  • (required) member's reference, accountReference, and walletReference.
  • (required) account balance.
  • (optional) array of details on all deposits associated with the member, if any.
  • (optional) migrationAddress used during the migration period.

To invoke this request, specify the member reference or the corresponding migrationAddress.

path Parameters
reference
required
string ^insolar:[A-z0-9_-]+$
Example: insolar:1GlDeBOnc7Ar5N34ShBdkx_SAVOfnZJKUCoQMi0_OcvE

Reference to the member object or the corresponding migrationAddress.

Note: Path parameters must be properly included into the URL, so : after insolar in references and IDs should be replaced with %3A to comply with the HTML URL encoding.

Responses

200

OK

204

Reference not found

400

Invalid reference format

404

Endpoint not found

500

Internal server error

get /api/member/{reference}

MainNet

https://wallet-api.insolar.io/api/member/{reference}

TestNet

https://wallet-api.testnet.insolar.io/api/member/{reference}

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
{
  • "balance": "1000000000000",
  • "reference": "insolar:1GlDeBOnc7Ar5N34ShBdkx_SAVOfnZJKUCoQMi0_OcvE",
  • "walletReference": "insolar:1AfNjPWh7Ut-P7Ky7Mj7HLCte3gjGXi4RpXNxTvrhlww",
  • "accountReference": "insolar:1LBBNgDpzKt0YGkrInkqGlsME4RAnSzQRIySreTX0j7g",
  • "deposits":
    [
    ]
}

Member by public key

Gets the following information on a member object:

  • (required) member's reference, accountReference, and walletReference.
  • (required) account balance.
  • (optional) array of details on all deposits associated with the member, if any.
  • (optional) migrationAddress used during the migration period.

To invoke this request, specify the member's publicKey.

query Parameters
publicKey
required
string
Example: publicKey=-----BEGIN PUBLIC KEY-----MFYwEAYHKoZIzj0CAQYFK4EEAAoDQgAE9qmU2JVIlNPE/hGxuJnXprOyFIIL5fkcJlFOLMIQnNK8uPyFgexekQKFvyy3/dvPCEYoXOVi25CQ9t2UAj4v+Q==-----END PUBLIC KEY-----

Public key of the target member object. With or without the -----BEGIN PUBLIC KEY----- and -----END PUBLIC KEY----- delimiters.

Note: Query parameters must be properly included into the URL, so publicKey value should comply with the HTML URL encoding.

Responses

200

OK

204

Reference not found

404

Endpoint not found

500

Internal server error

get /api/member/byPublicKey

MainNet

https://wallet-api.insolar.io/api/member/byPublicKey

TestNet

https://wallet-api.testnet.insolar.io/api/member/byPublicKey

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "reference": "insolar:1AfNjPWh7Ut-P7Ky7Mj7HLCte3gjGXi4RpXNxTvrhlww",
  • "balance": "1000000000",
  • "walletReference": "insolar:1AfNjPWh7Ut-P7Ky7Mj7HLCte3gjGXi4RpXNxTvrhlww",
  • "accountReference": "insolar:1LBBNgDpzKt0YGkrInkqGlsME4RAnSzQRIySreTX0j7g",
  • "deposits":
    [
    ],
  • "migrationAddress": "0xF4e1507486dFE411785B00d7D00A1f1a484f00E6"
}

Member balance

Gets the balance of a member's account.

To invoke this request, specify the member reference.

path Parameters
reference
required
string ^insolar:[A-z0-9_-]+$
Example: insolar:1GlDeBOnc7Ar5N34ShBdkx_SAVOfnZJKUCoQMi0_OcvE

Reference to the member object.

Note: Path parameters must be properly included into the URL, so : after insolar in references should be replaced with %3A to comply with the HTML URL encoding.

Responses

200

OK

204

Reference not found

400

Invalid reference format

404

Endpoint not found

500

Internal server error

get /api/member/{reference}/balance

MainNet

https://wallet-api.insolar.io/api/member/{reference}/balance

TestNet

https://wallet-api.testnet.insolar.io/api/member/{reference}/balance

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "balance": "1000000000"
}

Member transactions

Gets a list (page) of member's transactions.

To invoke this request, specify the member reference in path and parameters listed below.

Filters:

  • (optional) direction of transactions in the list: incoming, outgoing, or all.
  • (optional) type of transactions in the list.
  • (optional) status of transactions in the list.

Pagination parameters and chronological order:

  • (optional) order of the transaction list: chronological or reverse (default).
  • (required) limit to the number of transactions to get (page size).
  • (optional) index of the last known transaction. The list starts from the next one.

Each returned transaction has an index which can be specified in the corresponding parameter in subsequent requests.

If the index parameter is not specified, the request returns a list of the most recent or old (depending on the order value) transactions.

path Parameters
reference
required
string ^insolar:[A-z0-9_-]+$
Example: insolar:1GlDeBOnc7Ar5N34ShBdkx_SAVOfnZJKUCoQMi0_OcvE

Reference to the member object.

Note: Path parameters must be properly included into the URL, so : after insolar in references and IDs should be replaced with %3A to comply with the HTML URL encoding.

query Parameters
limit
required
integer [ 1 .. 1000 ]
Example: limit=100

Number of entries per list.

index
string
Example: index=38134090:7

Index of the last known transaction. The list starts from the next one. Each returned transaction has an index that can be specified as the value of this parameter.

To get the list of most recent or old (depending on the order value) transactions, omit the index.

direction
string
Default: "all"
Enum: "incoming" "outgoing" "all"
Example: direction=incoming

Transaction direction:

  • incoming—only transactions to the member.
  • outgoing—only transactions from the member.
  • all—both of the above.
order
string
Default: "reverse"
Enum: "chronological" "reverse"

Chronological order of the transaction list starting from a given index:

  • chronological—get transactions that chronologically follow a transaction with a given index.
  • reverse—get transactions that chronologically preceed a transaction with a given `index.
type
string
Enum: "transfer" "migration" "allocation" "release"
Example: type=transfer

Transaction type:

  • transfer—transactions to/from the member.
  • migration—only transactions to the member's deposits.
  • allocation—only transactions used by Insolar for internal funding purposes.
  • release—only transactions from the member's deposits to this member's account.
status
string
Enum: "registered" "sent" "received" "failed"
Example: status=received

Transaction status:

  • registered—transfer request is registered.
  • sent—transfer of funds from the sender is finalized.
  • received—transfer of funds to the receiver is finalized.
  • failed—transfer of funds is finalized with an error; for example, in case of insufficient balance.

Responses

200

OK

204

Reference not found

400

Invalid parameter(s) format

404

Endpoint not found

500

Internal server error

get /api/member/{reference}/transactions

MainNet

https://wallet-api.insolar.io/api/member/{reference}/transactions

TestNet

https://wallet-api.testnet.insolar.io/api/member/{reference}/transactions

Response samples

Content type
application/json
Example
Copy
Expand all Collapse all
[
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    }
]

Transaction

Transaction requests return paginated arrays of transactions, their details, and fees.

Closed transactions

Gets a list (page) of closed transactions (only with received and failed statuses).

To invoke this request, specify:

  • (required) limit to the number of transactions to get (page size).
  • (optional) index of the last known transaction. The list starts from the next one.
  • (optional) order of the transaction list: chronological or reverse (default).

Note: Indexes in the list of closed transactions do not match the indexes in the lists returned by member transactions, transactions, and transactions in pulse range.

Each returned transaction has an index which can be specified in the corresponding parameter in subsequent requests for closed transactions.

If the index parameter is not specified, the request returns a list of the most recent or old (depending on the order value) transactions.

query Parameters
limit
required
integer [ 1 .. 1000 ]
Example: limit=100

Number of entries per list.

index