• Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
  • Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

API Auth and Specs

Scheduled Pinned Locked Moved
General
3
4
486
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J
    joseheitor
    last edited by Aug 16, 2023, 2:44 PM

    Hi,

    I have followed the curl example in the docs for all three types of authentication (Basic, fog-api-token and fog-user-token) against the basic info endpoint, but I am either getting a 401 (Unauthorized) or 403 (Forbidden).

    Is there full API documentation online? Amongst other things, I would like to add/update host entries via the API, but require detailed spec…

    Thanks,
    Jose

    T 1 Reply Last reply Aug 16, 2023, 4:57 PM Reply Quote 0
    • T
      Tom Elliott @joseheitor
      last edited by Aug 16, 2023, 4:57 PM

      @joseheitor https://news.fogproject.org/simplified-api-documentation/

      Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

      Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

      Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

      J 1 Reply Last reply Aug 17, 2023, 10:14 AM Reply Quote 0
      • J
        joseheitor @Tom Elliott
        last edited by Aug 17, 2023, 10:14 AM

        @Tom-Elliott many thanks.

        I am now able to authenticate and access the APIs. The original docs were not clear about the fact that one needs to submit BOTH 'fog-api-token AND ‘fog-user-token’ headers.

        Will experiment and try to figure out the required content of the body messages for the POST/PUT operations that I need to work with and will reach out to you if I get stuck with a particular call.

        1 Reply Last reply Reply Quote 0
        • J
          Jaydennolan
          last edited by Aug 17, 2023, 10:32 AM

          Thanks for the information.

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          1 / 1
          • First post
            1/4
            Last post

          172

          Online

          12.0k

          Users

          17.3k

          Topics

          155.2k

          Posts
          Copyright © 2012-2024 FOG Project