mirror of
https://github.com/aljazceru/ark.git
synced 2025-12-17 04:04:21 +01:00
* api-spec: move the api-spec to root and init go.mod * go mod tidy * move buf files in the root as well * gh action for api-spec changes only * gh action for api-spec on push and pr
326 lines
7.6 KiB
JSON
326 lines
7.6 KiB
JSON
{
|
|
"swagger": "2.0",
|
|
"info": {
|
|
"title": "ocean/v1/account.proto",
|
|
"version": "version not set"
|
|
},
|
|
"tags": [
|
|
{
|
|
"name": "AccountService"
|
|
}
|
|
],
|
|
"consumes": [
|
|
"application/json"
|
|
],
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"paths": {},
|
|
"definitions": {
|
|
"TemplateFormat": {
|
|
"type": "string",
|
|
"enum": [
|
|
"FORMAT_UNSPECIFIED",
|
|
"FORMAT_DESCRIPTOR",
|
|
"FORMAT_MINISCRIPT",
|
|
"FORMAT_IONIO",
|
|
"FORMAT_RAW"
|
|
],
|
|
"default": "FORMAT_UNSPECIFIED"
|
|
},
|
|
"googlerpcStatus": {
|
|
"type": "object",
|
|
"properties": {
|
|
"code": {
|
|
"type": "integer",
|
|
"format": "int32"
|
|
},
|
|
"message": {
|
|
"type": "string"
|
|
},
|
|
"details": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"$ref": "#/definitions/protobufAny"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"protobufAny": {
|
|
"type": "object",
|
|
"properties": {
|
|
"@type": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"additionalProperties": {}
|
|
},
|
|
"v1AccountInfo": {
|
|
"type": "object",
|
|
"properties": {
|
|
"namespace": {
|
|
"type": "string",
|
|
"description": "Account namespace."
|
|
},
|
|
"label": {
|
|
"type": "string",
|
|
"description": "Account label."
|
|
},
|
|
"derivationPath": {
|
|
"type": "string",
|
|
"description": "Derivation path."
|
|
},
|
|
"xpubs": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"description": "Xpubs."
|
|
},
|
|
"masterBlindingKey": {
|
|
"type": "string",
|
|
"description": "The master blinding key of the account to derive blinding keypairs from."
|
|
}
|
|
}
|
|
},
|
|
"v1BalanceInfo": {
|
|
"type": "object",
|
|
"properties": {
|
|
"confirmedBalance": {
|
|
"type": "string",
|
|
"format": "uint64",
|
|
"description": "Balance of utxos with 1+ confirmations."
|
|
},
|
|
"unconfirmedBalance": {
|
|
"type": "string",
|
|
"format": "uint64",
|
|
"description": "Balance of utxos with no confirmations."
|
|
},
|
|
"lockedBalance": {
|
|
"type": "string",
|
|
"format": "uint64",
|
|
"description": "Balance of locked utxos."
|
|
},
|
|
"totalBalance": {
|
|
"type": "string",
|
|
"format": "uint64",
|
|
"description": "Total balance."
|
|
}
|
|
}
|
|
},
|
|
"v1BalanceResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"balance": {
|
|
"type": "object",
|
|
"additionalProperties": {
|
|
"$ref": "#/definitions/v1BalanceInfo"
|
|
},
|
|
"description": "The balance (total, confirmed, unconfirmed) per each asset."
|
|
}
|
|
}
|
|
},
|
|
"v1BlockDetails": {
|
|
"type": "object",
|
|
"properties": {
|
|
"hash": {
|
|
"type": "string",
|
|
"description": "Hash of the block."
|
|
},
|
|
"height": {
|
|
"type": "string",
|
|
"format": "uint64",
|
|
"description": "Heighth (index) of the block."
|
|
},
|
|
"timestamp": {
|
|
"type": "string",
|
|
"format": "int64",
|
|
"description": "Timestamp of the block."
|
|
}
|
|
}
|
|
},
|
|
"v1CreateAccountBIP44Response": {
|
|
"type": "object",
|
|
"properties": {
|
|
"info": {
|
|
"$ref": "#/definitions/v1AccountInfo",
|
|
"description": "Info about the new account."
|
|
}
|
|
}
|
|
},
|
|
"v1CreateAccountCustomResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"info": {
|
|
"$ref": "#/definitions/v1AccountInfo",
|
|
"description": "Info about the new account."
|
|
}
|
|
}
|
|
},
|
|
"v1CreateAccountMultiSigResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"info": {
|
|
"$ref": "#/definitions/v1AccountInfo",
|
|
"description": "Info about the new account."
|
|
}
|
|
}
|
|
},
|
|
"v1DeleteAccountResponse": {
|
|
"type": "object"
|
|
},
|
|
"v1DeriveAddressesResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"addresses": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"v1DeriveChangeAddressesResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"addresses": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"v1ListAddressesResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"addresses": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"v1ListUtxosResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"spendableUtxos": {
|
|
"$ref": "#/definitions/v1Utxos",
|
|
"description": "List of spendable utxos."
|
|
},
|
|
"lockedUtxos": {
|
|
"$ref": "#/definitions/v1Utxos",
|
|
"description": "List of currently locked utxos."
|
|
}
|
|
}
|
|
},
|
|
"v1SetAccountLabelResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"info": {
|
|
"$ref": "#/definitions/v1AccountInfo",
|
|
"description": "Info about the updated account."
|
|
}
|
|
}
|
|
},
|
|
"v1SetAccountTemplateResponse": {
|
|
"type": "object"
|
|
},
|
|
"v1Template": {
|
|
"type": "object",
|
|
"properties": {
|
|
"format": {
|
|
"$ref": "#/definitions/TemplateFormat"
|
|
},
|
|
"value": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"v1Utxo": {
|
|
"type": "object",
|
|
"properties": {
|
|
"txid": {
|
|
"type": "string",
|
|
"description": "Txid of the uxo."
|
|
},
|
|
"index": {
|
|
"type": "integer",
|
|
"format": "int64",
|
|
"description": "Output index."
|
|
},
|
|
"asset": {
|
|
"type": "string",
|
|
"description": "Asset."
|
|
},
|
|
"value": {
|
|
"type": "string",
|
|
"format": "uint64",
|
|
"description": "Value."
|
|
},
|
|
"script": {
|
|
"type": "string",
|
|
"description": "Script."
|
|
},
|
|
"assetBlinder": {
|
|
"type": "string",
|
|
"description": "Asset blinder for confidential utxo."
|
|
},
|
|
"valueBlinder": {
|
|
"type": "string",
|
|
"description": "Value blinder for confidential utxo."
|
|
},
|
|
"accountName": {
|
|
"type": "string",
|
|
"description": "Namespace of the account owning the utxo."
|
|
},
|
|
"spentStatus": {
|
|
"$ref": "#/definitions/v1UtxoStatus",
|
|
"description": "Info about utxo's spent status."
|
|
},
|
|
"confirmedStatus": {
|
|
"$ref": "#/definitions/v1UtxoStatus",
|
|
"description": "Info about utxo's confirmation status."
|
|
},
|
|
"redeemScript": {
|
|
"type": "string",
|
|
"description": "Redeem script locking the utxo in case its owned by a multisig account."
|
|
}
|
|
}
|
|
},
|
|
"v1UtxoStatus": {
|
|
"type": "object",
|
|
"properties": {
|
|
"txid": {
|
|
"type": "string"
|
|
},
|
|
"blockInfo": {
|
|
"$ref": "#/definitions/v1BlockDetails"
|
|
},
|
|
"txhex": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
},
|
|
"v1Utxos": {
|
|
"type": "object",
|
|
"properties": {
|
|
"accountName": {
|
|
"type": "string",
|
|
"description": "Account namespace."
|
|
},
|
|
"utxos": {
|
|
"type": "array",
|
|
"items": {
|
|
"type": "object",
|
|
"$ref": "#/definitions/v1Utxo"
|
|
},
|
|
"description": "List of utxos."
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|