v1 server and lifecycle manager working. execution contract added
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
import os
|
||||
|
||||
name = "Set availability"
|
||||
|
||||
kind = "action"
|
||||
|
||||
id = "setavailable"
|
||||
|
||||
showstatus = True
|
||||
|
||||
skipstep = {
|
||||
"checkavailable": "validTo >= 3600"
|
||||
}
|
||||
|
||||
availabletime = int(os.environ.get("AVAILABLE_DURATION",3))
|
||||
|
||||
duration = availabletime - 1
|
||||
|
||||
keys = [
|
||||
{
|
||||
"keytitle": "option",
|
||||
"keyvalue": 1,
|
||||
},
|
||||
{
|
||||
"keytitle": "duration",
|
||||
"keyvalue": duration,
|
||||
},
|
||||
]
|
||||
|
||||
method = "PUT"
|
||||
|
||||
path = "https://rentmasseur.com/api/v1/account/dashboard/availability"
|
||||
|
||||
headers = {
|
||||
"Authorization": {
|
||||
"output": "access_token",
|
||||
"prefix": "Bearer ",
|
||||
},
|
||||
}
|
||||
|
||||
outputs = {
|
||||
"available_until": "validTo"
|
||||
}
|
||||
|
||||
prints = {
|
||||
"Available until": "available_until"
|
||||
}
|
||||
Reference in New Issue
Block a user