Stand-Alone Angular Viewer for HOMER API 7.7
- This Application requires a Proxy like HEP Auth Proxy to access the HOMER API.
-
open the proxy config from
proxy/config.js
-
configure the proxy settings with your HOMER API parameters and the server you want to Proxy the API as shown:
...
var config = {
// the url of my api
apiUrl: 'http://[Api Host]/api/v3/',
// the url of my api auth
apiSess: 'http://[Api Host]/api/v3/auth',
apiAuthJWT: true, //Activate for Homer7 setup
apiUser: '[api-user]', // api user
apiPass: '[api-pass]', // api password
timeOut: 1800, // seconds
//my server host where I will run the View and the Proxy
proxyHost: '[my Homer-view host]',
// my server Proxy port
proxyPort: 8765
};
module.exports = config;
...
- start proxy: cd proxy; npm install && npm start ( The proxy will start in the Port you specified, so be sure that you have that port available for the Proxy )
-
cd homer-view
-
Run
npm install
to install dependencies. -
Run
npm install -g @angular/cli
to install or update Angular CLI. -
configure your
environment.ts
with the correctapiUrl
...
import { VERSION } from '../VERSION';
export const environment = {
production: false,
environment: VERSION + '(dev)',
/* MY URL with proxy port*/
apiUrl: 'http://my.host:8765'
};
...
-
npm run build
to build the Stand-Alone Angular Viewer. Or just jump to next step for running with the default environment. -
ng serve --host=my.server.host --port=4200
to serve the app replacing the4200
with the port andmy.server.host
with the host you will use for the Homer-view. -
Access the application at
http://my.server.host:4200/
-
Test the Homer-view app with the parameters of a call stored in your server.
http://localhost:4200/?id=16697926&[email protected]&from=1574632800000&to=1577224799000
- If you have errors in the console it should be because now the
?id=
param is needed. And the queries you made before are stored on local storage.
Just clean local storage and refresh the browser.
The Application accepts the following URL parameters defining search settings
Required
id
: id string or arraycallid
: callid string or arrayfrom
: start time in millisecondsto
: stop time in milliseconds
Optional
tabs
: visibile tabs, options- messages
- qos
- flow
- logs
- export
http://localhost:4200/?id=16697926&[email protected]&from=1574632800000&to=1577224799000
This Open-Source project is made possible by actual Humans without corporate sponsors, angels or patreons.
If you use this software in production, please consider supporting its development with contributions or donations