Improve the pagination and name convention so it can be more consistent across all API endpoints

XMLWordPrintable

    • 2

      At this moment, the parameters and data returned when using the endpoints available in the Organizations REST API don't provide a consistent experience. 

      A few examples: 

      1. Pagination:

      The value stored in the "next" attribute doesn't return a link to the next page when using the endpoint Search for users within an organization. It provides a cursor to the next page, which still works if there is a logic implemented on the code to extract it to be used in the next HTTP request.

          "links": {
              "next": "NTU3MDU4OmE4ZGVkMDljLTVlZmMtNDFmYy04M2RmLTY4OTE5OWQ1OWRiMA=="
          }

      However, the endpoint Get managed accounts in an organization provided the complete link in the "next" attribute. 

          "links": {
              "self": "https://api.atlassian.com/admin/v1/orgs/<ORG_ID>/users"
          }
       

      2. Attribute name convention

      Some attributes have different names depending on the endpoint being used. For example, "Account ID" and "Account Status":

      Endpoint cursor-pagination Account ID Account Status Naming convention
      Get managed accounts in an organization URL account_id account_status snake_case
      Search for users within an organization token accountId accountStatus camelCase

            Assignee:
            Unassigned
            Reporter:
            Renan Andrade (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: