letsencrypt via api?

Discussion in 'General' started by nhybgtvfr, Nov 30, 2021.

  1. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    is it possible to set the letsencrypt status of a website via the api?

    i've looked through the example files in the 3.2.7 tarball, and there's no mention of letsencrypt as part of the params in sites_web_domain_add.php or sites_web_domain_update.php.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, that should be possible. Basically, you can use almost any column of a database table in dbispconfig in the $params array in the matching API function, except for the primary ID of the table and except the sys_* columns. The table to look at for the websites is web_domain.
     
  3. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    ok, thanks.
    just to make it clear, i'm looking at the sites_web_domain_add.php file at the moment, with all the params in there.
    but basically, if i send a soap request add a web_domain, i can add any params in there, and leave any out, those left out will just take the db default entry? are there any params that are always required to be sent? apart from 'domain'?

    sorry if it all seems basic, but i'm not even close to being a programmer, i'm just looking at the blesta ispconfig module, there's definitely stuff missing out, there's nothing in there to add anything to the domains table, or create any maildomain, mailbox etc, so i'm hoping i can work it all out from what is in the module, and what's in the ispconfig example docs. but i'm basically starting from knowing nothing...
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    That's not so easy to say as leaving out parameters might cause issues. In general, when you use an example from API docs, it's best to keep it as it is and just add missing parameters, not removing any. The API docs are not up to date, so some parameters are missing.
     

Share This Page