Cognos Analytics

 View Only
  • 1.  Get User CAMID(searchPath) from REST API

    Posted Mon March 13, 2023 01:05 AM

    Hi, team. Just wondering if we can make a REST api call to get a user's CAMID by defaultName or email, which would be quite convenient to connect back to Planning Analytics. Thanks.

    By the way, in CA 11.1, looks like REST API returns nothing by call members of a folder like this /groups/{id}/members? The id here is the folder ID. 



    ------------------------------
    mvp morgan
    ------------------------------


  • 2.  RE: Get User CAMID(searchPath) from REST API

    Posted Sun March 19, 2023 03:14 AM

    I can query now but looks like there is one mintue timeout setting by default as there are too many members in the group. Does anyone know the timeout setting or possible paginated query via REST? Thanks.



    ------------------------------
    mvp morgan
    ------------------------------



  • 3.  RE: Get User CAMID(searchPath) from REST API

    IBM Champion
    Posted Mon March 20, 2023 08:59 AM

    Try something like this:

    URL: GATEWAY+'/v1/namespaces/'+ NamespaceID+'/search'
    params:

    1. types=account
    2. method=contains
    3. fields=id,userName,surname,givenName,email,searchPath
    4. filter=searchTerm

    this is against the pm2 environment:



    ------------------------------
    Paul Mendelson
    ------------------------------



  • 4.  RE: Get User CAMID(searchPath) from REST API

    Posted Tue March 21, 2023 01:31 AM

    Thanks for that. I have tried similar way to query the all members under a group but unfortunately it didn't return anything I expected. 

    From the https://www.ibm.com/docs/en/cognos-analytics/11.1.0?topic=apis-rest-api

    IBM® Cognos® Analytics includes REST APIs to perform create, read, update, and delete operations on Cognos Analytics data, in compliance with OData Version 4 (http://www.odata.org/documentation).

    It seems to support OData4 but I can't make any query option work. Do you have any example to show how to work on users in a group? Thanks.

    https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html#sec_SystemQueryOptiontop



    ------------------------------
    mvp morgan
    ------------------------------