{"openapi":"3.1.0","info":{"title":"AutoBackup.me Agent API","version":"1.0.0"},"paths":{"/v1/agent/me":{"get":{"tags":["Agent API"],"summary":"Me","operationId":"me_v1_agent_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/agent/projects":{"get":{"tags":["Agent API"],"summary":"Projects","operationId":"projects_v1_agent_projects_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Agent API"],"summary":"Create Project","operationId":"create_project_v1_agent_projects_post","parameters":[{"name":"idempotency-key","in":"header","required":true,"schema":{"type":"string","minLength":1,"maxLength":128,"title":"Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}":{"get":{"tags":["Agent API"],"summary":"Get Project","operationId":"get_project_v1_agent_projects__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Agent API"],"summary":"Rename","operationId":"rename_v1_agent_projects__project_id__patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RenameRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/policy":{"put":{"tags":["Agent API"],"summary":"Policy","operationId":"policy_v1_agent_projects__project_id__policy_put","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/file-keys":{"get":{"tags":["Agent API"],"summary":"List File Keys","operationId":"list_file_keys_v1_agent_projects__project_id__file_keys_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Agent API"],"summary":"New File Key","operationId":"new_file_key_v1_agent_projects__project_id__file_keys_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CredentialRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/file-keys/{username}":{"delete":{"tags":["Agent API"],"summary":"Revoke File Key","operationId":"revoke_file_key_v1_agent_projects__project_id__file_keys__username__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"username","in":"path","required":true,"schema":{"type":"string","title":"Username"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/s3-keys":{"get":{"tags":["Agent API"],"summary":"S3 Keys","operationId":"s3_keys_v1_agent_projects__project_id__s3_keys_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Agent API"],"summary":"Create S3 Keys","operationId":"create_s3_keys_v1_agent_projects__project_id__s3_keys_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/s3-keys/{access}":{"delete":{"tags":["Agent API"],"summary":"Revoke S3","operationId":"revoke_s3_v1_agent_projects__project_id__s3_keys__access__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"access","in":"path","required":true,"schema":{"type":"string","title":"Access"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/backups":{"get":{"tags":["Agent API"],"summary":"Backups","operationId":"backups_v1_agent_projects__project_id__backups_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/backups/{backup_id}":{"get":{"tags":["Agent API"],"summary":"Get Backup","operationId":"get_backup_v1_agent_projects__project_id__backups__backup_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","title":"Backup Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/backups/{backup_id}/retry":{"post":{"tags":["Agent API"],"summary":"Retry","operationId":"retry_v1_agent_projects__project_id__backups__backup_id__retry_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","title":"Backup Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/agent/projects/{project_id}/backups/{backup_id}/content":{"get":{"tags":["Agent API"],"summary":"Content","operationId":"content_v1_agent_projects__project_id__backups__backup_id__content_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","title":"Project Id"}},{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","title":"Backup Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"CredentialRequest":{"properties":{"name":{"type":"string","maxLength":80,"minLength":1,"title":"Name","default":"FTP/SFTP загрузка"},"allow_ftp":{"type":"boolean","title":"Allow Ftp","default":false},"expires_days":{"type":"integer","maximum":365.0,"minimum":1.0,"title":"Expires Days","default":90}},"type":"object","title":"CredentialRequest"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"Policy":{"properties":{"retention_days":{"type":"integer","maximum":365.0,"minimum":7.0,"title":"Retention Days","default":30},"expected_hours":{"type":"integer","maximum":720.0,"minimum":0.0,"title":"Expected Hours","default":24},"grace_hours":{"type":"integer","maximum":168.0,"minimum":1.0,"title":"Grace Hours","default":2}},"type":"object","title":"Policy"},"ProjectRequest":{"properties":{"name":{"type":"string","maxLength":80,"minLength":1,"pattern":"^[^\\x00-\\x1f]+$","title":"Name"},"quota_bytes":{"type":"integer","maximum":1000000000000000.0,"exclusiveMinimum":0.0,"title":"Quota Bytes"},"copies":{"type":"integer","maximum":3.0,"minimum":2.0,"title":"Copies","default":3}},"type":"object","required":["name","quota_bytes"],"title":"ProjectRequest"},"RenameRequest":{"properties":{"name":{"type":"string","maxLength":80,"minLength":1,"pattern":"^[^\\x00-\\x1f]+$","title":"Name"}},"type":"object","required":["name"],"title":"RenameRequest"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"ManagementKey":{"type":"http","scheme":"bearer","bearerFormat":"abm_..."}}},"servers":[{"url":"https://api.autobackup.me"}],"security":[{"ManagementKey":[]}]}