{"info":{"_postman_id":"4764e4f9-d539-42bf-88cb-84c02c64bd68","name":"Diksha_Reports_Analytics_Job_HawkEye_API's","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"description":"<html><head></head><body></body></html>","owner":"23635349","collectionId":"4764e4f9-d539-42bf-88cb-84c02c64bd68","publishedId":"2s9Y5Qzkep","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2023-08-16T12:43:43.000Z"},"item":[{"name":"SubmitRequest","id":"f0f2a850-7bd0-4147-800d-44a86a87c16c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","value":"application/json"},{"key":"Authorization","value":"Bearer {{analytics_api_key}}"}],"body":{"mode":"raw","raw":"{\n    \"request\": {\n        \"reportId\": \"ml_no_of_surveys_submitted_till_date_sl\",\n        \"config\": {\n            \"streamQuery\": true,\n            \"reportConfig\": {\n                \"id\": \"ml_no_of_surveys_submitted_till_date_sl\",\n                \"mergeConfig\": {\n                    \"postContainer\": \"$postContainer\",\n                    \"container\": \"$container\",\n                    \"basePath\": \"/mount/data/analytics/tmp\",\n                    \"reportPath\": \"ml_no_of_surveys_submitted_till_date_sl.csv\",\n                    \"rollup\": 0\n                },\n                \"labels\": {\n                    \"SUM(unique_users)\": \"total_content_plays_on_portal\",\n                    \"legend\": \"No of surveys submitted till date\",\n                    \"total_content_plays_on_portal\": \"No of surveys submitted till date\",\n                    \"organisation_name\": \"Organisation\",\n                    \"parent_channel\": \"parent_channel\",\n                    \"district_name\": \"District Name\",\n                    \"block_name\": \"Block name\",\n                    \"program_name\": \"Program Name\",\n                    \"state_name\": \"State Name\"\n                },\n                \"dateRange\": {\n                    \"staticInterval\": \"LastDay\",\n                    \"granularity\": \"all\",\n                    \"intervalSlider\": 0\n                },\n                \"metrics\": [\n                    {\n                        \"metric\": \"total_content_plays_on_portal\",\n                        \"label\": \"total_content_plays_on_portal\",\n                        \"druidQuery\": {\n                            \"dataSource\": \"ml-surveydistinctCount-status\",\n                            \"limitSpec\": {\n                                \"type\": \"default\",\n                                \"limit\": 50000,\n                                \"columns\": [\n                                    {\n                                        \"dimension\": \"SUM(unique_users)\",\n                                        \"direction\": \"descending\"\n                                    }\n                                ]\n                            },\n                            \"filters\": [\n                                {\n                                    \"dimension\": \"state_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"dimension\": \"program_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"dimension\": \"district_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"dimension\": \"block_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"type\": \"equals\",\n                                    \"dimension\": \"submission_status\",\n                                    \"value\": \"completed\"\n                                },\n                                {\n                                    \"type\": \"equals\",\n                                    \"dimension\": \"private_program\",\n                                    \"value\": \"false\"\n                                },\n                                {\n                                    \"type\": \"regex\",\n                                    \"dimension\": \"program_name\",\n                                    \"value\": \"^((?!(?i)(test)).)*$\"\n                                }\n                            ],\n                            \"granularity\": \"all\",\n                            \"dimensions\": [\n                                {\n                                    \"fieldName\": \"program_name\",\n                                    \"aliasName\": \"Program Name\"\n                                },\n                                {\n                                    \"fieldName\": \"state_name\",\n                                    \"aliasName\": \"State Name\"\n                                },\n                                {\n                                    \"fieldName\": \"parent_channel\",\n                                    \"aliasName\": \"parent_channel\"\n                                },\n                                {\n                                    \"fieldName\": \"district_name\",\n                                    \"aliasName\": \"District Name\"\n                                },\n                                {\n                                    \"fieldName\": \"block_name\",\n                                    \"aliasName\": \"Block name\"\n                                },\n                                {\n                                    \"fieldName\": \"organisation_name\",\n                                    \"aliasName\": \"Organisation\"\n                                }\n                            ],\n                            \"aggregations\": [\n                                {\n                                    \"fieldName\": \"unique_users\",\n                                    \"type\": \"longSum\",\n                                    \"name\": \"total_content_plays_on_portal\"\n                                }\n                            ],\n                            \"queryType\": \"groupBy\"\n                        }\n                    }\n                ],\n                \"output\": [\n                    {\n                        \"type\": \"csv\",\n                        \"metrics\": [\n                            \"total_content_plays_on_portal\"\n                        ],\n                        \"dims\": [\n                            \"date\"\n                        ],\n                        \"fileParameters\": [\n                            \"id\",\n                            \"dims\"\n                        ]\n                    }\n                ],\n                \"queryType\": \"groupBy\"\n            },\n            \"container\": \"$container\",\n            \"store\": \"$store\",\n            \"key\": \"hawk-eye/\"\n        },\n        \"createdBy\": \"$createdBy\",\n        \"description\": \"Big Number will give an overall count on number of surveys in submitted status as of today\",\n        \"reportSchedule\": \"DAILY\"\n    }\n}"},"url":"{{host}}/api/data/v1/report/jobs/submit","urlObject":{"path":["api","data","v1","report","jobs","submit"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"f0f2a850-7bd0-4147-800d-44a86a87c16c"},{"name":"GetReportRequest","id":"276064fe-b16d-453b-986b-89aa691a43fb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","value":"application/json"},{"key":"Authorization","value":"Bearer {{analytics_api_key}}"}],"url":"{{host}}/api/data/v1/report/jobs/{Report_ID}","urlObject":{"path":["api","data","v1","report","jobs","{Report_ID}"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"276064fe-b16d-453b-986b-89aa691a43fb"},{"name":"GetReportList","id":"6e630959-f863-420c-bd67-fbac39dc9659","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","value":"application/json"},{"key":"Authorization","value":"Bearer {{analytics_api_key}}"}],"url":"{{host}}/data/v1/report/jobs","urlObject":{"path":["data","v1","report","jobs"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"6e630959-f863-420c-bd67-fbac39dc9659"},{"name":"DeactivateReportAPI","id":"31224e41-652e-4b45-95d0-aed4ac4e2ab2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"Bearer {{analytics_api_key}}"}],"url":"{{host}}/report/jobs/deactivate/{Report_ID}","urlObject":{"path":["report","jobs","deactivate","{Report_ID}"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"31224e41-652e-4b45-95d0-aed4ac4e2ab2"},{"name":"UpdateAPI","id":"fb01ed75-512a-4701-9914-76911f062da0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","value":"application/json"},{"key":"Authorization","value":"Bearer  {{analytics_api_key}}"}],"body":{"mode":"raw","raw":"{\n    \"request\": {\n        \"reportId\": \"ml_no_of_surveys_submitted_till_date_sl\",\n        \"config\": {\n            \"streamQuery\": true,\n            \"reportConfig\": {\n                \"id\": \"ml_no_of_surveys_submitted_till_date_sl\",\n                \"mergeConfig\": {\n                    \"postContainer\": \"$postContainer\",\n                    \"container\": \"$container\",\n                    \"basePath\": \"/mount/data/analytics/tmp\",\n                    \"reportPath\": \"ml_no_of_surveys_submitted_till_date_sl.csv\",\n                    \"rollup\": 0\n                },\n                \"labels\": {\n                    \"SUM(unique_users)\": \"total_content_plays_on_portal\",\n                    \"legend\": \"No of surveys submitted till date\",\n                    \"total_content_plays_on_portal\": \"No of surveys submitted till date\",\n                    \"organisation_name\": \"Organisation\",\n                    \"parent_channel\": \"parent_channel\",\n                    \"district_name\": \"District Name\",\n                    \"block_name\": \"Block name\",\n                    \"program_name\": \"Program Name\",\n                    \"state_name\": \"State Name\"\n                },\n                \"dateRange\": {\n                    \"staticInterval\": \"LastDay\",\n                    \"granularity\": \"all\",\n                    \"intervalSlider\": 0\n                },\n                \"metrics\": [\n                    {\n                        \"metric\": \"total_content_plays_on_portal\",\n                        \"label\": \"total_content_plays_on_portal\",\n                        \"druidQuery\": {\n                            \"dataSource\": \"ml-surveydistinctCount-status\",\n                            \"limitSpec\": {\n                                \"type\": \"default\",\n                                \"limit\": 50000,\n                                \"columns\": [\n                                    {\n                                        \"dimension\": \"SUM(unique_users)\",\n                                        \"direction\": \"descending\"\n                                    }\n                                ]\n                            },\n                            \"filters\": [\n                                {\n                                    \"dimension\": \"state_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"dimension\": \"program_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"dimension\": \"district_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                {\n                                    \"dimension\": \"block_name\",\n                                    \"type\": \"isnotnull\"\n                                },\n                                \n                                {\n                                    \"type\": \"equals\",\n                                    \"dimension\": \"private_program\",\n                                    \"value\": \"false\"\n                                },\n                                {\n                                    \"type\": \"regex\",\n                                    \"dimension\": \"program_name\",\n                                    \"value\": \"^((?!(?i)(test)).)*$\"\n                                }\n                            ],\n                            \"granularity\": \"all\",\n                            \"dimensions\": [\n                                {\n                                    \"fieldName\": \"program_name\",\n                                    \"aliasName\": \"Program Name\"\n                                },\n                                {\n                                    \"fieldName\": \"state_name\",\n                                    \"aliasName\": \"State Name\"\n                                },\n                                {\n                                    \"fieldName\": \"parent_channel\",\n                                    \"aliasName\": \"parent_channel\"\n                                },\n                                {\n                                    \"fieldName\": \"district_name\",\n                                    \"aliasName\": \"District Name\"\n                                },\n                                {\n                                    \"fieldName\": \"block_name\",\n                                    \"aliasName\": \"Block name\"\n                                },\n                                {\n                                    \"fieldName\": \"organisation_name\",\n                                    \"aliasName\": \"Organisation\"\n                                }\n                            ],\n                            \"aggregations\": [\n                                {\n                                    \"fieldName\": \"unique_users\",\n                                    \"type\": \"longSum\",\n                                    \"name\": \"total_content_plays_on_portal\"\n                                }\n                            ],\n                            \"queryType\": \"groupBy\"\n                        }\n                    }\n                ],\n                \"output\": [\n                    {\n                        \"type\": \"csv\",\n                        \"metrics\": [\n                            \"total_content_plays_on_portal\"\n                        ],\n                        \"dims\": [\n                            \"date\"\n                        ],\n                        \"fileParameters\": [\n                            \"id\",\n                            \"dims\"\n                        ]\n                    }\n                ],\n                \"queryType\": \"groupBy\"\n            },\n            \"container\": \"$container\",\n            \"store\": \"$store\",\n            \"key\": \"hawk-eye/\"\n        },\n        \"createdBy\": \"$createdBy\",\n        \"description\": \"Big Number will give an overall count on number of surveys in submitted status as of today\",\n        \"reportSchedule\": \"DAILY\"\n    }\n}"},"url":"{{host}}/api/data/v1/report/jobs/{Report_ID}","urlObject":{"path":["api","data","v1","report","jobs","{Report_ID}"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"fb01ed75-512a-4701-9914-76911f062da0"}]}