March 6, 20242 yr I try to create a new customer via the API. I succeed in creating the customer and a standard domain. What I was not able to find out: - How can I tell the API to generate the default index.html - How can I tell the API to generate the default ftp account - How can I tell the API to send the login data to the customer (send password via mail) - I guess I have to send the hashed Password so how do I hash the password? What I tried is: command: "Customers.add", params: { new_loginname: "acustomer", email: "me@gmail.com", firstname: "Api", name: "Tester", password: "Generalissimss!1!", company: "The Mighty Conpany", adminid: 1, gender: 1, street: "Plamps Drive 5", zipcode: "122345", city: "Somewhere", phone: "", fax: "", customernumber: "", def_language: "de", diskspace: 40960, diskspace_used: 628, mysqls: 4, ftps: 1, subdomains: 0, traffic: 10485760, phpenabled: 1, pop3: 0, imap: 0, perlenabled: 1, dnsenabled: 0, theme: "Froxlor_dark", custom_notes: "", allowed_phpconfigs: [1], logviewenabled: 1, allowed_mysqlserver: [0], },
March 6, 20242 yr 1 minute ago, rhufsky said: How can I tell the API to generate the default index.html Parameter: store_defaultindex (bool) 2 minutes ago, rhufsky said: How can I tell the API to send the login data to the customer (send password via mail) Parameter: sendpassword (bool) 3 minutes ago, rhufsky said: I guess I have to send the hashed Password so how do I hash the password? You pass the plaintext password as froxlor hashes it according to the settings (and it's needed in plaintext to add the default ftp-user etc. internally or to send the password to the customer if the parameter 'sendpassword' is set to true) See: https://docs.froxlor.org/latest/api-guide/commands/customers.html#customers-add
March 6, 20242 yr Author 11 minutes ago, d00p said: Parameter: store_defaultindex (bool) Parameter: sendpassword (bool) You pass the plaintext password as froxlor hashes it according to the settings (and it's needed in plaintext to add the default ftp-user etc. internally or to send the password to the customer if the parameter 'sendpassword' is set to true) See: https://docs.froxlor.org/latest/api-guide/commands/customers.html#customers-add OK thanks
Create an account or sign in to comment