Not good news, I am afraid.
I want to connect the gateway to my Airport Time Capsule by WiFi, so I can automatically back up my MacBook Air to it.
Unfortunately, the AirPort Time Capsule cannot connect to a third party network using a wireless connection......the AirPort Time Capsule must connect to the gateway using a permanent, wired Ethernet cable connection.
I would also like to have my Airport Extreme connected by WiFi as a network extender?
Likewise, the AirPort Extreme cannot connect to a third party wireless network using a wireless connection.
But....if you connected the AirPort Time Capsule to the gateway using a permanent, wired Ethernet cable connection, then.....you could configure the AirPort Time Capsule to extend the wireless from the gateway.......and......the AirPort Extreme could then be configured to extend the AirPort Time Capsule using a wireless only connection.
Here, I am assuming that you are planning to locate the AirPort Time Capsule at least a room or two away from the gateway......since it would not make sense to try to configure the AirPort Time Capsule to extend the gateway wireless if both the gateway and the Time Capsule are in the same room, or in close proximity to each other.