There are two ways to write a functional spec as an integrator:
1) If the customer hired you because they don't know what they are doing and they trust you to be the expert, then you write how you think the system should work.
2) If the customer knows exactly what they want, and just want you do to the work for them, then the trick is to get all the stakeholders in the room long enough to agree/decide/tell you. Also, sometimes figuring out just who the stakeholders are is a trick by itself. It helps to have a first draft of what you think should happen (assuming 75% will be wrong), and then you let them pick it apart and fix everything.