Python SDK Open-api-sdk is a library for interaction with Open Platform.
Installing Using pip:
Get started OPEN Platform uses OpenKeys to allow access to the API. You can register a new OpenKey at your Account.
OPEN Platform expects the OpenKey to be included in all API requests to the server in a header.
We assume that you have the OpenKey by this moment.
To access the library import an OpenPlatform class and call an instance with the OpenKey as following:
open_key
- your open key.
In the following examples, it is assumed that op
is a result of instantiating the OpenPlatform
class with the open_key
API Page request attributes Attribute Type Description offset Long Page offset limit Int Page limit
Page response attributes Attribute Type Description totalCount Long Total count of entities in a database list [] List of entities with type T (T is generic)
Scaffold Scaffold attributes Attribute Type Description address String Scaffold address abi String Scaffold json interface description String Scaffold description fiatAmount String Scaffold fiat amount currency String Fiat amount currency conversionAmount String Fiat amount converted to ethereum developerAddress String Scaffold developer address webHook String Scaffold webhook for events properties ScaffoldProperty [] Scaffold properties
Scaffold properties attributes Attribute Type Description name String Property name type PropertyType Property type defaultValue String Property default value
get_all() get_single(address) Scaffold summary attributes Attribute Type Description scaffold Scaffold Scaffold transactionIndex BigInteger Transaction index tokenBalance BigInteger Scaffold token balance enabled Boolean Scaffold enabled currency String Fiat amount currency shareHolders ShareHolder Scaffold shareholders
get_summary(address) get_transactions(address) Set web hook request data
Attribute Type Description address String Scaffold address webHook String Scaffold webhook for events
example: set_webhook(address, data) Deploy scaffold request data
Attribute Type Description openKey String User open key description String Scaffold description fiatAmount String Scaffold fiat amount currency String Fiat amount currency conversionAmount String Fiat amount converted to ethereum developerAddress String Scaffold developer address webHook String Scaffold webhook for events properties ScaffoldProperty [] Scaffold properties
example: deploy_scaffold(data) deactivate_scaffold(address) Quota attributes Attribute Type Description currentCount Int Current deactivated scaffolds count limitCount Int Limit of deactivated scaffolds count
get_quota() Shareholder Shareholder attributes Attribute Type Description address String Shareholder address percent Int Shareholder percent
example: add(address, data) Update shareholder request data
Attribute Type Description percent Int Shareholder percent
example: update(address , holder_address , data) remove(address, holder_address)