@agentshouse/mdmodel 0.1.0-cbd3c46de90bf → 0.1.0-cc4fc15af6998
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/API.md +11 -5
- package/dist/definition.d.ts +1 -1
- package/dist/definition.d.ts.map +1 -1
- package/dist/definition.js +8 -3
- package/dist/facts.d.ts.map +1 -1
- package/dist/facts.js +3 -2
- package/dist/house-model.d.ts +3 -11
- package/dist/house-model.d.ts.map +1 -1
- package/dist/house-model.js +3 -5
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/validate.d.ts +2 -0
- package/dist/validate.d.ts.map +1 -1
- package/dist/validate.js +30 -4
- package/fixtures/README.md +3 -2
- package/fixtures/cases/absent-link-dangles/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/{boolean-field/schema.yaml → absent-optional-field/schema.md} +2 -0
- package/fixtures/cases/{duplicate-link-definition/schema.yaml → absolute-link/schema.md} +2 -0
- package/fixtures/cases/{attachment-reference-dangles/schema.yaml → attachment-reference-any-file/schema.md} +2 -0
- package/fixtures/cases/{attachment-reference-outside/schema.yaml → attachment-reference-dangles/schema.md} +2 -0
- package/fixtures/cases/{list-of-objects-reference/schema.yaml → attachment-reference-outside/schema.md} +2 -0
- package/fixtures/cases/binary-any-reference/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/binary-document-collision/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/binary-image-dangles/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/binary-link-dangles/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/binary-link-outside-collection/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/binary-prototype-reference/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/binary-typed-reference/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/{absent-optional-field/schema.yaml → boolean-field/schema.md} +2 -0
- package/fixtures/cases/{absolute-link/schema.yaml → bracketed-link-definition/schema.md} +2 -0
- package/fixtures/cases/closed-nested-object/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/composed-root-reference/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/conditional-long-text/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/cross-room-link/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/cross-room-reference/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/date-time-format/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/declared-binary-links/schema.md +3 -0
- package/fixtures/cases/default-unfilled/schema.md +57 -0
- package/fixtures/cases/defs-pattern/schema.md +57 -0
- package/fixtures/cases/dependent-rule/schema.md +57 -0
- package/fixtures/cases/{bracketed-link-definition/schema.yaml → duplicate-link-definition/schema.md} +2 -0
- package/fixtures/cases/email-format/schema.md +57 -0
- package/fixtures/cases/equal-labels/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/fenced-link-definition/schema.md +7 -0
- package/fixtures/cases/field-enum/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/integer-field/schema.md +57 -0
- package/fixtures/cases/interrupted-link-definition/schema.md +3 -0
- package/fixtures/cases/json-schema-constructs/schema.md +57 -0
- package/fixtures/cases/labels-in-the-rooms-language/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/lazy-list-item/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/link-into-a-reserved-name/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/list-item-enum/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/list-item-kind/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/list-items/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/list-of-objects-closed/schema.md +57 -0
- package/fixtures/cases/list-of-objects-item/schema.md +57 -0
- package/fixtures/cases/{attachment-reference-any-file/schema.yaml → list-of-objects-reference/schema.md} +2 -0
- package/fixtures/cases/list-reference-path/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/list-reference-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/list-size/schema.md +57 -0
- package/fixtures/cases/long-fence-link-definition/schema.md +3 -0
- package/fixtures/cases/long-value-past-six-levels/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/malformed-definition/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/malformed-list/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/member-document/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/member-on-another-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/missing-required-field/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/misspelled-key/schema.md +57 -0
- package/fixtures/cases/name-not-a-string/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/nested-defs/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/nested-object-reference/schema.md +34 -0
- package/fixtures/cases/nested-reference/schema.md +34 -0
- package/fixtures/cases/nested-required-field/schema.md +57 -0
- package/fixtures/cases/numeric-range/schema.md +57 -0
- package/fixtures/cases/one-key-two-labels/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/one-key-two-types/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/one-of-variant/schema.md +57 -0
- package/fixtures/cases/other-room-reference/schema.md +34 -0
- package/fixtures/cases/paragraph-link-definition/schema.md +3 -0
- package/fixtures/cases/prototype-field/schema.md +7 -0
- package/fixtures/cases/quoted-link-definition/schema.md +3 -0
- package/fixtures/cases/reference-into-a-reserved-name/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/reference-to-any-file-name/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/referenced-missing-file/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/referenced-missing-non-latin-file/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/remote-ref/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/schema-body-ignored/expected.json +1 -0
- package/fixtures/cases/schema-body-ignored/schema.md +9 -0
- package/fixtures/cases/schema-type-named-folders/context.json +1 -0
- package/fixtures/cases/schema-type-named-folders/expected.json +5 -0
- package/fixtures/cases/schema-type-named-folders/schema.md +5 -0
- package/fixtures/cases/schema-type-named-type/context.json +1 -0
- package/fixtures/cases/schema-type-named-type/expected.json +5 -0
- package/fixtures/cases/{unknown-type/schema.yaml → schema-type-named-type/schema.md} +3 -1
- package/fixtures/cases/second-member-document/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/sections-keyword-refused/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/shortcut-reference-link/schema.md +7 -0
- package/fixtures/cases/string-length/schema.md +57 -0
- package/fixtures/cases/submission-keys/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/text-field-kind/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/thematic-break-ends-the-values/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/truncated-link-definition/schema.md +3 -0
- package/fixtures/cases/typed-path-names-another-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/typed-path-names-its-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/typed-path-names-no-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/types-folder-content/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/undeclared-field/schema.md +7 -0
- package/fixtures/cases/unevaluated-items-closed/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/unlisted-reference-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/unnamed-typed-path-checks-its-fields/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/unnamed-typed-path-names-a-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/unnamed-typed-path-reads-its-type/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/unnamed-typed-path-without-a-body/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/unresolved-link/schema.md +7 -0
- package/fixtures/cases/valid-typed-document/{schema.yaml → schema.md} +2 -0
- package/fixtures/cases/wide-item-fence-link/schema.md +3 -0
- package/package.json +1 -1
- package/fixtures/cases/declared-binary-links/schema.yaml +0 -1
- package/fixtures/cases/default-unfilled/schema.yaml +0 -55
- package/fixtures/cases/defs-pattern/schema.yaml +0 -55
- package/fixtures/cases/dependent-rule/schema.yaml +0 -55
- package/fixtures/cases/email-format/schema.yaml +0 -55
- package/fixtures/cases/fenced-link-definition/schema.yaml +0 -5
- package/fixtures/cases/frontmatter-schema/expected.json +0 -5
- package/fixtures/cases/integer-field/schema.yaml +0 -55
- package/fixtures/cases/interrupted-link-definition/schema.yaml +0 -1
- package/fixtures/cases/json-schema-constructs/schema.yaml +0 -55
- package/fixtures/cases/list-of-objects-closed/schema.yaml +0 -55
- package/fixtures/cases/list-of-objects-item/schema.yaml +0 -55
- package/fixtures/cases/list-size/schema.yaml +0 -55
- package/fixtures/cases/long-fence-link-definition/schema.yaml +0 -1
- package/fixtures/cases/misspelled-key/schema.yaml +0 -55
- package/fixtures/cases/nested-object-reference/schema.yaml +0 -32
- package/fixtures/cases/nested-reference/schema.yaml +0 -32
- package/fixtures/cases/nested-required-field/schema.yaml +0 -55
- package/fixtures/cases/numeric-range/schema.yaml +0 -55
- package/fixtures/cases/one-of-variant/schema.yaml +0 -55
- package/fixtures/cases/other-room-reference/schema.yaml +0 -32
- package/fixtures/cases/paragraph-link-definition/schema.yaml +0 -1
- package/fixtures/cases/prototype-field/schema.yaml +0 -5
- package/fixtures/cases/quoted-link-definition/schema.yaml +0 -1
- package/fixtures/cases/shortcut-reference-link/schema.yaml +0 -5
- package/fixtures/cases/string-length/schema.yaml +0 -55
- package/fixtures/cases/truncated-link-definition/schema.yaml +0 -1
- package/fixtures/cases/undeclared-field/schema.yaml +0 -5
- package/fixtures/cases/unresolved-link/schema.yaml +0 -5
- package/fixtures/cases/wide-item-fence-link/schema.yaml +0 -1
- /package/fixtures/cases/{frontmatter-schema → schema-body-ignored}/context.json +0 -0
- /package/fixtures/cases/{frontmatter-schema/schema.yaml → unknown-type/schema.md} +0 -0
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
depot: { type: string, reference: place }
|
|
7
|
-
required: [city]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
product:
|
|
12
|
-
properties:
|
|
13
|
-
name: { type: string }
|
|
14
|
-
place:
|
|
15
|
-
properties:
|
|
16
|
-
name: { type: string }
|
|
17
|
-
deal:
|
|
18
|
-
type: object
|
|
19
|
-
properties:
|
|
20
|
-
title: { type: string }
|
|
21
|
-
company: { type: string, reference: company }
|
|
22
|
-
shipping: { $ref: '#/$defs/address' }
|
|
23
|
-
lines:
|
|
24
|
-
type: array
|
|
25
|
-
items:
|
|
26
|
-
type: object
|
|
27
|
-
properties:
|
|
28
|
-
product: { type: string, reference: product }
|
|
29
|
-
quantity: { type: integer, minimum: 1 }
|
|
30
|
-
required: [product, quantity]
|
|
31
|
-
contract: { type: string, reference: attachment }
|
|
32
|
-
required: [title, company]
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
depot: { type: string, reference: place }
|
|
7
|
-
required: [city]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
product:
|
|
12
|
-
properties:
|
|
13
|
-
name: { type: string }
|
|
14
|
-
place:
|
|
15
|
-
properties:
|
|
16
|
-
name: { type: string }
|
|
17
|
-
deal:
|
|
18
|
-
type: object
|
|
19
|
-
properties:
|
|
20
|
-
title: { type: string }
|
|
21
|
-
company: { type: string, reference: company }
|
|
22
|
-
shipping: { $ref: '#/$defs/address' }
|
|
23
|
-
lines:
|
|
24
|
-
type: array
|
|
25
|
-
items:
|
|
26
|
-
type: object
|
|
27
|
-
properties:
|
|
28
|
-
product: { type: string, reference: product }
|
|
29
|
-
quantity: { type: integer, minimum: 1 }
|
|
30
|
-
required: [product, quantity]
|
|
31
|
-
contract: { type: string, reference: attachment }
|
|
32
|
-
required: [title, company]
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
country: { type: string, pattern: '^[A-Z]{2}$' }
|
|
7
|
-
required: [ city ]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
deal:
|
|
12
|
-
type: object
|
|
13
|
-
properties:
|
|
14
|
-
title: { type: string, minLength: 1, maxLength: 40 }
|
|
15
|
-
company: { type: string, reference: company }
|
|
16
|
-
stage: { enum: [ lead, proposal, won, lost ], default: lead }
|
|
17
|
-
amount: { type: integer, minimum: 0 }
|
|
18
|
-
probability: { type: number, minimum: 0, maximum: 1 }
|
|
19
|
-
open: { type: boolean }
|
|
20
|
-
closes_at: { type: string, format: date-time }
|
|
21
|
-
contact_email: { type: string, format: email }
|
|
22
|
-
note: { type: [ string, 'null' ] }
|
|
23
|
-
shipping: { $ref: '#/$defs/address' }
|
|
24
|
-
tags: { type: array, items: { type: string }, maxItems: 3 }
|
|
25
|
-
lines:
|
|
26
|
-
type: array
|
|
27
|
-
items:
|
|
28
|
-
type: object
|
|
29
|
-
properties:
|
|
30
|
-
product: { type: string }
|
|
31
|
-
quantity: { type: integer, minimum: 1 }
|
|
32
|
-
required: [ product, quantity ]
|
|
33
|
-
blocks:
|
|
34
|
-
type: array
|
|
35
|
-
items:
|
|
36
|
-
oneOf:
|
|
37
|
-
- properties:
|
|
38
|
-
kind: { const: paragraph }
|
|
39
|
-
text: { type: string }
|
|
40
|
-
required: [ kind, text ]
|
|
41
|
-
- properties:
|
|
42
|
-
kind: { const: quiz }
|
|
43
|
-
question: { type: string }
|
|
44
|
-
required: [ kind, question ]
|
|
45
|
-
attributes:
|
|
46
|
-
type: object
|
|
47
|
-
additionalProperties: { type: string }
|
|
48
|
-
description: { type: string, contentMediaType: text/markdown, title: Description }
|
|
49
|
-
required: [ title, company, stage ]
|
|
50
|
-
if:
|
|
51
|
-
properties:
|
|
52
|
-
stage: { const: won }
|
|
53
|
-
required: [ stage ]
|
|
54
|
-
then:
|
|
55
|
-
required: [ amount ]
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
country: { type: string, pattern: '^[A-Z]{2}$' }
|
|
7
|
-
required: [ city ]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
deal:
|
|
12
|
-
type: object
|
|
13
|
-
properties:
|
|
14
|
-
title: { type: string, minLength: 1, maxLength: 40 }
|
|
15
|
-
company: { type: string, reference: company }
|
|
16
|
-
stage: { enum: [ lead, proposal, won, lost ], default: lead }
|
|
17
|
-
amount: { type: integer, minimum: 0 }
|
|
18
|
-
probability: { type: number, minimum: 0, maximum: 1 }
|
|
19
|
-
open: { type: boolean }
|
|
20
|
-
closes_at: { type: string, format: date-time }
|
|
21
|
-
contact_email: { type: string, format: email }
|
|
22
|
-
note: { type: [ string, 'null' ] }
|
|
23
|
-
shipping: { $ref: '#/$defs/address' }
|
|
24
|
-
tags: { type: array, items: { type: string }, maxItems: 3 }
|
|
25
|
-
lines:
|
|
26
|
-
type: array
|
|
27
|
-
items:
|
|
28
|
-
type: object
|
|
29
|
-
properties:
|
|
30
|
-
product: { type: string }
|
|
31
|
-
quantity: { type: integer, minimum: 1 }
|
|
32
|
-
required: [ product, quantity ]
|
|
33
|
-
blocks:
|
|
34
|
-
type: array
|
|
35
|
-
items:
|
|
36
|
-
oneOf:
|
|
37
|
-
- properties:
|
|
38
|
-
kind: { const: paragraph }
|
|
39
|
-
text: { type: string }
|
|
40
|
-
required: [ kind, text ]
|
|
41
|
-
- properties:
|
|
42
|
-
kind: { const: quiz }
|
|
43
|
-
question: { type: string }
|
|
44
|
-
required: [ kind, question ]
|
|
45
|
-
attributes:
|
|
46
|
-
type: object
|
|
47
|
-
additionalProperties: { type: string }
|
|
48
|
-
description: { type: string, contentMediaType: text/markdown, title: Description }
|
|
49
|
-
required: [ title, company, stage ]
|
|
50
|
-
if:
|
|
51
|
-
properties:
|
|
52
|
-
stage: { const: won }
|
|
53
|
-
required: [ stage ]
|
|
54
|
-
then:
|
|
55
|
-
required: [ amount ]
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
country: { type: string, pattern: '^[A-Z]{2}$' }
|
|
7
|
-
required: [ city ]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
deal:
|
|
12
|
-
type: object
|
|
13
|
-
properties:
|
|
14
|
-
title: { type: string, minLength: 1, maxLength: 40 }
|
|
15
|
-
company: { type: string, reference: company }
|
|
16
|
-
stage: { enum: [ lead, proposal, won, lost ], default: lead }
|
|
17
|
-
amount: { type: integer, minimum: 0 }
|
|
18
|
-
probability: { type: number, minimum: 0, maximum: 1 }
|
|
19
|
-
open: { type: boolean }
|
|
20
|
-
closes_at: { type: string, format: date-time }
|
|
21
|
-
contact_email: { type: string, format: email }
|
|
22
|
-
note: { type: [ string, 'null' ] }
|
|
23
|
-
shipping: { $ref: '#/$defs/address' }
|
|
24
|
-
tags: { type: array, items: { type: string }, maxItems: 3 }
|
|
25
|
-
lines:
|
|
26
|
-
type: array
|
|
27
|
-
items:
|
|
28
|
-
type: object
|
|
29
|
-
properties:
|
|
30
|
-
product: { type: string }
|
|
31
|
-
quantity: { type: integer, minimum: 1 }
|
|
32
|
-
required: [ product, quantity ]
|
|
33
|
-
blocks:
|
|
34
|
-
type: array
|
|
35
|
-
items:
|
|
36
|
-
oneOf:
|
|
37
|
-
- properties:
|
|
38
|
-
kind: { const: paragraph }
|
|
39
|
-
text: { type: string }
|
|
40
|
-
required: [ kind, text ]
|
|
41
|
-
- properties:
|
|
42
|
-
kind: { const: quiz }
|
|
43
|
-
question: { type: string }
|
|
44
|
-
required: [ kind, question ]
|
|
45
|
-
attributes:
|
|
46
|
-
type: object
|
|
47
|
-
additionalProperties: { type: string }
|
|
48
|
-
description: { type: string, contentMediaType: text/markdown, title: Description }
|
|
49
|
-
required: [ title, company, stage ]
|
|
50
|
-
if:
|
|
51
|
-
properties:
|
|
52
|
-
stage: { const: won }
|
|
53
|
-
required: [ stage ]
|
|
54
|
-
then:
|
|
55
|
-
required: [ amount ]
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
depot: { type: string, reference: place }
|
|
7
|
-
required: [city]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
product:
|
|
12
|
-
properties:
|
|
13
|
-
name: { type: string }
|
|
14
|
-
place:
|
|
15
|
-
properties:
|
|
16
|
-
name: { type: string }
|
|
17
|
-
deal:
|
|
18
|
-
type: object
|
|
19
|
-
properties:
|
|
20
|
-
title: { type: string }
|
|
21
|
-
company: { type: string, reference: company }
|
|
22
|
-
shipping: { $ref: '#/$defs/address' }
|
|
23
|
-
lines:
|
|
24
|
-
type: array
|
|
25
|
-
items:
|
|
26
|
-
type: object
|
|
27
|
-
properties:
|
|
28
|
-
product: { type: string, reference: product }
|
|
29
|
-
quantity: { type: integer, minimum: 1 }
|
|
30
|
-
required: [product, quantity]
|
|
31
|
-
contract: { type: string, reference: attachment }
|
|
32
|
-
required: [title, company]
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
note: {}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
note: {}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
$defs:
|
|
2
|
-
address:
|
|
3
|
-
type: object
|
|
4
|
-
properties:
|
|
5
|
-
city: { type: string }
|
|
6
|
-
country: { type: string, pattern: '^[A-Z]{2}$' }
|
|
7
|
-
required: [ city ]
|
|
8
|
-
company:
|
|
9
|
-
properties:
|
|
10
|
-
name: { type: string }
|
|
11
|
-
deal:
|
|
12
|
-
type: object
|
|
13
|
-
properties:
|
|
14
|
-
title: { type: string, minLength: 1, maxLength: 40 }
|
|
15
|
-
company: { type: string, reference: company }
|
|
16
|
-
stage: { enum: [ lead, proposal, won, lost ], default: lead }
|
|
17
|
-
amount: { type: integer, minimum: 0 }
|
|
18
|
-
probability: { type: number, minimum: 0, maximum: 1 }
|
|
19
|
-
open: { type: boolean }
|
|
20
|
-
closes_at: { type: string, format: date-time }
|
|
21
|
-
contact_email: { type: string, format: email }
|
|
22
|
-
note: { type: [ string, 'null' ] }
|
|
23
|
-
shipping: { $ref: '#/$defs/address' }
|
|
24
|
-
tags: { type: array, items: { type: string }, maxItems: 3 }
|
|
25
|
-
lines:
|
|
26
|
-
type: array
|
|
27
|
-
items:
|
|
28
|
-
type: object
|
|
29
|
-
properties:
|
|
30
|
-
product: { type: string }
|
|
31
|
-
quantity: { type: integer, minimum: 1 }
|
|
32
|
-
required: [ product, quantity ]
|
|
33
|
-
blocks:
|
|
34
|
-
type: array
|
|
35
|
-
items:
|
|
36
|
-
oneOf:
|
|
37
|
-
- properties:
|
|
38
|
-
kind: { const: paragraph }
|
|
39
|
-
text: { type: string }
|
|
40
|
-
required: [ kind, text ]
|
|
41
|
-
- properties:
|
|
42
|
-
kind: { const: quiz }
|
|
43
|
-
question: { type: string }
|
|
44
|
-
required: [ kind, question ]
|
|
45
|
-
attributes:
|
|
46
|
-
type: object
|
|
47
|
-
additionalProperties: { type: string }
|
|
48
|
-
description: { type: string, contentMediaType: text/markdown, title: Description }
|
|
49
|
-
required: [ title, company, stage ]
|
|
50
|
-
if:
|
|
51
|
-
properties:
|
|
52
|
-
stage: { const: won }
|
|
53
|
-
required: [ stage ]
|
|
54
|
-
then:
|
|
55
|
-
required: [ amount ]
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
note: {}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
note: {}
|
|
File without changes
|
|
File without changes
|