Project

General

Profile

Bug #16891

Wrong URI In Environment API Documentation

Added by Jason Nance over 3 years ago. Updated 9 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
API
Target version:
Difficulty:
easy
Triaged:
Yes
Bugzilla link:
Pull request:
Fixed in Releases:
Found in Releases:

Description

The documentation for the "Environments" API:

http://www.katello.org/docs/3.1/api/apidoc/environments.html

...states that the URI is /api/<foo> when it should say /katello/api/<foo>.

History

#1 Updated by Jason Nance over 3 years ago

Actually I'm not sure what the correct URI is...

GET /api/environments works as documented, but GET /api/environments/:id returns 404.
GET /katello/api/environments returns 404, but GET /katello/api/environments/:id works as documented.

#2 Updated by Eric Helms over 3 years ago

  • Category set to API
  • Legacy Backlogs Release (now unused) set to 188

#3 Updated by Justin Sherrill over 3 years ago

  • Legacy Backlogs Release (now unused) changed from 188 to 114

#4 Updated by Jason Nance about 3 years ago

I can't test whether this issue is still valid after the re-organization of the Katello website as the Katello-specific API docs seem to have disappeared.

Does anyone have a link to the Katello API docs? They used to have their own section but no more...

#5 Updated by John Mitsch 9 months ago

  • Difficulty set to easy

#7 Updated by James Jeffers 9 months ago

Here's an example of the api:

curl -X GET --user admin:changeme -k https://centos7-katello-devel.jjeffers.example.com/katello/api/environments | jq
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   939    0   939    0     0    700      0 --:--:--  0:00:01 --:--:--   701
{
  "total": 1,
  "subtotal": 1,
  "page": 1,
  "per_page": 20,
  "error": null,
  "search": null,
  "sort": {
    "by": "name",
    "order": "asc" 
  },
  "results": [
    {
      "library": true,
      "registry_name_pattern": null,
      "registry_unauthenticated_pull": false,
      "id": 1,
      "name": "Library",
      "label": "Library",
      "description": null,
      "organization_id": 1,
      "organization": {
        "name": "Default Organization",
        "label": "Default_Organization",
        "id": 1
      },
      "created_at": "2019-08-22 16:38:01 UTC",
      "updated_at": "2019-08-22 16:38:01 UTC",
      "prior": null,
      "successor": null,
      "counts": {
        "content_hosts": 0,
        "content_views": 3,
        "packages": 32,
        "puppet_modules": 0,
        "module_streams": 0,
        "errata": {
          "security": 4,
          "bugfix": 0,
          "enhancement": 0,
          "total": 4
        },
        "yum_repositories": 1,
        "docker_repositories": 0,
        "ostree_repositories": 0,
        "products": 1
      },
      "permissions": {
        "create_lifecycle_environments": true,
        "view_lifecycle_environments": true,
        "edit_lifecycle_environments": true,
        "destroy_lifecycle_environments": false,
        "promote_or_remove_content_views_to_environments": true
      }
    }
  ]
}

So the issue appears to work in 3.13.

#8 Updated by James Jeffers 9 months ago

  • Status changed from New to Resolved

Also available in: Atom PDF