First thing to take into consideration is testing for shelf life in your current packaging. That will help you determine how long your cookies will remain fresh based on their unique ingredients and the primary packaging you use. Put it in and let it sit and check it after so many days, repeat until it no longer meets your freshness criteria. Without knowing what you are already doing I would recommend you use a 2 mil reclosable poly bag of the appropriate size for your cookies. Changing the cookie ingredients or primary packaging can extend the shelf life, especially moisture content. You should also search for info on "nitrogen flushing" which is the way that many snack food companies extend shelf life.
After you've solved your primary package/shelf life equation - you'll want to look into a corrugated box for ecommerce mail shipping. I think bubble mailers or shipping bags are going to result in a high rate of crushed or broken cookies during shipment so I don't recommend those for cookies.