Keboola WIKI‎ > ‎Old Articles‎ > ‎Generic Extractor‎ > ‎

RallyDev documentation

Here is a small "guide" for documentation.


Warning: the documentation is only accessible after login with active credentials, that have active subscription (paying user). Also the documentation may change based on purchased services.

Creating extractor
Create generic extractor with configuration like this:

{
  "parameters": {
    "api": {
      "baseUrl": "https://rally1.rallydev.com/slm/webservice/v2.0/",
      "pagination": {
        "method": "offset",
        "limit": 1000,
        "limitParam": "pagesize",
        "offsetParam": "start"
      },
      "name": "rallydev",
      "authentication": {
        "type": "basic"
      },
      "query": {
        "fetch": {
          "attr": "fetch"
        }
      }
    },
    "config": {
      "id": "rallydev",
      "username": "your username here",
      "#password": "your password here",
      "fetch": "true",
      "debug": 1,
      "http": {
        "headers": {
          "Accept": "application/json"
        }
      },
      "jobs": [
        {
          "endpoint": "project",
          "dataType": "projects",
          "dataField": "QueryResult.Results"
        },
        {
          "endpoint": "hierarchicalrequirement",
          "dataType": "hierarchical_requirements",
          "dataField": "QueryResult.Results",
          "children": [
            {
              "endpoint": "hierarchicalrequirement/{ObjectID}/Tasks",
              "dataType": "tasks",
              "dataField": "QueryResult.Results",
              "placeholders": {
                "ObjectID": "_refObjectUUID"
              }
            }
          ]
        },
        {
          "endpoint": "portfolioitem",
          "dataType": "portfolio_items",
          "dataField": "QueryResult.Results"
        }
      ]
    }
  }
}

Plus change credentials (username and password). Please, do not forget to turn off the debug option once you are done with configuring the extractor. Just delete the row with "debug" keyword.

Object hierarchy
This API is divided into a structure of object, each one represents one entity. With endpoints you can access every children of the parent object exactly as you can see relations in the picture (click on any object in the documentation, then scroll all the way to the top).

How to access children? Just look at the object you want to get children for, get his refObjectUUID and use for example this URL to get all children for object of type project: https://rally1.rallydev.com/slm/webservice/v2.0/project/a3919f0c-0b0e-43e9-8636-72388fa8fec7/Children

In the response you will see all the possible children with their URLs you can use as another endpoints in the generic ex configuration.

Object name conventions
There is a slight difference in naming of the objects when you look to Rally through UI and API. Thanks to the source code of some Python SDK, here is a "dictionary" with the connections between original and API objects:

Theme, Initiative, Feature => PortfolioItem (it has subtypes like initiative, feature...)
Story, UserStory, User Story => HierarchicalRequirement
Tasks => HierarchicalRequirement/{ObjectID}/Tasks (children element)

Object details
When you download a list of objects (URL with no specified ID), you will get only the most necessary info about the project. To download the object with all details available, the request needs to have query parameter "fetch" with value "true". 

Authentication
This API uses standard Basic Auth, so all you need is the credentials as for your login to the system. Generic ex is already configured to use this.

Paging
API uses pair of limit and offset variables to page through the results. Right now it is set to 1000 results per page, because it can handle it. Also, the response are pretty fast, so there is right now no need for incremental load from the system as it will download all the data in appx 1m15s.

If you have any questions, let me know on vokurka@keboola.com, I would be happy to help! :)
Comments