version = 1
[artur.server]
bind = "127.0.0.1"
port = 46796
body_limit_bytes = 1048576
[[artur.endpoints]]
name = "create_challenge"
method = "POST"
path = "/v1/challenge"
action = "task.run"
task = "challenge_create"
[[artur.tasks]]
name = "challenge_create"
mode = "sync"
command = "challenge"
args = [
"create",
"--cost", "5000",
"--random-counter",
"--expires-in", "600",
"--hmac-secret", "{{env.ARTUR_CHALLENGE_HMAC_SECRET}}",
"--hmac-key-secret", "{{env.ARTUR_CHALLENGE_HMAC_KEY_SECRET}}",
]
timeout_ms = 10000
stdout_format = "json"
[artur.tasks.stdin]
type = "none"
[[artur.endpoints]]
name = "create_space"
method = "POST"
path = "/v1/space"
action = "task.run"
task = "space_create"
[[artur.tasks]]
name = "space_create"
mode = "sync"
command = "python3"
args = ["examples/scripts/space_create.py"]
timeout_ms = 30000
stdout_format = "json"
[artur.tasks.env]
ARTUR_CHALLENGE_HMAC_SECRET = "{{env.ARTUR_CHALLENGE_HMAC_SECRET}}"
ARTUR_CHALLENGE_HMAC_KEY_SECRET = "{{env.ARTUR_CHALLENGE_HMAC_KEY_SECRET}}"
ARTUR_SPACE_DB = "{{env.ARTUR_SPACE_DB}}"
[artur.tasks.stdin]
type = "body"
[[artur.endpoints]]
name = "get_space_by_path"
method = "GET"
path = "/v1/space/{sid}"
action = "task.run"
task = "space_get"
[[artur.tasks]]
name = "space_get"
mode = "sync"
command = "python3"
args = ["examples/scripts/space_get.py", "--sid", "{{param.sid}}"]
timeout_ms = 10000
stdout_format = "json"
[artur.tasks.env]
ARTUR_SPACE_DB = "{{env.ARTUR_SPACE_DB}}"
[artur.tasks.stdin]
type = "none"
[[artur.endpoints]]
name = "get_space_by_header"
method = "GET"
path = "/v1/space/"
action = "task.run"
task = "space_get_by_header"
[[artur.tasks]]
name = "space_get_by_header"
mode = "sync"
command = "python3"
args = ["examples/scripts/space_get.py", "--sid", "{{header.sid}}"]
timeout_ms = 10000
stdout_format = "json"
[artur.tasks.env]
ARTUR_SPACE_DB = "{{env.ARTUR_SPACE_DB}}"
[artur.tasks.stdin]
type = "none"