Left: | ||
Right: |
LEFT | RIGHT |
---|---|
1 # Scripts and web handlers for reports | 1 # Scripts and web handlers for reports |
2 | 2 |
3 ## resolveReport | 3 ## resolveReport |
4 | 4 |
5 This handler is mounted under `/resolveReport` and should be called as follows: | 5 This handler is mounted under `/resolveReport` and should be called as follows: |
6 | 6 |
7 http://<hostname>/<prefix>/resolveReport?<encrypted-report-id> | 7 http://<hostname>/<prefix>/resolveReport?<encrypted-report-id> |
8 | 8 |
9 If the report id is successfully decrypted, a `302 Found` response will be | 9 If the report id is successfully decrypted, a `302 Found` response will be |
10 returned redirectring to the url of the report. If the encrypted report id | 10 returned redirectring to the url of the report. If the encrypted report id |
11 is in the wrong format or encryption fails, a `404 Not Found` response will be | 11 is in the wrong format or encryption fails, a `404 Not Found` response will be |
12 returned. | 12 returned. |
13 | 13 |
14 ### Configuration | 14 ### Configuration |
15 | 15 |
16 The handler is configured via sitescripts config. In order to activate this | 16 The handler is configured via sitescripts config. In order to activate this |
17 handler, add the following line to multiplexer config: | 17 handler, add the following line to multiplexer config: |
18 | 18 |
19 [multiplexer] | 19 [multiplexer] |
20 sitescripts.reports.web.resolveReport = | 20 sitescripts.reports.web.resolveReport = |
21 | 21 |
22 Its own configuration is in the section `reports_anonymization`: | 22 Its own configuration is in the section `reports_anonymization`: |
23 | 23 |
24 [reports_anonymization] | 24 [reports_anonymization] |
25 encryption_key = <base64-encrypted-key> | 25 encryption_key = <base64-encrypted-key> |
26 redirect_url = https://target.host.com/reports/{report_id} | 26 redirect_url = https://target.host.com/reports/{report_id} |
27 | 27 |
28 The redirect URL could be any string. `{report_id}` will be replaced by | 28 The redirect URL could be any string. `{report_id}` will be replaced by |
29 decrypted id of the report. | 29 the decrypted id of the report. |
mathias
2017/10/24 14:53:44
There's a `the` missing between `by` and `decrypte
Vasily Kuznetsov
2017/10/24 15:36:57
Why do you think so? I don't mean to disagree, jus
mathias
2017/10/24 16:08:18
I cannot cite (read: am too lazy to dig up) some s
| |
LEFT | RIGHT |