api

  1. K

    Official Python SDK

    Is there an official python sdk for the api somewhere?
  2. C

    Updating WebDAV SSL Certificate via API

    Hello, and thanks in advance for any help. I have LetsEncrypt certificates for the web UI working great, thanks to danb35's script. Recently, the LetsEncrypt certificate renewal fired, and it got automatically applied to the web GUI just like it should. What I found out recently once the...
  3. vermaden

    How to Disable FreeNAS API

    Hi, FreeNAS has builtin API - http://api.freenas.org/ - described here. How to disable it entirely? Regards, vermaden
  4. PetrZ

    API Auth

    Hi. There is "Currently only the user of ID 0 (root) is allowed to access the API." in API documentation. Is there any chance it will be changed (implemented) in future releases? That really limits some serious usage. E.g. you want to give permit some script / person to add users or certificates...
  5. eivl

    I'm trying to restart a jail using the v2 websocket api

    So in case, this is an XY Problem, I will tell you first what I am trying to do. I would like to do some jail management from a private discord bot. The first iteration of this ran the bot directly on the FreeNAS machine and using subprocess call to run the `iocage restart jail` command, but it...
  6. P

    VM API - stop/start

    Hi I'm having trouble starting and stopping VMs using the 1.0 and 2.0 API. On 1.0 API, I cant find documentation for the "vm" endpoint. I can GET /api/v1.0/vm/vm, which is what the Angular interface uses to get status etc. on machines, but I can't figure out how to stop/start machines. The...
  7. M

    API spits out "Endpoint not found"

    Does anyone use FreeNAS API? The installed version is FreeNAS 11.0-U4 (11-STABLE) http://192.168.0.150/api/v1.0/sharing/cifs <-- this one works. http://192.168.0.150/api/v1.0/storage/dataset <-- this one spits out "Endpoint not found" I'm trying to get a list of datasets. Am I doing something...
  8. R

    Creating users through the API, I can't get it to accept the "bsdusr_group" argument

    Here's the shell line I'm using to try to use the API to create a user account: curl -X POST -u root:[password was here] -H 'Content-Type: application/json' -d '{ "bsdusr_password": "TestPassword", "bsdusr_creategroup": false, "bsdusr_username": "testUser", "bsdusr_full_name": "Testy...
  9. M

    API: Change name of zvol

    Hi all, I have tried without luck to change the name of a zvol through the API but no luck so far. Request: https://foo.bar.tld/api/v1.0/storage/volume/(name of pool)/zvols/zvol Body: { "name": "myzvol" } Response: { "name": "zvol", "volsize": 536870912 } Is this a bug or a missing feature...
  10. M

    api question

    Hi all, I am trying to work with the api using documentation from http://api.freenas.org/resources/storage.html Trying to create a zvol this way: Request POST https://freenas/api/v1.0/storage/volume/tank/zvols/ HTTP/1.1 Content-Type: application/json { "name": "test2", "refer": "10M"...
  11. G

    Unable to create volume using Storage API

    Hello, I tried to create a volume using the storage API but I either get a bad request(400) or the FreeNAS OS malfunctions and I need to reboot it. I am using the following API: { "volume_name": "tank", "layout": [ { "vdevtype": "stripe", "disks": ["ada1", "ada2"]...
  12. Cosmo_Kramer

    How to replace the SSL certificates via the API or SSH

    Hello, I'm working on some automation with Ansible to replace my FreeNAS web GUI certificate with certificates from Let's Encrypt. Looking at the API documentation (http://api.freenas.org/resources/system.html#ssl), I see that you can get a new certificate generated from the API, but I don't...
Top