Skip to content

provable-things/ptokens-jsonrpc-spec

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pTokens bridge JSON-RPC Specification

View the spec

The pTokens JSON-RPC is a collection of methods that all bridges implement.

Building

The specification is split into multiple files to improve readability. It can be compiled the spec into a single document as follows:

$ npm install
$ npm run build
Build successful.

This will output the file openrpc.json in the root of the project. This file will have all schema #refs resolved.

Contributing

The specification is written in OpenRPC. Refer to the OpenRPC specification and the JSON schema specification to get started.

Testing

There are currently twp tools for testing contributions. The main one that runs as GitHub action is the OpenRPC validator:

$ npm install
$ npm run lint
OpenRPC spec validated successfully.

The third tool can validate a live JSON-RPC provider against the specification:

$ ./scripts/debug.sh https://pbtconbsc-node-1a.eu.ngrok.io/v2/pbtc-on-bsc/ app_queryReport \"native\",2
data.json valid

License

This repository is licensed under MIT.

About

OpenRPC Specification for the pTokens bridges RPC API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages