Skip to content

Commit

Permalink
cleaned up some schemas that did not match api responses.
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Rutherford committed Oct 18, 2024
1 parent 07cb724 commit 19617d7
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 76 deletions.
54 changes: 15 additions & 39 deletions doc/electrs-rest-btcd-1.0.0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -255,11 +255,6 @@ paths:
required: true
schema:
type: string
- name: start_index
in: query
required: false
schema:
type: integer
responses:
'200':
description: Transactions for a given block
Expand Down Expand Up @@ -561,24 +556,6 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/TxStatus'
/tx/{txid}/hex:
get:
tags:
- tx
summary: Returns the raw transaction data in hexadecimal
parameters:
- name: txid
in: path
required: true
schema:
type: string
responses:
'200':
description: Raw transaction data
content:
application/octet-stream:
schema:
type: string
/tx/{txid}/raw:
get:
tags:
Expand Down Expand Up @@ -764,7 +741,7 @@ paths:
schema:
type: array
items:
$ref: '#/components/schemas/MempoolTx'
$ref: '#/components/schemas/MempoolTransaction'
/fee-estimates:
get:
summary: Returns an JSON object with key value pairs of Blocks to Fees for confirmation.
Expand Down Expand Up @@ -821,6 +798,7 @@ components:
type: integer
next_best:
type: string
nullable: true
Transaction:
type: object
properties:
Expand Down Expand Up @@ -898,14 +876,12 @@ components:
ScriptHash:
type: object
properties:
address:
scripthash:
type: string
chain_stats:
$ref: '#/components/schemas/ChainStats'
mempool_stats:
$ref: '#/components/schemas/MempoolStats'
scripthash:
type: string
Address:
type: object
properties:
Expand Down Expand Up @@ -941,6 +917,17 @@ components:
type: integer
tx_count:
type: integer
MempoolTransaction:
type: object
properties:
txid:
type: string
fee:
type: integer
vsize:
type: integer
value:
type: integer
Utxo:
type: object
properties:
Expand Down Expand Up @@ -988,15 +975,4 @@ components:
items:
type: array
items:
type: number
MempoolTx:
type: object
properties:
txid:
type: string
fee:
type: integer
vsize:
type: integer
value:
type: integer
type: number
75 changes: 38 additions & 37 deletions doc/electrs-rest-liquid-1.0.0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -259,11 +259,6 @@ paths:
required: true
schema:
type: string
- name: start_index
in: query
required: false
schema:
type: integer
responses:
'200':
description: Transactions for a given block
Expand Down Expand Up @@ -574,24 +569,6 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/TxStatus'
/tx/{txid}/hex:
get:
tags:
- tx
summary: Returns the raw transaction data in hexadecimal
parameters:
- name: txid
in: path
required: true
schema:
type: string
responses:
'200':
description: Raw transaction data
content:
application/octet-stream:
schema:
type: string
/tx/{txid}/raw:
get:
tags:
Expand Down Expand Up @@ -777,7 +754,7 @@ paths:
schema:
type: array
items:
$ref: '#/components/schemas/MempoolTx'
$ref: '#/components/schemas/MempoolTransaction'
/fee-estimates:
get:
summary: Returns an JSON object with key value pairs of Blocks to Fees for confirmation.
Expand Down Expand Up @@ -1012,6 +989,8 @@ components:
type: number
proof:
type: string
ext:
$ref: '#/components/schemas/ElementsExt'
BlockStatus:
type: object
properties:
Expand All @@ -1021,6 +1000,7 @@ components:
type: integer
next_best:
type: string
nullable: true
Transaction:
type: object
properties:
Expand Down Expand Up @@ -1123,14 +1103,12 @@ components:
ScriptHash:
type: object
properties:
address:
scripthash:
type: string
chain_stats:
$ref: '#/components/schemas/ChainStats'
mempool_stats:
$ref: '#/components/schemas/MempoolStats'
scripthash:
type: string
Address:
type: object
properties:
Expand Down Expand Up @@ -1166,6 +1144,17 @@ components:
type: integer
tx_count:
type: integer
MempoolTransaction:
type: object
properties:
txid:
type: string
fee:
type: integer
vsize:
type: integer
value:
type: integer
Utxo:
type: object
properties:
Expand Down Expand Up @@ -1214,17 +1203,29 @@ components:
type: array
items:
type: number
MempoolTx:
ElementsExt:
type: object
properties:
txid:
type: string
fee:
type: integer
vsize:
type: integer
value:
type: integer
properties:
current:
type: object
properties:
signblockscript:
type: string
signblock_witness_limit:
type: integer
elided_root:
type: string
proposed:
type: object
nullable: true
additionalProperties: true
signblock_witness:
type: array
items:
type: array
items:
type: integer
nullable: true
Asset:
type: object
properties:
Expand Down

0 comments on commit 19617d7

Please sign in to comment.