Summarize:

Select a jar and fill it with one part half-and-half and one part creamer. How much you add depends on the size of the jar. Make sure to leave an inch of headspace at the top. For precise measurements, use a measuring cup. Measure out the cocoa and espresso powder. Add that to your half-and-half and creamer mixture. Close the lid tightly. Then, shake the jar for a few seconds. Keep shaking until everything is mixed evenly and the creamer is all the same color. You should let the creamer sit in the fridge for at least an hour before using it. It will last about as long as the expiration date of the milk and half-and-half. It's a good idea to write the approximate expiration date on the top of the mason jar with sharpie.
Add equal parts half-and-half and creamer to a jar. Add your flavors. Shake to mix. Chill before using.