UniFi-API-client

A PHP API client class to interact with Ubiquiti's UniFi Controller API

MIT License

Downloads
238.7K
Stars
1.1K
Committers
11

Bot releases are hidden (Show)

UniFi-API-client - API client class v1.1.94 Latest Release

Published by malle-pietje 2 months ago

  • minor fix based on Scrutinizer feedback
  • re-added update_admin() method to the class; for some reason, the merge of #228 contributed by @Jacobtims was unsuccessful
UniFi-API-client - API client class v1.1.93

Published by malle-pietje 2 months ago

  • added the migrate_device() method to migrate one or more devices from one controller to another
  • added the cancel_migrate_device() method to cancel the migration for one or more devices
  • added the upgrade_all_devices() method to upgrade all devices of a selected type to the latest firmware version
  • changed the force_provision() method to allow for multiple MAC addresses to be passed as a parameter
  • minor changes to a number of doc-blocks
  • general changes for improved consistency and readability
UniFi-API-client - API client class v1.1.92

Published by malle-pietje 2 months ago

  • further reformatting of notes in the doc blocks
  • reformatted single-line comments
  • merged #232, added days parameter to generate_backup() method, contributed by @Jacobtims
UniFi-API-client - API client class v1.1.91

Published by malle-pietje 3 months ago

  • added `delete_admin()`` method, contributed by @Jacobtims
  • merged PR #228 to add update_admin(), contributed by @Jacobtims
  • reformatting of notes in the doc blocks
UniFi-API-client - API client class v1.1.90

Published by malle-pietje 8 months ago

  • remove existing x-csrf-token headers before adding a new one, apparently UniFi OS does not like multiple x-csrf-tokens in the same request
UniFi-API-client - API client class v1.1.89

Published by malle-pietje 8 months ago

  • added create_tag(), set_tagged_devices(), get_tag(), and delete_tag() methods to manage tags, contributed by @brenard, #205
UniFi-API-client - API client class v1.1.88

Published by malle-pietje 8 months ago

  • added list_fingerprint_devices() method to list fingerprints for clients devices, contributed by @dream-rhythm, #213
  • minor code clean up
UniFi-API-client - API client class v1.1.87

Published by malle-pietje 8 months ago

  • further code clean up and refactoring to pass more phpstan tests
UniFi-API-client -

Published by malle-pietje 8 months ago

API client class v1.1.86

  • fixes issue with curl_init() returning CurlHandle class objects instead of curl handlers with PHP 8 and higher
UniFi-API-client -

Published by malle-pietje 8 months ago

API client class v1.1.85

  • removed unnecessary type casting in several methods
  • fixed return type hinting in several methods where return type needed to be array|bool instead of just array
  • relaxed parameter type hinting in the constructor to allow for null values for several parameters that have sensible defaults, reported by @pbksol
  • using phpstan, the class passes level 5 checks
UniFi-API-client - API client class v1.1.84

Published by malle-pietje 8 months ago

  • PHP 7.4 is now the minimum required version
  • updated the code for 7.4. specific features such as parameter type hinting, return types, etc.
  • added the ability to the constructor to change the key that is used to store the unificookie in the session,
    ($_SESSION['unificookie'] is used by default), this is useful when running multiple applications on the same server
UniFi-API-client - API client class v1.1.83

Published by malle-pietje 10 months ago

  • added a accept: application/json header to the login requests
  • re-added support for cookies when working with a UniFi OS-based controller
UniFi-API-client - API client class v1.1.82

Published by malle-pietje 10 months ago

  • allow filtering by multiple MAC addresses in list_devices(), contributed by @sgrodzicki, #189
UniFi-API-client - API client class v1.1.81

Published by malle-pietje 10 months ago

  • hotfix to address cookie issues in UniFi OS 3.2.7, reported by @tflatebo
  • fixed minor typos
  • minor code reformatting of the examples
  • starting with this release, cookies are no longer supported when connecting to a UniFi OS-based controller
  • added set_vlan_to_port.php example, contributed by @SamuelSchnelly, #203
  • allow additional parameters in create_wlan()'s payload, contributed by @sgrodzicki, #191
UniFi-API-client - API client class v1.1.80

Published by malle-pietje over 1 year ago

  • added generate_backup_site() method, contributed by @labo-jad
  • added stat/device-basic endpoint #188, contributed by @sgrodzicki
UniFi-API-client - API client class v1.1.79

Published by malle-pietje over 2 years ago

  • updated README to reflect support for 7.X
  • get_last_error_message() now always returns a string which is empty if no message is available
  • applied PR #151 in slightly different way for consistency with other similar code sections, contributed by @banakito
  • changed default argument values in several methods/functions from null to an empty string
UniFi-API-client - API client class v1.1.78

Published by malle-pietje over 2 years ago

  • fixed create_radius_account() method to make Tunnel Type and Medium optional parameters, reported by @CodeByJacob
UniFi-API-client - API client class v1.1.77

Published by malle-pietje over 2 years ago

  • removed unnecessary CURLOPT_HEADER from the login() method
  • added several more possible attributes for client stats
  • cast VLAN id to string in create_radius_account()
UniFi-API-client - API client class v1.1.76

Published by malle-pietje almost 3 years ago

  • minor changes based on feedback by Scrutinizer
  • removed use of CURLOPT_NOBODY in login() method
  • switched to using cURL's default HTTP version
UniFi-API-client - API client class v1.1.75

Published by malle-pietje almost 3 years ago

  • updated docblocks to be less USG-specific
  • removed content-length header from the logout method, reported by @Olivier6767
  • added notes to reflect successful tests with UDR running the latest Pre-Release version of the UniFi controller (version 6.5.52)
  • added checks in specific cases when using trim() to prevent PHP 8 from throwing an error when the variable is null, submitted by @djchen