Despite the COVID-19 outbreak, our team continues operating at full speed. We are always here to support and answer all your questions.

Feel free to reach out by filling this quick form.

Fill the form
Get Free Trial

[Clarification] Custom Data Source API: Type of the keys object in /select response

Answered
eze@wejugo.com asked on May 27, 2020

I’m wondering whether this is a typo in the documentation for the /select call. The keys object is described as having string values, but as keys is meant to represent a tuple of members, and member’s values can be strings or numbers (in the case that dimensions are of type number or date) would that then not actually make keys a { (uniqueName): string | number } object?
Ref: https://www.flexmonster.com/api/select-request-for-pivot-table/
The examples in that page point to one where there is a numerical dimension listed in the by object, which would have resulted in number-valued members in the keys, but the example is just listed as having the same format as the previous one. 

{
    "aggs"[]: {
        "values": {
            (uniqueName): {
                (func): number
            }
        },
        "keys": {
            (uniqueName): string
        }
    },
    "page": number,
    "pageTotal": number
}

1 answer

Public
Vera Didenko Flexmonster May 28, 2020

Hello, 
 
Thank you for writing to us. 
 
We would like to confirm that this is a typo in our documentation. 
Indeed, the member’s values can be strings or numbers, making the keys property closer to a { (uniqueName): string | number } object. 
Our team will update the documentation shortly. 
 
If any further questions arise, please feel free to reach out. 
 
Kind regards, 
Vera

Please login or Register to Submit Answer