2495 lines
63 KiB
JSON
2495 lines
63 KiB
JSON
{
|
|
"basePath": "/api/v1",
|
|
"consumes": [
|
|
"application/json"
|
|
],
|
|
"definitions": {
|
|
"Alias": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/definitions/AliasUpdate"
|
|
},
|
|
{
|
|
"properties": {
|
|
"destination": {
|
|
"items": {
|
|
"description": "destination email address",
|
|
"example": "user@example.com",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"email": {
|
|
"description": "the alias email address",
|
|
"example": "user@example.com",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"email"
|
|
],
|
|
"type": "object"
|
|
}
|
|
]
|
|
},
|
|
"AliasUpdate": {
|
|
"properties": {
|
|
"comment": {
|
|
"description": "a comment",
|
|
"type": "string"
|
|
},
|
|
"destination": {
|
|
"items": {
|
|
"description": "alias email address",
|
|
"example": "user@example.com",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"wildcard": {
|
|
"description": "enable SQL Like wildcard syntax",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"AlternativeDomain": {
|
|
"properties": {
|
|
"domain": {
|
|
"description": "domain FQDN",
|
|
"example": "example.com",
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"description": "alternative FQDN",
|
|
"example": "example2.com",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"domain",
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"Domain": {
|
|
"properties": {
|
|
"alternatives": {
|
|
"example": "[\"example.com\"]",
|
|
"items": {
|
|
"description": "FQDN",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"comment": {
|
|
"description": "a comment",
|
|
"type": "string"
|
|
},
|
|
"max_aliases": {
|
|
"default": -1,
|
|
"description": "maximum number of aliases",
|
|
"minimum": -1,
|
|
"type": "integer"
|
|
},
|
|
"max_quota_bytes": {
|
|
"description": "maximum quota for mailbox",
|
|
"minimum": 0,
|
|
"type": "integer"
|
|
},
|
|
"max_users": {
|
|
"default": -1,
|
|
"description": "maximum number of users",
|
|
"minimum": -1,
|
|
"type": "integer"
|
|
},
|
|
"name": {
|
|
"description": "FQDN (e.g. example.com)",
|
|
"example": "example.com",
|
|
"type": "string"
|
|
},
|
|
"signup_enabled": {
|
|
"description": "allow signup",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"DomainGet": {
|
|
"properties": {
|
|
"alternatives": {
|
|
"example": "[\"example.com\"]",
|
|
"items": {
|
|
"description": "FQDN",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"comment": {
|
|
"description": "a comment",
|
|
"type": "string"
|
|
},
|
|
"dns_autoconfig": {
|
|
"items": {
|
|
"description": "DNS client auto-configuration entry",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"dns_dkim": {
|
|
"type": "string"
|
|
},
|
|
"dns_dmarc": {
|
|
"type": "string"
|
|
},
|
|
"dns_dmarc_report": {
|
|
"type": "string"
|
|
},
|
|
"dns_mx": {
|
|
"type": "string"
|
|
},
|
|
"dns_spf": {
|
|
"type": "string"
|
|
},
|
|
"dns_tlsa": {
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"managers": {
|
|
"items": {
|
|
"description": "manager of domain",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"max_aliases": {
|
|
"default": -1,
|
|
"description": "maximum number of aliases",
|
|
"minimum": -1,
|
|
"type": "integer"
|
|
},
|
|
"max_quota_bytes": {
|
|
"description": "maximum quota for mailbox",
|
|
"minimum": 0,
|
|
"type": "integer"
|
|
},
|
|
"max_users": {
|
|
"default": -1,
|
|
"description": "maximum number of users",
|
|
"minimum": -1,
|
|
"type": "integer"
|
|
},
|
|
"name": {
|
|
"description": "FQDN (e.g. example.com)",
|
|
"example": "example.com",
|
|
"type": "string"
|
|
},
|
|
"signup_enabled": {
|
|
"description": "allow signup",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"required": [
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"DomainUpdate": {
|
|
"properties": {
|
|
"alternatives": {
|
|
"example": "[\"example.com\"]",
|
|
"items": {
|
|
"description": "FQDN",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"comment": {
|
|
"description": "a comment",
|
|
"type": "string"
|
|
},
|
|
"max_aliases": {
|
|
"default": -1,
|
|
"description": "maximum number of aliases",
|
|
"minimum": -1,
|
|
"type": "integer"
|
|
},
|
|
"max_quota_bytes": {
|
|
"description": "maximum quota for mailbox",
|
|
"minimum": 0,
|
|
"type": "integer"
|
|
},
|
|
"max_users": {
|
|
"default": -1,
|
|
"description": "maximum number of users",
|
|
"minimum": -1,
|
|
"type": "integer"
|
|
},
|
|
"signup_enabled": {
|
|
"description": "allow signup",
|
|
"type": "boolean"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"Manager": {
|
|
"properties": {
|
|
"managers": {
|
|
"items": {
|
|
"description": "manager of domain",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"ManagerCreate": {
|
|
"properties": {
|
|
"user_email": {
|
|
"description": "email address of manager",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"user_email"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"Relay": {
|
|
"properties": {
|
|
"comment": {
|
|
"description": "a comment",
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"description": "relayed domain name",
|
|
"example": "example.com",
|
|
"type": "string"
|
|
},
|
|
"smtp": {
|
|
"description": "remote host",
|
|
"example": "example.com",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"RelayUpdate": {
|
|
"properties": {
|
|
"comment": {
|
|
"description": "a comment",
|
|
"type": "string"
|
|
},
|
|
"smtp": {
|
|
"description": "remote host",
|
|
"example": "example.com",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"Response": {
|
|
"properties": {
|
|
"code": {
|
|
"type": "integer"
|
|
},
|
|
"message": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"TokenGetResponse": {
|
|
"properties": {
|
|
"AuthorizedIP": {
|
|
"items": {
|
|
"description": "White listed IP addresses or networks that may use this token.",
|
|
"example": "203.0.113.0/24",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"Created": {
|
|
"description": "The date when the token was created",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"Last edit": {
|
|
"description": "The date when the token was last modifified",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the token. This description is shown on the Authentication tokens page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"description": "The email address of the user",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"id": {
|
|
"description": "The record id of the token (unique identifier)",
|
|
"example": "1",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"TokenPost": {
|
|
"properties": {
|
|
"AuthorizedIP": {
|
|
"items": {
|
|
"description": "White listed IP addresses or networks that may use this token.",
|
|
"example": "203.0.113.0/24",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the token. This description is shown on the Authentication tokens page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"description": "The email address of the user",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"email"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"TokenPost2": {
|
|
"properties": {
|
|
"AuthorizedIP": {
|
|
"items": {
|
|
"description": "White listed IP addresses or networks that may use this token.",
|
|
"example": "203.0.113.0/24",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the token. This description is shown on the Authentication tokens page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"TokenPostResponse": {
|
|
"properties": {
|
|
"AuthorizedIP": {
|
|
"items": {
|
|
"description": "White listed IP addresses or networks that may use this token.",
|
|
"example": "203.0.113.0/24",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"Created": {
|
|
"description": "The date when the token was created",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the token. This description is shown on the Authentication tokens page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"description": "The email address of the user",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"id": {
|
|
"description": "The record id of the token (unique identifier)",
|
|
"example": "1",
|
|
"type": "string"
|
|
},
|
|
"token": {
|
|
"description": "The created authentication token for the user.",
|
|
"example": "2caf6607de5129e4748a2c061aee56f2",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"UserCreate": {
|
|
"properties": {
|
|
"allow_spoofing": {
|
|
"description": "Allow the user to spoof the sender (send email as anyone)",
|
|
"type": "boolean"
|
|
},
|
|
"change_pw_next_login": {
|
|
"description": "Force the user to change their password at next login",
|
|
"type": "boolean"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the user. This description is shown on the Users page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
},
|
|
"displayed_name": {
|
|
"description": "The display name of the user within the Admin GUI",
|
|
"example": "John Doe",
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"description": "The email address of the user",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"enable_imap": {
|
|
"description": "Allow email retrieval via IMAP",
|
|
"type": "boolean"
|
|
},
|
|
"enable_pop": {
|
|
"description": "Allow email retrieval via POP3",
|
|
"type": "boolean"
|
|
},
|
|
"enabled": {
|
|
"description": "Enable the user. When an user is disabled, the user is unable to login to the Admin GUI or webmail or access his email via IMAP/POP3 or send mail",
|
|
"type": "boolean"
|
|
},
|
|
"forward_destination": {
|
|
"example": "[\"Other@example.com\"]",
|
|
"items": {
|
|
"description": "Email address to forward emails to",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"forward_enabled": {
|
|
"description": "Enable auto forwarding",
|
|
"type": "boolean"
|
|
},
|
|
"forward_keep": {
|
|
"description": "Keep a copy of the forwarded email in the inbox",
|
|
"type": "boolean"
|
|
},
|
|
"global_admin": {
|
|
"description": "Make the user a global administrator",
|
|
"type": "boolean"
|
|
},
|
|
"quota_bytes": {
|
|
"description": "The maximum quota for the user\u2019s email box in bytes",
|
|
"example": "1000000000",
|
|
"type": "integer"
|
|
},
|
|
"raw_password": {
|
|
"description": "The raw (plain text) password of the user. Mailu will hash the password using BCRYPT-SHA256",
|
|
"example": "secret",
|
|
"type": "string"
|
|
},
|
|
"reply_body": {
|
|
"description": "The body of the automatic reply email",
|
|
"example": "Hello, I am out of office. I will respond when I am back.",
|
|
"type": "string"
|
|
},
|
|
"reply_enabled": {
|
|
"description": "Enable automatic replies. This is also known as out of office (ooo) or out of facility (oof) replies",
|
|
"type": "boolean"
|
|
},
|
|
"reply_enddate": {
|
|
"description": "End date for automatic replies in YYYY-MM-DD format.",
|
|
"example": "2022-02-22",
|
|
"format": "date",
|
|
"type": "string"
|
|
},
|
|
"reply_startdate": {
|
|
"description": "Start date for automatic replies in YYYY-MM-DD format.",
|
|
"example": "2022-02-10",
|
|
"format": "date",
|
|
"type": "string"
|
|
},
|
|
"reply_subject": {
|
|
"description": "Optional subject for the automatic reply",
|
|
"example": "Out of office",
|
|
"type": "string"
|
|
},
|
|
"spam_enabled": {
|
|
"description": "Enable the spam filter",
|
|
"type": "boolean"
|
|
},
|
|
"spam_mark_as_read": {
|
|
"description": "Enable marking spam mails as read",
|
|
"type": "boolean"
|
|
},
|
|
"spam_threshold": {
|
|
"description": "The user defined spam filter tolerance",
|
|
"example": "80",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"email",
|
|
"raw_password"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"UserGet": {
|
|
"properties": {
|
|
"allow_spoofing": {
|
|
"description": "Allow the user to spoof the sender (send email as anyone)",
|
|
"type": "boolean"
|
|
},
|
|
"change_pw_next_login": {
|
|
"description": "Force the user to change their password at next login",
|
|
"type": "boolean"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the user. This description is shown on the Users page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
},
|
|
"displayed_name": {
|
|
"description": "The display name of the user within the Admin GUI",
|
|
"example": "John Doe",
|
|
"type": "string"
|
|
},
|
|
"email": {
|
|
"description": "The email address of the user",
|
|
"example": "John.Doe@example.com",
|
|
"type": "string"
|
|
},
|
|
"enable_imap": {
|
|
"description": "Allow email retrieval via IMAP",
|
|
"type": "boolean"
|
|
},
|
|
"enable_pop": {
|
|
"description": "Allow email retrieval via POP3",
|
|
"type": "boolean"
|
|
},
|
|
"enabled": {
|
|
"description": "Enable the user. When an user is disabled, the user is unable to login to the Admin GUI or webmail or access his email via IMAP/POP3 or send mail",
|
|
"type": "boolean"
|
|
},
|
|
"forward_destination": {
|
|
"example": "[\"Other@example.com\"]",
|
|
"items": {
|
|
"description": "Email address to forward emails to",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"forward_enabled": {
|
|
"description": "Enable auto forwarding",
|
|
"type": "boolean"
|
|
},
|
|
"forward_keep": {
|
|
"description": "Keep a copy of the forwarded email in the inbox",
|
|
"type": "boolean"
|
|
},
|
|
"global_admin": {
|
|
"description": "Make the user a global administrator",
|
|
"type": "boolean"
|
|
},
|
|
"password": {
|
|
"description": "Hash of the user's password; Example='$bcrypt-sha256$v=2,t=2b,r=12$fmsAdJbYAD1gGQIE5nfJq.$zLkQUEs2XZfTpAEpcix/1k5UTNPm0jO'",
|
|
"type": "string"
|
|
},
|
|
"quota_bytes": {
|
|
"description": "The maximum quota for the user\u2019s email box in bytes",
|
|
"example": "1000000000",
|
|
"type": "integer"
|
|
},
|
|
"quota_bytes_used": {
|
|
"description": "The size of the user\u2019s email box in bytes",
|
|
"example": "5000000",
|
|
"type": "integer"
|
|
},
|
|
"reply_body": {
|
|
"description": "The body of the automatic reply email",
|
|
"example": "Hello, I am out of office. I will respond when I am back.",
|
|
"type": "string"
|
|
},
|
|
"reply_enabled": {
|
|
"description": "Enable automatic replies. This is also known as out of office (ooo) or out of facility (oof) replies",
|
|
"type": "boolean"
|
|
},
|
|
"reply_enddate": {
|
|
"description": "End date for automatic replies in YYYY-MM-DD format.",
|
|
"example": "2022-02-22",
|
|
"format": "date",
|
|
"type": "string"
|
|
},
|
|
"reply_startdate": {
|
|
"description": "Start date for automatic replies in YYYY-MM-DD format.",
|
|
"example": "2022-02-10",
|
|
"format": "date",
|
|
"type": "string"
|
|
},
|
|
"reply_subject": {
|
|
"description": "Optional subject for the automatic reply",
|
|
"example": "Out of office",
|
|
"type": "string"
|
|
},
|
|
"spam_enabled": {
|
|
"description": "Enable the spam filter",
|
|
"type": "boolean"
|
|
},
|
|
"spam_mark_as_read": {
|
|
"description": "Enable marking spam mails as read",
|
|
"type": "boolean"
|
|
},
|
|
"spam_threshold": {
|
|
"description": "The user defined spam filter tolerance",
|
|
"example": "80",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"UserUpdate": {
|
|
"properties": {
|
|
"allow_spoofing": {
|
|
"description": "Allow the user to spoof the sender (send email as anyone)",
|
|
"type": "boolean"
|
|
},
|
|
"change_pw_next_login": {
|
|
"description": "Force the user to change their password at next login",
|
|
"type": "boolean"
|
|
},
|
|
"comment": {
|
|
"description": "A description for the user. This description is shown on the Users page",
|
|
"example": "my comment",
|
|
"type": "string"
|
|
},
|
|
"displayed_name": {
|
|
"description": "The display name of the user within the Admin GUI",
|
|
"example": "John Doe",
|
|
"type": "string"
|
|
},
|
|
"enable_imap": {
|
|
"description": "Allow email retrieval via IMAP",
|
|
"type": "boolean"
|
|
},
|
|
"enable_pop": {
|
|
"description": "Allow email retrieval via POP3",
|
|
"type": "boolean"
|
|
},
|
|
"enabled": {
|
|
"description": "Enable the user. When an user is disabled, the user is unable to login to the Admin GUI or webmail or access his email via IMAP/POP3 or send mail",
|
|
"type": "boolean"
|
|
},
|
|
"forward_destination": {
|
|
"example": "[\"Other@example.com\"]",
|
|
"items": {
|
|
"description": "Email address to forward emails to",
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"forward_enabled": {
|
|
"description": "Enable auto forwarding",
|
|
"type": "boolean"
|
|
},
|
|
"forward_keep": {
|
|
"description": "Keep a copy of the forwarded email in the inbox",
|
|
"type": "boolean"
|
|
},
|
|
"global_admin": {
|
|
"description": "Make the user a global administrator",
|
|
"type": "boolean"
|
|
},
|
|
"quota_bytes": {
|
|
"description": "The maximum quota for the user\u2019s email box in bytes",
|
|
"example": "1000000000",
|
|
"type": "integer"
|
|
},
|
|
"raw_password": {
|
|
"description": "The raw (plain text) password of the user. Mailu will hash the password using BCRYPT-SHA256",
|
|
"example": "secret",
|
|
"type": "string"
|
|
},
|
|
"reply_body": {
|
|
"description": "The body of the automatic reply email",
|
|
"example": "Hello, I am out of office. I will respond when I am back.",
|
|
"type": "string"
|
|
},
|
|
"reply_enabled": {
|
|
"description": "Enable automatic replies. This is also known as out of office (ooo) or out of facility (oof) replies",
|
|
"type": "boolean"
|
|
},
|
|
"reply_enddate": {
|
|
"description": "End date for automatic replies in YYYY-MM-DD format.",
|
|
"example": "2022-02-22",
|
|
"format": "date",
|
|
"type": "string"
|
|
},
|
|
"reply_startdate": {
|
|
"description": "Start date for automatic replies in YYYY-MM-DD format.",
|
|
"example": "2022-02-10",
|
|
"format": "date",
|
|
"type": "string"
|
|
},
|
|
"reply_subject": {
|
|
"description": "Optional subject for the automatic reply",
|
|
"example": "Out of office",
|
|
"type": "string"
|
|
},
|
|
"spam_enabled": {
|
|
"description": "Enable the spam filter",
|
|
"type": "boolean"
|
|
},
|
|
"spam_mark_as_read": {
|
|
"description": "Enable marking spam mails as read",
|
|
"type": "boolean"
|
|
},
|
|
"spam_threshold": {
|
|
"description": "The user defined spam filter tolerance",
|
|
"example": "80",
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"type": "object"
|
|
}
|
|
},
|
|
"info": {
|
|
"title": "Mailu API",
|
|
"version": "1.0"
|
|
},
|
|
"paths": {
|
|
"/alias": {
|
|
"get": {
|
|
"operationId": "list_alias",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"items": {
|
|
"$ref": "#/definitions/Alias"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all aliases",
|
|
"tags": [
|
|
"alias"
|
|
]
|
|
},
|
|
"post": {
|
|
"operationId": "create_alias",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/Alias"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Duplicate alias",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new alias",
|
|
"tags": [
|
|
"alias"
|
|
]
|
|
}
|
|
},
|
|
"/alias/destination/{domain}": {
|
|
"get": {
|
|
"operationId": "find_alias_filter_domain",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Alias"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Alias or domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up the aliases of the specified domain",
|
|
"tags": [
|
|
"alias"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "domain",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
]
|
|
},
|
|
"/alias/{alias}": {
|
|
"delete": {
|
|
"operationId": "delete_alias",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Alias not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified alias",
|
|
"tags": [
|
|
"alias"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_alias",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Alias"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Alias not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up the specified alias",
|
|
"tags": [
|
|
"alias"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "alias",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"patch": {
|
|
"operationId": "update_alias",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/AliasUpdate"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Alias not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Update the specfied alias",
|
|
"tags": [
|
|
"alias"
|
|
]
|
|
}
|
|
},
|
|
"/alternative": {
|
|
"get": {
|
|
"operationId": "list_alternative",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"items": {
|
|
"$ref": "#/definitions/AlternativeDomain"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all alternatives",
|
|
"tags": [
|
|
"alternative"
|
|
]
|
|
},
|
|
"post": {
|
|
"operationId": "create_alternative",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/AlternativeDomain"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Domain not found or missing",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Duplicate alternative domain name",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new alternative (for domain)",
|
|
"tags": [
|
|
"alternative"
|
|
]
|
|
}
|
|
},
|
|
"/alternative/{alt}": {
|
|
"delete": {
|
|
"operationId": "delete_alternative",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Alternative/Domain not found or missing",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Duplicate domain name",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified alternative (for domain)",
|
|
"tags": [
|
|
"alternative"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_alternative",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/AlternativeDomain"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Alternative not found or missing",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up the specified alternative (of domain)",
|
|
"tags": [
|
|
"alternative"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "alt",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
]
|
|
},
|
|
"/domain": {
|
|
"get": {
|
|
"operationId": "list_domain",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"items": {
|
|
"$ref": "#/definitions/DomainGet"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all domains",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"post": {
|
|
"operationId": "create_domain",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/Domain"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"409": {
|
|
"description": "Duplicate domain/alternative name",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
}
|
|
},
|
|
"/domain/{domain}": {
|
|
"delete": {
|
|
"operationId": "delete_domain",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_domain",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/DomainGet"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "domain",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"patch": {
|
|
"operationId": "update_domain",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/DomainUpdate"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Duplicate domain/alternative name",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Update the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
}
|
|
},
|
|
"/domain/{domain}/dkim": {
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "domain",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"post": {
|
|
"operationId": "generate_dkim",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Generate new DKIM/DMARC keys for the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
}
|
|
},
|
|
"/domain/{domain}/manager": {
|
|
"get": {
|
|
"operationId": "list_managers",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Manager"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all managers of the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "domain",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"post": {
|
|
"operationId": "create_manager",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/ManagerCreate"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User or domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"409": {
|
|
"description": "Duplicate domain manager",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new domain manager for the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
}
|
|
},
|
|
"/domain/{domain}/manager/{email}": {
|
|
"delete": {
|
|
"operationId": "delete_manager",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Manager not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified manager of the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_manager",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Manager not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Check if the specified user is a manager of the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "domain",
|
|
"required": true,
|
|
"type": "string"
|
|
},
|
|
{
|
|
"in": "path",
|
|
"name": "email",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
]
|
|
},
|
|
"/domain/{domain}/users": {
|
|
"get": {
|
|
"operationId": "list_user_domain",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/UserGet"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Domain not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all the users from the specified domain",
|
|
"tags": [
|
|
"domain"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "domain",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
]
|
|
},
|
|
"/relay": {
|
|
"get": {
|
|
"operationId": "list_relays",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"items": {
|
|
"$ref": "#/definitions/Relay"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all relays",
|
|
"tags": [
|
|
"relay"
|
|
]
|
|
},
|
|
"post": {
|
|
"operationId": "create_relay",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/Relay"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"409": {
|
|
"description": "Duplicate relay",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new relay",
|
|
"tags": [
|
|
"relay"
|
|
]
|
|
}
|
|
},
|
|
"/relay/{name}": {
|
|
"delete": {
|
|
"operationId": "delete_relay",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Relay not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified relay",
|
|
"tags": [
|
|
"relay"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_relay",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Relay"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Relay not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up the specified relay",
|
|
"tags": [
|
|
"relay"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "name",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"patch": {
|
|
"operationId": "update_relay",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/RelayUpdate"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Relay not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Update the specified relay",
|
|
"tags": [
|
|
"relay"
|
|
]
|
|
}
|
|
},
|
|
"/token": {
|
|
"get": {
|
|
"operationId": "list_tokens",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"items": {
|
|
"$ref": "#/definitions/TokenGetResponse"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all tokens",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
},
|
|
"post": {
|
|
"operationId": "create_token",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenPost"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenPostResponse"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new token",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
}
|
|
},
|
|
"/token/{token_id}": {
|
|
"delete": {
|
|
"operationId": "delete_token",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Token not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified token",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_token",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenGetResponse"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Token not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Find the specified token",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "token_id",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"patch": {
|
|
"operationId": "update_token",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenPost2"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Update the specified token",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
}
|
|
},
|
|
"/tokenuser/{email}": {
|
|
"get": {
|
|
"operationId": "find_tokens_of_user",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenGetResponse"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "Token not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up all the tokens of the specified user",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "email",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"post": {
|
|
"operationId": "create_token",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenPost2"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/TokenPostResponse"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new token for the specified user",
|
|
"tags": [
|
|
"token"
|
|
]
|
|
}
|
|
},
|
|
"/user": {
|
|
"get": {
|
|
"operationId": "list_user",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"items": {
|
|
"$ref": "#/definitions/UserGet"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "List all users",
|
|
"tags": [
|
|
"user"
|
|
]
|
|
},
|
|
"post": {
|
|
"operationId": "create_user",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/UserCreate"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"409": {
|
|
"description": "Duplicate user",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Create a new user",
|
|
"tags": [
|
|
"user"
|
|
]
|
|
}
|
|
},
|
|
"/user/{email}": {
|
|
"delete": {
|
|
"operationId": "delete_user",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Delete the specified user",
|
|
"tags": [
|
|
"user"
|
|
]
|
|
},
|
|
"get": {
|
|
"operationId": "find_user",
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/UserGet"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Look up the specified user",
|
|
"tags": [
|
|
"user"
|
|
]
|
|
},
|
|
"parameters": [
|
|
{
|
|
"in": "path",
|
|
"name": "email",
|
|
"required": true,
|
|
"type": "string"
|
|
}
|
|
],
|
|
"patch": {
|
|
"operationId": "update_user",
|
|
"parameters": [
|
|
{
|
|
"in": "body",
|
|
"name": "payload",
|
|
"required": true,
|
|
"schema": {
|
|
"$ref": "#/definitions/UserUpdate"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "Success",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"400": {
|
|
"description": "Input validation exception",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
},
|
|
"401": {
|
|
"description": "Authorization header missing"
|
|
},
|
|
"403": {
|
|
"description": "Invalid authorization header"
|
|
},
|
|
"404": {
|
|
"description": "User not found",
|
|
"schema": {
|
|
"$ref": "#/definitions/Response"
|
|
}
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"summary": "Update the specified user",
|
|
"tags": [
|
|
"user"
|
|
]
|
|
}
|
|
}
|
|
},
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"responses": {
|
|
"MaskError": {
|
|
"description": "When any error occurs on mask"
|
|
},
|
|
"ParseError": {
|
|
"description": "When a mask can't be parsed"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"Bearer": []
|
|
}
|
|
],
|
|
"securityDefinitions": {
|
|
"Bearer": {
|
|
"in": "header",
|
|
"name": "Authorization",
|
|
"type": "apiKey"
|
|
}
|
|
},
|
|
"swagger": "2.0",
|
|
"tags": [
|
|
{
|
|
"description": "User operations",
|
|
"name": "user"
|
|
},
|
|
{
|
|
"description": "Domain operations",
|
|
"name": "domain"
|
|
},
|
|
{
|
|
"description": "Alternative operations",
|
|
"name": "alternative"
|
|
},
|
|
{
|
|
"description": "Alias operations",
|
|
"name": "alias"
|
|
},
|
|
{
|
|
"description": "Relay operations",
|
|
"name": "relay"
|
|
},
|
|
{
|
|
"description": "Token operations",
|
|
"name": "token"
|
|
}
|
|
]
|
|
}
|