Caja does not allow object or embed tags in HTML. However, a container may provide an JavaScript API for embedding flash on a page. A common library that provides this functionality is SWFObject. The Caja Playground provides a tamed version of the swfobject.embedSWF which you can use to embed flash objects which to not need to interact with scripts on the page.

For example, here is a YouTube video.

Loading...
You need Flash player 8+ and JavaScript enabled to view this video.

This works by creating a div where the Flash object will be placed. A tame version of SWFObject is exposed to the gadget which in turn uses the real SWFObject to add the flash in a cross-browser supported fashion. Some of the parameters maybe modified by the container before being passed to the real SWFObject. For example, the Caja Playground requires a minimum Flash version of 9 and does not allow script access to the page, inspite of what was requested by the gadget.

Other Caja containers (such as iGoogle or Orkut) may give you a different JavaScript API for embedding flash in your page and possibly allow your Flash object to interact with the rest of the page.