Import a pack
curl --request POST \
--url https://judged.systems/api/packs/import \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"name": "<string>",
"document": {
"questions": [
{
"type": "choice",
"id": "<string>",
"name": "<string>",
"instructions": "<string>",
"criteria": {},
"review": {
"minSelectedProbability": 0.5
}
}
]
}
}
'const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
document: {
questions: [
{
type: 'choice',
id: '<string>',
name: '<string>',
instructions: '<string>',
criteria: {},
review: {minSelectedProbability: 0.5}
}
]
}
})
};
fetch('https://judged.systems/api/packs/import', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://judged.systems/api/packs/import"
payload = {
"name": "<string>",
"document": { "questions": [
{
"type": "choice",
"id": "<string>",
"name": "<string>",
"instructions": "<string>",
"criteria": {},
"review": { "minSelectedProbability": 0.5 }
}
] }
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"name": "<string>",
"draftVersionId": "<string>"
}{
"error": "<string>",
"issues": [
{}
]
}Packs
Import a pack
Requires packs:write.
POST
/
api
/
packs
/
import
Import a pack
curl --request POST \
--url https://judged.systems/api/packs/import \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"name": "<string>",
"document": {
"questions": [
{
"type": "choice",
"id": "<string>",
"name": "<string>",
"instructions": "<string>",
"criteria": {},
"review": {
"minSelectedProbability": 0.5
}
}
]
}
}
'const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
document: {
questions: [
{
type: 'choice',
id: '<string>',
name: '<string>',
instructions: '<string>',
criteria: {},
review: {minSelectedProbability: 0.5}
}
]
}
})
};
fetch('https://judged.systems/api/packs/import', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://judged.systems/api/packs/import"
payload = {
"name": "<string>",
"document": { "questions": [
{
"type": "choice",
"id": "<string>",
"name": "<string>",
"instructions": "<string>",
"criteria": {},
"review": { "minSelectedProbability": 0.5 }
}
] }
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "<string>",
"name": "<string>",
"draftVersionId": "<string>"
}{
"error": "<string>",
"issues": [
{}
]
}