XBee's would be the way to go. Your biggest issue with trying to get that type of range will be RF Power levels.
I'm assuming your needing to have the system using "unlicensed" channels.
With unlicensed channels, the RF power levels will be limited to +10dbm to maybe +24dbm depending
on where you are in the world. So your simple little soldered on piece of wire isn't going to do the job.
Your going to need to consider your antenna system. High gain directional antennas will be needed.
I have set up many point to point systems in the 32-80 Km range with just +24dbm.
I have simplified this as much as possible to help you understand:
Fist thing you need to know is the power output of the RF module yours using. +24dbm is equal to about 0.25 watts.
Second thing you need to know is the receiver sensitivity of the RF module your using. Lets say its -100dbm.
Third thing you need to know is what the "free air space loss" is for the frequency range your using.
868Mhz has about a -91db loss per Km.
So you have a transmitter at +24dbm signal, a receive that needs a min of a -100dbm signal. You have about 115db of
acceptable path fade.
You need to understand the dbm scale. Dbm is an RF measurement scale based on 0 dbm = 1mW.
Every 3dbm increase doubles the level. So in this case if a +24dbm(+0.25w) transmitter increases to +27dbm the output is now
0.5watts.
You can increase the range by using directional gain antennas. Depending on the frequency and size limitations
you can take a signal that would have a radiation pattern of 360 degrees and concentrate that power in one direction.
This might be in the form of a Yagi antenna. They take the signal and direct a lot of the signal in one direction.
You still loose some to side and rear lobes, but you can get gains in the 6-18db range with about a 20 degree
beam width.
If higher gain is needed, you can use a dish antenna, something like a small satellite dish. They direct all most all
of the energy in one direction in a very tight beam width. Usually about 2 degrees with a gain of upwards of +32db.
As I said at the beginning, I have made distances of 80km with the correct antenna even with only +24dbm.
Systems gains would work something like this.
+24dbm (0.25watts) of actual RF power.
An antenna with the following gain would give you this:
+3db = 0.5watt ERP (ERP = Effective Radiated Power)
+6db = 1.0watt ERP
+9db = 2 watts ERP
+12db = 4 watts ERP
A 0.25watt transmitter with a +12db gain directional antenna will give you the effective power level of 4 watts.
Hope this helps you with understanding how you can obtain the 7Km range you need for your project.