-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
openapi.json
1 lines (1 loc) · 18.2 KB
/
openapi.json
1
{"info":{"title":"Lethean Server","description":"Lethean dAppServer","version":"3.1.1","contact":{"name":"Lethean","url":"https://lethean.io","email":"hello@lt.hn"},"license":{"name":"EUPL-1.2","url":"https://eupl.eu/1.2/en/"}},"tags":[],"servers":[{"url":"http://localhost:36911"}],"openapi":"3.0.3","components":{"schemas":{"FilePathDTO":{"properties":{"path":{"type":"string"}},"required":["path"]},"CreateFileDTO":{"properties":{"path":{"type":"string"},"data":{"type":"string"}},"required":["path","data"]},"FilePathCheckDTO":{"properties":{"path":{"type":"string"},"result":{"type":"boolean"}},"required":["path","result"]},"FileDownloadRequest":{"properties":{"url":{"type":"string"},"file":{"type":"string"},"dir":{"type":"string"},"mode":{"type":"number"}},"required":["url","file","dir"]},"ConfigObjectGetDTO":{"properties":{"group":{"type":"string"},"object":{"type":"string"}},"required":["group","object"]},"ConfigObjectSetDTO":{"properties":{"group":{"type":"string"},"object":{"type":"string"},"data":{"type":"string"}},"required":["group","object","data"]},"ConfigObjectRemoveDTO":{"properties":{"group":{"type":"string"},"object":{"type":"string"}},"required":["group","object"]},"ConfigObjectClearDTO":{"properties":{"group":{"type":"string"}},"required":["group"]},"ConfigObjectCountDTO":{"properties":{"group":{"type":"string"}},"required":["group"]},"ConfigFileRenderDTO":{"properties":{"file":{"type":"string"},"model":{"type":"object"}},"required":["file","model"]},"ConfigFileRenderStringDTO":{"properties":{"template":{"type":"string"},"model":{"type":"object"}},"required":["template","model"]},"ConfigFileLoadDTO":{"properties":{"filename":{"type":"string"}},"required":["filename"]},"ConfigFileRenderAndLoadDTO":{"properties":{"file":{"type":"string"},"model":{"$ref":"#/components/schemas/ConfigObjectGetDTO"}},"required":["file","model"]},"INIObjectParseJSONDTO":{"properties":{"data":{"type":"string"}},"required":["data"]},"QuasiSaltHashDTO":{"properties":{"input":{"type":"string"}},"required":["input"]},"QuasiSaltHashVerifyDTO":{"properties":{"input":{"type":"string"},"hash":{"type":"string"}},"required":["input","hash"]},"HashDTO":{"properties":{"input":{"type":"string"}},"required":["input"]},"OpenPGPCreateKeyPairDTO":{"properties":{"passphrase":{"type":"string"},"name":{"type":"string"}},"required":["passphrase","name"]},"OpenPGPEncryptBYIDDTO":{"properties":{"id":{"type":"string"},"message":{"type":"string"},"passphrase":{"type":"string"}},"required":["id","message"]},"OpenPGPDecryptBYIDDTO":{"properties":{"id":{"type":"string"},"message":{"type":"string"},"passphrase":{"type":"string"},"signedBy":{"type":"string"}},"required":["id","message","passphrase"]},"OpenPGPSignBYIDDTO":{"properties":{"id":{"type":"string"},"message":{"type":"string"},"passphrase":{"type":"string"}},"required":["id","message","passphrase"]},"OpenPGPVerifyBYIDDTO":{"properties":{"id":{"type":"string"},"message":{"type":"string"}},"required":["id","message"]},"OpenPGPGetPublicKeyDTO":{"properties":{"id":{"type":"string"}},"required":["id"]},"Object":{"properties":{}},"ServerResponse":{"properties":{"status":{"type":"number","enum":[200,404],"example":200},"data":{"type":"string"},"signature":{"type":"string"}},"required":["status","data"]},"ProcessRunDTO":{"properties":{"command":{"type":"string"},"args":{"type":"object"}},"required":["command","args"]},"ProcessAddDTO":{"properties":{"key":{"type":"string"},"command":{"type":"string"},"stdOut":{"type":"object"},"stdIn":{"type":"object"},"stdErr":{"type":"object"}},"required":["key","command","stdOut","stdIn","stdErr"]},"ProcessStartDTO":{"properties":{"key":{"type":"string"}},"required":["key"]},"ProcessStopDTO":{"properties":{"key":{"type":"string"}},"required":["key"]},"ProcessKillDTO":{"properties":{"key":{"type":"string"}},"required":["key"]},"ContainerCreateResponse":{"properties":{}},"Container":{"properties":{"Image":{"type":"string"},"Cmd":{"type":"array"},"AttachStdin":{"type":"boolean"},"AttachStdout":{"type":"boolean"},"AttachStderr":{"type":"boolean"},"Tty":{"type":"boolean"},"OpenStdin":{"type":"boolean"},"StdinOnce":{"type":"boolean"},"Env":{"type":"array"},"HostConfig":{"type":"object"},"NetworkingConfig":{"type":"object"}},"required":["Image","Cmd","AttachStdin","AttachStdout","AttachStderr","Tty","OpenStdin","StdinOnce","Env","HostConfig","NetworkingConfig"]},"BlockchainLetheanDaemonStartDTO":{"properties":{"configFile":{"type":"string"},"dataDir":{"type":"string"},"logDir":{"type":"string"}},"required":["configFile","dataDir","logDir"]},"BlockchainLetheanRPCDTO":{"properties":{"url":{"type":"string"},"req":{"type":"string"}},"required":["url","req"]}}},"paths":{"/mod/io/fs/local/list":{"post":{"operationId":"getDirectoryList","responses":{"200":{"description":""}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathDTO"}}},"required":true,"description":""}}},"/mod/io/fs/local/list-detailed":{"post":{"operationId":"getDetailedDirectoryList","responses":{"200":{"description":""}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathDTO"}}},"required":true,"description":""}}},"/mod/io/fs/local/read":{"post":{"operationId":"readFile","responses":{"200":{"description":""}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathDTO"}}},"required":true,"description":""}}},"/mod/io/fs/local/write":{"post":{"operationId":"writeFile","responses":{"200":{"description":""}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateFileDTO"}}},"required":true,"description":""}}},"/mod/io/fs/local/is-storage":{"post":{"operationId":"isFile","responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathCheckDTO"}}}}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathDTO"}}},"required":true,"description":""}}},"/mod/io/fs/local/is-dir":{"post":{"operationId":"isDir","responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathCheckDTO"}}}}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FilePathDTO"}}},"required":true,"description":""}}},"/io/download/fetch":{"post":{"operationId":"fetchFile","responses":{"200":{"description":""}},"tags":["Input/Output"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileDownloadRequest"}}},"required":true,"description":""}}},"/config/object/get":{"post":{"operationId":"getConfig","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigObjectGetDTO"}}},"required":true,"description":""}}},"/config/object/set":{"post":{"operationId":"setConfig","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigObjectSetDTO"}}},"required":true,"description":""}}},"/config/object/remove":{"post":{"operationId":"removeConfig","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigObjectRemoveDTO"}}},"required":true,"description":""}}},"/config/object/clear":{"post":{"operationId":"clearConfig","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigObjectClearDTO"}}},"required":true,"description":""}}},"/config/object/count":{"post":{"operationId":"countConfig","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigObjectCountDTO"}}},"required":true,"description":""}}},"/config/storage/render":{"post":{"operationId":"render","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigFileRenderDTO"}}},"required":true,"description":""}}},"/config/storage/renderString":{"post":{"operationId":"renderString","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigFileRenderStringDTO"}}},"required":true,"description":""}}},"/config/storage/load":{"post":{"operationId":"load","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigFileLoadDTO"}}},"required":true,"description":""}}},"/config/storage/renderAndLoad":{"post":{"operationId":"renderAndLoad","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfigFileRenderAndLoadDTO"}}},"required":true,"description":""}}},"/config/ini/parseJSON":{"post":{"operationId":"parse","responses":{"200":{"description":""}},"tags":["Config"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/INIObjectParseJSONDTO"}}},"required":true,"description":""}}},"/crypto/hash/quasi-salted-hash":{"post":{"operationId":"createQuasiSalt","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuasiSaltHashDTO"}}},"required":true,"description":""}}},"/crypto/hash/quasi-salted-hash-verify":{"post":{"operationId":"verifyQuasiSalt","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuasiSaltHashVerifyDTO"}}},"required":true,"description":""}}},"/crypto/hash/sha256":{"post":{"operationId":"sha256","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HashDTO"}}},"required":true,"description":""}}},"/crypto/hash/sha384":{"post":{"operationId":"sha384","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HashDTO"}}},"required":true,"description":""}}},"/crypto/hash/sha512":{"post":{"operationId":"sha512","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HashDTO"}}},"required":true,"description":""}}},"/crypto/openpgp/generate-key-pair":{"post":{"operationId":"generateKeyPair","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenPGPCreateKeyPairDTO"}}},"required":true,"description":""}}},"/crypto/openpgp/encrypt":{"post":{"operationId":"encrypt","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenPGPEncryptBYIDDTO"}}},"required":true,"description":""}}},"/crypto/openpgp/decrypt":{"post":{"operationId":"decrypt","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenPGPDecryptBYIDDTO"}}},"required":true,"description":""}}},"/crypto/openpgp/sign":{"post":{"operationId":"sign","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenPGPSignBYIDDTO"}}},"required":true,"description":""}}},"/crypto/openpgp/verify":{"post":{"operationId":"verify","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenPGPVerifyBYIDDTO"}}},"required":true,"description":""}}},"/crypto/openpgp/get-public-key":{"post":{"operationId":"getPublicKey","responses":{"200":{"description":""}},"tags":["Cryptography"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenPGPGetPublicKeyDTO"}}},"required":true,"description":""}}},"/apps/installed":{"get":{"operationId":"listApps","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"string"}}}}},"tags":["Apps"]}},"/apps/marketplace":{"get":{"operationId":"getMarketPlaceApps","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"string"}}}}},"tags":["Apps"],"parameters":[]}},"/apps/install":{"post":{"operationId":"installApp","responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerResponse"}}}}},"tags":["Apps"]}},"/apps/remove":{"post":{"operationId":"removeApp","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"object"}}}}},"tags":["Apps"]}},"/process/run":{"post":{"operationId":"runProcess","responses":{"200":{"description":""}},"tags":["Process"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProcessRunDTO"}}},"required":true,"description":""}}},"/process/add":{"post":{"operationId":"addProcess","responses":{"200":{"description":""}},"tags":["Process"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProcessAddDTO"}}},"required":true,"description":""}}},"/process/start":{"post":{"operationId":"startProcess","responses":{"200":{"description":""}},"tags":["Process"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProcessStartDTO"}}},"required":true,"description":""}}},"/process/stop":{"post":{"operationId":"stopProcess","responses":{"200":{"description":""}},"tags":["Process"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProcessStopDTO"}}},"required":true,"description":""}}},"/process/kill":{"post":{"operationId":"killProcess","responses":{"200":{"description":""}},"tags":["Process"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProcessKillDTO"}}},"required":true,"description":""}}},"/docker/container/list":{"get":{"operationId":"listContainers","responses":{"200":{"description":""}},"tags":["Docker"]}},"/docker/container/create/{id}":{"post":{"operationId":"createContainer","responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContainerCreateResponse"}}}}},"tags":["Docker"],"parameters":[{"name":"id","in":"path","description":"","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Container"}}},"required":true,"description":""}}},"/docker/container/start/{id}":{"get":{"operationId":"startContainer","responses":{"200":{"description":""}},"tags":["Docker"],"parameters":[{"name":"id","in":"path","description":"","required":true,"schema":{"type":"string"}}]}},"/docker/container/stop/{id}":{"get":{"operationId":"stopContainer","responses":{"200":{"description":""}},"tags":["Docker"],"parameters":[{"name":"id","in":"path","description":"","required":true,"schema":{"type":"string"}}]}},"/docker/container/kill/{id}":{"get":{"operationId":"killContainer","responses":{"200":{"description":""}},"tags":["Docker"],"parameters":[{"name":"id","in":"path","description":"","required":true,"schema":{"type":"string"}}]}},"/docker/container/remove/{id}":{"get":{"operationId":"removeContainer","responses":{"200":{"description":""}},"tags":["Docker"],"parameters":[{"name":"id","in":"path","description":"","required":true,"schema":{"type":"string"}}]}},"/docker/container/inspect/{id}":{"get":{"operationId":"inspectContainer","responses":{"200":{"description":""}},"tags":["Docker"],"parameters":[{"name":"id","in":"path","description":"","required":true,"schema":{"type":"string"}}]}},"/docker/image/list":{"get":{"operationId":"listImages","responses":{"200":{"description":""}},"tags":["Docker"]}},"/docker/image/pull":{"post":{"operationId":"pullImage","responses":{"200":{"description":""}},"tags":["Docker"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Object"}}},"required":true,"description":""}}},"/api/blockchain/lthn/v1/daemon":{"get":{"operationId":"getDaemonStatus","responses":{"200":{"description":""}},"tags":["blockchain-lthn-v1-daemon"]},"post":{"operationId":"start","responses":{"200":{"description":""}},"tags":["blockchain-lthn-v1-daemon"]}},"/api/blockchain/lthn/v1/daemon/start":{"post":{"operationId":"startDaemon","responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerResponse"}}}}},"tags":["blockchain-lthn-v1-daemon"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockchainLetheanDaemonStartDTO"}}},"required":true,"description":""}}},"/api/blockchain/lthn/v1/daemon/json_rpc":{"post":{"operationId":"jsonRpc","responses":{"200":{"description":"","content":{"application/json":{"schema":{"type":"string"}}}}},"tags":["blockchain-lthn-v1-daemon"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockchainLetheanRPCDTO"}}},"required":true,"description":""}}},"/api/blockchain/lthn/v1/daemon/export":{"post":{"operationId":"exportBlockchain","responses":{"200":{"description":""}},"tags":["blockchain-lthn-v1-daemon"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Object"}}},"required":true,"description":""}}},"/api/blockchain/lthn/v1/daemon/import":{"post":{"operationId":"importBlockchain","responses":{"200":{"description":""}},"tags":["blockchain-lthn-v1-daemon"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Object"}}},"required":true,"description":""}}},"/api/blockchain/lthn/v1/daemon/download":{"post":{"operationId":"downloadDaemon","responses":{"200":{"description":""}},"tags":["blockchain-lthn-v1-daemon"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Object"}}},"required":true,"description":""}}},"//h":{"get":{"operationId":"welcomePage","responses":{"200":{"description":""}},"tags":["Info"]}},"/system/check":{"get":{"operationId":"checkServer","responses":{"200":{"description":""}},"tags":["System"]}},"/system/cert":{"get":{"operationId":"getServerCertificate","responses":{"200":{"description":""}},"tags":["System"]}}}}