Skip to content
Snippets Groups Projects
Commit 0e7fefc6 authored by Colton Leekley-Winslow's avatar Colton Leekley-Winslow
Browse files

separate job schema from raml and add job definition schema

parent 8c80894b
No related branches found
No related tags found
No related merge requests found
......@@ -6,92 +6,7 @@ get:
body:
application/json:
example: !include ../examples/job_list.json
schema: |
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "array",
"items": {
"type": "object",
"properties": {
"inputs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"input": {
"type": "string"
},
"type": {
"type": "string"
},
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"input",
"type",
"id",
"name"
]
}
},
"attempt": {
"type": "integer"
},
"name": {
"type": "string"
},
"tags": {
"type": "array",
"items": {
"type": "string"
}
},
"destination": {
"type": "object",
"properties": {
"type": {
"type": "string"
},
"id": {
"type": "string"
}
},
"required": [
"type",
"id"
]
},
"modified": {
"type": "string"
},
"created": {
"type": "string"
},
"state": {
"type": "string"
},
"_id": {
"type": "string"
}
},
"required": [
"inputs",
"attempt",
"name",
"tags",
"destination",
"modified",
"created",
"state",
"_id"
]
}
}
schema: !include ../schemas/output/job-list.json
/add:
description: Add a job
post:
......
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"inputs": {
"type": "array",
"items": {
"type": "object",
"properties": {
"input": {
"type": "string"
},
"type": {
"type": "string"
},
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"input",
"type",
"id",
"name"
]
}
},
"attempt": {
"type": "integer"
},
"name": {
"type": "string"
},
"tags": {
"type": "array",
"items": {
"type": "string"
}
},
"destination": {
"type": "object",
"properties": {
"type": {
"type": "string"
},
"id": {
"type": "string"
}
},
"required": [
"type",
"id"
]
},
"modified": {
"type": "string"
},
"created": {
"type": "string"
},
"state": {
"type": "string"
},
"_id": {
"type": "string"
}
}
}
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "array",
"items": {
"$ref":"../definitions/job.json#",
"required": [
"inputs",
"attempt",
"name",
"tags",
"destination",
"modified",
"created",
"state",
"_id"
]
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment