mirror of
https://github.com/planetmint/planetmint.git
synced 2025-10-14 00:59:17 +00:00
Script tag schema (#245)
* updated tx schema for v2 and v3, some errors remaining Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com> * linted transaction spec v2, wip script tag Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com> * fixed state error on script tag Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com> * fixed transaction schema script error Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com> Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com>
This commit is contained in:
parent
a9abc4114a
commit
e41ce5df76
@ -9,13 +9,13 @@ type: object
|
|||||||
additionalProperties: false
|
additionalProperties: false
|
||||||
title: Transaction Schema
|
title: Transaction Schema
|
||||||
required:
|
required:
|
||||||
- id
|
- id
|
||||||
- inputs
|
- inputs
|
||||||
- outputs
|
- outputs
|
||||||
- operation
|
- operation
|
||||||
- metadata
|
- metadata
|
||||||
- asset
|
- asset
|
||||||
- version
|
- version
|
||||||
properties:
|
properties:
|
||||||
id:
|
id:
|
||||||
anyOf:
|
anyOf:
|
||||||
@ -39,6 +39,8 @@ properties:
|
|||||||
version:
|
version:
|
||||||
type: string
|
type: string
|
||||||
pattern: "^2\\.0$"
|
pattern: "^2\\.0$"
|
||||||
|
script:
|
||||||
|
"$ref": "#/definitions/script"
|
||||||
definitions:
|
definitions:
|
||||||
offset:
|
offset:
|
||||||
type: integer
|
type: integer
|
||||||
@ -168,3 +170,53 @@ definitions:
|
|||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
"$ref": "#/definitions/condition_details"
|
"$ref": "#/definitions/condition_details"
|
||||||
|
script:
|
||||||
|
type: object
|
||||||
|
additionalProperties: false
|
||||||
|
required:
|
||||||
|
- code
|
||||||
|
- state
|
||||||
|
- input
|
||||||
|
- output
|
||||||
|
properties:
|
||||||
|
code:
|
||||||
|
anyOf:
|
||||||
|
- type: object
|
||||||
|
additionalProperties: false
|
||||||
|
required:
|
||||||
|
- type
|
||||||
|
- raw
|
||||||
|
- parameters
|
||||||
|
properties:
|
||||||
|
type:
|
||||||
|
type: string
|
||||||
|
enum:
|
||||||
|
- zenroom
|
||||||
|
raw:
|
||||||
|
type: string
|
||||||
|
parameters:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
type: object
|
||||||
|
- type: object
|
||||||
|
additionalProperties: false
|
||||||
|
required:
|
||||||
|
- transaction_id
|
||||||
|
properties:
|
||||||
|
transaction_id:
|
||||||
|
"$ref": "#/definitions/sha3_hexdigest"
|
||||||
|
state:
|
||||||
|
anyOf:
|
||||||
|
- type: object
|
||||||
|
"$ref": "#/definitions/sha3_hexdigest"
|
||||||
|
input:
|
||||||
|
type: object
|
||||||
|
output:
|
||||||
|
type: object
|
||||||
|
policies:
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
raw:
|
||||||
|
type: object
|
||||||
|
txids:
|
||||||
|
type: object
|
||||||
|
@ -40,7 +40,9 @@ properties:
|
|||||||
"$ref": "#/definitions/metadata"
|
"$ref": "#/definitions/metadata"
|
||||||
version:
|
version:
|
||||||
type: string
|
type: string
|
||||||
pattern: "^2\\.0$"
|
pattern: "^3\\.0$"
|
||||||
|
script:
|
||||||
|
"$ref": "#/definitions/script"
|
||||||
definitions:
|
definitions:
|
||||||
offset:
|
offset:
|
||||||
type: integer
|
type: integer
|
||||||
@ -172,3 +174,53 @@ definitions:
|
|||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
"$ref": "#/definitions/condition_details"
|
"$ref": "#/definitions/condition_details"
|
||||||
|
script:
|
||||||
|
type: object
|
||||||
|
additionalProperties: false
|
||||||
|
required:
|
||||||
|
- code
|
||||||
|
- state
|
||||||
|
- input
|
||||||
|
- output
|
||||||
|
properties:
|
||||||
|
code:
|
||||||
|
anyOf:
|
||||||
|
- type: object
|
||||||
|
additionalProperties: false
|
||||||
|
required:
|
||||||
|
- type
|
||||||
|
- raw
|
||||||
|
- parameters
|
||||||
|
properties:
|
||||||
|
type:
|
||||||
|
type: string
|
||||||
|
enum:
|
||||||
|
- zenroom
|
||||||
|
raw:
|
||||||
|
type: string
|
||||||
|
parameters:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
type: object
|
||||||
|
- type: object
|
||||||
|
additionalProperties: false
|
||||||
|
required:
|
||||||
|
- transaction_id
|
||||||
|
properties:
|
||||||
|
transaction_id:
|
||||||
|
"$ref": "#/definitions/sha3_hexdigest"
|
||||||
|
state:
|
||||||
|
anyOf:
|
||||||
|
- type: object
|
||||||
|
"$ref": "#/definitions/sha3_hexdigest"
|
||||||
|
input:
|
||||||
|
type: object
|
||||||
|
output:
|
||||||
|
type: object
|
||||||
|
policies:
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
raw:
|
||||||
|
type: object
|
||||||
|
txids:
|
||||||
|
type: object
|
||||||
|
Loading…
x
Reference in New Issue
Block a user