Change FTP user of a web hosting package
Change password, directory, disk space, status, end or name of one FTP user.
manitu_webhosting_web_ftpuser_set on https://mcp.manitu.de/mcpAnnotations as tools/list sends them
Description for the model
Changes an FTP user of a web hosting package of the manitu customer account this connection works in, by site_id and username from manitu_webhosting_web_ftpuser_list. Only the fields given change. A new password only as password_same_as (the password of another FTP user of the package) or password_hash (bcrypt) - NEVER ask for or pass a plaintext password, it is refused over this connection; otherwise the customer sets it in the customer panel. status inactive switches it off without deleting it; expires_at null removes the end. A new password or inactive ends its open sessions. Refused with a conflict when the package cannot be changed now (not_configurable). Tell the customer what will change and ask for an explicit yes first.
Arguments
site_idinteger | stringrequiredThe site_id from manitu_webhosting_list - never guess one.
usernamestringrequiredThe user name of the FTP user (ftp<number>) from manitu_webhosting_web_ftpuser_list - never guess one.
quota_mbinteger | nullDisk space in MB the files it owns may take, at most the package's; null or 0: no limit of its own.
statusstringactive, or inactive to switch it off without deleting it. Default when created: active.
expires_atstring | nullWhen the FTP user expires - it works up to the next midnight (Europe/Berlin) at or after the moment given, which the answer shows. Not in the past. From this moment on it can no longer be used (the moment itself is excluded); null: without end.
descriptionstring | nullThe customer's description, for his own overview - e.g. who uses it. Left out: unchanged (set) or none (create); null or empty: none.
passwordstringwrite-onlyThe password of the FTP user - customer panel and REST only, refused over MCP: never ask for a password in a chat. Kept as a hash only, never shown again. Only one of password, password_hash, password_same_as. 12 to 72 printable ASCII characters, no space at the start or the end, not listed as leaked (pwnedpasswords.com).
password_hashstringwrite-onlyThe password as a hash made by the customer - instead of password. A hash can be attacked offline: only for a strong password. Taken: bcrypt ("$2b$" or "$2y$", cost 10 or more).
password_same_asstringThe user name of the FTP user (ftp<number>) from manitu_webhosting_web_ftpuser_list - never guess one.
home_dirstringThe directory it starts in and cannot leave, relative to the package - "/" for the whole package, e.g. "/web/shop". It must exist. Default when created: "/".
Result structuredContent, checked against the schema
usernamestringrequiredThe user name to log in with (ftp<number>) - what the other FTP user tools take.
descriptionstring | nullrequiredWhat the customer wrote about it (his description), null if nothing - not its name or user name.
statusstringrequiredactive, or inactive (switched off by the customer, kept for later).
is_usable_nowbooleanrequiredIt can log in right now: active and not expired.
expires_atstring | nullrequiredWhen the FTP user expires. From this moment on it can no longer be used (the moment itself is excluded); null: without end.
home_dirstring | nullrequiredThe directory it starts in and cannot leave, relative to the package (/ = the whole package).
quota_mbinteger | nullrequiredDisk space in MB the files it owns may take; null: no limit of its own (the package's applies).
password_change_recommendedbooleanrequiredThe password is kept in an outdated form - the customer should set a new one.
created_atstring | nullrequiredWhen it was created.
last_login_atstring | nullrequiredIts last login, null if never.
connectionobjectrequiredconnection.hoststring | nullrequiredThe host to connect to - the web server of the package.
connection.usernamestringrequiredThe user name to log in with.
connection.method_listarray of objectrequiredThe ways to connect, the one to prefer first. SFTP is on port 23, NOT 22; implicit FTPS is not offered; plain FTP (unencrypted) only if nothing else works.
connection.method_list[].protocolstringrequiredsftp (SSH file transfer), ftps_explicit (FTP with explicit TLS, AUTH TLS), ftp (unencrypted).
connection.method_list[].portintegerrequiredconnection.method_list[].is_encryptedbooleanrequiredconnection.method_list[].is_recommendedbooleanrequiredconnection.web_ftp_urlstringrequiredFTP in the browser, with the same user name and password.
Authentication
One of X-API-Key, Authorization: Bearer … - never more than one in a request. More
Request body JSON; unknown fields are refused
site_idinteger | stringrequiredThe site_id from manitu_webhosting_list - never guess one.
usernamestringrequiredThe user name of the FTP user (ftp<number>) from manitu_webhosting_web_ftpuser_list - never guess one.
quota_mbinteger | nullDisk space in MB the files it owns may take, at most the package's; null or 0: no limit of its own.
statusstringactive, or inactive to switch it off without deleting it. Default when created: active.
expires_atstring | nullWhen the FTP user expires - it works up to the next midnight (Europe/Berlin) at or after the moment given, which the answer shows. Not in the past. From this moment on it can no longer be used (the moment itself is excluded); null: without end.
descriptionstring | nullThe customer's description, for his own overview - e.g. who uses it. Left out: unchanged (set) or none (create); null or empty: none.
passwordstringwrite-onlyThe password of the FTP user - customer panel and REST only, refused over MCP: never ask for a password in a chat. Kept as a hash only, never shown again. Only one of password, password_hash, password_same_as. 12 to 72 printable ASCII characters, no space at the start or the end, not listed as leaked (pwnedpasswords.com).
password_hashstringwrite-onlyThe password as a hash made by the customer - instead of password. A hash can be attacked offline: only for a strong password. Taken: bcrypt ("$2b$" or "$2y$", cost 10 or more).
password_same_asstringThe user name of the FTP user (ftp<number>) from manitu_webhosting_web_ftpuser_list - never guess one.
home_dirstringThe directory it starts in and cannot leave, relative to the package - "/" for the whole package, e.g. "/web/shop". It must exist. Default when created: "/".
Response in data; the rest of the body as on every call
usernamestringrequiredThe user name to log in with (ftp<number>) - what the other FTP user tools take.
descriptionstring | nullrequiredWhat the customer wrote about it (his description), null if nothing - not its name or user name.
statusstringrequiredactive, or inactive (switched off by the customer, kept for later).
is_usable_nowbooleanrequiredIt can log in right now: active and not expired.
expires_atstring | nullrequiredWhen the FTP user expires. From this moment on it can no longer be used (the moment itself is excluded); null: without end.
home_dirstring | nullrequiredThe directory it starts in and cannot leave, relative to the package (/ = the whole package).
quota_mbinteger | nullrequiredDisk space in MB the files it owns may take; null: no limit of its own (the package's applies).
password_change_recommendedbooleanrequiredThe password is kept in an outdated form - the customer should set a new one.
created_atstring | nullrequiredWhen it was created.
last_login_atstring | nullrequiredIts last login, null if never.
connectionobjectrequiredconnection.hoststring | nullrequiredThe host to connect to - the web server of the package.
connection.usernamestringrequiredThe user name to log in with.
connection.method_listarray of objectrequiredThe ways to connect, the one to prefer first. SFTP is on port 23, NOT 22; implicit FTPS is not offered; plain FTP (unencrypted) only if nothing else works.
connection.method_list[].protocolstringrequiredsftp (SSH file transfer), ftps_explicit (FTP with explicit TLS, AUTH TLS), ftp (unencrypted).
connection.method_list[].portintegerrequiredconnection.method_list[].is_encryptedbooleanrequiredconnection.method_list[].is_recommendedbooleanrequiredconnection.web_ftp_urlstringrequiredFTP in the browser, with the same user name and password.
Statuses
200Success.400The request does not match the declared input schema.401No credential was presented, or it was not recognised.403The credential is not permitted to use this operation.500The server failed. Nothing about the request was wrong. Whether a change took effect is not known - check before trying it again.503The channel this operation forwards through is unavailable.