Output Push JSON to external website

2984
4
03-20-2014 07:28 AM
Highlighted
New Contributor III
Is there any way to manipulate the JSON or format of data before you push it to a external website? Or control which fields? Or will I have to do a Field reducer or enricher and put it into another service before i send it to the output?
Reply
0 Kudos
4 Replies
Highlighted
Esri Regular Contributor
Hello Morgan -

I'm not sure I understand when you say "and put it into another service before i send it to the output" ...

You should be able to include as many processors -- Field Reducer, Field Calculator, Field Enricher, etc. -- in-line to manage an event's fields, calculate new (or update existing) fields, and enrich events with data prior to sending then to an Output. There's only one GeoEvent Service in play; you shouldn't need another service to do what you are trying to do.

Keep in mind that an Input receives event data as a byte-stream and is responsible for constructing a GeoEvent. The GeoEvent is the object being processed by the GeoEvent Service. If, for example, you do not want a recipient to see certain fields in the JSON they receive, you need to use either a Field Reducer to remove those fields from the GeoEvent or a Field Mapper to map the GeoEvent to a target output schema.

The GeoEvent Service is not going to "manipulate the JSON or format of data". The Output will receive a processed GeoEvent and deconstructing it to build a JSON representation before sending the event data as JSON to the external website.

- RJ
Reply
0 Kudos
Highlighted
New Contributor II

Hi,

What about building JSON output in a way that it contains nested attributes? I need to produce output which 'push JSON to an External Website' and the group structure of JSON is required. I tried to build a new definition and use Field Mapper to map non-group fields into group fields but then GeoEvent Service stopped counting outputs. I found similar issue but there was no solution (https://community.esri.com/thread/183832-mapping-non-group-fields-into-group-fields-using-field-mapp... ). Is there any way to achieve it?

Best, Aleksandra

Reply
0 Kudos
Highlighted
New Contributor III
It will post the data in JSON correct? Can I use any of the fields in as a parameter on the URL, and put them in the output?

For example,

http://someurl.com/myjsonreceiver.php?

Is it possible to do something like that?

x=&y&myid=[OBJECTID]
Reply
0 Kudos
Highlighted
Esri Regular Contributor

If you are using the Push JSON to an external website outbound connector, yes, the connector's adapter will create a JSON representation of the GeoEvent it receives.

At the 10.3.x and 10.4.x releases, the Push JSON to an external website outbound connector does not support the inclusion of query parameters in the URL. Beginning with the 10.5 release you can include query parameters in the outbound connector's URL. Variable substitution will provide value(s) for the query parameters based on the event record received by the outbound connector. Please refer to the following blog: Enhancements to the GeoEvent Server's outbound HTTP transport

- RJ

Reply
0 Kudos