As mentioned in the above reply, your subscribing service should have an input documentType (reference to publishable doc) with the name same as the fully qualified name of the publishable document. This name can be found by right clicking on the publishable doc and click on Find References. This name is slightly different than the broker doc. e.g. Find Reference will give you “sample:myDoc” whereas the associated broker doc would be “wm::is::sample::myDoc”. So create a input documentReference with the name “sample:myDoc” refering to sample:myDoc.
By doing this your input document is populated automatically once the document is published and subscribed by the trigger.
Now you may declare a local document lets say temp_doc with the same structure as sample:myDoc and in the first step in the service use a map to populate this temp_doc.
Now you have flexibilities to do whatever with the data populated in temp_doc.
Hope this helps!