Forum Discussion

khill's avatar
khill
Mentor
8 years ago

REST API v2 - Rank change date?

Hi everyone,

 

We are scoping some ideas around Rank reporting to answer questions like "How long do users generally stay in the Newbie rank?", "Are users moving through certain parts of our ranking ladder too quickly/slowly?", etc.  To do so, I am thinking of using REST API v2 data and am looking for some kind of field like Rank Date, Last Rank Change, something like that which can associate to the user.  I can't find anything the documentation, does anyone know if this type of field exists?

 

Thanks!

Kate

  • khill- Following details are associated with the user for a rank.

     

    "rank" : {
            "type" : "rank",
            "id" : "27",
            "name" : "Rank Title",
            "position" : 21,
            "bold" : false,
            "color" : "000000",
            "roles_granted" : {
              "query" : "SELECT * FROM roles WHERE ranks_granting.id = '27'"
            },
            "roles_removed" : {
              "query" : "SELECT * FROM roles WHERE ranks_removing.id = '27'"
            },
            "formula_enabled" : false,
            "formula" : "",
            "simple_criteria" : {
              "type" : "simple_rank_criteria",
              "role" : { },
              "user" : { },
              "number_of_posts" : 5,
              "number_of_page_views" : 0,
              "number_of_signins" : 0,
              "minutes_online" : 0,
              "minutes_since_registering" : 5760,
              "simple_formula" : "(posts - deleted_posts >= 5) && (registrationAge >= 5760)"
            }
          }

    You can get above information with following query.

     

    select rank from users

    There is no field like Rank Date. However, you can get the ranking formula and some other details.

     

    https://community.lithium.com/t5/Developer-Documentation/bd-p/dev-doc-portal?section=commv2&collection=users#fields-rank

     

2 Replies

  • khill- Following details are associated with the user for a rank.

     

    "rank" : {
            "type" : "rank",
            "id" : "27",
            "name" : "Rank Title",
            "position" : 21,
            "bold" : false,
            "color" : "000000",
            "roles_granted" : {
              "query" : "SELECT * FROM roles WHERE ranks_granting.id = '27'"
            },
            "roles_removed" : {
              "query" : "SELECT * FROM roles WHERE ranks_removing.id = '27'"
            },
            "formula_enabled" : false,
            "formula" : "",
            "simple_criteria" : {
              "type" : "simple_rank_criteria",
              "role" : { },
              "user" : { },
              "number_of_posts" : 5,
              "number_of_page_views" : 0,
              "number_of_signins" : 0,
              "minutes_online" : 0,
              "minutes_since_registering" : 5760,
              "simple_formula" : "(posts - deleted_posts >= 5) && (registrationAge >= 5760)"
            }
          }

    You can get above information with following query.

     

    select rank from users

    There is no field like Rank Date. However, you can get the ranking formula and some other details.

     

    https://community.lithium.com/t5/Developer-Documentation/bd-p/dev-doc-portal?section=commv2&collection=users#fields-rank

     

  • khill's avatar
    khill
    Mentor
    8 years ago

    Thanks Tariq - I was hoping I was just missing a field that would get me the time based info we are looking for, but it looks like it just isn't available through this API.  Bummer!

     

    I very much appreciate the help though!